source: golgotha/src/golg/objs/explosion1.hh

Last change on this file was 80, checked in by Sam Hocevar, 11 years ago
  • Adding the Golgotha source code. Not sure what's going to be interesting in there, but since it's all public domain, there's certainly stuff to pick up.
File size: 1.4 KB
Line 
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
9#ifndef G1_EXPLOSION1_HH
10#define G1_EXPLOSION1_HH
11
12#include "g1_object.hh"
13
14class g1_light_object_class;
15class g1_particle_emitter_class;
16
17class g1_explosion1_class : public g1_object_class
18{
19protected:
20  w16  num_exp_frames, exp_frame;
21  sw16  start_delay;
22
23public:
24  float zv;                 // z velocity
25  r1_texture_handle han;
26
27  w16 model_id;
28  void destroy_light();
29  void create_light();
30
31  g1_typed_reference_class<g1_light_object_class> light;
32  g1_typed_reference_class<g1_particle_emitter_class> emitter;
33
34  virtual i4_float occupancy_radius() const  {         return 0.4;  }
35
36  g1_explosion1_class(g1_object_type id, g1_loader_class *fp);
37  ~g1_explosion1_class();
38 
39  enum
40  {
41    HIT_GROUND  = 1,
42    HIT_OBJECT  = 2,
43    MAKE_SPHERE = 128
44  };
45
46  virtual void setup(i4_float sx, i4_float sy, i4_float sh, w32 type=HIT_OBJECT);
47 
48  virtual void draw(g1_draw_context_class *context);
49  virtual void think();
50};
51
52#endif
Note: See TracBrowser for help on using the repository browser.