Staredit Network > Forums > SC1 UMS Mapmaking Assistance > Topic: Why does my map lag?
Why does my map lag?
Feb 19 2008, 2:01 am
By: mAdnAyze  

Feb 19 2008, 2:01 am mAdnAyze Post #1



Ive recently been working on 2 maps. One is big, the other is small. They both lag in multiplayer. The only thing I know that causes lag is if the map has tons of units on it or if its 255 by 255 or w/e. One of my maps is big and does have a lot of units but Ive constantly been trying to cut down on the number of units there are. And every time I play the big map, it goes "Cannot Create More Units" atleast once. What is the MAX number of units allowed?? And is there any other reasons why it might lag? Its kinda like a DOTA map where there are a lot of constant spawns.

My 2nd map is a small map. I have 2 suspicions of why it lags. Its a map that uses constant mobile grids for each player. It seems to lag when theres +2 ppl in the game. 2nd suspicion is that each player has a Wait running all the time. Otherwise im confused.

Just if anyone could give me a list of reasons why maps lag that would be good, these 2 maps im making im pushing my knowledge and skills to somewhat of a limit so I wouldnt be surprised if I ran into some brick walls.



None.

Feb 19 2008, 3:02 am Falkoner Post #2



The unit max is 1700, a 256x256 is not going to cause lag, they just tend to since they can fit more at once on them. If you are hitting that limit, then that is definitely the reason why it is lagging. Lots of units moving close together causes lag.

In the second map, a wait will not cause lag, unless you are talking about wait blocks, but that isn't lag. Mobile grids could cause lag, but if done correctly, they don't. Just set up the grid everytime the player moves, instead of constantly.



None.

Feb 19 2008, 8:31 am y10k Post #3



Hypertriggers tend to make game laggy in multiplayer games.
Once in my map i put HT in and the game was so unplayable i removed it. Game was smooth again.



None.

Feb 19 2008, 10:08 am NudeRaider Post #4

We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch

Yeah but that's because every trigger runs 16x more often than usual.

If you got many triggers that always alter units (create, move, order, set hp, etc.) they will weigh 16 times heavier.




Feb 19 2008, 5:29 pm mAdnAyze Post #5



so what if my whole idea for the game revolves around a constant grid system for each player, is there anyway other way to reduce lag? Well, sometimes its constant. Players have the ability increase the delay (Wait) between each grid check. So for example one player might have their grid fire every 500 milliseconds while another player has his fireing every 10 millesconds, and are also able to have no Wait at all (constant fire).

Any other ways to reduce lag besides taking away constant grid firing?



None.

Feb 19 2008, 5:41 pm NudeRaider Post #6

We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch

I think it makes a significant difference if the units are created "with properties" or not when using a grid.
Btw. you can only make delays in increments of 84ms. Every other value is rounded.

I posted a few actions that are lag intense.
If nothing of them is executed often or always then you might find other reasons in THIS topic @ maplantis.
I think all reasons for lag are covered there.




Feb 19 2008, 5:57 pm Falkoner Post #7



Not 84 increments, 42. Now, why would you ever need to have the grid be constant?



None.

Feb 19 2008, 7:16 pm NudeRaider Post #8

We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch

Quote from Falkoner
Not 84 increments, 42. Now, why would you ever need to have the grid be constant?
proof?

Ofc 0-41ms = 0ms,
but 42-125ms = 84ms, 126-209ms = 164ms, etc.




Feb 19 2008, 10:37 pm Falkoner Post #9



Quote
proof?

I just ran 2 different test maps, one with wait 85, and one with wait 84, at the end of 1000 in-game seconds, the 85 millisecond one had ran 4004 trigger loops, and the 84 milliseconds had run 5338 trigger loops. Proof enough?

Therefore:
Quote
0-41ms = 0ms
True.

Quote
42-125ms = 84ms, 126-209ms = 164ms, etc.
False.



None.

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[06:47 am]
NudeRaider -- lil-Inferno
lil-Inferno shouted: nah
strong
[05:41 am]
Ultraviolet -- 🤔 so inf is in you?
[04:57 am]
O)FaRTy1billion[MM] -- my name is mud
[04:35 am]
Ultraviolet -- mud, meet my friend, the stick
[2024-5-16. : 10:07 pm]
lil-Inferno -- nah
[2024-5-16. : 8:36 pm]
Ultraviolet -- Inf, we've got a job for you. ASUS has been very naughty and we need our lil guy to go do their mom's to teach them if they fuck around, they gon' find out
[2024-5-16. : 5:25 pm]
NudeRaider -- there he is, right on time! Go UV! :D
[2024-5-16. : 5:24 pm]
lil-Inferno -- poopoo
[2024-5-16. : 5:14 pm]
UndeadStar -- I wonder if that's what happened to me. A returned product (screen) was "officially lost" for a while before being found and refunded. Maybe it would have remained "lost" if I didn't communicate?
[2024-5-16. : 3:36 pm]
NudeRaider -- :lol:
Please log in to shout.


Members Online: 8jasminee7622eL4, Roy, Sylph-Of-Space, 2milae1222tN7