feelingparty
New Member
- Reaction score
- 3
So something's wrong with my map because whenever there are more units on the screen there is a major drop-down in fps. There are some leaks that need clearing but that (i think) is not the case as the laggs are there from the beginning itself. For example I have this spell that shoots an arrow and a fiery dummy unit that i use for the effect. And everything works fine except that when I cast it my fps goes down from 63 to 18 until the arrow and the effect are dead then it goes up again. Any thoughts? Here is the movement trigger :
And here is the other trigger (even though i think the problem is in the upper)
Trigger:
- Move Proj
- Events
- Time - Every 0.02 seconds of game time
- Conditions
- Actions
- Unit Group - Pick every unit in Arrows and do (Actions)
- Loop - Actions
- Set Temp_Point = (Position of (Picked unit))
- Set Temp_Point2 = (Temp_Point offset by (Load 3 of (Key (Picked unit)) from hasharrows) towards (Load 4 of (Key (Picked unit)) from hasharrows) degrees)
- Set Temp_Group = (Units within 70.00 of Temp_Point)
- Unit Group - Pick every unit in Temp_Group and do (Actions)
- Loop - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- (Unit-type of (Picked unit)) Not equal to FieldDummy
- (Unit-type of (Picked unit)) Not equal to FlamingArrow
- ((Picked unit) is dead) Equal to False
- Then - Actions
- Set unit = (Picked unit)
- Else - Actions
- If - Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Loop - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- (Load 2 of (Key (Picked unit)) from hasharrows) Greater than or equal to 0.00
- ((Picked unit) is alive) Equal to True
- unit Equal to No unit
- Then - Actions
- Unit - Move (Picked unit) instantly to Temp_Point2
- Hashtable - Save ((Load 2 of (Key (Picked unit)) from hasharrows) - (Load 3 of (Key (Picked unit)) from hasharrows)) as 2 of (Key (Picked unit)) in hasharrows
- Else - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- Or - Any (Conditions) are true
- Conditions
- (Unit-type of (Picked unit)) Equal to FieldDummy
- (Unit-type of (Picked unit)) Equal to FlamingArrow
- Conditions
- Or - Any (Conditions) are true
- Then - Actions
- Unit - Cause (Picked unit) to damage unit, dealing (Load 5 of (Key (Picked unit)) from hasharrows) damage of attack type Spells and damage type Normal
- Unit - Remove (Picked unit) from the game
- Else - Actions
- Unit - Remove (Picked unit) from the game
- If - Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- Set unit = No unit
- Custom script: call RemoveLocation (udg_Temp_Point)
- Custom script: call RemoveLocation (udg_Temp_Point2)
- Custom script: call DestroyGroup (udg_Temp_Group)
- Loop - Actions
- Unit Group - Pick every unit in Arrows and do (Actions)
- Events
And here is the other trigger (even though i think the problem is in the upper)
Trigger:
- Arrow Fire
- Events
- Unit - A unit Starts the effect of an ability
- Conditions
- Or - Any (Conditions) are true
- Conditions
- (Ability being cast) Equal to Shoot Flaming Arrow
- (Ability being cast) Equal to Fletch Arrow
- (Ability being cast) Equal to Shoot Flaming Arrow 2
- Conditions
- Or - Any (Conditions) are true
- Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- (Ability being cast) Equal to Shoot Flaming Arrow 2
- Then - Actions
- Unit - Create 1 FlamingArrow for (Triggering player) at ((Position of (Triggering unit)) offset by 100.00 towards (Angle from (Position of (Triggering unit)) to (Target point of ability being cast)) degrees) facing (Angle from (Position of (Triggering unit)) to (Target point of ability being cast)) degrees
- Special Effect - Create a special effect attached to the overhead of (Last created unit) using Abilities\Spells\Other\BreathOfFire\BreathOfFireDamage.mdl
- Hashtable - Save (Angle from (Position of (Triggering unit)) to (Target point of ability being cast)) as 4 of (Key (Last created unit)) in hasharrows
- Hashtable - Save ATRIBspeed[(Player number of (Triggering player))] as 3 of (Key (Last created unit)) in hasharrows
- Hashtable - Save ATRIBdistance[(Player number of (Triggering player))] as 2 of (Key (Last created unit)) in hasharrows
- Hashtable - Save (ATRIBattack[(Player number of (Triggering player))] x ATRIBattMultip[(Player number of (Triggering player))]) as 5 of (Key (Last created unit)) in hasharrows
- Unit Group - Add (Last created unit) to Arrows
- Unit - Create 1 FlamingArrowFX for (Triggering player) at ((Position of (Triggering unit)) offset by 100.00 towards (Angle from (Position of (Triggering unit)) to (Target point of ability being cast)) degrees) facing (Angle from (Position of (Triggering unit)) to (Target point of ability being cast)) degrees
- Hashtable - Save (Angle from (Position of (Triggering unit)) to (Target point of ability being cast)) as 4 of (Key (Last created unit)) in hasharrows
- Hashtable - Save ATRIBspeed[(Player number of (Triggering player))] as 3 of (Key (Last created unit)) in hasharrows
- Hashtable - Save ATRIBdistance[(Player number of (Triggering player))] as 2 of (Key (Last created unit)) in hasharrows
- Hashtable - Save (ATRIBattack[(Player number of (Triggering player))] x ATRIBattMultip[(Player number of (Triggering player))]) as 5 of (Key (Last created unit)) in hasharrows
- Unit Group - Add (Last created unit) to Arrows
- Else - Actions
- If - Conditions
- Sound - Play ArrowAttack1 <gen> at 100.00% volume, attached to (Triggering unit)
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Events