معاك حق الشي يبي له مخمخة ..
: .. بسيرفر سايد الى onReg استبدل حدث
addEvent ( "onReg", true )
addEventHandler ( "onReg", root, function ( user, pass )
if ( user and pass and type ( user ) == "string" and type ( pass ) == "string" ) then
local account = getAccount ( user )
if ( not account ) then
local account = addAccount ( user, pass )
if ( account ) then
if ( not logIn ( source, account, pass ) ) then
return outputChatBox ( "Login Error!", source, 255, 0, 0 )
end
triggerClientEvent ( source, "Hidewindow", source )
else
return outputChatBox ( "Register Error !", source, 255, 0, 0 )
end
else
return outputChatBox ( "Account is registered", source, 255, 0, 0 )
end
end
return false
end )