• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Prosty skrypcik

Status
Not open for further replies.
onLogin / global storage / doPlayerAddItem
 
Tez tak myslalem, ustawilem global event na 10 i taki skrypcik dalem
function onLogin(cid)
if getGlobalStorageValue(2430) == 0 then
return TRUE
else
doPlayerAddItem(cid, 2160, 100)
setGlobalStorageValue(2430, -1)
end
return TRUE
end

jednak kasa przychodzi w nieskonczonosc
 
onLogin to creaturescript, nie globalevent lulz
 
Code:
function onLogin(cid)
	if getGlobalStorageValue(2430) == 10 then
		return true
	end

	doPlayerAddItem(cid, 2160, 100)
	setGlobalStorageValue(2430, getGlobalStorageValue(2430) == -1 and 1 or getGlobalStorageValue(2430) + 1)
	return true
end
 
PHP:
function onLogin(cid)
	if getGlobalStorageValue(2430) == 10 or getPlayerStorageValue(cid, 101) then
		return true
	end
	doPlayerAddItem(cid, 2160, 100)
	setPlayerStorageValue(cid, 101, 1)
	setGlobalStorageValue(2430, getGlobalStorageValue(2430) == -1 and 1 or getGlobalStorageValue(2430) + 1)
	return true
end
drobna poprawka... :D
bo jakbyś na tamtym skrypcie relognął 10x to byś dostał 1000cc a inni nic. :)
 
function onLogin(cid)
if getGlobalStorageValue(2430) == 10 or getPlayerStorageValue(cid, 101) > -1 then
return true
end
doPlayerAddItem(cid, 2160, 100)
setPlayerStorageValue(cid, 101, 1)
setGlobalStorageValue(2430, getGlobalStorageValue(2430) == -1 and 1 or getGlobalStorageValue(2430) + 1)
return true
end
drobna poprawka... :D
bo jakbyś na tamtym skrypcie relognął 10x to byś dostał 1000cc a inni nic. :)

<_<
 
Status
Not open for further replies.
Back
Top