• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

Tutorial Arrow

Status
Not open for further replies.

Sherlok

Active Member
Joined
Aug 29, 2008
Messages
2,116
Reaction score
44
Location
Poland, Wrocław.
Hiho,
I need script: when adwance lvl 40 and don't have XXXX storage then on pos x=1, y=1, z=7 player see CONST_ME_TUTORIALARROW effect and animated red text "Get your money!" :D

Thanks
 
Code:
function onAdvance(cid, skill, oldlevel, newlevel)
	if getPlayerStorageValue(cid, 1111) <= 0 and skill == SKILL__LEVEL and newlevel >= 40 then
		doSendMagicEffect({x=1, y=1, z=7}, CONST_ME_TUTORIALARROW)
		doSendAnimatedText({x=1, y=1, z=7}, "Get your money!", TEXTCOLOR_RED)
	end
return true
end
 
Code:
local t = {
	storage = 1111,
	pos = {x=1, y=1, z=1},
	level = 40,
	effect = CONST_ME_TUTORIALARROW,
	text = "Get your money!",
	textcolor = TEXTCOLOR_RED
}
function onThink(interval, lastExecution, thinkInterval)
	for _, cid in ipairs(getPlayersOnline()) do
		if getPlayerStorageValue(cid, t.storage) < 1 and getPlayerLevel(cid) >= t.level then
			doSendMagicEffect(t.pos, t.effect, cid)
			doSendAnimatedText(t.pos, t.text, t.textcolor, cid)
		end
	end
	return true
end
 
Status
Not open for further replies.
Back
Top