本文整理汇总了C++中CServerDE::GetPropVector方法的典型用法代码示例。如果您正苦于以下问题:C++ CServerDE::GetPropVector方法的具体用法?C++ CServerDE::GetPropVector怎么用?C++ CServerDE::GetPropVector使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CServerDE
的用法示例。
在下文中一共展示了CServerDE::GetPropVector方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: ReadProp
void PolyGrid::ReadProp(ObjectCreateStruct * pStruct)
{
CServerDE* pServerDE = GetServerDE();
if (!pServerDE) return;
pStruct->m_Flags = FLAG_VISIBLE;
char buf[MAX_CS_FILENAME_LEN];
buf[0] = '\0';
pServerDE->GetPropString("SpriteSurfaceName", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrSurfaceSprite = pServerDE->CreateString(buf);
if (pServerDE->GetPropVector("Dims", &m_vDims) == DE_OK)
{
m_bSetup = DTRUE;
}
pServerDE->GetPropVector("Color1", &m_vColor1);
pServerDE->GetPropVector("Color2", &m_vColor2);
pServerDE->GetPropReal("XScaleMin", &m_fXScaleMin);
pServerDE->GetPropReal("XScaleMax", &m_fXScaleMax);
pServerDE->GetPropReal("YScaleMin", &m_fYScaleMin);
pServerDE->GetPropReal("YScaleMax", &m_fYScaleMax);
pServerDE->GetPropReal("XScaleDuration", &m_fXScaleDuration);
pServerDE->GetPropReal("YScaleDuration", &m_fYScaleDuration);
pServerDE->GetPropReal("XPan", &m_fXPan);
pServerDE->GetPropReal("YPan", &m_fYPan);
pServerDE->GetPropReal("Alpha", &m_fAlpha);
long nLongVal;
if (pServerDE->GetPropLongInt("NumPolies", &nLongVal) == DE_OK)
{
m_dwNumPolies = (DDWORD)nLongVal;
}
pServerDE->GetPropLongInt("PlasmaType", &nLongVal);
m_nPlasmaType = (DBYTE)nLongVal;
pServerDE->GetPropLongInt("Ring1Rate", &nLongVal);
m_nRingRate[0] = (DBYTE)nLongVal;
pServerDE->GetPropLongInt("Ring2Rate", &nLongVal);
m_nRingRate[1] = (DBYTE)nLongVal;
pServerDE->GetPropLongInt("Ring3Rate", &nLongVal);
m_nRingRate[2] = (DBYTE)nLongVal;
pServerDE->GetPropLongInt("Ring4Rate", &nLongVal);
m_nRingRate[3] = (DBYTE)nLongVal;
}
示例2: ReadProp
void VolumeBrush::ReadProp(ObjectCreateStruct *pStruct)
{
CServerDE* pServerDE = GetServerDE();
if (!pServerDE || !pStruct) return;
long nLongVal;
char buf[MAX_CS_FILENAME_LEN];
pServerDE->GetPropBool("Hidden", &m_bHidden);
pServerDE->GetPropBool("ShowSurface", &m_bShowSurface);
buf[0] = '\0';
pServerDE->GetPropString("SpriteSurfaceName", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrSurfaceSprite = pServerDE->CreateString(buf);
pServerDE->GetPropBool( "FogEnable", &m_bFogEnable );
pServerDE->GetPropReal( "FogFarZ", &m_fFogFarZ );
pServerDE->GetPropReal( "FogNearZ", &m_fFogNearZ );
pServerDE->GetPropVector( "FogColor", &m_vFogColor );
pServerDE->GetPropReal("XScaleMin", &m_fXScaleMin);
pServerDE->GetPropReal("XScaleMax", &m_fXScaleMax);
pServerDE->GetPropReal("YScaleMin", &m_fYScaleMin);
pServerDE->GetPropReal("YScaleMax", &m_fYScaleMax);
pServerDE->GetPropReal("XScaleDuration", &m_fXScaleDuration);
pServerDE->GetPropReal("YScaleDuration", &m_fYScaleDuration);
pServerDE->GetPropReal("SurfaceHeight", &m_fSurfaceHeight);
pServerDE->GetPropVector("SurfaceColor1", &m_vSurfaceColor1);
pServerDE->GetPropVector("SurfaceColor2", &m_vSurfaceColor2);
pServerDE->GetPropReal("Viscosity", &m_fViscosity);
pServerDE->GetPropReal( "SurfaceAlpha", &m_fSurfaceAlpha);
if (pServerDE->GetPropLongInt("Code", &nLongVal) == DE_OK)
m_eContainerCode = (ContainerCode)nLongVal;
pServerDE->GetPropVector("Current", &m_vCurrent);
pServerDE->GetPropReal("Damage", &m_fDamage);
if (pServerDE->GetPropLongInt("DamageType", &nLongVal) == DE_OK)
m_nDamageType = (DBYTE)nLongVal;
pServerDE->GetPropBool("Locked", &m_bLocked);
pServerDE->GetPropBool("UnlockKeyRemove", &m_bUnlockKeyRemove);
buf[0] = '\0';
pServerDE->GetPropString("UnlockKeyName", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrKeyName = pServerDE->CreateString(buf);
if (pServerDE->GetPropLongInt("NumSurfacePolies", &nLongVal) == DE_OK)
{
m_dwNumSurfacePolies = (DDWORD)nLongVal;
}
}
示例3: ReadProp
DBOOL ObjectiveTrigger::ReadProp(ObjectCreateStruct *pData)
{
CServerDE* pServerDE = BaseClass::GetServerDE();
if (!pServerDE || !pData) return DFALSE;
char buf[MAX_CS_FILENAME_LEN];
pServerDE->GetPropVector("Dims", &m_vDims);
pServerDE->GetPropBool("PlayerTriggerable", &m_bPlayerTriggerable);
pServerDE->GetPropBool("AITriggerable", &m_bAITriggerable);
buf[0] = '\0';
pServerDE->GetPropString("AITriggerName", buf, MAX_CS_FILENAME_LEN);
if (buf[0] && strlen(buf)) m_hstrAIName = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("AddObjectives", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hAddObjectives = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("RemoveObjectives", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hRemoveObjectives = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("CompleteObjectives", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hCompletedObjectives = pServerDE->CreateString(buf);
return DTRUE;
}
示例4: ReadProp
void Explosion::ReadProp(ObjectCreateStruct *pStruct)
{
CServerDE* pServerDE = GetServerDE();
if (!pServerDE || !pStruct) return;
char buf[MAX_CS_FILENAME_LEN];
buf[0] = '\0';
pServerDE->GetPropString("Skin", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrSkinName = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("Model", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrModelName = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("Sound", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrSound = pServerDE->CreateString(buf);
pServerDE->GetPropReal("SoundRadius", &m_fSoundRadius);
pServerDE->GetPropReal("DamageRadius", &m_fDamageRadius);
pServerDE->GetPropReal("MaxDamage", &m_fMaxDamage);
pServerDE->GetPropReal("MinScale", &m_fMinScale);
pServerDE->GetPropReal("MaxScale", &m_fMaxScale);
pServerDE->GetPropReal("Duration", &m_fMinScale);
pServerDE->GetPropBool("CreateLight", &m_bCreateLight);
pServerDE->GetPropVector("LightColor", &m_vLightColor);
VEC_DIVSCALAR(m_vLightColor, m_vLightColor, 255.0f);
pServerDE->GetPropBool("CreateSmoke", &m_bCreateSmoke);
pServerDE->GetPropBool("CreateShockwave", &m_bCreateShockwave);
buf[0] = '\0';
pServerDE->GetPropString("ShockwaveFile", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrShockwaveSprite = pServerDE->CreateString(buf);
pServerDE->GetPropVector("ShockwaveScaleMin", &m_vShockwaveScaleMin);
pServerDE->GetPropVector("ShockwaveScaleMax", &m_vShockwaveScaleMax);
pServerDE->GetPropReal("ShockwaveDuration", &m_fShockwaveDuration);
pServerDE->GetPropReal("Delay", &m_fDelay);
pServerDE->GetPropVector("RotateSpeed", &m_vRotation);
return;
}
示例5: ReadProp
DBOOL Rain::ReadProp(ObjectCreateStruct *pStruct)
{
CServerDE* pServerDE = GetServerDE();
if (!pServerDE || !pStruct) return DFALSE;
pServerDE->GetPropVector("Dims", &m_vDims);
pServerDE->GetPropReal("Density", &m_fDensity);
pServerDE->GetPropReal("Lifetime", &m_fLifetime);
pServerDE->GetPropVector("Direction", &m_vDirection);
pServerDE->GetPropBool("AddGravity", &m_bGravity);
pServerDE->GetPropReal("ParticleScale", &m_fParticleScale);
pServerDE->GetPropReal("Spread", &m_fSpread);
pServerDE->GetPropBool("Triggered", &m_bTriggered);
pServerDE->GetPropVector("Color1", &m_vColor1);
pServerDE->GetPropVector("Color2", &m_vColor2);
pServerDE->GetPropReal("TimeLimit", &m_fTimeLimit);
pServerDE->GetPropReal("Pulse", &m_fPulse);
return DTRUE;
}
示例6: ReadProp
DBOOL CDestructable::ReadProp(BaseClass *pObject, ObjectCreateStruct *pStruct)
{
GenericProp genProp;
CServerDE* pServerDE = BaseClass::GetServerDE();
if (!pStruct || !pServerDE) return DFALSE;
char buf[MAX_CS_FILENAME_LEN];
buf[0] = '\0';
pServerDE->GetPropString("DamageTriggerTarget", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrDamageTriggerTarget = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("DamageTriggerMessage", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrDamageTriggerMessage = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("DeathTriggerTarget", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrDeathTriggerTarget = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("DeathTriggerMessage", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrDeathTriggerMessage = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("SpawnObject", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrSpawnObject = pServerDE->CreateString(buf);
pServerDE->GetPropVector("SpawnObjectVel", &m_vSpawnObjectVel);
pServerDE->GetPropBool("TriggerDestroyOnly", &m_bTriggerOnly);
// Create empty message strings if there is are trigger targets & no messages
if (m_hstrDamageTriggerTarget && !m_hstrDamageTriggerMessage)
m_hstrDamageTriggerMessage = pServerDE->CreateString("");
if (m_hstrDeathTriggerTarget && !m_hstrDeathTriggerMessage)
m_hstrDeathTriggerMessage = pServerDE->CreateString("");
if (g_pServerDE->GetPropGeneric("CanDamage", &genProp) == DE_OK)
{
m_bDestructable = genProp.m_Bool;
}
return DTRUE;
}
示例7: ReadProp
void CClientExplosionSFX::ReadProp(ObjectCreateStruct *pData)
{
CServerDE* pServerDE = GetServerDE();
if(!pServerDE || !pData) return;
long temp;
pServerDE->GetPropLongInt("ExplosionType", &temp);
m_nType = (DDWORD)temp;
pServerDE->GetPropReal("Damage", &m_fDamage);
pServerDE->GetPropReal("DamageRadius", &m_fDamageRadius);
pServerDE->GetPropVector("Direction", &m_vNormal);
char buf[MAX_CS_FILENAME_LEN];
buf[0] = '\0';
pServerDE->GetPropString("WaveFile", buf, MAX_CS_FILENAME_LEN);
if (buf[0]) m_hstrSound = pServerDE->CreateString(buf);
}
示例8: ReadProp
DBOOL Trigger::ReadProp(ObjectCreateStruct *pData)
{
CServerDE* pServerDE = GetServerDE();
if (!pServerDE || !pData) return DFALSE;
const int nMaxFilesize = 500;
char buf[nMaxFilesize + 1];
char propName[50];
for (int i=0; i < MAX_NUM_MESSAGES; i++)
{
sprintf(propName, "TargetName%d", i+1);
if (pServerDE->GetPropString(propName, buf, nMaxFilesize) == DE_OK)
{
m_hstrTargetName[i] = pServerDE->CreateString(buf);
}
sprintf(propName, "MessageName%d", i+1);
if (pServerDE->GetPropString(propName, buf, nMaxFilesize) == DE_OK)
{
m_hstrMessageName[i] = pServerDE->CreateString(buf);
}
}
pServerDE->GetPropBool("TriggerTouch", &m_bTriggerTouch);
buf[0] = '\0';
pServerDE->GetPropString("MessageTouch", buf, nMaxFilesize);
if (buf[0] && strlen(buf)) m_hstrMessageTouch = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("ActivationSound", buf, nMaxFilesize);
if (buf[0] && strlen(buf)) m_hstrActivationSound = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("AttachToObject", buf, nMaxFilesize);
if (buf[0] && strlen(buf)) m_hstrAttachToObject = pServerDE->CreateString(buf);
pServerDE->GetPropVector("Dims", &m_vDims);
pServerDE->GetPropReal("TriggerDelay", &m_fTriggerDelay);
pServerDE->GetPropReal("SendDelay", &m_fSendDelay);
pServerDE->GetPropReal("SoundRadius", &m_fSoundRadius);
pServerDE->GetPropBool("PlayerTriggerable", &m_bPlayerTriggerable);
pServerDE->GetPropBool("AITriggerable", &m_bAITriggerable);
pServerDE->GetPropBool("Locked", &m_bLocked);
buf[0] = '\0';
pServerDE->GetPropString("UnlockKey", buf, nMaxFilesize);
if (buf[0] && strlen(buf)) m_hstrUnlockKey = pServerDE->CreateString(buf);
pServerDE->GetPropReal("SoundRadius", &m_fSoundRadius);
pServerDE->GetPropReal("AccessDeniedMsg", &m_fAccessDeniedMsg);
pServerDE->GetPropReal("AccessGrantedMsg", &m_fAccessGrantedMsg);
buf[0] = '\0';
pServerDE->GetPropString("AccessDeniedSound", buf, nMaxFilesize);
if (buf[0] && strlen(buf)) m_hstrAccessDeniedSound = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("AccessGrantedSound", buf, nMaxFilesize);
if (buf[0] && strlen(buf)) m_hstrAccessGrantedSound = pServerDE->CreateString(buf);
buf[0] = '\0';
pServerDE->GetPropString("AITriggerName", buf, nMaxFilesize);
if (buf[0] && strlen(buf)) m_hstrAIName = pServerDE->CreateString(buf);
long nLongVal;
pServerDE->GetPropLongInt("ActivationCount", &nLongVal);
m_nActivationCount = nLongVal;
pServerDE->GetPropBool("WeightedTrigger", &m_bWeightedTrigger);
pServerDE->GetPropReal("Message1Weight", &m_fMessage1Weight);
pServerDE->GetPropBool("TimedTrigger", &m_bTimedTrigger);
pServerDE->GetPropReal("MinTriggerTime", &m_fMinTriggerTime);
pServerDE->GetPropReal("MaxTriggerTime", &m_fMaxTriggerTime);
m_fNextTriggerTime = pServerDE->GetTime() + m_fMinTriggerTime;
return DTRUE;
}
示例9: ReadProp
void CClientWarpGateSFX::ReadProp(ObjectCreateStruct *pData)
{
CServerDE* pServerDE = GetServerDE();
if(!pServerDE || !pData) return;
char szString[MAX_CS_FILENAME_LEN];
long tempLong;
if (wSpr.hstrSprite) // [blg]
{
g_pServerDE->FreeString(wSpr.hstrSprite);
}
if (wPS1.hstrParticle) // [blg]
{
g_pServerDE->FreeString(wPS1.hstrParticle);
}
if (wPS2.hstrParticle) // [blg]
{
g_pServerDE->FreeString(wPS2.hstrParticle);
}
pServerDE->GetPropReal("RampUpTime", &fRampUpTime);
pServerDE->GetPropReal("RampDownTime", &fRampDownTime);
pServerDE->GetPropBool("InitiallyOn", &bOn);
pServerDE->GetPropReal("SpriteMinScale", &wSpr.fMinScale);
pServerDE->GetPropReal("SpriteMaxScale", &wSpr.fMaxScale);
pServerDE->GetPropReal("SpriteAlpha", &wSpr.fAlpha);
pServerDE->GetPropLongInt("SpriteRampUpType", &tempLong);
wSpr.nRampUpType = (DDWORD)tempLong;
pServerDE->GetPropLongInt("SpriteRampDownType", &tempLong);
wSpr.nRampDownType = (DDWORD)tempLong;
pServerDE->GetPropBool("SpriteAlign", &wSpr.bAlign);
pServerDE->GetPropString("SpriteFile", szString, MAX_CS_FILENAME_LEN);
wSpr.hstrSprite = pServerDE->CreateString(szString);
pServerDE->GetPropReal("PS1SystemRadius", &wPS1.fSystemRadius);
pServerDE->GetPropReal("PS1PositionRadius", &wPS1.fPosRadius);
pServerDE->GetPropVector("PS1Offset", &wPS1.vOffset);
pServerDE->GetPropVector("PS1Rotations", &wPS1.vRotations);
pServerDE->GetPropReal("PS1MinVelocity", &wPS1.fMinVelocity);
pServerDE->GetPropReal("PS1MaxVelocity", &wPS1.fMaxVelocity);
pServerDE->GetPropLongInt("PS1NumParticles", &tempLong);
wPS1.nNumParticles = (DDWORD)tempLong;
pServerDE->GetPropLongInt("PS1EmitType", &tempLong);
wPS1.nEmitType = (DDWORD)tempLong;
pServerDE->GetPropColor("PS1MinColor", &wPS1.vMinColor);
pServerDE->GetPropColor("PS1MaxColor", &wPS1.vMaxColor);
pServerDE->GetPropReal("PS1SystemAlpha", &wPS1.fAlpha);
pServerDE->GetPropReal("PS1MinLifetime", &wPS1.fMinLifetime);
pServerDE->GetPropReal("PS1MaxLifetime", &wPS1.fMaxLifetime);
pServerDE->GetPropReal("PS1AddDelay", &wPS1.fAddDelay);
pServerDE->GetPropReal("PS1Gravity", &wPS1.fGravity);
pServerDE->GetPropLongInt("PS1RampUpType", &tempLong);
wPS1.nRampUpType = (DDWORD)tempLong;
pServerDE->GetPropLongInt("PS1RampDownType", &tempLong);
wPS1.nRampDownType = (DDWORD)tempLong;
pServerDE->GetPropBool("PS1Align", &wPS1.bAlign);
pServerDE->GetPropString("PS1ParticleFile", szString, MAX_CS_FILENAME_LEN);
wPS1.hstrParticle = pServerDE->CreateString(szString);
pServerDE->GetPropReal("PS2SystemRadius", &wPS2.fSystemRadius);
pServerDE->GetPropReal("PS2PositionRadius", &wPS2.fPosRadius);
pServerDE->GetPropVector("PS2Offset", &wPS2.vOffset);
pServerDE->GetPropVector("PS2Rotations", &wPS2.vRotations);
pServerDE->GetPropReal("PS2MinVelocity", &wPS2.fMinVelocity);
pServerDE->GetPropReal("PS2MaxVelocity", &wPS2.fMaxVelocity);
pServerDE->GetPropLongInt("PS2NumParticles", &tempLong);
wPS2.nNumParticles = (DDWORD)tempLong;
pServerDE->GetPropLongInt("PS2EmitType", &tempLong);
wPS2.nEmitType = (DDWORD)tempLong;
pServerDE->GetPropColor("PS2MinColor", &wPS2.vMinColor);
pServerDE->GetPropColor("PS2MaxColor", &wPS2.vMaxColor);
pServerDE->GetPropReal("PS2SystemAlpha", &wPS2.fAlpha);
pServerDE->GetPropReal("PS2MinLifetime", &wPS2.fMinLifetime);
pServerDE->GetPropReal("PS2MaxLifetime", &wPS2.fMaxLifetime);
pServerDE->GetPropReal("PS2AddDelay", &wPS2.fAddDelay);
pServerDE->GetPropReal("PS2Gravity", &wPS2.fGravity);
pServerDE->GetPropLongInt("PS2RampUpType", &tempLong);
wPS2.nRampUpType = (DDWORD)tempLong;
pServerDE->GetPropLongInt("PS2RampDownType", &tempLong);
wPS2.nRampDownType = (DDWORD)tempLong;
pServerDE->GetPropBool("PS2Align", &wPS2.bAlign);
pServerDE->GetPropString("PS2ParticleFile", szString, MAX_CS_FILENAME_LEN);
wPS2.hstrParticle = pServerDE->CreateString(szString);
pServerDE->GetPropReal("SoundRadius", &fSoundRadius);
pServerDE->GetPropString("RampUpSound", szString, MAX_CS_FILENAME_LEN);
hstrSound1 = pServerDE->CreateString(szString);
pServerDE->GetPropString("LoopSound", szString, MAX_CS_FILENAME_LEN);
hstrSound2 = pServerDE->CreateString(szString);
pServerDE->GetPropString("RampDownSound", szString, MAX_CS_FILENAME_LEN);
hstrSound3 = pServerDE->CreateString(szString);
return;
}