explosion1.hh 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. /********************************************************************** <BR>
  2. This file is part of Crack dot Com's free source code release of
  3. Golgotha. <a href="http://www.crack.com/golgotha_release"> <BR> for
  4. information about compiling & licensing issues visit this URL</a>
  5. <PRE> If that doesn't help, contact Jonathan Clark at
  6. golgotha_source@usa.net (Subject should have "GOLG" in it)
  7. ***********************************************************************/
  8. #ifndef G1_EXPLOSION1_HH
  9. #define G1_EXPLOSION1_HH
  10. #include "g1_object.hh"
  11. class g1_light_object_class;
  12. class g1_particle_emitter_class;
  13. class g1_explosion1_class : public g1_object_class
  14. {
  15. protected:
  16. w16 num_exp_frames, exp_frame;
  17. sw16 start_delay;
  18. public:
  19. float zv; // z velocity
  20. r1_texture_handle han;
  21. w16 model_id;
  22. void destroy_light();
  23. void create_light();
  24. g1_typed_reference_class<g1_light_object_class> light;
  25. g1_typed_reference_class<g1_particle_emitter_class> emitter;
  26. virtual i4_float occupancy_radius() const { return 0.4; }
  27. g1_explosion1_class(g1_object_type id, g1_loader_class *fp);
  28. ~g1_explosion1_class();
  29. enum
  30. {
  31. HIT_GROUND = 1,
  32. HIT_OBJECT = 2,
  33. MAKE_SPHERE = 128
  34. };
  35. virtual void setup(i4_float sx, i4_float sy, i4_float sh, w32 type=HIT_OBJECT);
  36. virtual void draw(g1_draw_context_class *context);
  37. virtual void think();
  38. };
  39. #endif