static_object.h 668 B

1234567891011121314151617181920212223242526272829303132333435
  1. /**
  2. *** :: Static Object ::
  3. ***
  4. *** A basic instance of an object in the world
  5. *** Basically just a scale, position and rotation
  6. *** applied to a renderable and collision body
  7. ***
  8. **/
  9. #ifndef static_object_h
  10. #define static_object_h
  11. #include "cengine.h"
  12. #include "casset.h"
  13. typedef struct {
  14. vec3 position;
  15. vec3 scale;
  16. quat rotation;
  17. bool active;
  18. bool recieve_shadows;
  19. bool cast_shadows;
  20. asset_hndl renderable;
  21. asset_hndl collision_body;
  22. } static_object;
  23. static_object* static_object_new();
  24. void static_object_delete(static_object* s);
  25. mat4 static_object_world(static_object* s);
  26. mat3 static_object_world_normal(static_object* s);
  27. #endif