- Katılım
- 4 yıl 8 ay 24 gün
- Mesajlar
- 931
Kod:
RegisterServerEvent("kashactersS:CharacterChosen")
AddEventHandler('kashactersS:CharacterChosen', function(charid, ischar,loc)
local src = source
local spawn = {}
SetLastCharacter(src, tonumber(charid))
SetCharToIdentifier(GetPlayerIdentifiers(src)[1], tonumber(charid))
if type(charid) == "number" and string.len(charid) == 1 and type(ischar) == "boolean" then
if ischar == "true" then
spawn = GetSpawnPos(src)
else
TriggerClientEvent('skinchanger:loadDefaultModel', src, true, cb)
spawn = { x = -207.11, y = -1016.05, z = 30.14 } -- DEFAULT SPAWN POSITION
end
TriggerClientEvent("kashactersC:SpawnCharacter", src, spawn)
else
-- Trigger Ban Event here to ban individuals trying to use SQL Injections
end
end)
Kod:
RegisterServerEvent("kashactersS:DeleteCharacter")
AddEventHandler('kashactersS:DeleteCharacter', function(charid)
local src = source
if type(charid) == "number" and string.len(charid) == 1 then
DeleteCharacter(GetPlayerIdentifiers(src)[1], charid)
TriggerClientEvent("kashactersC:ReloadCharacters", src)
else
-- Trigger Ban Event here to ban individuals trying to use SQL Injections
end
end)
Son düzenleme: