Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

It exist a game developed with a vectorfield game engine?

What I mean is that instead of calculating intersections, one could calculate the vector field generated for example by gravity, and for example by the ground and let the object follow those fields.

What are the advantages and drawbacks of this kind of game engine?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

The more vectors you have, the more you have to store, and the more floating-point operations you (potentially) have to do. I have no doubt that this method would require a vast number of vectors. Why instance vectors that may never be used? It wouldn't make sense from am efficient space/time usage perspective.

Intersection checks cannot possibly be replaced by your proposed field physics. In classical mechanics, at a human scale, objects will not noticeably affect each other by gravitic forces in any case. The only time they are going to "push away from one another" is when they are intersecting in your simulation, then and only then. Thus there is no way a field-based approach could eliminate the need to perform intersection checks (in whatever form).

The discrepancy between what you are imagining and the reality of computer simulations, is as follows:

A simulation runs through some finite number of steps per time interval (whether these steps are variable or equal duration is irrelevant). Based on this, objects must "jump" a certain distance in each time step -- this process is not analog -- based on their velocity, no matter how small. So logically there are always going to be cases where an object may potentially "jump into" and intersect another, hence the need for intersection checks.

The real world, on the other hand, doesn't work in the same way that computer simulations do, because real-world time is (in practice) analog. So the machine that is the universe, so to speak, resolves collisions in a different manner, using something like the approach you propose. Atoms never really collide, they just apply forces that grow stronger and stronger the closer you force them together. That means that objects, which are made of atoms, obey similar rules: forces are applied on a continual, analog basis between every object in existence -- so the physicists tell us.

P.S. Subject to the eminent Martin Sojka's proofreading for errors of a physical or mathematical nature. ;)

share|improve this answer
    
thx for the answer, pretty explicative :D but, I think it could even reduce the number of operations needed, because let's say, before you calculate the vector field than you feed in all the vectors of the object in the field function and so you have the next step, instead of calculating the path of each particle, consequently total runs 2x number of object instead of an exponential increase (kd tree excluded). Did I made mistakes in my logic? –  Pella86 Sep 7 '11 at 21:55

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.