mirror of
https://github.com/ptitSeb/Serious-Engine
synced 2024-11-26 12:15:53 +01:00
589 lines
24 KiB
C++
589 lines
24 KiB
C++
|
/*
|
||
|
* This file is generated by Entity Class Compiler, (c) CroTeam 1997-98
|
||
|
*/
|
||
|
|
||
|
#line 4 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
|
||
|
#include "StdH.h"
|
||
|
#include "EntitiesMP/Effector.h"
|
||
|
#include "EntitiesMP/BackgroundViewer.h"
|
||
|
#include "EntitiesMP/WorldSettingsController.h"
|
||
|
|
||
|
#include <EntitiesMP/EffectMarker.h>
|
||
|
#include <EntitiesMP/EffectMarker_tables.h>
|
||
|
#line 31 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
|
||
|
extern void CBasicEffect_OnPrecache(CDLLEntityClass *pdec, INDEX iUser);
|
||
|
|
||
|
void CEffectMarker::SetDefaultProperties(void) {
|
||
|
m_emtType = EMT_NONE ;
|
||
|
m_penModel = NULL;
|
||
|
m_tmEffectLife = 10.0f;
|
||
|
m_penModel2 = NULL;
|
||
|
m_penEffector = NULL;
|
||
|
m_fShakeFalloff = 250.0f;
|
||
|
m_fShakeFade = 3.0f;
|
||
|
m_fShakeIntensityY = 0.1f;
|
||
|
m_fShakeFrequencyY = 5.0f;
|
||
|
m_fShakeIntensityB = 2.5f;
|
||
|
m_fShakeFrequencyB = 7.2f;
|
||
|
m_fShakeIntensityZ = 0.0f;
|
||
|
m_fShakeFrequencyZ = 5.0f;
|
||
|
m_betType = BET_ROCKET ;
|
||
|
m_fStretch = 1.0f;
|
||
|
m_colColor = COLOR(C_WHITE | CT_TRANSPARENT );
|
||
|
CMarker::SetDefaultProperties();
|
||
|
}
|
||
|
|
||
|
#line 68 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
void CEffectMarker::Precache(void)
|
||
|
#line 69 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 70 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
switch(m_betType )
|
||
|
#line 71 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 72 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_BASIC_EFFECT :
|
||
|
#line 73 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CDLLEntityClass * pdec = & CBasicEffect_DLLClass ;
|
||
|
#line 75 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CBasicEffect_OnPrecache (pdec , m_emtType );
|
||
|
#line 76 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 77 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 78 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
|
||
|
#line 81 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
BOOL CEffectMarker::IsTargetValid(SLONG slPropertyOffset,CEntity * penTarget)
|
||
|
#line 82 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 83 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(penTarget == NULL )
|
||
|
#line 84 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 85 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
return FALSE ;
|
||
|
#line 86 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 88 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(slPropertyOffset == offsetof (CEffectMarker , m_penModel ) ||
|
||
|
#line 89 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
slPropertyOffset == offsetof (CEffectMarker , m_penModel2 ))
|
||
|
#line 90 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 91 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
return IsOfClass (penTarget , "ModelHolder2");
|
||
|
#line 92 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 93 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
return TRUE ;
|
||
|
#line 94 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
|
||
|
#line 97 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
BOOL CEffectMarker::HandleEvent(const CEntityEvent & ee)
|
||
|
#line 98 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 99 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(ee . ee_slEvent == EVENTCODE_ETrigger )
|
||
|
#line 100 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 101 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
switch(m_emtType )
|
||
|
#line 102 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 103 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_SET_PLACEMENT :
|
||
|
#line 104 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 105 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penModel != NULL && m_penModel2 != NULL )
|
||
|
#line 106 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 107 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penModel -> Teleport (m_penModel2 -> GetPlacement () , FALSE );
|
||
|
#line 108 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 109 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 110 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 111 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_SET_PARENT :
|
||
|
#line 112 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 113 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penModel != NULL && m_penModel2 != NULL )
|
||
|
#line 114 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 115 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penModel -> SetParent (m_penModel2 );
|
||
|
#line 116 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 117 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 118 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 119 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_CLEAR_PARENT :
|
||
|
#line 120 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 121 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penModel != NULL )
|
||
|
#line 122 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 123 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penModel -> SetParent (NULL );
|
||
|
#line 124 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 125 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 126 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 127 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_SHAKE_IT_BABY :
|
||
|
#line 128 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 130 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CWorldSettingsController * pwsc = NULL ;
|
||
|
#line 132 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CBackgroundViewer * penBcgViewer = (CBackgroundViewer *) GetWorld () -> GetBackgroundViewer ();
|
||
|
#line 133 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(penBcgViewer != NULL && penBcgViewer -> m_penWorldSettingsController != NULL )
|
||
|
#line 134 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 135 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc = (CWorldSettingsController *) & * penBcgViewer -> m_penWorldSettingsController ;
|
||
|
#line 136 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_tmShakeStarted = _pTimer -> CurrentTick ();
|
||
|
#line 137 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_vShakePos = GetPlacement () . pl_PositionVector ;
|
||
|
#line 138 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_fShakeFalloff = m_fShakeFalloff ;
|
||
|
#line 139 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_fShakeFade = m_fShakeFade ;
|
||
|
#line 140 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_fShakeIntensityZ = m_fShakeIntensityZ ;
|
||
|
#line 141 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_tmShakeFrequencyZ = m_fShakeFrequencyZ ;
|
||
|
#line 142 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_fShakeIntensityY = m_fShakeIntensityY ;
|
||
|
#line 143 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_tmShakeFrequencyY = m_fShakeFrequencyY ;
|
||
|
#line 144 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_fShakeIntensityB = m_fShakeIntensityB ;
|
||
|
#line 145 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_tmShakeFrequencyB = m_fShakeFrequencyB ;
|
||
|
#line 146 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_bShakeFadeIn = FALSE ;
|
||
|
#line 147 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 148 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 149 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 150 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_HIDE_ENTITY :
|
||
|
#line 151 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 152 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penTarget != NULL )
|
||
|
#line 153 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 154 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penTarget -> SetFlags (m_penTarget -> GetFlags () | ENF_HIDDEN );
|
||
|
#line 155 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 156 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 157 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 158 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_SHOW_ENTITY :
|
||
|
#line 159 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 160 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penTarget != NULL )
|
||
|
#line 161 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 162 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penTarget -> SetFlags (m_penTarget -> GetFlags () & ~ ENF_HIDDEN );
|
||
|
#line 163 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 164 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 165 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 166 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_PLAYER_APPEAR :
|
||
|
#line 167 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penModel != NULL && IsOfClass (m_penModel , "ModelHolder2"))
|
||
|
#line 168 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 169 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CModelObject * pmo = m_penModel -> GetModelObject ();
|
||
|
#line 170 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(pmo != NULL )
|
||
|
#line 171 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 173 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CPlacement3D plFX = m_penModel -> GetPlacement ();
|
||
|
#line 174 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CEntity * penFX = CreateEntity (plFX , CLASS_EFFECTOR );
|
||
|
#line 175 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
ESpawnEffector eSpawnFX ;
|
||
|
#line 176 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . tmLifeTime = m_tmEffectLife ;
|
||
|
#line 177 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . eetType = ET_PORTAL_LIGHTNING ;
|
||
|
#line 178 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . penModel = m_penModel ;
|
||
|
#line 179 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
penFX -> Initialize (eSpawnFX );
|
||
|
#line 180 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 181 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 182 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 183 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_APPEARING_BIG_BLUE_FLARE :
|
||
|
#line 184 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 186 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CPlacement3D plFX = GetPlacement ();
|
||
|
#line 187 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CEntity * penFX = CreateEntity (plFX , CLASS_EFFECTOR );
|
||
|
#line 188 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
ESpawnEffector eSpawnFX ;
|
||
|
#line 189 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . tmLifeTime = m_tmEffectLife ;
|
||
|
#line 190 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . fSize = 1.0f;
|
||
|
#line 191 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . eetType = ET_SIZING_BIG_BLUE_FLARE ;
|
||
|
#line 192 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
penFX -> Initialize (eSpawnFX );
|
||
|
#line 193 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 194 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 195 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_BLEND_MODELS :
|
||
|
#line 196 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penModel != NULL && IsOfClass (m_penModel , "ModelHolder2") &&
|
||
|
#line 197 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penModel2 != NULL && IsOfClass (m_penModel2 , "ModelHolder2"))
|
||
|
#line 198 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 199 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penEffector == NULL )
|
||
|
#line 200 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 201 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CModelObject * pmo1 = m_penModel -> GetModelObject ();
|
||
|
#line 202 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CModelObject * pmo2 = m_penModel2 -> GetModelObject ();
|
||
|
#line 203 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(pmo1 != NULL && pmo2 != NULL )
|
||
|
#line 204 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 206 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CPlacement3D plFX = m_penModel -> GetPlacement ();
|
||
|
#line 207 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CEntity * penFX = CreateEntity (plFX , CLASS_EFFECTOR );
|
||
|
#line 208 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
ESpawnEffector eSpawnFX ;
|
||
|
#line 209 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . tmLifeTime = m_tmEffectLife ;
|
||
|
#line 210 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . eetType = ET_MORPH_MODELS ;
|
||
|
#line 211 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . penModel = m_penModel ;
|
||
|
#line 212 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . penModel2 = m_penModel2 ;
|
||
|
#line 213 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
penFX -> Initialize (eSpawnFX );
|
||
|
#line 214 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penEffector = penFX ;
|
||
|
#line 215 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 216 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 217 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
else
|
||
|
#line 218 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 219 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penEffector -> SendEvent (ETrigger ());
|
||
|
#line 220 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 221 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 222 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 223 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_DISAPPEAR_MODEL :
|
||
|
#line 224 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penModel != NULL && IsOfClass (m_penModel , "ModelHolder2"))
|
||
|
#line 225 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 226 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penEffector == NULL )
|
||
|
#line 227 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 228 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CModelObject * pmo = m_penModel -> GetModelObject ();
|
||
|
#line 229 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(pmo != NULL )
|
||
|
#line 230 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 232 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CPlacement3D plFX = m_penModel -> GetPlacement ();
|
||
|
#line 233 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CEntity * penFX = CreateEntity (plFX , CLASS_EFFECTOR );
|
||
|
#line 234 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
ESpawnEffector eSpawnFX ;
|
||
|
#line 235 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . tmLifeTime = m_tmEffectLife ;
|
||
|
#line 236 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . eetType = ET_DISAPPEAR_MODEL ;
|
||
|
#line 237 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . penModel = m_penModel ;
|
||
|
#line 238 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
penFX -> Initialize (eSpawnFX );
|
||
|
#line 239 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penEffector = penFX ;
|
||
|
#line 240 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 241 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 242 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
else
|
||
|
#line 243 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 244 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penEffector -> SendEvent (ETrigger ());
|
||
|
#line 245 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 246 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 247 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 248 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_APPEAR_MODEL :
|
||
|
#line 249 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penModel != NULL && IsOfClass (m_penModel , "ModelHolder2"))
|
||
|
#line 250 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 251 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penEffector == NULL )
|
||
|
#line 252 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 253 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CModelObject * pmo = m_penModel -> GetModelObject ();
|
||
|
#line 254 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(pmo != NULL )
|
||
|
#line 255 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 257 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CPlacement3D plFX = m_penModel -> GetPlacement ();
|
||
|
#line 258 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CEntity * penFX = CreateEntity (plFX , CLASS_EFFECTOR );
|
||
|
#line 259 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
ESpawnEffector eSpawnFX ;
|
||
|
#line 260 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . tmLifeTime = m_tmEffectLife ;
|
||
|
#line 261 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . eetType = ET_APPEAR_MODEL ;
|
||
|
#line 262 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . penModel = m_penModel ;
|
||
|
#line 263 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
penFX -> Initialize (eSpawnFX );
|
||
|
#line 264 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penEffector = penFX ;
|
||
|
#line 265 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 266 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 267 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
else
|
||
|
#line 268 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 269 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penEffector -> SendEvent (ETrigger ());
|
||
|
#line 270 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 271 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 272 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 273 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_BASIC_EFFECT :
|
||
|
#line 274 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 276 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CPlacement3D plEffect = GetPlacement ();
|
||
|
#line 277 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CEntityPointer penEffect = CreateEntity (plEffect , CLASS_BASIC_EFFECT );
|
||
|
#line 278 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
ESpawnEffect eSpawnEffect ;
|
||
|
#line 279 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnEffect . colMuliplier = C_WHITE | CT_OPAQUE ;
|
||
|
#line 280 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnEffect . betType = m_betType ;
|
||
|
#line 281 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnEffect . vStretch = FLOAT3D (m_fStretch , m_fStretch , m_fStretch );
|
||
|
#line 282 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
penEffect -> Initialize (eSpawnEffect );
|
||
|
#line 283 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 284 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 285 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_GLARE :
|
||
|
#line 286 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CWorldSettingsController * pwsc = GetWSC (this );
|
||
|
#line 287 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(pwsc != NULL )
|
||
|
#line 288 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 289 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_colGlade = m_colColor ;
|
||
|
#line 290 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_tmGlaringStarted = _pTimer -> CurrentTick ();
|
||
|
#line 291 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_tmGlaringEnded = pwsc -> m_tmGlaringStarted + m_tmEffectLife ,
|
||
|
#line 292 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_fGlaringFadeInRatio = 0.2f;
|
||
|
#line 293 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
pwsc -> m_fGlaringFadeOutRatio = 0.7f;
|
||
|
#line 294 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 295 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 296 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 297 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 298 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
else if(ee . ee_slEvent == EVENTCODE_EActivate )
|
||
|
#line 299 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 300 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
switch(m_emtType )
|
||
|
#line 301 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 302 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_APPEAR_DISAPPEAR :
|
||
|
#line 303 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penModel != NULL && IsOfClass (m_penModel , "ModelHolder2"))
|
||
|
#line 304 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 305 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CModelObject * pmo = m_penModel -> GetModelObject ();
|
||
|
#line 306 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(pmo != NULL )
|
||
|
#line 307 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 309 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CPlacement3D plFX = m_penModel -> GetPlacement ();
|
||
|
#line 310 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CEntity * penFX = CreateEntity (plFX , CLASS_EFFECTOR );
|
||
|
#line 311 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
ESpawnEffector eSpawnFX ;
|
||
|
#line 312 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . tmLifeTime = m_tmEffectLife ;
|
||
|
#line 313 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . eetType = ET_APPEAR_MODEL_NOW ;
|
||
|
#line 314 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . penModel = m_penModel ;
|
||
|
#line 315 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
penFX -> Initialize (eSpawnFX );
|
||
|
#line 316 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penEffector = penFX ;
|
||
|
#line 317 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 318 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 319 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 320 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 321 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 322 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
else if(ee . ee_slEvent == EVENTCODE_EDeactivate )
|
||
|
#line 323 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 324 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
switch(m_emtType )
|
||
|
#line 325 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 326 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
case EMT_APPEAR_DISAPPEAR :
|
||
|
#line 327 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(m_penModel != NULL && IsOfClass (m_penModel , "ModelHolder2"))
|
||
|
#line 328 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 329 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CModelObject * pmo = m_penModel -> GetModelObject ();
|
||
|
#line 330 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
if(pmo != NULL )
|
||
|
#line 331 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
{
|
||
|
#line 333 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CPlacement3D plFX = m_penModel -> GetPlacement ();
|
||
|
#line 334 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
CEntity * penFX = CreateEntity (plFX , CLASS_EFFECTOR );
|
||
|
#line 335 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
ESpawnEffector eSpawnFX ;
|
||
|
#line 336 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . tmLifeTime = m_tmEffectLife ;
|
||
|
#line 337 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . eetType = ET_DISAPPEAR_MODEL_NOW ;
|
||
|
#line 338 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
eSpawnFX . penModel = m_penModel ;
|
||
|
#line 339 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
penFX -> Initialize (eSpawnFX );
|
||
|
#line 340 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penEffector = penFX ;
|
||
|
#line 341 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 342 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 343 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
break ;
|
||
|
#line 344 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 345 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
#line 346 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
return FALSE ;
|
||
|
#line 347 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
}
|
||
|
BOOL CEffectMarker::
|
||
|
#line 351 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
Main(const CEntityEvent &__eeInput) {
|
||
|
#undef STATE_CURRENT
|
||
|
#define STATE_CURRENT STATE_CEffectMarker_Main
|
||
|
ASSERTMSG(__eeInput.ee_slEvent==EVENTCODE_EVoid, "CEffectMarker::Main expects 'EVoid' as input!"); const EVoid &e = (const EVoid &)__eeInput;
|
||
|
#line 354 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
InitAsEditorModel ();
|
||
|
#line 355 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
SetPhysicsFlags (EPF_MODEL_IMMATERIAL );
|
||
|
#line 356 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
SetCollisionFlags (ECF_IMMATERIAL );
|
||
|
#line 359 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
SetModel (MODEL_MARKER );
|
||
|
#line 360 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
SetModelMainTexture (TEXTURE_MARKER );
|
||
|
#line 362 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
m_penEffector = NULL ;
|
||
|
#line 363 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
Return(STATE_CURRENT,EVoid());
|
||
|
#line 363 "D:/SE1_GPL/Sources/EntitiesMP/EffectMarker.es"
|
||
|
return TRUE; ASSERT(FALSE); return TRUE;};
|