1234567891011121314151617181920212223242526272829 |
- # ifndef MISSILES_H
- # define MISSILES_H
- // Basiques
- # include <iostream>
- # include <vector>
- // bBox2D
- # include <box2d/box2d.h>
- // Identification
- enum Identity { LAND = 0, PLANE = 1, INERT = 2, ANG = 3, ARROW = 4, CHARGE = 5 };
- // Entité
- struct Entity
- {
- float rayon ;
- Identity id ;
- };
- // Fonctions
- void updateMissiles( b2World &world, b2Body* target, bool foresee = false );
- void createInert( b2Vec2 from, b2Body* target, b2World &world, Identity missile );
- b2Vec2 anticipate( b2Body* missile, b2Body* target );
- # endif // MISSILES_H
|