Hallo,
ich hab mal was ausprobiert jedoch funktioniert es nicht >:
Erstmal es soll eigentlich bezwecken das man folgenden Befehl eingeben kann: /aarrest [NAME] [ZEIT] [GRUND]
Es soll eigentlich nur dafür sorgen das man einen Spieler mit einem Admin Befehl Jailtime zuweisen kann bsp. ein Admin Arrest Befehl
Hier das Script:
Spoiler anzeigen
Lua
function arrestbadplayer ( player, cmd, target, ... )
local reason = {...}
reason = table.concat( reason, " " )
local target = findPlayerByName( target )
if isAdminLevel ( player, 1 ) then
if target then
bool = tonumber ( bool )
if bool then
if reason then
vioSetElementData ( target, "jailtime", bool )
outputChatBox ( ""..getPlayerName ( player ).." hat "..getPlayerName ( target ).." fuer "..bool.." Minuten eingesperrt!", getRootElement(), 255, 0, 0 )
outputChatBox ( "Grund: "..tostring(reason).."!", getRootElement(), 255, 0, 0 )
end
end
else
outputChatBox ( "Gebrauch: /!", player, 255, 0, 0 )
end
else
outputChatBox ( "Du bist kein Moderator oder höher!", player, 255, 0, 0 )
end
end
addCommandHandler ("aarrest", arrestbadplayer)
Alles anzeigen