-- Talybalyho123

local coin = script.Parent;
local enabled = false;

coin.Touched:connect(function(part)
	if (part.Parent == nil or enabled == true) then
		return;
	end
	
	local player = game.Players:GetPlayerFromCharacter(part.Parent);
	
	if (player ~= nil) then
		enabled = true;
		
		pcall(function()
			_G.awardPoints(player, math.random(5));
		end);
		
		coin:remove();
	end
end);
