mirror of
https://github.com/ptitSeb/Serious-Engine
synced 2024-11-22 10:20:26 +01:00
601 lines
30 KiB
C++
601 lines
30 KiB
C++
/*
|
|
* This file is generated by Entity Class Compiler, (c) CroTeam 1997-98
|
|
*/
|
|
|
|
#line 4 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
|
|
#include "StdH.h"
|
|
|
|
#include <EntitiesMP/EnvironmentBase.h>
|
|
#include <EntitiesMP/EnvironmentBase_tables.h>
|
|
void CEnvironmentBase::SetDefaultProperties(void) {
|
|
m_strName = "Base Environment";
|
|
m_strDescription = "";
|
|
m_fDistance = 100.0f;
|
|
m_fStretch = 1.0f;
|
|
m_penTarget = NULL;
|
|
m_penWatcher = NULL;
|
|
m_fWatcherFrequency = 2.0f;
|
|
m_vDesiredPosition = FLOAT3D(0 , 0 , 0);
|
|
m_fMoveSpeed = 2.0f;
|
|
m_fRotateSpeed = 60.0f;
|
|
m_fMoveFrequency = 0.5f;
|
|
m_bUseWatcher = FALSE ;
|
|
m_bFlying = FALSE ;
|
|
m_fWaitTime = 0.0f;
|
|
m_fnMdl = CTFILENAME("Models\\Editor\\Axis.mdl");
|
|
m_fnTex = CTString("");
|
|
m_iAnim = 0;
|
|
m_fnAtt1Mdl = CTString("");
|
|
m_fnAtt1Tex = CTString("");
|
|
m_iAtt1Position = 0;
|
|
m_iAtt1Anim = 0;
|
|
m_fnAtt2Mdl = CTString("");
|
|
m_fnAtt2Tex = CTString("");
|
|
m_iAtt2Position = 1;
|
|
m_iAtt2Anim = 0;
|
|
m_fnAtt3Mdl = CTString("");
|
|
m_fnAtt3Tex = CTString("");
|
|
m_iAtt3Position = 1;
|
|
m_iAtt3Anim = 0;
|
|
CMovableEntity::SetDefaultProperties();
|
|
}
|
|
|
|
#line 58 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
BOOL CEnvironmentBase::MovesByTargetedRoute(CTString & strTargetProperty)const {
|
|
#line 59 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
strTargetProperty = "Target";
|
|
#line 60 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return TRUE ;
|
|
#line 61 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 63 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
BOOL CEnvironmentBase::DropsMarker(CTFileName & fnmMarkerClass,CTString & strTargetProperty)const {
|
|
#line 64 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
fnmMarkerClass = CTFILENAME ("Classes\\EnvironmentMarker.ecl");
|
|
#line 65 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
strTargetProperty = "Target";
|
|
#line 66 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return TRUE ;
|
|
#line 67 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 68 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
const CTString & CEnvironmentBase::GetDescription(void)const {
|
|
#line 69 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
((CTString &) m_strDescription ) . PrintF ("-><none>");
|
|
#line 70 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_penTarget != NULL ){
|
|
#line 71 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
((CTString &) m_strDescription ) . PrintF ("->%s" , m_penTarget -> GetName ());
|
|
#line 72 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 73 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return m_strDescription ;
|
|
#line 74 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 76 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CAnimData * CEnvironmentBase::GetAnimData(SLONG slPropertyOffset) {
|
|
#line 77 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(slPropertyOffset == offsetof (CEnvironmentBase , m_iAnim )){
|
|
#line 78 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return GetModelObject () -> GetData ();
|
|
#line 80 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}else if(slPropertyOffset == offsetof (CEnvironmentBase , m_iAtt1Anim )){
|
|
#line 81 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CAttachmentModelObject * pamo = GetModelObject () -> GetAttachmentModel (m_iAtt1Position );
|
|
#line 82 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(pamo != NULL ){return pamo -> amo_moModelObject . GetData ();}
|
|
#line 83 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return CEntity :: GetAnimData (slPropertyOffset );
|
|
#line 85 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}else if(slPropertyOffset == offsetof (CEnvironmentBase , m_iAtt2Anim )){
|
|
#line 86 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CAttachmentModelObject * pamo = GetModelObject () -> GetAttachmentModel (m_iAtt2Position );
|
|
#line 87 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(pamo != NULL ){return pamo -> amo_moModelObject . GetData ();}
|
|
#line 88 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return CEntity :: GetAnimData (slPropertyOffset );
|
|
#line 90 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}else if(slPropertyOffset == offsetof (CEnvironmentBase , m_iAtt3Anim )){
|
|
#line 91 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CAttachmentModelObject * pamo = GetModelObject () -> GetAttachmentModel (m_iAtt3Position );
|
|
#line 92 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(pamo != NULL ){return pamo -> amo_moModelObject . GetData ();}
|
|
#line 93 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return CEntity :: GetAnimData (slPropertyOffset );
|
|
#line 95 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}else {
|
|
#line 96 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return CEntity :: GetAnimData (slPropertyOffset );
|
|
#line 97 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 98 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 106 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
BOOL CEnvironmentBase::NextMarker(void) {
|
|
#line 107 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_penTarget == NULL ){
|
|
#line 108 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return FALSE ;
|
|
#line 109 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 112 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_penTarget != NULL && ! IsOfClass (m_penTarget , "Environment Marker")){
|
|
#line 113 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
WarningMessage ("Target '%s' is not of Environment Marker class!" , m_penTarget -> GetName ());
|
|
#line 114 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_penTarget = NULL ;
|
|
#line 115 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return FALSE ;
|
|
#line 116 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 119 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CMarker * penTarget = (CMarker *) (CEntity *) m_penTarget ;
|
|
#line 120 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CMarker * penNextTarget = (CMarker *) (CEntity *) penTarget -> m_penTarget ;
|
|
#line 123 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(penNextTarget == NULL ){
|
|
#line 124 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return FALSE ;
|
|
#line 125 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 128 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_penTarget = penNextTarget ;
|
|
#line 130 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return TRUE ;
|
|
#line 131 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 134 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::CalcRotation(ANGLE aWantedHeadingRelative,ANGLE3D & aRotation) {
|
|
#line 136 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
aWantedHeadingRelative = NormalizeAngle (aWantedHeadingRelative );
|
|
#line 139 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(aWantedHeadingRelative < - m_fRotateSpeed * m_fMoveFrequency ){
|
|
#line 141 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
aRotation (1) = - m_fRotateSpeed ;
|
|
#line 143 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}else if(aWantedHeadingRelative > m_fRotateSpeed * m_fMoveFrequency ){
|
|
#line 145 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
aRotation (1) = + m_fRotateSpeed ;
|
|
#line 147 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}else {
|
|
#line 148 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
aRotation (1) = aWantedHeadingRelative / m_fMoveFrequency ;
|
|
#line 149 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 150 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 153 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::StopMoving(void) {
|
|
#line 154 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetDesiredRotation (ANGLE3D (0 , 0 , 0));
|
|
#line 155 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetDesiredTranslation (FLOAT3D (0.0f , 0.0f , 0.0f));
|
|
#line 156 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 159 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::MoveToPosition(void) {
|
|
#line 160 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
FLOAT3D vDesiredAngle ;
|
|
#line 163 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
vDesiredAngle = (m_vDesiredPosition - GetPlacement () . pl_PositionVector ) . Normalize ();
|
|
#line 165 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
ANGLE3D aRotation (0 , 0 , 0);
|
|
#line 166 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CalcRotation (GetRelativeHeading (vDesiredAngle ) , aRotation );
|
|
#line 169 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
FLOAT3D vTranslation (0.0f , 0.0f , 0.0f);
|
|
#line 170 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
vTranslation (3) = - m_fMoveSpeed ;
|
|
#line 173 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_bFlying ){
|
|
#line 174 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
vTranslation (2) = Sgn (vDesiredAngle (2)) * m_fMoveSpeed / 10;
|
|
#line 175 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 178 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetDesiredRotation (aRotation );
|
|
#line 179 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetDesiredTranslation (vTranslation );
|
|
#line 180 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 183 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::CalcDestination() {
|
|
#line 185 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
FLOAT fR = FRnd () * ((CEnvironmentMarker &) * m_penTarget ) . m_fMarkerRange ;
|
|
#line 186 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
FLOAT fA = FRnd () * 360.0f;
|
|
#line 187 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_vDesiredPosition = m_penTarget -> GetPlacement () . pl_PositionVector +
|
|
#line 188 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
FLOAT3D (CosFast (fA ) * fR , 0 , SinFast (fA ) * fR );
|
|
#line 189 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 192 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::MarkerParameters() {
|
|
#line 193 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_penTarget != NULL ){
|
|
#line 194 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CEnvironmentMarker & em = (CEnvironmentMarker &) * m_penTarget ;
|
|
#line 195 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(em . m_fMoveSpeed > 0.0f){
|
|
#line 196 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_fMoveSpeed = em . m_fMoveSpeed ;
|
|
#line 197 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 198 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(em . m_fRotateSpeed > 0.0f){
|
|
#line 199 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_fRotateSpeed = em . m_fRotateSpeed ;
|
|
#line 200 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 201 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 202 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 209 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::Initialize(void) {
|
|
#line 211 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
InitAsModel ();
|
|
#line 212 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetPhysicsFlags (EPF_MODEL_WALKING & ~ (EPF_ORIENTEDBYGRAVITY | EPF_TRANSLATEDBYGRAVITY ));
|
|
#line 213 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetCollisionFlags (ECF_MODEL );
|
|
#line 216 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
GetModelObject () -> mo_Stretch = FLOAT3D (m_fStretch , m_fStretch , m_fStretch );
|
|
#line 219 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetModel (m_fnMdl );
|
|
#line 220 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
GetModelObject () -> PlayAnim (m_iAnim , AOF_LOOPING );
|
|
#line 221 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_fnTex != CTString ("")){
|
|
#line 222 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
GetModelObject () -> mo_toTexture . SetData_t (m_fnTex );
|
|
#line 223 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 225 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
GetModelObject () -> RemoveAllAttachmentModels ();
|
|
#line 227 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
AddAttachment (m_iAtt1Position , m_fnAtt1Mdl , m_fnAtt1Tex );
|
|
#line 228 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CAttachmentModelObject * pamo = GetModelObject () -> GetAttachmentModel (m_iAtt1Position );
|
|
#line 229 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(pamo != NULL ){
|
|
#line 230 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
pamo -> amo_moModelObject . StartAnim (m_iAtt1Anim );
|
|
#line 231 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 233 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if((m_iAtt2Position != m_iAtt1Position ) && (m_fnAtt1Mdl != m_fnAtt2Mdl )){
|
|
#line 234 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
AddAttachment (m_iAtt2Position , m_fnAtt2Mdl , m_fnAtt2Tex );
|
|
#line 235 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CAttachmentModelObject * pamo = GetModelObject () -> GetAttachmentModel (m_iAtt2Position );
|
|
#line 236 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(pamo != NULL ){
|
|
#line 237 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
pamo -> amo_moModelObject . StartAnim (m_iAtt2Anim );
|
|
#line 238 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 239 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 241 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if((m_iAtt3Position != m_iAtt1Position ) && (m_fnAtt1Mdl != m_fnAtt3Mdl ) &&
|
|
#line 242 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
(m_iAtt3Position != m_iAtt2Position ) && (m_fnAtt2Mdl != m_fnAtt3Mdl )){
|
|
#line 243 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
AddAttachment (m_iAtt3Position , m_fnAtt3Mdl , m_fnAtt3Tex );
|
|
#line 244 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CAttachmentModelObject * pamo = GetModelObject () -> GetAttachmentModel (m_iAtt3Position );
|
|
#line 245 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(pamo != NULL ){
|
|
#line 246 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
pamo -> amo_moModelObject . StartAnim (m_iAtt3Anim );
|
|
#line 247 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 248 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 251 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_penTarget != NULL && ! IsOfClass (m_penTarget , "Environment Marker")){
|
|
#line 252 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
WarningMessage ("Target '%s' is not of Environment Marker class!" , m_penTarget -> GetName ());
|
|
#line 253 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_penTarget = NULL ;
|
|
#line 254 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 255 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 261 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::InitializeWatcher(FLOAT fWaitTime) {
|
|
#line 263 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_penWatcher = CreateEntity (GetPlacement () , CLASS_WATCHPLAYERS );
|
|
#line 264 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_penWatcher -> Initialize (EVoid ());
|
|
#line 267 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CWatchPlayers & pw = (CWatchPlayers &) * m_penWatcher ;
|
|
#line 268 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
pw . m_penOwner = this ;
|
|
#line 269 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
pw . m_fWaitTime = 2.0f;
|
|
#line 270 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
pw . m_fDistance = m_fDistance ;
|
|
#line 271 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
pw . m_bRangeWatcher = FALSE ;
|
|
#line 272 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
pw . m_eetEventClose = EET_ENVIRONMENTSTART ;
|
|
#line 273 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
pw . m_eetEventFar = EET_ENVIRONMENTSTOP ;
|
|
#line 274 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 282 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::PlayDefaultAnim(void) {
|
|
#line 283 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
GetModelObject () -> PlayAnim (m_iAnim , AOF_LOOPING | AOF_NORESTART );
|
|
#line 284 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 287 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::PlayMarkerAnimation(void) {
|
|
#line 288 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_penTarget != NULL ){
|
|
#line 289 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
GetModelObject () -> PlayAnim (((CEnvironmentMarker &) * m_penTarget ) . m_iAnim , AOF_LOOPING | AOF_NORESTART );
|
|
#line 290 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 291 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 294 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::ChangeDefaultAnim(void) {
|
|
#line 295 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_penTarget != NULL && ((CEnvironmentMarker &) * m_penTarget ) . m_bChangeDefaultAnim ){
|
|
#line 296 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_iAnim = ((CEnvironmentMarker &) * m_penTarget ) . m_iAnim ;
|
|
#line 297 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 298 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
|
|
#line 301 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
void CEnvironmentBase::WaitOnMarker(void) {
|
|
#line 302 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_penTarget != NULL ){
|
|
#line 303 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CEnvironmentMarker & em = (CEnvironmentMarker &) * m_penTarget ;
|
|
#line 304 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_fWaitTime = em . m_fWaitTime ;
|
|
#line 305 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_fWaitTime += FRnd () * em . m_fRandomTime ;
|
|
#line 307 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(em . m_bFixedAnimLength ){
|
|
#line 308 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_fWaitTime = floor (m_fWaitTime + 0.5f);
|
|
#line 309 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 310 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 311 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
BOOL CEnvironmentBase::
|
|
#line 320 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
MoveToMarker(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT STATE_CEnvironmentBase_MoveToMarker
|
|
ASSERTMSG(__eeInput.ee_slEvent==EVENTCODE_EVoid, "CEnvironmentBase::MoveToMarker expects 'EVoid' as input!"); const EVoid &e = (const EVoid &)__eeInput;
|
|
#line 322 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(!(NextMarker ())){ Jump(STATE_CURRENT,0x03840005, FALSE, EInternal());return TRUE;}
|
|
#line 324 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
CalcDestination ();
|
|
#line 326 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
Jump(STATE_CURRENT,0x03840003, FALSE, EInternal());return TRUE;}BOOL CEnvironmentBase::H0x03840003_MoveToMarker_03(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840003
|
|
if(!((m_vDesiredPosition - GetPlacement () . pl_PositionVector ) . Length () > 5.0f)){ Jump(STATE_CURRENT,0x03840004, FALSE, EInternal());return TRUE;}
|
|
#line 327 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetTimerAfter(m_fMoveFrequency );
|
|
Jump(STATE_CURRENT, 0x03840001, FALSE, EBegin());return TRUE;}BOOL CEnvironmentBase::H0x03840001_MoveToMarker_01(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840001
|
|
switch(__eeInput.ee_slEvent){case(EVENTCODE_EBegin):{const EBegin&e= (EBegin&)__eeInput;
|
|
|
|
#line 329 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
MoveToPosition ();
|
|
#line 330 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return TRUE;
|
|
#line 331 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}ASSERT(FALSE);break;case(EVENTCODE_ETimer):{const ETimer&e= (ETimer&)__eeInput;
|
|
UnsetTimer();Jump(STATE_CURRENT,0x03840002, FALSE, EInternal());return TRUE;}ASSERT(FALSE);break;default: return FALSE; break;
|
|
#line 333 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}return TRUE;}BOOL CEnvironmentBase::H0x03840002_MoveToMarker_02(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840002
|
|
Jump(STATE_CURRENT,0x03840003, FALSE, EInternal());return TRUE;
|
|
#line 334 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}BOOL CEnvironmentBase::H0x03840004_MoveToMarker_04(const CEntityEvent &__eeInput) {
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840004
|
|
Jump(STATE_CURRENT,0x03840005, FALSE, EInternal());return TRUE;}BOOL CEnvironmentBase::H0x03840005_MoveToMarker_05(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840005
|
|
|
|
#line 337 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
StopMoving ();
|
|
#line 338 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
Return(STATE_CURRENT,EEnd ());
|
|
#line 338 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return TRUE; ASSERT(FALSE); return TRUE;};BOOL CEnvironmentBase::
|
|
#line 347 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
Activate(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT STATE_CEnvironmentBase_Activate
|
|
ASSERTMSG(__eeInput.ee_slEvent==EVENTCODE_EVoid, "CEnvironmentBase::Activate expects 'EVoid' as input!"); const EVoid &e = (const EVoid &)__eeInput;
|
|
#line 348 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetTimerAt(THINKTIME_NEVER);
|
|
Jump(STATE_CURRENT, 0x03840007, FALSE, EBegin());return TRUE;}BOOL CEnvironmentBase::H0x03840007_Activate_01(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840007
|
|
switch(__eeInput.ee_slEvent){case(EVENTCODE_EBegin):{const EBegin&e= (EBegin&)__eeInput;
|
|
Call(STATE_CURRENT, STATE_CEnvironmentBase_DoAction, TRUE, EVoid());return TRUE;}ASSERT(FALSE);break;case(EVENTCODE_EEnvironmentStop):{const EEnvironmentStop&e= (EEnvironmentStop&)__eeInput;
|
|
Jump(STATE_CURRENT, STATE_CEnvironmentBase_Stop, TRUE, EVoid());return TRUE;}ASSERT(FALSE);break;default: return FALSE; break;
|
|
#line 351 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}return TRUE;}BOOL CEnvironmentBase::H0x03840008_Activate_02(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840008
|
|
ASSERT(FALSE); return TRUE;};BOOL CEnvironmentBase::
|
|
#line 355 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
Stop(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT STATE_CEnvironmentBase_Stop
|
|
ASSERTMSG(__eeInput.ee_slEvent==EVENTCODE_EVoid, "CEnvironmentBase::Stop expects 'EVoid' as input!"); const EVoid &e = (const EVoid &)__eeInput;
|
|
#line 356 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
StopMoving ();
|
|
#line 357 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetTimerAt(THINKTIME_NEVER);
|
|
Jump(STATE_CURRENT, 0x0384000a, FALSE, EBegin());return TRUE;}BOOL CEnvironmentBase::H0x0384000a_Stop_01(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x0384000a
|
|
switch(__eeInput.ee_slEvent){case(EVENTCODE_EBegin):{const EBegin&e= (EBegin&)__eeInput;
|
|
return TRUE;}ASSERT(FALSE);break;case(EVENTCODE_EEnvironmentStart):{const EEnvironmentStart&e= (EEnvironmentStart&)__eeInput;
|
|
Jump(STATE_CURRENT, STATE_CEnvironmentBase_Activate, TRUE, EVoid());return TRUE;}ASSERT(FALSE);break;default: return FALSE; break;
|
|
#line 360 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}return TRUE;}BOOL CEnvironmentBase::H0x0384000b_Stop_02(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x0384000b
|
|
ASSERT(FALSE); return TRUE;};BOOL CEnvironmentBase::
|
|
#line 364 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
DoAction(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT STATE_CEnvironmentBase_DoAction
|
|
ASSERTMSG(__eeInput.ee_slEvent==EVENTCODE_EVoid, "CEnvironmentBase::DoAction expects 'EVoid' as input!"); const EVoid &e = (const EVoid &)__eeInput;
|
|
#line 365 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
Jump(STATE_CURRENT,0x03840015, FALSE, EInternal());return TRUE;}BOOL CEnvironmentBase::H0x03840015_DoAction_09(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840015
|
|
if(!(TRUE )){ Jump(STATE_CURRENT,0x03840016, FALSE, EInternal());return TRUE;}
|
|
#line 366 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
WaitOnMarker ();
|
|
#line 367 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(!(m_fWaitTime > 0.0f)){ Jump(STATE_CURRENT,0x0384000f, FALSE, EInternal());return TRUE;}
|
|
#line 368 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
PlayMarkerAnimation ();
|
|
#line 369 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetTimerAfter(m_fWaitTime );
|
|
Jump(STATE_CURRENT, 0x0384000d, FALSE, EBegin());return TRUE;}BOOL CEnvironmentBase::H0x0384000d_DoAction_01(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x0384000d
|
|
switch(__eeInput.ee_slEvent) {case EVENTCODE_EBegin: return TRUE;case EVENTCODE_ETimer: Jump(STATE_CURRENT,0x0384000e, FALSE, EInternal()); return TRUE;default: return FALSE; }}BOOL CEnvironmentBase::H0x0384000e_DoAction_02(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x0384000e
|
|
;Jump(STATE_CURRENT,0x0384000f, FALSE, EInternal());return TRUE;}BOOL CEnvironmentBase::H0x0384000f_DoAction_03(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x0384000f
|
|
|
|
#line 371 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
ChangeDefaultAnim ();
|
|
#line 373 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
MarkerParameters ();
|
|
#line 374 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
PlayDefaultAnim ();
|
|
#line 375 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
STATE_CEnvironmentBase_MoveToMarker, TRUE;
|
|
Jump(STATE_CURRENT, 0x03840010, FALSE, EBegin());return TRUE;}BOOL CEnvironmentBase::H0x03840010_DoAction_04(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840010
|
|
switch(__eeInput.ee_slEvent) {case EVENTCODE_EBegin: Call(STATE_CURRENT, STATE_CEnvironmentBase_MoveToMarker, TRUE, EVoid());return TRUE;case EVENTCODE_EEnd: Jump(STATE_CURRENT,0x03840011, FALSE, __eeInput); return TRUE;default: return FALSE; }}BOOL CEnvironmentBase::H0x03840011_DoAction_05(const CEntityEvent &__eeInput){
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840011
|
|
const EEnd&__e= (EEnd&)__eeInput;
|
|
;
|
|
#line 378 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(!(m_penTarget == NULL || ((CEnvironmentMarker &) * m_penTarget ) . m_penTarget == NULL )){ Jump(STATE_CURRENT,0x03840014, FALSE, EInternal());return TRUE;}
|
|
#line 379 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetTimerAt(THINKTIME_NEVER);
|
|
Jump(STATE_CURRENT, 0x03840012, FALSE, EBegin());return TRUE;}BOOL CEnvironmentBase::H0x03840012_DoAction_06(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840012
|
|
switch(__eeInput.ee_slEvent) {case EVENTCODE_EBegin: return TRUE;case EVENTCODE_ETimer: Jump(STATE_CURRENT,0x03840013, FALSE, EInternal()); return TRUE;default: return FALSE; }}BOOL CEnvironmentBase::H0x03840013_DoAction_07(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840013
|
|
;Jump(STATE_CURRENT,0x03840014, FALSE, EInternal());return TRUE;}BOOL CEnvironmentBase::H0x03840014_DoAction_08(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840014
|
|
Jump(STATE_CURRENT,0x03840015, FALSE, EInternal());return TRUE;
|
|
#line 381 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}BOOL CEnvironmentBase::H0x03840016_DoAction_10(const CEntityEvent &__eeInput) {
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840016
|
|
ASSERT(FALSE); return TRUE;};BOOL CEnvironmentBase::
|
|
#line 390 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
MainLoop(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT STATE_CEnvironmentBase_MainLoop
|
|
ASSERTMSG(__eeInput.ee_slEvent==EVENTCODE_EVoid, "CEnvironmentBase::MainLoop expects 'EVoid' as input!"); const EVoid &e = (const EVoid &)__eeInput;
|
|
#line 391 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
STATE_CEnvironmentBase_Stop, TRUE;
|
|
Jump(STATE_CURRENT, 0x03840018, FALSE, EBegin());return TRUE;}BOOL CEnvironmentBase::H0x03840018_MainLoop_01(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840018
|
|
switch(__eeInput.ee_slEvent) {case EVENTCODE_EBegin: Call(STATE_CURRENT, STATE_CEnvironmentBase_Stop, TRUE, EVoid());return TRUE;case EVENTCODE_EEnd: Jump(STATE_CURRENT,0x03840019, FALSE, __eeInput); return TRUE;default: return FALSE; }}BOOL CEnvironmentBase::H0x03840019_MainLoop_02(const CEntityEvent &__eeInput){
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x03840019
|
|
const EEnd&__e= (EEnd&)__eeInput;
|
|
;
|
|
#line 394 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_penWatcher -> SendEvent (EEnd ());
|
|
#line 397 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
Destroy ();
|
|
#line 399 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
Return(STATE_CURRENT,EVoid());
|
|
#line 399 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
return TRUE; ASSERT(FALSE); return TRUE;};BOOL CEnvironmentBase::
|
|
#line 402 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
Main(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT STATE_CEnvironmentBase_Main
|
|
ASSERTMSG(__eeInput.ee_slEvent==EVENTCODE_EVoid, "CEnvironmentBase::Main expects 'EVoid' as input!"); const EVoid &e = (const EVoid &)__eeInput;
|
|
#line 404 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
Initialize ();
|
|
#line 407 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
SetTimerAfter(FRnd () * 2.0f + 1.0f);
|
|
Jump(STATE_CURRENT, 0x0384001a, FALSE, EBegin());return TRUE;}BOOL CEnvironmentBase::H0x0384001a_Main_01(const CEntityEvent &__eeInput) {
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x0384001a
|
|
switch(__eeInput.ee_slEvent) {case EVENTCODE_EBegin: return TRUE;case EVENTCODE_ETimer: Jump(STATE_CURRENT,0x0384001b, FALSE, EInternal()); return TRUE;default: return FALSE; }}BOOL CEnvironmentBase::H0x0384001b_Main_02(const CEntityEvent &__eeInput){
|
|
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
|
|
#undef STATE_CURRENT
|
|
#define STATE_CURRENT 0x0384001b
|
|
;
|
|
#line 410 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
if(m_bUseWatcher ){
|
|
#line 411 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
InitializeWatcher (m_fWatcherFrequency );
|
|
#line 412 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
}
|
|
#line 414 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
m_strDescription = "Environment base";
|
|
#line 416 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentBase.es"
|
|
Jump(STATE_CURRENT, STATE_CEnvironmentBase_MainLoop, TRUE, EVoid());return TRUE; ASSERT(FALSE); return TRUE;}; |