Ir para conteúdo

Setaccountstoragevalue E Getaccountstoragevalue


meubk

Posts Recomendados

Blokiando scripts por account agora ficow mais facil.

 

setAccountStorageValue(accountid, storage, value)

 

function setAccountStorageValue(accountid, storage, value)
if type(accountid) ~= "number" then
	error("[ERROR] ACCOUNT NOT IS NUMBER")
end
mountacc = accountid .. storage
setGlobalStorageValue(mountacc, value)
end

 

getAccountStorageValue(accountid, storage)

 

function getAccountStorageValue(accountid, storage)
if type(accountid) ~= "number" then
	error("[ERROR] ACCOUNT NOT IS NUMBER")
end
mountacc = accountid .. storage
return getGlobalStorageValue(mountacc)
end

 

Exemplo de uso

 

function onSay(cid)

if getAccountStorageValue(getPlayerAccountId(cid), 5656) == 1 then
	doPlayerSendCancel(cid, "Account blokiada")
else
	setAccountStorageValue(getPlayerAccountId(cid), 5656, 1)
end
return true

end

 

Fui...

Link para o comentário
Compartilhar em outros sites

×
×
  • Criar Novo...