setElementData ( source , "setPlayerBan", true )
Use This In Code Ban The Player , Change Source To Definition The Player ,
Save The Data In SQL And Save On Serial ,
The Code For Close Key If His Data ,
buttons = {
['F1'] = true,
['F2'] = true,
['F3'] = true,
['F4'] = true,
['F5'] = true,
['F6'] = true,
['F7'] = true,
['F8'] = true,
['F9'] = true,
['J'] = true,
['T'] = true,
}
addEventHandler( 'onClientKey', root,
function (button , prees)
if prees and getElementData(localPlayer,"setPlayerBan") == true then
if buttons[button] then
cancelEvent()
end
end
end)
If Not Bind Key F8 , The Code For Cancel Your Command In F8 ,
local Cmd = { "showchat" , "register" , "login" )
addEventHandler("onPlayerCommand", root,
function( cmd )
for _,v in iprise ( Cmd ) do
if cmd == v then
cancelEvent()
end
end
end)