HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Game gets super laggy

08-20-2005, 08:26 PM#1
MrApples
About 20 minutes into the game its about no longer playable due to the lag.
Only thing it can be is memory leaks I suppose.

Can any of these be the problem?

TRIGGERS
Quote:
Info
Events
Map initialization
Actions
Creates 4 Quests
Quote:
Messages
Events
Time - Elapsed game time is 5.00 seconds
Actions
Game - Display to TempPlayerGroup for 60.00 seconds the text: |cff32cd32Clan FnHr...
Custom script: call DestroyTrigger(GetTriggeringTrigger())
Quote:
Melee Initialization
Events
Map initialization
Actions
Melee Game - Use melee time of day (for all players)
Melee Game - Give trained Heroes a Scroll of Town Portal (for
Melee Game - Limit Heroes to 1 per Hero-type (for all players)
Melee Game - Set starting resources (for all players)
Melee Game - Remove creeps and critters from used start
Melee Game - Create starting units (for all players)
Melee Game - Run melee AI scripts (for computer players)
Melee Game - Enforce victory/defeat conditions (for all
Custom script: call DestroyTrigger(GetTriggeringTrigger())
Quote:
Bounty
Events
Map initialization
Actions
Player Group - Pick every player in (All players) and do (Player - Turn Gives bounty On for (Picked player))
Custom script: call DestroyTrigger(GetTriggeringTrigger())
Quote:
Battle Experience
Events
Unit - A unit Dies
Conditions
((Owner of (Killing unit)) is an enemy of (Owner of (Dying unit))) Equal to True
Actions
Unit - Increase Level of Battle Experience Army for (Killing unit)

Quote:
Battle Upgrade
Events
Unit - A unit enters (Playable map area)
Conditions
Actions
Unit - Set Level of Battle Experience Army for (Entering unit) to ((Current research level of War Training for (Owner of (Entering unit))) + (Level of Battle Experience Army for (Entering unit)))
Quote:
Smart Ally
Events
Unit - A unit Is attacked
Conditions
((Owner of (Attacked unit)) is an ally of (Owner of (Attacking unit))) Equal to True
((Owner of (Attacking unit)) is an ally of (Owner of (Attacked unit))) Equal to True
((Attacked unit) is in (Units owned by (Owner of (Attacking unit)))) Equal to False
Actions
Game - Display to (Player group((Owner of (Attacking unit)))) for 30.00 seconds the text: ((SMART ALLY: + (Name of (Owner of (Attacking unit)))) + has attacked you thus declaring war.)
Game - Display to (Player group((Owner of (Attacked unit)))) for 30.00 seconds the text: ((SMART ALLY: You have attacked a unit owned by + (Name of (Owner of (Attacked unit)))) + thus declaring war.)
Player - Make (Owner of (Attacking unit)) treat (Owner of (Attacked unit)) as an Enemy
Trigger - Run Smart Ally On <gen> (ignoring conditions)
Trigger - Turn off (This trigger)

Quote:
Smart Ally On
Events
Conditions
Actions
Wait 0.10 seconds
Trigger - Turn on Smart Ally <gen>
08-20-2005, 11:28 PM#2
Vexorian
Player group (a player) creates a player group each time it is called, you should Destroy that force with DestroyForce

((Attacked unit) is in (Units owned by (Owner of (Attacking unit)))) Equal to False

Completelly senseless statements that leaks a unit group.

Shouldn't you use Owner of attacked unit equal to owner of attacking unit?

Anyways a player is considered an ally of himself btw
08-22-2005, 01:23 AM#3
MrApples
EDIT, This post was meant for another
08-25-2005, 02:53 PM#4
Kalvorod
Oh, so calling "Pick every unit in(unit group(units owned by (player 12))))

That will create a memory leak if I don't destroy it?

I never knew that. Ok cool, my map doesn't suffer from memory leaks that badly, but after a while you can sence that it's not as great as it was before.

EDIT: Please contact the guy who made Maze Creator and tell him this (after about 20 minite, or the time it takes to make the maze, the game lags so bad you can't win most mazes, so everyone quits. Otherwise it's not a bad map)