- Joined
- Dec 15, 2013
- Messages
- 4
Apologies in advance for covering yet another topic that's probably been beaten to death, but after two days of searching, I still seem to be coming up blank, so if if this has been covered previously then apologies in advance.
In terms of expected outcome for the trigger or script, what I'm looking for is a very slow and gradual tree regrowth script over time for an altered melee-style map. Rather then using scripts that revive fallen trees after a set period, I want the script to check for dead trees in the region and revive them randomly every x amount of seconds. For that purpose I've cobbled together a really rudimentary script for now that needs some serious polishing.
As you can see, the trigger is...really long for what I would think is a fairly straightforward trigger and is probable a lot more complicated then it needs to be, so I'd like some help in streamlining it. A few extra considerations - the map is huge, and has an absolute ton of tree in the landscape, so I'd like to avoid anything that relies on logging the number of killed destructibles or anything that could potentially cause memory problems if the number of values stored increases memory usage. If a single global region is too much then smaller regions with staggered trigger times (ie all regions fire every 30 seconds, but region 2's trigger fires 5 seconds after region 1 and so forth) is a possible workaround to reduce trigger-related shudders in-game. I'm very open to suggestions.
Another factor I'd like to look into concerns blighted trees. If at all possible, I'd like to add in some sort of mechanic whereupon a blighted tree does not revive under this global trigger. I can live without this extra function, but I figured I would ask.
I'm open to using JASS, as I can read it, but I'm not all that adept at writing it, and in all honesty this is the first time I've cracked open the World Editor in a few years, so I've probably forgotten most of what I used to know.
Anyway, thanks for hearing me out, and a BIG thanks in advance to anyone who can help me out with this script!
In terms of expected outcome for the trigger or script, what I'm looking for is a very slow and gradual tree regrowth script over time for an altered melee-style map. Rather then using scripts that revive fallen trees after a set period, I want the script to check for dead trees in the region and revive them randomly every x amount of seconds. For that purpose I've cobbled together a really rudimentary script for now that needs some serious polishing.
- Events
- -Time - Every 30.00 seconds of game time
- Actions
- -Destructible - Resurrect (Random destructible in (Entire map) Matching (((Destructible-type of (Matching Destructible)) Equal to (==) Summer Tree Wall) and ((Current life of (Matching Destructible)) Less than or equal to (<= 0.00) with 120.00 life and Show birth animation
Another factor I'd like to look into concerns blighted trees. If at all possible, I'd like to add in some sort of mechanic whereupon a blighted tree does not revive under this global trigger. I can live without this extra function, but I figured I would ask.
I'm open to using JASS, as I can read it, but I'm not all that adept at writing it, and in all honesty this is the first time I've cracked open the World Editor in a few years, so I've probably forgotten most of what I used to know.
Anyway, thanks for hearing me out, and a BIG thanks in advance to anyone who can help me out with this script!
Last edited: