Cuberite Forum
[SOLVED] Player:GetUniqueID vs Player:GetUUID - Printable Version

+- Cuberite Forum (https://forum.cuberite.org)
+-- Forum: Plugins (https://forum.cuberite.org/forum-1.html)
+--- Forum: Plugin Discussion (https://forum.cuberite.org/forum-8.html)
+--- Thread: [SOLVED] Player:GetUniqueID vs Player:GetUUID (/thread-2126.html)



[SOLVED] Player:GetUniqueID vs Player:GetUUID - DrMasik - 09-19-2015

When I must to use Player:GetUniqueID and Player:GetUUID?


RE: Player:GetUniqueID vs Player:GetUUID - NiLSPACE - 09-19-2015

cPlayer:GetUniqueID returns the ID of the entity of the player, while GetUUID returns the (mojang) UUID of the player. The UUID is from the mojang servers if the server is in online mode. Otherwise it is generated.

UniqueID is only valid while the player is logged in. When the server restarts or the player logs of he gets a different Unique ID.


RE: Player:GetUniqueID vs Player:GetUUID - worktycho - 09-19-2015

GetUniqueID is a server internal ID, which is unique across entities, This is primarily used for apis that work with entities. UUID returns the player UUID, (which is not necessarily unique) which only players have, and is persistent across multiple logins. It is primarily used for the login apis.