Serious-Engine/Sources/EntitiesMP/VoiceHolder.cpp
2016-03-11 15:57:17 +02:00

116 lines
4.6 KiB
C++

/*
* This file is generated by Entity Class Compiler, (c) CroTeam 1997-98
*/
#line 4 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
#include "StdH.h"
extern INDEX ent_bReportBrokenChains;
#include <EntitiesMP/VoiceHolder.h>
#include <EntitiesMP/VoiceHolder_tables.h>
void CVoiceHolder::SetDefaultProperties(void) {
m_strName = "VoiceHolder";
m_strDescription = "";
m_fnmMessage = CTString("");
m_bActive = TRUE ;
m_ctMaxTrigs = 1;
CRationalEntity::SetDefaultProperties();
}
#line 29 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
void CVoiceHolder::Precache(void)
#line 30 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
{
#line 31 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
m_aps . Precache (m_fnmMessage );
#line 32 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
}
#line 33 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
const CTString & CVoiceHolder::GetDescription(void)const {
#line 34 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
((CTString &) m_strDescription ) . PrintF ("%s" , m_fnmMessage . FileName ());
#line 35 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
return m_strDescription ;
#line 36 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
}
BOOL CVoiceHolder::
#line 39 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
Main(const CEntityEvent &__eeInput) {
#undef STATE_CURRENT
#define STATE_CURRENT STATE_CVoiceHolder_Main
ASSERTMSG(__eeInput.ee_slEvent==EVENTCODE_EVoid, "CVoiceHolder::Main expects 'EVoid' as input!"); const EVoid &e = (const EVoid &)__eeInput;
#line 41 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
InitAsEditorModel ();
#line 42 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
SetPhysicsFlags (EPF_MODEL_IMMATERIAL );
#line 43 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
SetCollisionFlags (ECF_IMMATERIAL );
#line 46 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
SetModel (MODEL_MARKER );
#line 47 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
SetModelMainTexture (TEXTURE_MARKER );
#line 48 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
SetTimerAt(THINKTIME_NEVER);
Jump(STATE_CURRENT, 0x00e70000, FALSE, EBegin());return TRUE;}BOOL CVoiceHolder::H0x00e70000_Main_01(const CEntityEvent &__eeInput) {
#undef STATE_CURRENT
#define STATE_CURRENT 0x00e70000
switch(__eeInput.ee_slEvent){case(EVENTCODE_ETrigger):{const ETrigger&eTrigger= (ETrigger&)__eeInput;
#line 50 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
if(! m_bActive ){
#line 51 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
return TRUE;
#line 52 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
}
#line 53 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
CEntity * penCaused = FixupCausedToPlayer (this , eTrigger . penCaused );
#line 54 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
EVoiceMessage eMsg ;
#line 55 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
eMsg . fnmMessage = m_fnmMessage ;
#line 56 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
penCaused -> SendEvent (eMsg );
#line 58 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
if(m_ctMaxTrigs > 0){
#line 60 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
m_ctMaxTrigs -= 1;
#line 62 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
if(m_ctMaxTrigs <= 0){
#line 64 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
Destroy ();
#line 65 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
UnsetTimer();Jump(STATE_CURRENT,0x00e70001, FALSE, EInternal());return TRUE;
#line 66 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
}
#line 67 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
}
#line 68 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
return TRUE;
#line 69 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
}ASSERT(FALSE);break;case(EVENTCODE_EActivate):{const EActivate&e= (EActivate&)__eeInput;
#line 71 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
m_bActive = TRUE ;
#line 72 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
return TRUE;
#line 73 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
}ASSERT(FALSE);break;case(EVENTCODE_EDeactivate):{const EDeactivate&e= (EDeactivate&)__eeInput;
#line 75 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
m_bActive = FALSE ;
#line 76 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
return TRUE;
#line 77 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
}ASSERT(FALSE);break;default: return FALSE; break;
#line 78 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
}return TRUE;}BOOL CVoiceHolder::H0x00e70001_Main_02(const CEntityEvent &__eeInput){
ASSERT(__eeInput.ee_slEvent==EVENTCODE_EInternal);
#undef STATE_CURRENT
#define STATE_CURRENT 0x00e70001
#line 79 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
Return(STATE_CURRENT,EVoid());
#line 79 "D:/SE1_GPL/Sources/EntitiesMP/VoiceHolder.es"
return TRUE; ASSERT(FALSE); return TRUE;};