Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

3 Dimensional Chat / Pool of Hidden Objects

Author
Message
Northern Fist
21
Years of Service
User Offline
Joined: 23rd Sep 2003
Location:
Posted: 10th Nov 2003 05:35
I got a question...
What are your secrets to having a faster, robust 3D game concerning the pool of objects that are initially hidden. True, you have to experiment with the number of hidden objects to see what suits you best. However, what do you do with a vast array of actors, items that have to be displayed immediately.
How have you delt with this issue, and what kind of "logic" did you use to get around it to make things robust enough.

"Power, precision, and don't forget about speed. If you practice everyday with these things in mind... you begin to develope A FIGHTING MODE." - Fist of Legend (Jet Li)
Genesis Rage
21
Years of Service
User Offline
Joined: 5th Oct 2003
Location:
Posted: 10th Nov 2003 06:24
if i understand what you are trying to ask...

what almost EVERY game does... a loading screen!
when the loading screen is shown the 3D world is being loaded (all objects), and setting up the scene (posistioning, hiding, etc...)

this is what i do... and with objects that are initially hidden... i position them where they will first need to be unhidden (this way it just unhides an object other than moving it then unhiding it)

Van B
Moderator
22
Years of Service
User Offline
Joined: 8th Oct 2002
Location: Sunnyvale
Posted: 10th Nov 2003 11:28
It depends really, with enemies for instance, it's a good idea to hide them when not in use - but how could you make (for example) 50 enemies and have only 20 models for them to use. This means that you'd have to make it impossible to have more than 20 enemies on screen. Personally, I'd most likely have 30 or so enemy objects, then once an enemy dies, it can be regenerated somewhere else, keeping a nice even flow of cannon fodder - plus it adds the gameplay dynamic that if your quiet and don't kill the enemies all the time, you don't get more and more enemies comming after you.

For level objects, it's a good idea to have a set number of a particular object you can display in the same area - like if you made 10 lamp posts, and your camera range is 1000 units, you'd make sure that at any give location there is no more than 10 lamp posts - that way you can position each lamp post object at the right place without running out of objects. It's always a good idea to use arrays for this sort of thing, and a function that can count the amount of a specified object in a certain area.


Van-B


I laugh in the face of fate!
Pincho Paxton
22
Years of Service
User Offline
Joined: 8th Dec 2002
Location:
Posted: 10th Nov 2003 11:35
You're question is open to a lot of interpretation, in other words I don't fully understand it. If you have a lot of objects that have to be displayed all at once you have to use low poly models.

Pincho.
Van B
Moderator
22
Years of Service
User Offline
Joined: 8th Oct 2002
Location: Sunnyvale
Posted: 10th Nov 2003 11:57
Pincho,
The problem is that the objects don't have to be displayed at once - if you have 100 lamp posts in a level, it's not very efficient to load 100 lamp post models and position them - it's more efficient to load 10 lamp posts and reposition them to suit the area the camera is in, if done well you'd think there was 100 lamp posts, but with the resource drain of only 10. It's all a matter of boosting speed while maintaining screen detail.


Van-B


I laugh in the face of fate!
Beta 1
21
Years of Service
User Offline
Joined: 27th Aug 2003
Location:
Posted: 10th Nov 2003 16:34
In my current project I have written a node based system for recurrent terrain features such as trees/lampposts whatever.

Enough instances of each object is loaded to make sure theres enough to display the most dense area required then when the scenery is updated the "node" nearest the players position is determined ( actually it determines one of four top nodes and then checks each of the 4 lower nodes to see which one is closest and so one down to the bottom of the structure. When the bottom node is found it has a precalculated list of all the scenery within "X" units of the node. the pre loaded trees etc are then moved to these locations to generate the scenery around the player. So if you look at a level from above with a larger camera range you see the level doesnt actually have any scenery in it apart from around the player. This way I can have several thousand trees/whatever across a level but only need a hundred or so objects to display it.

If you mix in a ferw different tree types, rotate them a bit, change their textures you can make it look nice and varied.

And why bother with the nodes rather than just check each scenery objects distance from the player - well thats a speed thing too - the precalculated lists take up a fair bit of memory but they are faster. Equally I can have around a thousand bottom nodes on a really big map so the layered nodes cut the search time down drastically when trying to determine which area to populate with scenery.
Northern Fist
21
Years of Service
User Offline
Joined: 23rd Sep 2003
Location:
Posted: 10th Nov 2003 17:33
You all are on the right page.
Sorry if I phrased the question inadequately.

@ Van-B
I see what you're saying... Lately I've been rather discouraged from facing the idea of a third person action game, because I've been battling speed problems with a MINI game that I'm hopefully almost finished with. You will probably see it eventually in the 20-line competition.

@ Beta 1
Cool! I look forward to seeing it.

"Power, precision, and don't forget about speed. If you practice everyday with these things in mind... you begin to develope A FIGHTING MODE." - Fist of Legend (Jet Li)
Beta 1
21
Years of Service
User Offline
Joined: 27th Aug 2003
Location:
Posted: 11th Nov 2003 16:11
Thats dependant on me getting back into the swing of it after moving house. Maybe I'll put in some time tonight while the better halfs out

Login to post a reply

Server time is: 2025-05-14 20:47:32
Your offset time is: 2025-05-14 20:47:32