mirror of
https://github.com/ptitSeb/Serious-Engine
synced 2024-11-29 13:25:52 +01:00
110 lines
4.5 KiB
C++
110 lines
4.5 KiB
C++
|
/*
|
||
|
* This file is generated by Entity Class Compiler, (c) CroTeam 1997-98
|
||
|
*/
|
||
|
|
||
|
#line 4 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
|
||
|
#include "StdH.h"
|
||
|
|
||
|
#include <EntitiesMP/EnvironmentMarker.h>
|
||
|
#include <EntitiesMP/EnvironmentMarker_tables.h>
|
||
|
void CEnvironmentMarker::SetDefaultProperties(void) {
|
||
|
m_fWaitTime = 0.0f;
|
||
|
m_fRandomTime = 0.0f;
|
||
|
m_fMarkerRange = 5.0f;
|
||
|
m_bFixedAnimLength = FALSE ;
|
||
|
m_bChangeDefaultAnim = FALSE ;
|
||
|
m_fMoveSpeed = -1.0f;
|
||
|
m_fRotateSpeed = -1.0f;
|
||
|
m_fnMdl = CTFILENAME("Models\\Editor\\Axis.mdl");
|
||
|
m_iAnim = 0;
|
||
|
m_moAnimData.SetData(NULL);
|
||
|
m_moAnimData.mo_toTexture.SetData(NULL);
|
||
|
CMarker::SetDefaultProperties();
|
||
|
}
|
||
|
|
||
|
#line 34 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
BOOL CEnvironmentMarker::MovesByTargetedRoute(CTString & strTargetProperty)const {
|
||
|
#line 35 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
strTargetProperty = "Target";
|
||
|
#line 36 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
return TRUE ;
|
||
|
#line 37 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
}
|
||
|
|
||
|
#line 39 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
BOOL CEnvironmentMarker::DropsMarker(CTFileName & fnmMarkerClass,CTString & strTargetProperty)const {
|
||
|
#line 40 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
fnmMarkerClass = CTFILENAME ("Classes\\EnvironmentMarker.ecl");
|
||
|
#line 41 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
strTargetProperty = "Target";
|
||
|
#line 42 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
return TRUE ;
|
||
|
#line 43 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
}
|
||
|
|
||
|
#line 45 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
CAnimData * CEnvironmentMarker::GetAnimData(SLONG slPropertyOffset) {
|
||
|
#line 46 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
if(slPropertyOffset == offsetof (CEnvironmentMarker , m_iAnim )){
|
||
|
#line 47 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
return m_moAnimData . GetData ();
|
||
|
#line 49 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
}else {
|
||
|
#line 50 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
return CEntity :: GetAnimData (slPropertyOffset );
|
||
|
#line 51 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
}
|
||
|
#line 52 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
}
|
||
|
|
||
|
#line 56 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
void CEnvironmentMarker::SetModelObject(void) {
|
||
|
#line 58 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
try {
|
||
|
#line 60 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
m_moAnimData . SetData_t (m_fnMdl );
|
||
|
#line 62 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
}catch (char * strError ){
|
||
|
#line 63 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
strError ;
|
||
|
#line 64 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
DECLARE_CTFILENAME (fnmDefault , "Models\\Editor\\Axis.mdl");
|
||
|
#line 66 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
try {
|
||
|
#line 68 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
m_moAnimData . SetData_t (fnmDefault );
|
||
|
#line 70 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
}catch (char * strErrorDefault ){
|
||
|
#line 71 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
FatalError (TRANS ("Cannot load default model '%s':\n%s") ,
|
||
|
#line 72 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
(CTString &) fnmDefault , strErrorDefault );
|
||
|
#line 73 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
}
|
||
|
#line 74 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
}
|
||
|
#line 75 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
}
|
||
|
BOOL CEnvironmentMarker::
|
||
|
#line 79 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
Main(const CEntityEvent &__eeInput) {
|
||
|
#undef STATE_CURRENT
|
||
|
#define STATE_CURRENT STATE_CEnvironmentMarker_Main
|
||
|
ASSERTMSG(__eeInput.ee_slEvent==EVENTCODE_EVoid, "CEnvironmentMarker::Main expects 'EVoid' as input!"); const EVoid &e = (const EVoid &)__eeInput;
|
||
|
#line 80 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
InitAsEditorModel ();
|
||
|
#line 81 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
SetPhysicsFlags (EPF_MODEL_IMMATERIAL );
|
||
|
#line 82 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
SetCollisionFlags (ECF_IMMATERIAL );
|
||
|
#line 85 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
SetModel (MODEL_MARKER );
|
||
|
#line 86 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
SetModelMainTexture (TEXTURE_MARKER );
|
||
|
#line 89 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
SetModelObject ();
|
||
|
#line 91 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
Return(STATE_CURRENT,EVoid());
|
||
|
#line 91 "D:/SE1_GPL/Sources/EntitiesMP/EnvironmentMarker.es"
|
||
|
return TRUE; ASSERT(FALSE); return TRUE;};
|