[Server] Use regular int as return value for GetObjectSummonerPid()

Additionally, clarify descriptions of script functions for getting information about summoners.
0.6.3
David Cernat 7 years ago
parent f02492a593
commit e8ce009521

@ -128,7 +128,7 @@ bool ObjectFunctions::DoesObjectHavePlayerSummoner(unsigned int i) noexcept
return readObjectList->baseObjects.at(i).master.isPlayer; return readObjectList->baseObjects.at(i).master.isPlayer;
} }
unsigned int ObjectFunctions::GetObjectSummonerPid(unsigned int i) noexcept int ObjectFunctions::GetObjectSummonerPid(unsigned int i) noexcept
{ {
Player *player = Players::getPlayer(readObjectList->baseObjects.at(i).master.guid); Player *player = Players::getPlayer(readObjectList->baseObjects.at(i).master.guid);

@ -287,6 +287,7 @@ public:
* *
* Only living actors can be summoned. * Only living actors can be summoned.
* *
* \param i The index of the object.
* \return Whether a player is the summoner of the object. * \return Whether a player is the summoner of the object.
*/ */
static bool DoesObjectHavePlayerSummoner(unsigned int i) noexcept; static bool DoesObjectHavePlayerSummoner(unsigned int i) noexcept;
@ -298,10 +299,10 @@ public:
* \param i The index of the object. * \param i The index of the object.
* \return The player ID of the summoner. * \return The player ID of the summoner.
*/ */
static unsigned int GetObjectSummonerPid(unsigned int i) noexcept; static int GetObjectSummonerPid(unsigned int i) noexcept;
/** /**
* \brief Get the refId of the summoner of the object at a certain index in the read object * \brief Get the refId of the actor summoner of the object at a certain index in the read object
* list's object changes. * list's object changes.
* *
* \param i The index of the object. * \param i The index of the object.
@ -310,7 +311,7 @@ public:
static const char *GetObjectSummonerRefId(unsigned int i) noexcept; static const char *GetObjectSummonerRefId(unsigned int i) noexcept;
/** /**
* \brief Get the refNumIndex of the summoner of the object at a certain index in the read object * \brief Get the refNumIndex of the actor summoner of the object at a certain index in the read object
* list's object changes. * list's object changes.
* *
* \param i The index of the object. * \param i The index of the object.
@ -319,7 +320,7 @@ public:
static int GetObjectSummonerRefNumIndex(unsigned int i) noexcept; static int GetObjectSummonerRefNumIndex(unsigned int i) noexcept;
/** /**
* \brief Get the mpNum of the summoner of the object at a certain index in the read object list's * \brief Get the mpNum of the actor summoner of the object at a certain index in the read object list's
* object changes. * object changes.
* *
* \param i The index of the object. * \param i The index of the object.

Loading…
Cancel
Save