mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-17 02:51:27 +00:00
Obliterate hsBool
This commit is contained in:
@ -134,10 +134,10 @@ void plLinkEffectsMgr::IAddPsuedo(plPseudoLinkEffectMsg *msg)
|
||||
fPseudolist.Append(msg);
|
||||
}
|
||||
|
||||
hsBool plLinkEffectsMgr::IHuntWaitlist(plLinkEffectsTriggerMsg *msg)
|
||||
bool plLinkEffectsMgr::IHuntWaitlist(plLinkEffectsTriggerMsg *msg)
|
||||
{
|
||||
int i;
|
||||
hsBool found = false;
|
||||
bool found = false;
|
||||
for (i = fWaitlist.GetCount() - 1; i >= 0; i--)
|
||||
{
|
||||
if (fWaitlist[i] == msg)
|
||||
@ -152,10 +152,10 @@ hsBool plLinkEffectsMgr::IHuntWaitlist(plLinkEffectsTriggerMsg *msg)
|
||||
return found || IHuntWaitlist(msg->GetLinkKey());
|
||||
}
|
||||
|
||||
hsBool plLinkEffectsMgr::IHuntWaitlist(plKey linkKey)
|
||||
bool plLinkEffectsMgr::IHuntWaitlist(plKey linkKey)
|
||||
{
|
||||
int i;
|
||||
hsBool found = false;
|
||||
bool found = false;
|
||||
for (i = fWaitlist.GetCount() - 1; i >= 0; i--)
|
||||
{
|
||||
if (fWaitlist[i]->GetLinkKey() == linkKey)
|
||||
@ -172,10 +172,10 @@ hsBool plLinkEffectsMgr::IHuntWaitlist(plKey linkKey)
|
||||
return found;
|
||||
}
|
||||
|
||||
hsBool plLinkEffectsMgr::IHuntDeadlist(plLinkEffectsTriggerMsg *msg)
|
||||
bool plLinkEffectsMgr::IHuntDeadlist(plLinkEffectsTriggerMsg *msg)
|
||||
{
|
||||
int i;
|
||||
hsBool found = false;
|
||||
bool found = false;
|
||||
for (i = fDeadlist.GetCount() - 1; i >= 0; i--)
|
||||
{
|
||||
if (fDeadlist[i] == msg)
|
||||
@ -233,7 +233,7 @@ void plLinkEffectsMgr::ISendAllReadyCallbacks()
|
||||
}
|
||||
}
|
||||
|
||||
hsBool plLinkEffectsMgr::MsgReceive(plMessage *msg)
|
||||
bool plLinkEffectsMgr::MsgReceive(plMessage *msg)
|
||||
{
|
||||
plNetClientMgr* nc = plNetClientMgr::GetInstance();
|
||||
plNetLinkingMgr* lm = plNetLinkingMgr::GetInstance();
|
||||
|
@ -73,9 +73,9 @@ protected:
|
||||
void IRemovePseudo(plKey avatarKey);
|
||||
plPseudoLinkEffectMsg* IFindPseudo(plKey avatarKey);
|
||||
|
||||
hsBool IHuntWaitlist(plLinkEffectsTriggerMsg *msg);
|
||||
hsBool IHuntWaitlist(plKey linkKey);
|
||||
hsBool IHuntDeadlist(plLinkEffectsTriggerMsg *msg);
|
||||
bool IHuntWaitlist(plLinkEffectsTriggerMsg *msg);
|
||||
bool IHuntWaitlist(plKey linkKey);
|
||||
bool IHuntDeadlist(plLinkEffectsTriggerMsg *msg);
|
||||
void ISendAllReadyCallbacks();
|
||||
|
||||
public:
|
||||
@ -91,7 +91,7 @@ public:
|
||||
|
||||
plMessage *WaitForEffect(plKey linkKey);
|
||||
|
||||
virtual hsBool MsgReceive(plMessage *msg);
|
||||
virtual bool MsgReceive(plMessage *msg);
|
||||
};
|
||||
|
||||
#endif // plLinkEffectsMgr_inc
|
||||
|
@ -243,7 +243,7 @@ void plNetClientMgr::IRemoveCloneRoom()
|
||||
//
|
||||
// turn null send on/off. Null send does everything except actually send the msg out on the socket
|
||||
//
|
||||
void plNetClientMgr::SetNullSend(hsBool on)
|
||||
void plNetClientMgr::SetNullSend(bool on)
|
||||
{
|
||||
}
|
||||
|
||||
@ -850,7 +850,7 @@ int plNetClientMgr::IsLocallyOwned(const plSynchedObject* obj) const
|
||||
//
|
||||
// return localPlayer ptr
|
||||
//
|
||||
plSynchedObject* plNetClientMgr::GetLocalPlayer(hsBool forceLoad) const
|
||||
plSynchedObject* plNetClientMgr::GetLocalPlayer(bool forceLoad) const
|
||||
{
|
||||
if (forceLoad)
|
||||
return fLocalPlayerKey ? plSynchedObject::ConvertNoRef(fLocalPlayerKey->GetObjectPtr()) : nil;
|
||||
@ -895,12 +895,12 @@ plSynchedObject* plNetClientMgr::GetRemotePlayer(int i) const
|
||||
//
|
||||
// check if a key si a remote player
|
||||
//
|
||||
hsBool plNetClientMgr::IsRemotePlayerKey(const plKey pKey, int *idx)
|
||||
bool plNetClientMgr::IsRemotePlayerKey(const plKey pKey, int *idx)
|
||||
{
|
||||
if (pKey)
|
||||
{
|
||||
plKeyVec::iterator result=std::find(fRemotePlayerKeys.begin(), fRemotePlayerKeys.end(), pKey);
|
||||
hsBool found = result!=fRemotePlayerKeys.end();
|
||||
bool found = result!=fRemotePlayerKeys.end();
|
||||
if (idx)
|
||||
*idx = found ? result-fRemotePlayerKeys.begin() : -1;
|
||||
return found;
|
||||
@ -924,7 +924,7 @@ void plNetClientMgr::AddRemotePlayerKey(plKey pKey)
|
||||
//
|
||||
// MsgReceive handler for plasma messages
|
||||
//
|
||||
hsBool plNetClientMgr::MsgReceive( plMessage* msg )
|
||||
bool plNetClientMgr::MsgReceive( plMessage* msg )
|
||||
{
|
||||
if (plNetLinkingMgr::GetInstance()->MsgReceive( msg ))
|
||||
return true;
|
||||
|
@ -210,13 +210,13 @@ private:
|
||||
int ISendMembersListRequest();
|
||||
int ISendRoomsReset();
|
||||
void ISendCCRPetition(plCCRPetitionMsg* petMsg);
|
||||
void ISendCameraReset(hsBool bEnteringAge);
|
||||
void ISendCameraReset(bool bEnteringAge);
|
||||
|
||||
hsBool IUpdateListenList(double secs);
|
||||
bool IUpdateListenList(double secs);
|
||||
void IHandleNetVoiceListMsg(plNetVoiceListMsg* msg);
|
||||
hsBool IApplyNewListenList(std::vector<DistSqInfo>& newListenList, hsBool forceSynch);
|
||||
bool IApplyNewListenList(std::vector<DistSqInfo>& newListenList, bool forceSynch);
|
||||
int IPrepMsg(plNetMessage* msg);
|
||||
void IPlayerChangeAge(hsBool exiting, int32_t spawnPt);
|
||||
void IPlayerChangeAge(bool exiting, int32_t spawnPt);
|
||||
|
||||
void IAddCloneRoom();
|
||||
void IRemoveCloneRoom();
|
||||
@ -252,7 +252,7 @@ public:
|
||||
void StartLinkOutFX();
|
||||
void StartLinkInFX();
|
||||
|
||||
hsBool MsgReceive(plMessage* msg);
|
||||
bool MsgReceive(plMessage* msg);
|
||||
void Shutdown();
|
||||
int Init();
|
||||
|
||||
@ -280,8 +280,8 @@ public:
|
||||
void SetSPDesiredPlayerName( const char * value ) { fSPDesiredPlayerName=value;}
|
||||
const char * GetSPDesiredPlayerName() const { return fSPDesiredPlayerName.c_str(); }
|
||||
|
||||
void SetLocalPlayerKey(plKey l, hsBool pageOut=false);
|
||||
void SetNullSend(hsBool on); // turn null send on/off
|
||||
void SetLocalPlayerKey(plKey l, bool pageOut=false);
|
||||
void SetNullSend(bool on); // turn null send on/off
|
||||
void SetPingServer(uint8_t serverType) { fPingServerType = serverType; }
|
||||
|
||||
// getters
|
||||
@ -293,10 +293,10 @@ public:
|
||||
uint8_t GetJoinOrder() const { return fJoinOrder; } // only valid at join time
|
||||
|
||||
plKey GetLocalPlayerKey() const { return fLocalPlayerKey; }
|
||||
plSynchedObject* GetLocalPlayer(hsBool forceLoad=false) const;
|
||||
plSynchedObject* GetLocalPlayer(bool forceLoad=false) const;
|
||||
|
||||
hsBool IsPeerToPeer() const { return false; }
|
||||
hsBool IsConnected() const { return true; }
|
||||
bool IsPeerToPeer() const { return false; }
|
||||
bool IsConnected() const { return true; }
|
||||
|
||||
void IncNumInitialSDLStates();
|
||||
void ResetNumInitialSDLStates() { fNumInitialSDLStates=0; }
|
||||
@ -321,7 +321,7 @@ public:
|
||||
const plKeyVec& RemotePlayerKeys() const { return fRemotePlayerKeys; }
|
||||
plSynchedObject* GetRemotePlayer(int i) const;
|
||||
void AddRemotePlayerKey(plKey p);
|
||||
hsBool IsRemotePlayerKey(const plKey p, int* idx=nil);
|
||||
bool IsRemotePlayerKey(const plKey p, int* idx=nil);
|
||||
bool IsAPlayerKey(const plKey pKey) { return (pKey==GetLocalPlayerKey() || IsRemotePlayerKey(pKey)); }
|
||||
|
||||
void SetConsoleOutput( bool b ) { SetFlagsBit(kConsoleOutput, b); }
|
||||
|
@ -90,7 +90,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
extern hsBool gDataServerLocal;
|
||||
extern bool gDataServerLocal;
|
||||
|
||||
|
||||
// Load Player object
|
||||
@ -175,7 +175,7 @@ plKey plNetClientMgr::ILoadClone(plLoadCloneMsg *pCloneMsg)
|
||||
// Cause a player to respawn. This is typically called on the local player when he links to a new age.
|
||||
// or for unspawn:
|
||||
//
|
||||
void plNetClientMgr::IPlayerChangeAge(hsBool exitAge, int32_t spawnPt)
|
||||
void plNetClientMgr::IPlayerChangeAge(bool exitAge, int32_t spawnPt)
|
||||
{
|
||||
plArmatureMod *avatar = plAvatarMgr::GetInstance()->GetLocalAvatar();
|
||||
|
||||
@ -186,7 +186,7 @@ void plNetClientMgr::IPlayerChangeAge(hsBool exitAge, int32_t spawnPt)
|
||||
avatar->LeaveAge();
|
||||
else
|
||||
{
|
||||
hsBool validSpawn = (spawnPt >= 0);
|
||||
bool validSpawn = (spawnPt >= 0);
|
||||
avatar->EnterAge(!validSpawn);
|
||||
if (validSpawn)
|
||||
avatar->SpawnAt(spawnPt, hsTimer::GetSysSeconds());
|
||||
|
@ -179,7 +179,7 @@ void plNetClientMgr::ISendCCRPetition(plCCRPetitionMsg* petMsg)
|
||||
//
|
||||
// send a msg to reset the camera in a new age
|
||||
//
|
||||
void plNetClientMgr::ISendCameraReset(hsBool bEnteringAge)
|
||||
void plNetClientMgr::ISendCameraReset(bool bEnteringAge)
|
||||
{
|
||||
plCameraMsg* pCamMsg = new plCameraMsg;
|
||||
if (bEnteringAge)
|
||||
@ -314,9 +314,9 @@ int plNetClientMgr::ISendGameMessage(plMessage* msg)
|
||||
|
||||
// check if this msg uses direct communication (sent to specific rcvrs)
|
||||
// if so the server can filter it
|
||||
hsBool bCast = msg->HasBCastFlag(plMessage::kBCastByExactType) ||
|
||||
bool bCast = msg->HasBCastFlag(plMessage::kBCastByExactType) ||
|
||||
msg->HasBCastFlag(plMessage::kBCastByType);
|
||||
hsBool directCom = msg->GetNumReceivers()>0;
|
||||
bool directCom = msg->GetNumReceivers()>0;
|
||||
if( directCom )
|
||||
{
|
||||
// It's direct if we have receivers AND any of them are in non-virtual locations
|
||||
@ -357,7 +357,7 @@ int plNetClientMgr::ISendGameMessage(plMessage* msg)
|
||||
//
|
||||
// CCRs can route a plMessage to all online players.
|
||||
//
|
||||
hsBool ccrSendToAllPlayers = false;
|
||||
bool ccrSendToAllPlayers = false;
|
||||
#ifndef PLASMA_EXTERNAL_RELEASE
|
||||
if ( AmCCR() )
|
||||
{
|
||||
@ -373,7 +373,7 @@ int plNetClientMgr::ISendGameMessage(plMessage* msg)
|
||||
//
|
||||
if ( !ccrSendToAllPlayers )
|
||||
{
|
||||
hsBool allowInterAge = msg->HasBCastFlag( plMessage::kNetAllowInterAge );
|
||||
bool allowInterAge = msg->HasBCastFlag( plMessage::kNetAllowInterAge );
|
||||
if ( allowInterAge )
|
||||
netMsgWrap->SetBit(plNetMessage::kInterAgeRouting);
|
||||
}
|
||||
|
@ -79,9 +79,9 @@ bool lessComp(DistSqInfo a, DistSqInfo b)
|
||||
// send listenList update msgs to old and new members in the list
|
||||
// return true if the new list is different
|
||||
//
|
||||
hsBool plNetClientMgr::IApplyNewListenList(std::vector<DistSqInfo>& newListenList, hsBool forceSynch)
|
||||
bool plNetClientMgr::IApplyNewListenList(std::vector<DistSqInfo>& newListenList, bool forceSynch)
|
||||
{
|
||||
hsBool changed=false;
|
||||
bool changed=false;
|
||||
int i;
|
||||
|
||||
// see if new listen list differs from current one
|
||||
@ -115,7 +115,7 @@ hsBool plNetClientMgr::IApplyNewListenList(std::vector<DistSqInfo>& newListenLis
|
||||
llu.SetAdding(false);
|
||||
for(i=0;i<GetListenList()->GetNumMembers(); i++)
|
||||
{
|
||||
hsBool found=false;
|
||||
bool found=false;
|
||||
if (!forceSynch)
|
||||
{
|
||||
int j;
|
||||
@ -208,14 +208,14 @@ hsBool plNetClientMgr::IApplyNewListenList(std::vector<DistSqInfo>& newListenLis
|
||||
// Returns true if the listenList was changed.
|
||||
// Note: Updates distSq to each member. Other things rely on this so we must do it even if p2p is disabled.
|
||||
//
|
||||
hsBool plNetClientMgr::IUpdateListenList(double secs)
|
||||
bool plNetClientMgr::IUpdateListenList(double secs)
|
||||
{
|
||||
if (GetFlagsBit(kDisabled))
|
||||
return false;
|
||||
if (!fLocalPlayerKey || !fLocalPlayerKey->ObjectIsLoaded())
|
||||
return false;
|
||||
|
||||
hsBool changed = false;
|
||||
bool changed = false;
|
||||
|
||||
if (secs - GetListenList()->GetLastUpdateTime()>plNetListenList::kUpdateInterval)
|
||||
{
|
||||
|
@ -314,7 +314,7 @@ std::string plNetLinkingMgr::GetProperAgeName( const char * ageName )
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
hsBool plNetLinkingMgr::MsgReceive( plMessage *msg )
|
||||
bool plNetLinkingMgr::MsgReceive( plMessage *msg )
|
||||
{
|
||||
if (s_ageLeaver && NCAgeLeaverMsgReceive(s_ageLeaver, msg))
|
||||
return true;
|
||||
|
@ -115,7 +115,7 @@ class plNetLinkingMgr
|
||||
|
||||
public:
|
||||
static plNetLinkingMgr * GetInstance();
|
||||
hsBool MsgReceive( plMessage *msg ); // TODO: Make this a hsKeyedObject so we can really handle messages.
|
||||
bool MsgReceive( plMessage *msg ); // TODO: Make this a hsKeyedObject so we can really handle messages.
|
||||
void Update();
|
||||
|
||||
bool IsEnabled( void ) const { return fLinkingEnabled;}
|
||||
|
@ -89,7 +89,7 @@ public:
|
||||
void SetLastUpdateTime(double t) { fLastUpdateTime=t; fNumUpdates++; }
|
||||
double GetLastUpdateTime() { return fLastUpdateTime; }
|
||||
|
||||
hsBool CheckForceSynch() { if (fNumUpdates>10) { fNumUpdates=0; return true;} return false; }
|
||||
bool CheckForceSynch() { if (fNumUpdates>10) { fNumUpdates=0; return true;} return false; }
|
||||
|
||||
virtual void AddMember(plNetTransportMember* e);
|
||||
virtual void RemoveMember(plNetTransportMember* e);
|
||||
|
Reference in New Issue
Block a user