[HELP] BattleRoyal 'gPostBoxesMngr' : undeclared identifier
Error 1 error C2065: 'gPostBoxesMngr' : undeclared identifier
Code:
bool ServerGameLogic::CheckForPlayersAround(const r3dPoint3D& pos, float dist){
float distSq = dist * dist;
for(int i=0; i<curPlayers_; i++)
{
const obj_ServerPlayer* plr = plrList_[i];
if((plr->GetPosition() - pos).LengthSq() < distSq)
return true;
}
return false;
}
void ServerGameLogic::GetSpawnPositionBattleRoyale(const r3dPoint3D& GamePos, r3dPoint3D* pos, float* dir)
{
// Get random safezone position
srand((unsigned int)r3dGetTime());
int randNum = rand() % gPostBoxesMngr.numPostBoxes_;
r3dPoint3D postboxPoint = gPostBoxesMngr.postBoxes_[randNum]->GetPosition();
float radius = (gPostBoxesMngr.postBoxes_[randNum]->useRadius - 1);
Re: [HELP] BattleRoyal 'gPostBoxesMngr' : undeclared identifier
Error 1 error C2065: 'gPostBoxesMngr' : undeclared identifierundeclared identifier
Go an declare it. Simple
Re: [HELP] BattleRoyal 'gPostBoxesMngr' : undeclared identifier
help please ? don't speak english sorry bad.
Re: [HELP] BattleRoyal 'gPostBoxesMngr' : undeclared identifier
Quote:
Originally Posted by
Ownii
help please ? don't speak english sorry bad.
you need declare this variable in servergamelogic.h
'gPostBoxesMngr'
if you need more help contact me. :)
Re: [HELP] BattleRoyal 'gPostBoxesMngr' : undeclared identifier