• New Horizons on Maelstrom
    Maelstrom New Horizons


    Visit our website www.piratehorizons.com to quickly find download links for the newest versions of our New Horizons mods Beyond New Horizons and Maelstrom New Horizons!

Fixed Reduced Storm Chance

I think the weatherini shouldn't be called right? And probally you first need to delete the other weatherenvironment...
 
I copied these three lines from what appears to be the code that is called upon the hourly weather update:
Code:
  WeatherInit();
  CreateWeatherEnvironment();
  MoveWeatherToLayers(sNewExecuteLayer, sNewRealizeLayer);
Indeed perhaps you're right though that the weather must be removed first to ensure it is completely redone when called.
 
Deleting the weather before initializing it again just causes the game to crash again. So that doesn't work.
Am I really going to have to return the for loops? Doing that with weather updates just BEGS for game crashes so I REALLY don't want to.
 
This seems to be the best it can be:
Code:
    pchar.skipWeatherLogs = true;
     if(Whr_IsStorm())
     {
       LogIt("By the power of Neptune, I command this storm to end!");
       while(Whr_IsStorm())
       {
         SetNextWind(-1, 20);
         CreateWeatherEnvironment();
         MoveWeatherToLayers(sNewExecuteLayer, sNewRealizeLayer);
       }
       iStormLockSeconds = 0;
     }
     else
     {
       LogIt("I call upon the sea godess Calypso to bring a storm onto my foes!");
       while(!Whr_IsStorm())
       {
         SetNextWeather("Heavy Storm");
         CreateWeatherEnvironment();
         MoveWeatherToLayers(sNewExecuteLayer, sNewRealizeLayer);
       }
     }
     DeleteAttribute(PChar, "skipWeatherLogs");

     x = stf(pchar.Ship.pos.x);
     y = stf(pchar.Ship.pos.y);
     z = stf(pchar.Ship.pos.z);

     for(i = 0; i < 100; i++)
     {
       CreateParticleSystemX("cancloud_stock", x+rand(40)-20  , y+rand(15)+3, z+rand(40)-20  , x, y, z,20);
       CreateParticleSystemX("cancloud"  , x+rand(60)-30  , y+rand(20)+3, z+rand(60)-30  , x, y, z,20);
     }
     PlaySound("objects\DUEL\lightning.wav");
No unnecessary code and it works every time. And even if I execute it a a whole bunch of times within a second, the game doesn't crash on me.
Sure the performance gets all crappy for a while, but that was to be expected with the overkill of particle effects.

So I'll consider this "Fixed" for real now.
 
will try to test it ingame later.
 
I've been unable to break it myself. Hopefully other people will try and confirm that it is a stable feature. :doff
 
I still find it odd you call on calypso with neptunes weapon. Why not call on neptue himself?
 
Supposed Pirates of the Caribbean: Dead Men Tell No Tales (2017) plot description:
Thrust into an all-new adventure, a down-on-his-luck Captain Jack Sparrow finds the winds of ill-fortune blowing even more strongly when deadly ghost pirates led by his old nemesis, the terrifying Captain Salazar, escape from the Devil's Triangle, determined to kill every pirate at sea... including him. Captain Jack's only hope of survival lies in seeking out the legendary Trident of Poseidon, a powerful artifact that bestows upon its possessor total control over the seas.
Source: http://www.imdb.com/title/tt1790809/?ref_=nv_sr_1

I've got to wonder where the person who wrote that got the inspiration from?
If this is true, I totally expect "cursed albatrosses" to be the subject of the 6th film.
And to complete the trilogy, a final film is to feature Clint Eastwood carrying a Pump Shotgun. It'll be the "New Horizons: Easter Eggs" film trilogy! :razz

Yep, I post that in this thread on purpose.... :rolleyes:[/QUOTE]
 
Back
Top