05-13-2015, 06:28 AM
These kind of issues where a player disconnecting causing issues is confusing to me. In the environment I worked in we usually had methods that would search for a player so something like
Then the Player variable would store the player object then I can simply do
Is this not feasible with your API? This method of things seems a lot better instead of worrying about player disconnecting. Player will just become nil when the player disconnects. That if statement can handle the player disconnecting easily.
Code:
local Player = game.Players:FindPlayer("Player")
Then the Player variable would store the player object then I can simply do
Code:
if Player then
--code
end
Is this not feasible with your API? This method of things seems a lot better instead of worrying about player disconnecting. Player will just become nil when the player disconnects. That if statement can handle the player disconnecting easily.