I started making an arcade map and tried testing it online. So far the only people who have helped me test it have told me they couldn't see anything (Despite them having units on the map) and that they had slow frames per second when they were near the edge of the map.
The odd thing is that I haven't done much things on the map itself, at this rate the map won't be able to run at all if I finish the whole thing.
Is it normal for an arcade map to lag with very few units in it? Should I post it so you guys can open it in the editor and judge for yourselves? I really want to address this issue before I continue further in working on it.
So far the most complicated things I have added are triggers for spawning units and added around 7 custom units (Basically resized units which already exist).
Two things cause lag in general;
Lots of units
Poor triggering
If you have few units, then the problem is very likely due to your triggers. I think that's about as much help as anyone can give without seeing your map.
There are some other probable causes, but generally they aren't as prevalent as the above 2.
and that they had slow frames per second when they were near the edge of the map.
From your description it does not sound like a script problem but that something is wrong with your terrain.
Do you use alot of doodads on the edges of the map? Water? Lots of lighting? etc.
Overall your description is way to vague to offer any sort of competent help.
@Mille25, I actually have around 60 doodads around the center of the map (None at the edges), 1 lighting, and around 30 squares of water.
__
I have read your replies, thanks for the advice. Whenever I playtest the map in the editor, no problems show up.
I feel that the possible problem might be in the triggers (Specifically the periodic events being too short).
Since I want to make sure what the problem is (If there is any) I'd like to ask you to check the map if you have the time (I worked hard on it but there is not much content to analyze).
I'd try to playtest it online a few more times, but finding people in chats willing to help me fill the player 2 spot is really hard.
i cannot correctly open the map due to hots depencies but from what i see i would say it's the terrain. pathfinding isn't easy and yolu have lots of different layers.
using the "painting" i would try to avoid difficult geometrical objects, just plain and straight rectangles ( you have quite complex ones)
i cannot correctly open the map due to hots depencies but from what i see i would say it's the terrain. pathfinding isn't easy and yolu have lots of different layers. using the "painting" i would try to avoid difficult geometrical objects, just plain and straight rectangles ( you have quite complex ones)
I actually do have a lot of paths in the map. The reason why I have a lot of them is that I wanted to make a layout I could follow when making the terrain so I know where a corridor continues and where there are walls (Yellow paths for low ground and blue paths for high ground as well as green paths for starting areas.
They are basically placeholders so I don't make a mistake in the terrain in the future when I get around to editing the terrain (If that is the case I can remove a major portion of it while I'm still working on it). So should I remove these placeholder paths?
I also have a consistent perimeter of red pathing (No walking on it) around the whole map about 16 units wide (To avoid having a player wander off the map), would that be the reason why my map might be reducing frame rate around the edges? (That would make sense if it is true since it is the only thing I have on the edges) Would having downward/upward cliffs around the edges be less laggy or would those lag the map too?
I actually feel the map is pretty small for what I want, can't imagine working with anything smaller than that (Is 256 X 256 too large for a lag free map?, that would stink if its true XD).
my bet is still pathfinding :d and since it makes sense (somehow) you could give it a try. if i were you i would copy the map, remove pathing and test it again
"Only register for this event when you absolutely need it, as it will generate network traffic from all players for every button they press. This event fires when a player presses the specified key. Use "Key Pressed" to get the key that was pressed. Use "Alt Key Pressed", "Control Key Pressed", and "Shift Key Pressed" to find out what modifier keys were pressed."
you should avoid using "while"-conditions as much as possible. use it only when you are sure the conditions to break the actions are soon to be met, and use wait inbetween the whiles. while fires many, many times per second if you don't use wait. try using "repeat" or "if" instead or other solutions.
Thanks for the suggestions, I did what you recommended and it seems the map doesn't lag horribly right now (Hopefully it will stay that way).
But now I have a problem that is just as important.
My map has a custom ability called "GatherFood", which units use to "Eat" meat units and red berry bush units.
For some RANDOM reason I can see the ability button, BUT NO ONE ELSE CAN.
I have done tests and found out that it is not the host who can see buttons, but me specifically. If I play as the host only I can see the ability button, if I don't play as host, I am still the only player who can see the button for the "GatherFood" ability.
I really need to have the players see the button (So that they may toggle it for autocast). What is wrong with my setup that it hides the "GatherFood" ability button on the command card?
(My Map is posted in my first reply to this thread, all my data entries have the "Monster-" prefix for easy locating on the search bar.
Not any that I remember. As far as I know, the only triggers I have made concerning abilities simply modify variables and create units when abilities are cast.
UPDATE: I disabled "Hides for Simple Text" field on the ability button, and the ability now seems to show up for other players. Maybe that was the problem.
I started making an arcade map and tried testing it online. So far the only people who have helped me test it have told me they couldn't see anything (Despite them having units on the map) and that they had slow frames per second when they were near the edge of the map.
The odd thing is that I haven't done much things on the map itself, at this rate the map won't be able to run at all if I finish the whole thing.
Is it normal for an arcade map to lag with very few units in it? Should I post it so you guys can open it in the editor and judge for yourselves? I really want to address this issue before I continue further in working on it.
So far the most complicated things I have added are triggers for spawning units and added around 7 custom units (Basically resized units which already exist).
Two things cause lag in general;
Lots of units
Poor triggering
If you have few units, then the problem is very likely due to your triggers. I think that's about as much help as anyone can give without seeing your map.
There are some other probable causes, but generally they aren't as prevalent as the above 2.
Try stagerring periodic trigger events and increase their periods if you are using any with less than a second.
Use ActorInfoDisplay chat command when testing the map to notice actor leaks...
From your description it does not sound like a script problem but that something is wrong with your terrain.
Do you use alot of doodads on the edges of the map? Water? Lots of lighting? etc.
Overall your description is way to vague to offer any sort of competent help.
@Mille25, I actually have around 60 doodads around the center of the map (None at the edges), 1 lighting, and around 30 squares of water.
__
I have read your replies, thanks for the advice. Whenever I playtest the map in the editor, no problems show up.
I feel that the possible problem might be in the triggers (Specifically the periodic events being too short).
Since I want to make sure what the problem is (If there is any) I'd like to ask you to check the map if you have the time (I worked hard on it but there is not much content to analyze).
I'd try to playtest it online a few more times, but finding people in chats willing to help me fill the player 2 spot is really hard.
@wisesquirrel: Go
Map Size
Try Smaller
Egod
i cannot correctly open the map due to hots depencies but from what i see i would say it's the terrain. pathfinding isn't easy and yolu have lots of different layers. using the "painting" i would try to avoid difficult geometrical objects, just plain and straight rectangles ( you have quite complex ones)
I actually do have a lot of paths in the map. The reason why I have a lot of them is that I wanted to make a layout I could follow when making the terrain so I know where a corridor continues and where there are walls (Yellow paths for low ground and blue paths for high ground as well as green paths for starting areas.
They are basically placeholders so I don't make a mistake in the terrain in the future when I get around to editing the terrain (If that is the case I can remove a major portion of it while I'm still working on it). So should I remove these placeholder paths?
I also have a consistent perimeter of red pathing (No walking on it) around the whole map about 16 units wide (To avoid having a player wander off the map), would that be the reason why my map might be reducing frame rate around the edges? (That would make sense if it is true since it is the only thing I have on the edges) Would having downward/upward cliffs around the edges be less laggy or would those lag the map too?
I actually feel the map is pretty small for what I want, can't imagine working with anything smaller than that (Is 256 X 256 too large for a lag free map?, that would stink if its true XD).
my bet is still pathfinding :d and since it makes sense (somehow) you could give it a try. if i were you i would copy the map, remove pathing and test it again
You are using the any player presses key events.
Here is the in-editor description for them:
"Only register for this event when you absolutely need it, as it will generate network traffic from all players for every button they press. This event fires when a player presses the specified key. Use "Key Pressed" to get the key that was pressed. Use "Alt Key Pressed", "Control Key Pressed", and "Shift Key Pressed" to find out what modifier keys were pressed."
you should avoid using "while"-conditions as much as possible. use it only when you are sure the conditions to break the actions are soon to be met, and use wait inbetween the whiles. while fires many, many times per second if you don't use wait. try using "repeat" or "if" instead or other solutions.
Thanks for the suggestions, I did what you recommended and it seems the map doesn't lag horribly right now (Hopefully it will stay that way).
But now I have a problem that is just as important.
My map has a custom ability called "GatherFood", which units use to "Eat" meat units and red berry bush units.
For some RANDOM reason I can see the ability button, BUT NO ONE ELSE CAN.
I have done tests and found out that it is not the host who can see buttons, but me specifically. If I play as the host only I can see the ability button, if I don't play as host, I am still the only player who can see the button for the "GatherFood" ability.
I really need to have the players see the button (So that they may toggle it for autocast). What is wrong with my setup that it hides the "GatherFood" ability button on the command card?
(My Map is posted in my first reply to this thread, all my data entries have the "Monster-" prefix for easy locating on the search bar.
Did you do any triggering that gives you special commands in the map? That may be the problem.
@Spoolofwhool: Go
Not any that I remember. As far as I know, the only triggers I have made concerning abilities simply modify variables and create units when abilities are cast.
UPDATE: I disabled "Hides for Simple Text" field on the ability button, and the ability now seems to show up for other players. Maybe that was the problem.