Browse Source

Add PyUnicode version of getPlayerName

Michael Hansen 9 years ago
parent
commit
bd74de80b8
  1. 7
      Sources/Plasma/FeatureLib/pfPython/pyPlayerGlue.cpp

7
Sources/Plasma/FeatureLib/pfPython/pyPlayerGlue.cpp

@ -140,6 +140,11 @@ PYTHON_METHOD_DEFINITION_NOARGS(ptPlayer, getPlayerName)
return PyString_FromPlString(self->fThis->GetPlayerName());
}
PYTHON_METHOD_DEFINITION_NOARGS(ptPlayer, getPlayerNameW)
{
return PyUnicode_FromPlString(self->fThis->GetPlayerName());
}
PYTHON_METHOD_DEFINITION_NOARGS(ptPlayer, getPlayerID)
{
return PyLong_FromUnsignedLong(self->fThis->GetPlayerID());
@ -213,4 +218,4 @@ void pyPlayer::AddPlasmaClasses(PyObject *m)
PYTHON_CLASS_IMPORT_START(m);
PYTHON_CLASS_IMPORT(m, ptPlayer);
PYTHON_CLASS_IMPORT_END(m);
}
}

Loading…
Cancel
Save