• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Spell] How to make a harmful, always-on ground AoE?

Status
Not open for further replies.
Level 1
Joined
Feb 7, 2020
Messages
4
Heyo. I'm very new (~2 days of exp) to the WC3 editor. I'm no stranger to coding, and understand basic things like triggers, spell customization, regions, etc., but am clearly missing a few key points unique to the WC3 engine. Was wondering, how could I make... say, a bale of hay catch fire, and have it consistently damage units in range of it?

This is what I have set up right now; a simple region surrounding a fire doodad. The unit steps inside, and takes 5 damage.

UDFfsCP.png


It works, and the unit takes damage. Problem here, is that I'm struggling to make this loop until the unit leaves the trigger. Right now, the unit is ticked for damage a single time, nothing further.

0gineAJ.png


Like sure, this makes it loop, but then I just keep taking damage forever, even after I leave the region. How could I go about turning a loop like this off? Could I have it check to see if the unit is inside of a region, and have it only function if that returns true?

Ty!
 
Level 45
Joined
Feb 27, 2007
Messages
5,578
Welcome to the world of wc3 mapmaking! In general you would want to use a “Time - Periodic Event” to execute your trigger. Pick units in range of the hay bales and cause the bales to damage any units found in their radius.

This, however, is not the simplest solution; often it’s possible to achieve what a trigger would by cleverly using the object editor. In this case you want to make use of the Permanent Immolation ability, which functions exactly as you intend here. Change its targets allowed to hit the appropriate units as well as art/model, buff fields. When a hay bale is lit, simply give it this ability. When it’s extinguished, remove the ability.
 
Level 1
Joined
Feb 7, 2020
Messages
4
Thank you.

That's undoubtedly a more graceful solution than what I had whipped up. I'll share the trainwreck I created so that all who gaze upon this thread shall know of my ability to create spaghetti code.

Two triggers: 1,
4dUxRTt.png

and 2.
tNFMvcu.png

It works as intended, somehow, but I don't think anyone would recommend using it...

I'll go ahead and give what you suggested a shot. Thank you very much.
 
Status
Not open for further replies.
Top