Alice Community

Alice Community (http://www.alice.org/community/index.php)
-   How do I...? (http://www.alice.org/community/forumdisplay.php?f=16)
-   -   Remove lagg. (http://www.alice.org/community/showthread.php?t=4831)

Watsamax1 08-02-2010 02:05 PM

Remove lagg.
 
My RPG style game currently is about 130 mb's and it isnt getting smaller. Ive tried removing events, and making methods for everything. But not i still need collision that works fast, walking that doesn't lag somehow always messes up :mad:. And combat, and another world and a dungeon. so as you may see my game will be laggy then and i still need some building collision for a few buildings.

So any ideas on how to remove this lag will be appreciated.

x2495iiii 08-02-2010 04:09 PM

-Set objects that aren't visible (too far away, behind buildings, etc) to isShowing = false

-Use pauses in collision detection.

Loop infinity times
check for collision
wait .01 seconds

-Use png billboards instead of objects as boundaries (makes collision detection easier too)

-Avoid using simultaneous loops (if there's a collision that can't possibly happen while another one is happening, make sure they're not both running)

or better yet

-Make collision loops so they only run when necessary

Loop infinity times
if character is within 1 meter of building
collision detection
else
do nothing

Dameria 08-02-2010 08:06 PM

In this case the lag is occuring because of all of the objects. It would probably help to make a fog and have the objects too deep in the fog just stop showing (but you will also have to have them reappear when you get closer).

Alice wasn't meant to handle all of those objects at once like other games can.

zonedabone 08-05-2010 11:29 PM

Another awesome thing to do is set the camera clip distance to that of the fog far distance. This will make all objects beyond the fog un-rendered.

King Gamer(gorit) 08-05-2010 11:46 PM

Well, I just wanted to say That my oclusion culling will cut down lag from objects but I haven't started and would be hard to fit into somthing the big already.


All times are GMT -5. The time now is 02:29 PM.

Copyright ©2020, Carnegie Mellon University
Alice 2.x 1999-2012, Alice 3.x 2008-2012, Carnegie Mellon University. All rights reserved.