source: golgotha/src/golg/objs/bases.hh @ 80

Last change on this file since 80 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.5 KB
RevLine 
[80]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_BASES_HH
10#define G1_BASES_HH
11
12#include "isllist.hh"
13#include "memory/que.hh"
14#include "g1_object.hh"
15#include "objs/structure_death.hh"
16
17class g1_path_object_class;
18
19struct g1_build_item
20{
21  int type;
22  g1_id_ref *path;  // null terminated
23};
24
25class g1_factory_class : public g1_object_class
26{
27protected:
28  g1_structure_death_class death;
29  g1_map_piece_class *create_object(int type);
30public:
31  g1_factory_class *next;
32  i4_fixed_que<g1_build_item, 50> deploy_que;
33 
34  g1_factory_class(g1_object_type id, g1_loader_class *fp); 
35  void think();
36  i4_bool occupy_location();
37  void unoccupy_location();
38  virtual g1_path_object_class *get_start();
39  virtual void set_start(g1_path_object_class *start);
40  virtual i4_bool build(int type);
41  virtual w32 get_path_color();
42  virtual w32 get_selected_path_color();
43
44  void damage(g1_object_class *obj, int hp, i4_3d_vector damage_dir);
45};
46
47extern i4_isl_list<g1_factory_class> g1_factory_list;
48
49#endif
Note: See TracBrowser for help on using the repository browser.