I'm making an rpg, so far everthing is working out fine except for one thing, Lag. I noticed that with hyper triggers the map moved at a 2 frames rate per minute (Little Exxagerated). So instead of having wait (0), I did, wait (500) miliseconds in my hyper trigger. It makes the triggers go faster and cuts some lag but its still unbareable. I friend said it was probably a trigger constatntly creating or giving or killing. I do have triggers that do that but all with hefty conditions, not constant. He also said it might be something with units. Even with out the Hyper Triggers it still lags a bit. Im getting frustrated because its a good map but nobody will want to play a laggy rpg. not worth it. You cant ban the lagger when its the map.
If you have any ideas...
mayb lots of sprites/units? umm..can u post map?
sprites and placed units can't lag a game. its only if alot of things are being done at the same time. like he said his friend thought it was a trigger creating and killing units thats my thought but thats more like a lag test not for rpgs.
Having a lot of sprits and a lot of units can lag the game. Try placing a lot of the same sprite in a map and see what happens.
I pretty sure that its not because of alot of units. It'd probably lag on Bill Gates Personal Computer. Or not.
Sprites do not lag the game in the slightest. Units, however, do, because you need a separate pathing script running for each unit in addition to base AIs.
no you know like in massing games that a good example of what we talking about kinda. when theres alot of units it lags.. but thats because the player is using the masser to make all his units move thats what lags the game i'm pretty sure its that
Hyper triggers don't speed up lag...its probably your computer. Do you have sounds on your map? That would definitely add to lag.
ok lag comes from to many things happening at the same time like moving units, sounds, creating units, killing units, bad/slow internet connection, a slow computer. Or it can simply be that your computer can't take starcraft which that would be pretty sad.
actually i have one of the best computers in the world, im rich.
Well its probally sc itself that makes the lag
like what i said in my last post except for the good/bad computer now
well one of my map it lagged becuase i make a trigger repeat so fast
accutally tell you the truth there is like only 2 reason why it will lag usally
1) to many units
2) trigger reapting itself like i mean like 3 trigger that repeat itself like over and over hella fast and sometime i gotta tell you, you dont even need hypertrigger...
becuase once one of my game lagged becuase of hypertrigger
and i still dont know why it did but games work fine without hypertrigger unless it really needs it...
QUOTE(ragnarokk @ Oct 23 2005, 01:07 PM)
I pretty sure that its not because of alot of units. It'd probably lag on Bill Gates Personal Computer. Or not.
[right][snapback]339640[/snapback][/right]
If it lags on his computer than it is definetly the game.
theres really no other reason
I think someone else needs to dl the map and see if it lags for them.
yes can u just post the map it would help alot
One thing I know for sure is that, it is because of units. When I deleted all the units, map didn't lag. Perhaps it has got something to do with its AI. If you run AI constantly then it may require huge amount of calculation. (This could be the reason why enemy units don't attack.) So look for the trigger that loops the AI such as Zerg Easy, Terran medium, Terran expansion custom, you know, something like that.
FYI, I'm ragnarokk's friend. And yes, I'm rich, too.

QUOTE(fishgold @ Oct 24 2005, 07:51 PM)
One thing I know for sure is that, it is because of units. When I deleted all the units, map didn't lag. Perhaps it has got something to do with its AI.
[right][snapback]340992[/snapback][/right]
Just because you delete all the units doesn't meant its the NUMBER of units. But if you have an AI running constantly on preserve...thats pretty stupid if you ask me. Don't you only need to run it once and it will keep going (the whole POINT of the AI script)?
are you kidding hyper triggers do lag the game up!! if you have a lot of "always", "action", "preserve trigger" and combined with hyper triggers, it lags up like hell. and make sure you use the non lagging hyper triggers. other factors are the number of units, sprites, and x2,x4 speed lags a lot too.
this probably isn't your problem but i made a map befor with "always" "turn share vision for player x" and then "preserve trigger" and it was very laggy.
2 triggers, better than 62wait(0). best if placed for 2 seperate players.
condtion:
switchX clear
action:
wait(0)
set switchX
wait(0)
condtion:
switchX set
action:
wait(0)
clear switchX
wait(0)
never seen that before does it really work?
A lot said already, my take:
- Over-use of Units cause lag.
- Unit actions scripting.
- Slow Computers.
- Slow internet connection.
- Sound (if over-done).
- Waits (if used improperly).
- TRANSMISSIONS!!! (They're freakin' evil, I never use 'em. Even with wait '0' and displaying only text, they still lag like hell if you use 'em with hyper triggs)
I don't think you can "put too many triggers" so that it doesn't read 'em fast enough. I think it's the ACTIONS that the triggers cause, may not be DONE fast enough (due to limits).
Would 'server lag' have anything to do with limitations? Battle.net, i know it's mainly peer to peer connections, but would Battle.net have server limitations?
QUOTE(Drakiel @ Oct 26 2005, 12:23 PM)
I don't think you can "put too many triggers" so that it doesn't read 'em fast enough. I think it's the ACTIONS that the triggers cause, may not be DONE fast enough (due to limits).[right][snapback]341919[/snapback][/right]
There is no limits on trigger numbers. Only trigger ACTIONS (64 for those who don't know). The amount of triggers have no affect on any lag. It is the amount of triggers processing at one time. I will still stick with my belief that you should not be preserving an AI script with tons of units on the map. One time is enough or at least give a wait in between script enabling.
Triggers are processed in order one at a time (one condition at a time and one action at a time).
QUOTE(LegacyWeapon @ Oct 27 2005, 12:59 PM)
Triggers are processed in order one at a time (one condition at a time and one action at a time).
[right][snapback]342609[/snapback][/right]
One condition and one action at a time WITHIN that trigger. You can have multiple triggers processing. If you couldn't, then when you do something like...lets say...center a screen somewhere constantly and then you did another trigger with a 10,000 milisecond wait...during that wait you wouldn't have center screen. But you do, so triggers can process at the same time, its the conditions and actions WITHIN that trigger that go one at a time.