• 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.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

Trigger: Special Effects that Deals Damage

Status
Not open for further replies.

GgS15

G

GgS15

----------------------------------------------------------------------------

Anyone knows how a special effect created in a random point in the map can damage a unit on its position or vicinity.

Please let me know about the trigger or your idea about it. I don't seem to figure it out correctly. You will be credited in any map that I will use it for. Thank You!

----------------------------------------------------------------------------

:vw_wtf:
 
There are two forums: https://www.hiveworkshop.com/forums/world-editor-help-zone-98/ and https://www.hiveworkshop.com/forums/triggers-scripts-269/ to post these things. Site Discussion is irrelevant :p

As for the trigger
  • Actions
    • Set Point = (Random point in (Playable map area))
    • Special Effect - Create a special effect at Point using Abilities\Spells\Demon\RainOfFire\RainOfFireTarget.mdl
    • Special Effect - Destroy (Last created special effect)
    • Custom script: set bj_wantDestroyGroup = true
    • Unit Group - Pick every unit in (Units within 150.00 of Point) and do (Actions)
      • Loop - Actions
        • Unit - Cause (Picked unit) to damage (Picked unit), dealing 25.00 damage of attack type Normal and damage type Normal
    • Custom script: call RemoveLocation (udg_Point)
 
ahh, sorry for that...

but i'll try this one, thanks...
...and i'll see if it works with periodically timed events...:thumbs_up:
 
the last block had an error...why?

what does those custom scripts mean anyway?...
 
It's dependent on the variable's name, my sample variable is called "Point", if you named it for example "Location1278", it would be
  • Custom script: call RemoveLocation (udg_Location1278)
Understanding the variables: https://www.hiveworkshop.com/forums/trigger-gui-editor-tutorials-279/variables-5896/

Custom scripts allow GUI to communicate with Jass. As for the use of the specific function, the RemoveLocation() one, https://www.hiveworkshop.com/forums/triggers-scripts-269/things-leak-35124/.
set bj_wantDestroyGroup is a boolean that will clean the memory leak, created by the very next allocated unit group.
 
yes, i used the variable 'Point' (the type is a 'point' to)...still, it wont work...
 
no i just entered "call RemoveLocation (udg_Point)" on the custom script...

but I've already solved my problem thanks to you...

I didn't use custom scripts, I've removed them & i just changed the "Unit - Cause (Picked unit) to damage (Picked unit)..." line with another action (i cant remember, its the one next to it in the Action dialog and it worked).

The result, a special effect(flame strike) is created at a random point in every 0.1 secs and it damages the unit or destructible in its vicinity.

THANKS for YOUR help with the triggers!
 
Status
Not open for further replies.
Back
Top