Tiberian Technologies Scripts Reference Revision: 9000
Loading...
Searching...
No Matches
RepairBayGameObj.h
1/* Renegade Scripts.dll
2 Copyright 2013 Tiberian Technologies
3
4 This file is part of the Renegade scripts.dll
5 The Renegade scripts.dll is free software; you can redistribute it and/or modify it under
6 the terms of the GNU General Public License as published by the Free
7 Software Foundation; either version 2, or (at your option) any later
8 version. See the file COPYING for more details.
9 In addition, an exemption is given to allow Run Time Dynamic Linking of this code with any closed source module that does not contain code covered by this licence.
10 Only the source code to the module(s) containing the licenced code has to be released.
11*/
12#ifndef TT_INCLUDE__REPAIRBAYGAMEOBJ_H
13#define TT_INCLUDE__REPAIRBAYGAMEOBJ_H
14
15#include "BuildingGameObj.h"
16#include "Matrix3D.h"
17#include "engine_common.h"
18#include "SimplePersistFactoryClass.h"
19#include "RepairBayGameObjDef.h"
20#include "OBBoxClass.h"
21#include "SimpleGameObj.h"
22class RepairBayGameObj : public BuildingGameObj
23{
24public:
25 RepairBayGameObj (void);
26 ~RepairBayGameObj (void);
27 virtual void Init( void );
28 void Init (const RepairBayGameObjDef & definition);
29 SCRIPTS_API const RepairBayGameObjDef & Get_Definition (void) const;
30 RepairBayGameObj * As_RepairBayGameObj (void) { return this; }
31 bool Save (ChunkSaveClass &csave);
32 bool Load (ChunkLoadClass &cload);
33 const PersistFactoryClass & Get_Factory (void) const;
34 void CnC_Initialize (BaseControllerClass *base);
35 void Think (void);
36 void Export_Creation (BitStreamClass &packet);
37 void Import_Creation (BitStreamClass &packet);
38private:
39 void Load_Variables (ChunkLoadClass &cload);
40 bool Repair_Vehicle (void);
41 void Play_Repairing_Animation (bool onoff);
42 void Update_Repairing_Animations (void);
43 void Emit_Welding_Arc (RenderObjClass *vehicle_model);
44 enum
45 {
46 ARC_OBJ_COUNT = 4,
47 BONE_COUNT = 6
48 };
49 float RepairTimer;
50 OBBoxClass RepairZone;
51 int RepairAnimationID;
52 bool IsReparing;
53 DynamicVectorClass<ReferencerClass> VehicleList;
54 StaticPhysClass * RepairMesh;
55 SimpleGameObj * ArcObjects[ARC_OBJ_COUNT];
56 float ArcLifeRemaining[ARC_OBJ_COUNT];
57 Matrix3D EndTM;
58 Matrix3D Bones[BONE_COUNT];
59 static const char * BoneNames[BONE_COUNT];
60};
61
62#endif