Jump to content

  • Log In with Google      Sign In   
  • Create Account

We're offering banner ads on our site from just $5!

1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


What's your preferred way of letting objects affect the game?


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
20 replies to this topic

#21 darkhaven3   Members   -  Reputation: 160

Like
0Likes
Like

Posted 24 February 2013 - 11:29 AM


I can see this being a legitimate approach if and only if your game logic is heavily data-driven and validated by external tools prior to loading into the engine.

Really? All I can see is the many hundreds of ways this can crash and burn in a series of amusing ways... more so when you consider the follow up reply about not sanity checking the results... dry.png

 

Sure it can crash and burn if I care to introduce bad definitions in the frametable. Who cares? If the function called by a frame for a particular mobj_t says "You can't move here because I said so", then the mobj_t shouldn't give a damn. All that would happen is the mobj_t would stop moving in that direction, and possibly attempt to move in a different direction arbitrarily. It's not an mobj_t's responsibility to determine where it can move in this specific context; it's handled at a higher level. All an mobj_t is responsible for is itself, or being the target of another mobj_t in special cases (monster infighting, or the player being the target of a monster, mainly). And even in that case, mobj_t's typically don't care if they are targets of one another, and can't directly modify one another's target reference; they will attack one another until it is somehow resolved by other mechanics, typically by means of one mobj_t changing targets to the player or another monster, or entering its death state.

 

It seems simple and concise enough to be easy to debug and easy to implement, and it seems like it would be quite fast, especially in the context of a 2D sidescroller.



Sponsor:



Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS