Browse Source

Fixes pointed out by @zrax and @hoikas.

Darryl Pogue 12 years ago
parent
commit
a8126757f8
  1. 3
      Sources/Plasma/FeatureLib/pfPython/Games/pyGameCli.cpp
  2. 2
      Sources/Plasma/FeatureLib/pfPython/Games/pyGameCli.h
  3. 1
      Sources/Plasma/FeatureLib/pfPython/Games/pyGameCliGlue.cpp
  4. 4
      Sources/Plasma/FeatureLib/pfPython/Games/pyGameMgrMsg.cpp
  5. 2
      Sources/Plasma/FeatureLib/pfPython/pyNotify.cpp
  6. 2
      Sources/Plasma/FeatureLib/pfPython/pyNotify.h
  7. 4
      Sources/Plasma/FeatureLib/pfPython/pyNotifyGlue.cpp
  8. 2
      Sources/Plasma/FeatureLib/pfPython/pyVaultMarkerGameNode.cpp
  9. 2
      Sources/Plasma/FeatureLib/pfPython/pyVaultNode.cpp
  10. 2
      Sources/Plasma/FeatureLib/pfPython/pyVaultPlayerInfoNode.cpp
  11. 2
      Sources/Plasma/NucleusLib/pnMessage/plNotifyMsg.cpp
  12. 2
      Sources/Plasma/NucleusLib/pnMessage/plNotifyMsg.h
  13. 1
      Sources/Plasma/NucleusLib/pnUUID/pnUUID_Unix.cpp

3
Sources/Plasma/FeatureLib/pfPython/Games/pyGameCli.cpp

@ -47,6 +47,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
#include "pyGameCli.h"
#include "pfGameMgr/pfGameMgr.h"
#include "pnUUID/pnUUID.h"
#include "TicTacToe/pyTTTGame.h"
#include "Heek/pyHeekGame.h"
@ -104,7 +105,7 @@ plUUID pyGameCli::GameTypeID() const
{
if (gameClient)
{
return plUUID(gameClient->GetGameTypeId());
return gameClient->GetGameTypeId();
}
return kNilUuid;
}

2
Sources/Plasma/FeatureLib/pfPython/Games/pyGameCli.h

@ -52,10 +52,10 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
#include "../pyGlueHelpers.h"
#include <string>
#include <vector>
#include "pnUUID/pnUUID.h"
class pfGameCli;
class plString;
class plUUID;
class pyGameCli
{

1
Sources/Plasma/FeatureLib/pfPython/Games/pyGameCliGlue.cpp

@ -44,6 +44,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
#include "../pyKey.h"
#pragma hdrstop
#include "pnUUID/pnUUID.h"
#include "pyGameCli.h"
#include "../pyEnum.h"

4
Sources/Plasma/FeatureLib/pfPython/Games/pyGameMgrMsg.cpp

@ -109,7 +109,7 @@ plUUID pyGameMgrInviteReceivedMsg::GameTypeID() const
if (message)
{
const Srv2Cli_GameMgr_InviteReceived* gmMsg = (const Srv2Cli_GameMgr_InviteReceived*)message->netMsg;
return plUUID(gmMsg->gameTypeId);
return gmMsg->gameTypeId;
}
return kNilUuid;
}
@ -148,7 +148,7 @@ plUUID pyGameMgrInviteRevokedMsg::GameTypeID() const
if (message)
{
const Srv2Cli_GameMgr_InviteRevoked* gmMsg = (const Srv2Cli_GameMgr_InviteRevoked*)message->netMsg;
return plUUID(gmMsg->gameTypeId);
return gmMsg->gameTypeId;
}
return kNilUuid;
}

2
Sources/Plasma/FeatureLib/pfPython/pyNotify.cpp

@ -141,7 +141,7 @@ void pyNotify::AddVarNumber(const char* name, float number)
fBuildMsg.AddVariableEvent(name, number);
}
void pyNotify::AddVarNumber(const char* name, int number)
void pyNotify::AddVarNumber(const char* name, int32_t number)
{
fBuildMsg.AddVariableEvent(name, number);
}

2
Sources/Plasma/FeatureLib/pfPython/pyNotify.h

