• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

"Trigger - add the event" problem (GUI)

Status
Not open for further replies.
Level 4
Joined
Jun 19, 2010
Messages
113
  • Trigger - Add to DamageHeal <gen> the event (Unit - (Triggering unit) Takes damage)
at begining trigger looks like this:
trigger
event
condition
action
<actions>

later

trigger
event
unit recieve damage
condition
action
<actions>
(runs 1 time)

later

trigger
event
unit recieve damage
unit recieve damage
unit recieve damage
unit recieve damage
unit recieve damage
unit recieve damage
unit recieve damage
condition
action
<actions>
(runs freaking many times)

and so on.


i need action that would clear trigger from those events.
for rep ofc
 
Level 11
Joined
Jan 25, 2009
Messages
572
Well you can prevent from adding the same unit over and over again to the event.
Just going to open WE. Just a sec =)

Here you have it =)

  • Trigger 1
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) is in Eventgroup) Equal to False
        • Then - Actions
          • Trigger - Add to Trigger 2 <gen> the event (Unit - (Triggering unit) Takes damage)
          • Unit Group - Add (Triggering unit) to Eventgroup
        • Else - Actions
 
Level 4
Joined
Jun 19, 2010
Messages
113
yeah, i tryed some thing like this
this prevent trigger to spam events with same unit

but main problem not gone. it s not 10, or 100 units in map, there is much more :D

and... 100+ events in one trigger, that runs on every attack... dunno, will it cause lag or not, but it sounds very... ugly.

anyway, it's does not matter, i already found a workaround
thank to ya, guys.
 
Level 11
Joined
Jan 25, 2009
Messages
572
Nope it wont cause lagg because it checks throught the list of the event until it finds the right one. It WILL cause lag after a while, or maybe bug/crash, because you add meaby like 20 events of the same unit. It may heal 20 times over or something if you use this for an heal stuff.
 
Status
Not open for further replies.
Top