• 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.

Mega lag problem

Status
Not open for further replies.
Level 18
Joined
May 11, 2012
Messages
2,108
Ok, so I created spell based on shadow strike.
I created A buff that goes with that spell.

Now, when I order dummy unit to cast that spell onto an enemy unit, it LAGS HORRIBLYYYYYYYYYYY!
I put debug message, and it casts only once, no infinite loop.

Here's the trigger
  • Morrowind
    • Events
      • Game - damageEventTrigger becomes Equal to 1.00
    • Conditions
      • (target is A structure) Not equal to True
      • ((Item carried by target of type Morrowind) is owned) Equal to True
      • (target belongs to an enemy of (Owner of source)) Equal to True
      • (target has buff Slowed (Morrowind Chill)) Not equal to True
      • (source is Magic Immune) Equal to False
    • Actions
      • Set TempPoint = (Position of source)
      • Unit - Create 1 Dummy Caster for (Owner of target) at TempPoint facing Default building facing degrees
      • Unit - Add Morrowind Chill to (Last created unit)
      • Unit - Order (Last created unit) to Night Elf Warden - Shadow Strike source
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Custom script: set udg_TempPoint = null
What the hell is the problem?
 
Level 18
Joined
May 11, 2012
Messages
2,108
When you order your conditions in single block like this, it reads them as AND, so all of them must be positive for the trigger to fire.

The "And" check you use only inside "Or Any Conditions are true".

Like here:
If
Or any conditions are true
----== Your conditions here ==
----== Your conditions here ==
----== Your conditions here ==
----== Your conditions here ==
----And all conditions are true
-----------== Your conditions here ==
-----------== Your conditions here ==
-----------== Your conditions here ==
----== Your conditions here ==
----== Your conditions here ==

then
 
Status
Not open for further replies.
Top