@ -97,7 +97,7 @@ public:
virtual void AddPickEvent(bool enabled, pyKey* other, pyKey* self, pyPoint3 hitPoint);
virtual void AddControlKeyEvent( int32_t key, bool down );
virtual void AddVarNumber(const char* name, float number);
virtual void AddVarNumber(const char* name, int number);
virtual void AddVarNumber(const char* name, int32_t number);
virtual void AddVarNull(const char* name);
virtual void AddVarKey(const char* name, pyKey* key);
virtual void AddFacingEvent( bool enabled, pyKey* other, pyKey* self, float dot);

4
Sources/Plasma/FeatureLib/pfPython/pyNotifyGlue.cpp

@ -210,14 +210,14 @@ PYTHON_METHOD_DEFINITION(ptNotify, addVarNumber, args)
if (number == NULL || number == Py_None)
self->fThis->AddVarNull(name);
else if (PyInt_Check(number))
self->fThis->AddVarNumber(name, (int)PyInt_AsLong(number));
self->fThis->AddVarNumber(name, static_cast<int32_t>(PyInt_AsLong(number)));
else if (PyLong_Check(number))
{
// try as int first
long i = PyLong_AsLong(number);
if (!PyErr_Occurred())
{
self->fThis->AddVarNumber(name, (int)i);
self->fThis->AddVarNumber(name, static_cast<int32_t>(i));
}
else
{

2
Sources/Plasma/FeatureLib/pfPython/pyVaultMarkerGameNode.cpp

@ -93,7 +93,7 @@ plUUID pyVaultMarkerGameNode::GetGameGuid() const
{
if (fNode) {
VaultMarkerGameNode access(fNode);
return plUUID(access.gameGuid);
return access.gameGuid;
}
return kNilUuid;
}

2
Sources/Plasma/FeatureLib/pfPython/pyVaultNode.cpp

@ -325,7 +325,7 @@ const char * pyVaultNode::GetCreateAgeName( void )
plUUID pyVaultNode::GetCreateAgeGuid(void) const
{
if (fNode) {
return plUUID(fNode->createAgeUuid);
return fNode->createAgeUuid;
}
return kNilUuid;

2
Sources/Plasma/FeatureLib/pfPython/pyVaultPlayerInfoNode.cpp

@ -162,7 +162,7 @@ plUUID pyVaultPlayerInfoNode::Player_GetAgeGuid(void) const
{
if (fNode) {
VaultPlayerInfoNode playerInfo(fNode);
return plUUID(playerInfo.ageInstUuid);
return playerInfo.ageInstUuid;
}
return kNilUuid;
}

2
Sources/Plasma/NucleusLib/pnMessage/plNotifyMsg.cpp

@ -607,7 +607,7 @@ void plNotifyMsg::AddVariableEvent( const char* name, float number )
//
// PURPOSE : Add a variable event record to this notify message
//
void plNotifyMsg::AddVariableEvent( const char* name, int number )
void plNotifyMsg::AddVariableEvent( const char* name, int32_t number )
{
// create the control key event record
proVariableEventData* pED = new proVariableEventData;

2
Sources/Plasma/NucleusLib/pnMessage/plNotifyMsg.h

@ -376,7 +376,7 @@ public:
void AddPickEvent( const plKey &other, const plKey& self, bool enabled, hsPoint3 hitPoint );
void AddControlKeyEvent( int32_t key, bool down );
void AddVariableEvent( const char* name, float number );
void AddVariableEvent( const char* name, int number );
void AddVariableEvent( const char* name, int32_t number );
void AddVariableEvent( const char* name );
void AddVariableEvent( const char *name, const plKey &key );
void AddFacingEvent( const plKey &other, const plKey &self, float dot, bool enabled);

1
Sources/Plasma/NucleusLib/pnUUID/pnUUID_Unix.cpp

@ -67,7 +67,6 @@ struct plUUIDHelper
void plUUID::Clear()
{
uuid_t g;
//plUUIDHelper::CopyToNative( g, this );
uuid_clear( g );
plUUIDHelper::CopyToPlasma( this, g );
}

Loading…
Cancel
Save