Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

For some reason my script cannot determine that i am the owner of the game?

For some reason my script cannot determine that i am the owner of the game even though game.CreatorId and plr.UserId are the same

Here is the code:

function module.IsOwner(plr)
    if game.CreatorType == Enum.CreatorType.User then
        if plr.UserId == game.CreatorId then
        	return true
        end
    elseif game.CreatorType == Enum.CreatorType.Group then
        if plr:IsInGroup(game.CreatorId) then
            if plr:GetRankInGroup(game.CreatorId) == 255 then
				return true
			end
        end
    end
	return false
end

4 comments

0

Did you actually require this module?

0

Can I see the script that uses this module?

0

Try using player.name, that will probably work.

0

No that will not, the CreatorId is a UserId.

1 answer

I solved this my using a different method, thanks anyone who tried to help!

This discussion is preserved as it was. New answers, comments, and votes are closed.