• 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!

TalkAction Kick-Ass Script!

everyone will use it to get money BTw why the gms need this ?-.-
 
dont bump old threads lol, And maybe donators can use it with storage u can use it like 10 times per week idk,
 
Heres somewhat of an edited version lol

Lua:
function onSay(cid, word, param)
	if getPlayerVocation(cid) == 1, 2, 3, 4 then
		doPlayerAddMoney(cid, 100000)
		doPlayerSendTextMessage(cid, 21, "You have now gotten your 10 Crystal Coins. Happy Hunting!")
		setPlayerStorageValue(cid, 54000, 1)
	end
	if getPlayerVocation(cid) == 5, 6, 7, 8 then
		doPlayerSendTextMessage(cid, 21, "You have gotten 5 crystal coins, since you are promoted.")
		doPlayerAddMoney(cid, 500000)
		setPlayerStorageValue(cid, 54000, 1)
	end
	if getPlayerStorageValue(cid) == 54000 then
		doPlayerSendCancel(cid, "You have already gotten your money."
	end
		return true
end
 
Heres somewhat of an edited version lol

Lua:
function onSay(cid, word, param)
	if getPlayerVocation(cid) == 1, 2, 3, 4 then
		doPlayerAddMoney(cid, 100000)
		doPlayerSendTextMessage(cid, 21, "You have now gotten your 10 Crystal Coins. Happy Hunting!")
		setPlayerStorageValue(cid, 54000, 1)
	end
	if getPlayerVocation(cid) == 5, 6, 7, 8 then
		doPlayerSendTextMessage(cid, 21, "You have gotten 5 crystal coins, since you are promoted.")
		doPlayerAddMoney(cid, 500000)
		setPlayerStorageValue(cid, 54000, 1)
	end
	if getPlayerStorageValue(cid) == 54000 then
		doPlayerSendCancel(cid, "You have already gotten your money."
	end
		return true
end

It'd give money everytime. And why do you use "getPlayerVocation(cid) == 5, 6, 7, 8" better use isInArray().

Edited version:
Lua:
function onSay(cid, word, param)
	if getPlayerStorageValue(cid) == 54000 then
		if isInArray({1, 2, 3, 4}, getPlayerVocation(cid)) then
			doPlayerAddMoney(cid, 100000)
			doPlayerSendTextMessage(cid, 21, "You have now gotten your 10 Crystal Coins. Happy Hunting!")
			setPlayerStorageValue(cid, 54000, 1)
		elseif isInArray({5, 6, 7, 8}, getPlayerVocation(cid)) then
			doPlayerSendTextMessage(cid, 21, "You have gotten 5 crystal coins, since you are promoted.")
			doPlayerAddMoney(cid, 500000)
			setPlayerStorageValue(cid, 54000, 1)
		end
	else
		doPlayerSendCancel(cid, "You have already gotten your money."
	end
	return true
end
 
It'd give money everytime. And why do you use "getPlayerVocation(cid) == 5, 6, 7, 8" better use isInArray().

Sorry I'm sort of new xD

Don't worry bout it everyone needs to learn somewhere. Here's my version. BTW this is an old thread and you probably shouldn't bump old threads, people usually frown upon that.

Lua:
function onSay(cid, word, param)
	local promoLv, storage, result = getPlayerPromotionLevel(cid), 54000, "You have already received your bonus money!"
	local rewards = {100000, 500000}
	if(getCreatureStorage(cid, storage) == -1)then
		local reward = rewards[promoLv+1]
		if(reward)then
			result = "You have received "..reward.." gold. Happy Hunting!"
			doCreatureSetStorage(cid, storage, 1)
			doPlayerAddMoney(cid, reward)
		end
	end
	return doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, result)
end

Theres my version :p not tested ofc.
 
Back
Top