Simulation out-of-bounds
I''ve been having trouble thinking about this problem, I haven''t hit it yet as my game doesn''t have any characters yet, let alone AI. But I will have to face it sooner or later. What are some good ways to simulate npc''s/monsters routines when the scenery in which they are isn''t even loaded into the engine currently? My game has a fairly large scope, and I''m already streaming the terrain and objects as you mvoe around, but none of the objects currently change over time. My problem is that the ai uses the game physics to determine where it can move and such, and if the player goes far enough away that that scenery is unloaded, the ai character will be unloaded as well.
Also, on slower systems, the range of scenery that''s loaded is pretty small. Think of the fog in the original Turok for n64. It could potientially only have that much area loaded. How do I simulate enemies and characters when they have no scenery or physics calculations to speak of? How far should I abstract it, and how do I silve issues like travelling groups of characters, and making sure that when they do spawn in scenery once the scenery is loaded, that they don''t spawn in the middle of a wall or something crazy like that.
I keep thinking about a situation such as two kids playing ball in a villiage on a slow computer, with a really small loaded area, where one kid throws the ball off the screen, then nothing happens unless you move out a bit and the next area loads for the other kid to throw the ball back.
Probably biting off more than I can chew, but I''d like to hear your ideas on the subject before I either put this issue off a few years or alter the design and factor out some of the ai component.
If I understand your query correctly, you''re asking, "how do I know/maintain the state of an object once it moves out of the currently loaded environment". Is that correct?
If this is what you are asking, then the answer really depends on the object and how you want to store and update the state of all objects in the world. Do you have a master list of states of all objects, or, more likely, does each object store its current state? For a given object, do you care about its state when it leaves the current area? Presumably for NPCs and monsters you do.
You might want to investigate Level Of Detail (LOD) design principles. If indeed we are talking about a design question, then your question might be better suited to the Game Design, or even Game Programming forums.
Cheers,
Timkin
If this is what you are asking, then the answer really depends on the object and how you want to store and update the state of all objects in the world. Do you have a master list of states of all objects, or, more likely, does each object store its current state? For a given object, do you care about its state when it leaves the current area? Presumably for NPCs and monsters you do.
You might want to investigate Level Of Detail (LOD) design principles. If indeed we are talking about a design question, then your question might be better suited to the Game Design, or even Game Programming forums.
Cheers,
Timkin
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement