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

Lua 5 Crystal In 45 Level

Erikas Kontenis

Excellent OT User
Joined
Jul 3, 2009
Messages
1,937
Reaction score
682
Location
Lithuania
Is Possible That Script Make For Tfs 0.2.2 ? :D



LUA:
function onAdvance(cid, skill, oldlevel, newlevel)
       
        if(getPlayerStorageValue(cid, 99963) ~= 1 and skill == SKILL__LEVEL and newlevel >= 45) then
                doPlayerAddItem(cid, 2160, 5)
                setPlayerStorageValue(cid, 99963, 1)
                doPlayerSendTextMessage(cid, 22, "You have received 5 crystal coin because you reached level 45")
                end
        return TRUE
end

i will by very happy and will gift big rep :D
 
Dont Know What To Say Self Tried To Create A Script Here's Mine It's Working But U must Click On Chest :D

D:\Real Map Project\data\actions\scripts\quests\scripted
LUA:
elseif item.uid == 9899 then
                     if getPlayerLevel(cid) > 45 then
			doPlayerSendTextMessage(cid,25,"You have found a bag.")
			local bag = doPlayerAddItem(cid,1987,1)
			doAddContainerItem(bag, 2160, 5)
			setPlayerStorageValue(cid,78782,1)
		else
            doPlayerSendCancel(cid,"You need to be at least level 46 to get 5 crystal coins.")
		end

Mayby Someone Know Better Idea How i can make IT? :D
 
Is Possible That Script Make For Tfs 0.2.2 ? :D



LUA:
function onAdvance(cid, skill, oldlevel, newlevel)
       
        if(getPlayerStorageValue(cid, 99963) ~= 1 and skill == SKILL__LEVEL and newlevel >= 45) then
                doPlayerAddItem(cid, 2160, 5)
                setPlayerStorageValue(cid, 99963, 1)
                doPlayerSendTextMessage(cid, 22, "You have received 5 crystal coin because you reached level 45")
                end
        return TRUE
end

i will by very happy and will gift big rep :D

Will work, but you'll have to use the function" on advance.

#edit
here you are http://otland.net/f163/release-onadvance-1607/ :)
 
Dont Know What To Say Self Tried To Create A Script Here's Mine It's Working But U must Click On Chest :D


Mayby Someone Know Better Idea How i can make IT? :D

I hope that is not the whole script. Post the whole thing.

If it isn't replace the part you have with this

LUA:
elseif item.uid == 9899 then
		if getPlayerLevel(cid) > 45 and getPlayerStorageValue(cid, 78782) < 0 then
			doPlayerSendTextMessage(cid,25,"You have found a bag.")
			local bag = doPlayerAddItem(cid,1987,1)
			doAddContainerItem(bag, 2160, 5)
			setPlayerStorageValue(cid,78782,1)
		elseif getPlayerStorageValue(cid, 78782) == 1 then
			doPlayerSendCancel(cid,"You have already found the bag.")
		else
                        doPlayerSendCancel(cid,"You need to be at least level 46 to get 5 crystal coins.")
		end
end
 
Back
Top