KDIS  2-8-x
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
AirPlatformAppearance.h
Go to the documentation of this file.
1 /*********************************************************************
2 Copyright 2013 Karl Jones
3 All rights reserved.
4 
5 Redistribution and use in source and binary forms, with or without
6 modification, are permitted provided that the following conditions are met:
7 
8 1. Redistributions of source code must retain the above copyright notice, this
9  list of conditions and the following disclaimer.
10 2. Redistributions in binary form must reproduce the above copyright notice,
11  this list of conditions and the following disclaimer in the documentation
12  and/or other materials provided with the distribution.
13 
14 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
15 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
16 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
17 DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
18 ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
19 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
20 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
21 ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
22 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
23 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
24 
25 For Further Information Please Contact me at
26 Karljj1@yahoo.com
27 http://p.sf.net/kdis/UserGuide
28 *********************************************************************/
29 
30 /********************************************************************
31  class: AirPlatformAppearance
32  created: 22/09/2008 - Updated March 2012
33  author: Karl Jones
34 
35  purpose: Represents the appearance of a air platform.
36  Implemented as struct so as to prevent the size from
37  changing due to RTTI etc. This struct will be part of a
38  union with all specific appearance values so it is implemented
39  slightly different.
40  No constructors to prevent C2620 error caused by union of
41  classes/structs.
42  size: 32 Bits / 4 Octet
43 *********************************************************************/
44 
45 #pragma once
46 
47 #include "./../KDefines.h"
48 #include "./Enums/KDISEnums.h"
49 
50 namespace KDIS {
51 namespace DATA_TYPE {
52 
54 {
55 protected:
56  // Bits
57  KUINT32 m_PaintScheme : 1; // 0
58  KUINT32 m_MobilityKill : 1; // 1
59  KUINT32 m_Unused1 : 1; // 2
60  KUINT32 m_Damage : 2; // 3-4
61  KUINT32 m_Smoke : 2; // 5-6
62  KUINT32 m_TrailingEffect : 2; // 7-8
63  KUINT32 m_CanopyState : 3; // 9-11
64  KUINT32 m_LandingLights : 1; // 12
65  KUINT32 m_NavLights : 1; // 13
66  KUINT32 m_AntiColLights : 1; // 14
67  KUINT32 m_FlamingEffectField : 1; // 15
68  KUINT32 m_Afterburner : 1; // 16
69  KUINT32 m_Unused2 : 4; // 17-20
70  KUINT32 m_FrozenStatus : 1; // 21
71  KUINT32 m_PowerPlantStatus : 1; // 22
72  KUINT32 m_State : 1; // 23
73  KUINT32 m_FormationLights : 1; // 24
74  KUINT32 m_Unused3 : 3; // 25-27
75  KUINT32 m_SpotLights : 1; // 28
76  KUINT32 m_InteriorLights : 1; // 29
77  KUINT32 m_Unused4 : 2; // 30 - 31
78 
79 public:
80 
81  //************************************
82  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityPaintScheme
83  // KDIS::DATA_TYPE::AirPlatformAppearance::GetEntityPaintScheme
84  //!Description: Describes the paint scheme of an entity.
85  // Parameter: EntityPaintScheme EPS
86  //************************************
87  void SetEntityPaintScheme( KDIS::DATA_TYPE::ENUMS::EntityPaintScheme EPS );
88  KDIS::DATA_TYPE::ENUMS::EntityPaintScheme GetEntityPaintScheme() const;
89 
90  //************************************
91  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityMobilityKill
92  // KDIS::DATA_TYPE::AirPlatformAppearance::DoesEntityMobilityKill
93  //!Description: Mobility/Propulsion Kill True/False?
94  // Parameter: KBOOL MK
95  //************************************
96  void SetEntityMobilityKill( KBOOL MK );
97  KBOOL DoesEntityMobilityKill() const;
98 
99  //************************************
100  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityDamage
101  // KDIS::DATA_TYPE::AirPlatformAppearance::GetEntityDamage
102  //!Description: Entity Damage State
103  // Parameter: EntityDamage ED
104  //************************************
105  void SetEntityDamage( KDIS::DATA_TYPE::ENUMS::EntityDamage ED );
106  KDIS::DATA_TYPE::ENUMS::EntityDamage GetEntityDamage() const;
107 
108  //************************************
109  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntitySmoke,
110  // KDIS::DATA_TYPE::AirPlatformAppearance::GetEntitySmoke
111  //!Description: Entity Smoke State
112  // Parameter: EntitySmoke ES
113  //************************************
114  void SetEntitySmoke( KDIS::DATA_TYPE::ENUMS::EntitySmoke ES );
115  KDIS::DATA_TYPE::ENUMS::EntitySmoke GetEntitySmoke() const;
116 
117  //************************************
118  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityTrailingEffect
119  // KDIS::DATA_TYPE::AirPlatformAppearance::GetEntityTrailingEffect
120  //!Description: Describes the size of the dust cloud/trailing effect.
121  // Parameter: EntityTrailingEffect ETE
122  //************************************
123  void SetEntityTrailingEffect( KDIS::DATA_TYPE::ENUMS::EntityTrailingEffect ETE );
124  KDIS::DATA_TYPE::ENUMS::EntityTrailingEffect GetEntityTrailingEffect() const;
125 
126  //************************************
127  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityCanopyState
128  // KDIS::DATA_TYPE::AirPlatformAppearance::GetEntityCanopyState
129  //!Description: Is the canopy open or closed? Note: Only PrimaryHatchIsClosed
130  // or PrimaryHatchIsOpen are acceptable values when using aircraft.
131  // Parameter: EntityHatchState ECS
132  //************************************
133  void SetEntityCanopyState( KDIS::DATA_TYPE::ENUMS::EntityHatchState ECS );
134  KDIS::DATA_TYPE::ENUMS::EntityHatchState GetEntityCanopyState() const;
135 
136  //************************************
137  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityLandingLights
138  // KDIS::DATA_TYPE::AirPlatformAppearance::IsEntityLandingLightsOn
139  //!Description: Are the vehicles landing lights turned on? True = On, False = Off.
140  // Parameter: KBOOL LL
141  //************************************
142  void SetEntityLandingLights( KBOOL LL );
143  KBOOL IsEntityLandingLightsOn() const;
144 
145  //************************************
146  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityNavigationLights
147  // KDIS::DATA_TYPE::AirPlatformAppearance::IsEntityNavigationLightsOn
148  //!Description: Are the vehicles Navigation lights turned on? True = On, False = Off.
149  // Parameter: KBOOL NL
150  //************************************
151  void SetEntityNavigationLights( KBOOL NL );
152  KBOOL IsEntityNavigationLightsOn() const;
153 
154  //************************************
155  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityAntiCollisionLights
156  // KDIS::DATA_TYPE::AirPlatformAppearance::IsEntityAntiCollisionLightsOn
157  //!Description: Are the vehicles Anti-Collision lights turned on? True = On, False = Off.
158  // Parameter: KBOOL ACL
159  //************************************
160  void SetEntityAntiCollisionLights( KBOOL ACL );
161  KBOOL IsEntityAntiCollisionLightsOn() const;
162 
163  //************************************
164  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityFlamingEffect
165  // KDIS::DATA_TYPE::AirPlatformAppearance::IsEntityFlaming
166  //!Description: Are flames rising from the entity?
167  // Parameter: KBOOL EFE
168  //************************************
169  void SetEntityFlamingEffect( KBOOL EFE );
170  KBOOL IsEntityFlaming() const;
171 
172  //************************************
173  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityAfterburner
174  // KDIS::DATA_TYPE::AirPlatformAppearance::IsAfterburnerOn
175  //!Description: Is the entity afterburner on?
176  // Parameter: KBOOL AB, void
177  //************************************
178  void SetEntityAfterburner( KBOOL AB );
179  KBOOL IsAfterburnerOn() const;
180 
181  //************************************
182  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityFrozenStatus
183  // KDIS::DATA_TYPE::AirPlatformAppearance::IsEntityFrozen
184  //!Description: Is the entity frozen?
185  //! Note: Frozen entities should not be dead-reckoned, they should remain
186  //! frozen in place. You would likely freeze entites when your application is
187  //! in a paused state.
188  // Parameter: KBOOL EFS
189  //************************************
190  void SetEntityFrozenStatus( KBOOL EFS );
191  KBOOL IsEntityFrozen() const;
192 
193  //************************************
194  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityPowerPlantOn
195  // KDIS::DATA_TYPE::AirPlatformAppearance::IsEntityPowerPlantOn
196  //!Description: Power Plant On/Off. True = On, False = Off.
197  // Parameter: KBOOL EPPS
198  //************************************
199  void SetEntityPowerPlantOn( KBOOL EPPS );
200  KBOOL IsEntityPowerPlantOn() const;
201 
202  //************************************
203  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityStateActive
204  // KDIS::DATA_TYPE::AirPlatformAppearance::IsEntityStateActive
205  //!Description: True = Active, False = Deactivated.
206  // Parameter: KBOOL ES
207  //************************************
208  void SetEntityStateActive( KBOOL ES );
209  KBOOL IsEntityStateActive() const;
210 
211  //************************************
212  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityFormationLights
213  // KDIS::DATA_TYPE::AirPlatformAppearance::IsEntityFormationLightsOn
214  //!Description: Are the vehicles Formation lights turned on? True = On, False = Off.
215  // Parameter: KBOOL FL
216  //************************************
217  void SetEntityFormationLights( KBOOL FL );
218  KBOOL IsEntityFormationLightsOn() const;
219 
220  //************************************
221  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityBlackoutBrakeLights
222  // KDIS::DATA_TYPE::AirPlatformAppearance::IsEntityBlackoutBrakeLightsOn
223  //!Description: Are the vehicles spot lights turned on? True = On, False = Off.
224  // Parameter: KBOOL SL
225  //************************************
226  void SetEntitySpotLights( KBOOL SL );
227  KBOOL IsEntitySpotLightsOn() const;
228 
229  //************************************
230  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::SetEntityInteriorLights
231  // KDIS::DATA_TYPE::AirPlatformAppearance::IsEntityInteriorLightsOn
232  //!Description: Are the vehicles interior lights turned on? True = On, False = Off.
233  // Parameter: KBOOL IL
234  //************************************
235  void SetEntityInteriorLights( KBOOL IL );
236  KBOOL IsEntityInteriorLightsOn() const;
237 
238  //************************************
239  // FullName: KDIS::DATA_TYPE::AirPlatformAppearance::GetAsString
240  //!Description: Returns a string representation
241  //************************************
242  KString GetAsString() const;
243 
244  KBOOL operator == ( const AirPlatformAppearance & Value ) const;
245  KBOOL operator != ( const AirPlatformAppearance & Value ) const;
246 };
247 
248 } // END namespace DATA_TYPES
249 } // END namespace KDIS
250 
unsigned int KUINT32
Definition: KDefines.h:103
EntityTrailingEffect
Definition: EnumEntityInfoInteraction.h:667
EntityPaintScheme
Definition: EnumEntityInfoInteraction.h:630
EntityDamage
Definition: EnumEntityInfoInteraction.h:641
Definition: EnumEmitter.h:949
EntitySmoke
Definition: EnumEntityInfoInteraction.h:654
EntityHatchState
Definition: EnumEntityInfoInteraction.h:680
bool KBOOL
Definition: KDefines.h:119
Definition: AirPlatformAppearance.h:53
std::string KString
Definition: KDefines.h:116
#define KDIS_EXPORT
Definition: KDefines.h:82