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

How do I script a touch admin square using HD Admin?

Essentially, I am asking exactly what script would be required for me to emulate the touch admin squares on Kohl’s Admin House, but touching the square gives HD admin instead of Kohl’s Admin.

1 answer

local hdMain = require(game:GetService("ReplicatedStorage"):WaitForChild("HDAdminSetup")):GetMain()
local hd = hdMain:GetModule("API")
local part = script.Parent
part.Touched:Connect(function(hit)
	local player = game:GetService("Players"):GetPlayerFromCharacter(hit.Parent)
	if player then
		local playerRank = hd:GetRank(player)
		if playerRank == 0 then
			hd:SetRank(player, "Mod", "Server")
		end
	end
end)

The GitHub has alot of useful information.

1 comment

0

If that doesn't work for you, there is also an official version https://web.roblox.com/library/3105433364/Admin-Pads

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