Jump to content
  • Advertisement
Sign in to follow this  
grill8

Questions about creating large FPS games and event handling in a game engine.

This topic is 3161 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, I have some questions about creating large FPS games and event handling in a game engine. Question 1) Ok, so some games have very large worlds and there is a finite amount of memory available. To reduce memory, I use resource instancing etc. (standard procedures). My question now is ... if I program a large (or very large) world as my game, how do I manage the world properly so that there is enough memory for everything and that everything runs smoothly. I am assuming you cannot simply have the ENTIRE world loaded in memory which means you are probably doing something like loading portions at a time (probably slowly in a separate thread) as regions become visible etc. I am needing information on how to properly manage LARGE FPS worlds in this manner and in memory and at run-time. Question 2) Ok, so events happen in games ... something collides with something else and you need to notify the objects that events have occured. Other times you want to simply trigger events in other objects without collision. Currently my game engine physical entity class has a couple of virtual methods:
class JPhysicalObject
{
public
     void HandleCollision(JPhysicalObject* collider) = 0;
     void HandleEvent(int event_id, void* arg1, void* arg2) = 0;
};

When two objects collide they pass themselves to each other for querying the collider type and performing collision events. When events need triggering you simply trigger the event with HandleEvent. I am hoping to get some information as to whether there is a more robust solution or if I am doing this correctly. Thank you for your help. Jeremy

Share this post


Link to post
Share on other sites
Advertisement
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!