- Joined
- May 19, 2009
- Messages
- 5
Good Tutorial !
Maybe in Vampirism Fire units are removed in a different way? I don't know, there are tons of ways to remove a unit and non of them differs much visually.
They are not removed on a different way 99% shure....and i dont have any revive deat ability< so it will not cause any problems
![]()
Great...i will remove units and i dont have to worry about triggers with event - unit diesWell, Unit - Remove unit doesn't leak for sure, I was just saying there are reports on that. Then do what you want.
Wouldnt a variable instead of Random Unit stop the leak?
that sucks....i need to do it like this?It has to go before groups are used. And it doesn't stack, so you need another one before the next time you use a group.
that sucks....i need to do it like this?,for every group
(i have 32 triggers 0_o and they will need this...
)
are that leaks really so inportant?Would it work that i make trigger that destroys groups every time units is attacked,i think not...
want to destroy group
-if conditions.....
want to destroy group
-if conditions.....
want to destroy group
-if conditions.....
You would need to do that each time, tough luck
Yeah, leaks are that important, ffs!!! Leaks cleaning is one of the most important things in a map! How would you feel if you make a killer map that has great effects and stuff, but it crashes after 5 minutes every time you try to play the map??
I'll tell you how you'd feel, you would feel like shit.
Yeah but i never saw my map lagging when i wasn´t fixing leaks .....
is it better to set the group and after the action destroy it or its the same with "Custom script: set bj_wantDestroyGroup = true"?
if you have "Custom script: set bj_wantDestroyGroup = true" do you need to destroy the group every time iven if it is not changed?
Stop asking questions already![]()
gle zbilja........because you are not logged in?
gle zbilja........
So when i answer i must not klick the "Back" button,damn i have to work so hard( NOOB question BTW...)
Of course it has nothing to do with leKs....Arghh that has nothing to do with leaks.
Wtf croatian?
I think you need to set entering unit with a variable when you use waits but you must not change the veriable before 0.5 secdo waits create leak?
im pretty sure this trigger is leaking since it's causing the lag
Skip Player1
Events
Unit - A unit enters Move1 <gen>
Conditions
Actions
Wait 0.50 seconds
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Number of units in (Units in (Playable map area) matching (((Unit-type of (Matching unit)) Equal to Control Tower) and ((Owner of (Matching unit)) Equal to Player 1 (Red))))) Equal to 0
Then - Actions
Set Start = (Random point in Start2 <gen>)
Unit - Move (Triggering unit) instantly to Start
Custom script: call RemoveLocation(udg_Start)
Else - Actions
(Line: 16) (Word: 3) Special Effect Leak
Special Effect - Create a special effect at TempLoc[19] using Abilities\Spells\Other\Stampede\StampedeMissileDeath.mdl
Special Effect - ^Leak
(Line: 24) (Word: 3) Special Effect Leak
Special Effect - Create a special effect at TempLoc[19] using Abilities\Spells\Other\Stampede\StampedeMissileDeath.mdl
Special Effect - ^Leak
Scan Complete
Location leaks: 0
Special Effect leaks: 2
Lightning leaks: 0
Unit Group leaks: 0
Player Group leaks: 0
Variables
TempLoc[19] : (Line: 7) Location - Removed: Yes
Summary
Total Leaks: 2
Unremoved Variables: 0
Scan duration: 0 seconds
Total Lines Scanned: 30
Total Words Scanned: 189
(Line: 15) (Word: 3) Player Group Leak
Set TempPGroup[2] = (Player group((Triggering player)))
Set TempPGroup[2] = ^Leak
Scan Complete
Location leaks: 0
Special Effect leaks: 0
Lightning leaks: 0
Unit Group leaks: 0
Player Group leaks: 1
Variables
TempGroup[6] : (Line: 16) Unit Group - Removed: Yes
Summary
Total Leaks: 1
Unremoved Variables: 0
Scan duration: 0 seconds
Total Lines Scanned: 28
Total Words Scanned: 246
Fixing Memory Leaks: http://world-editor-tutorials.thehelper.net/cat_usersubmit.php?view=27219
actually leak checker is correct
you are leaking here Player group((Triggering player)
that function creates a player group from triggering player and you store the player group created into a variable, but then you destroy the variable but not the first player group created... instead of that you should do it this way
add triggering player to TempPGroup[2]
and then you can destroy it safely![]()
function GetForceOfPlayer takes player whichPlayer returns force
local force f = CreateForce()
call ForceAddPlayer(f, whichPlayer)
return f
endfunction
the jass function for this "(Player group((Triggering player)))" isnt creating a player group?
something like this
JASS:function GetForceOfPlayer takes player whichPlayer returns force local force f = CreateForce() call ForceAddPlayer(f, whichPlayer) return f endfunction
function GetForceOfPlayer takes player whichPlayer returns force
local force f = CreateForce()
call ForceAddPlayer(f, whichPlayer)
return f
endfunction