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

Looking for this script!

D3mon

New Member
Joined
Mar 26, 2011
Messages
28
Reaction score
0
Hey im looking for a script where once you use a lever you gain a mount (The mount will be added to your mount section in outfits).. IF someone could help or make the script it would be much apreciated. thanks :) Im willing to pay some $$
 
Nah just a normal mount like real tibia no custom ones for example use lever and you get black sheep mount etc, also ye your only able to get 1 mount..
 
LUA:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2165 and getPlayerStorageValue(cid, 1234, 1) == true then
doPlayerSendTextMessage(cid,19,"You already have this mount!")
elseif item.uid == 2165 then
doPlayerSendTextMessage(cid,19,"Now you can use a black sheep as a mount!")
doPlayerAddMount(cid, 5)
setPlayerStorageValue(cid,1234,1) 
         end
 return true
end
 
When using this script im getting an error, Whats happening is everytime I use the lever it's saying "Now you can use a black sheep as a mount!" but its not saying when you use lever again "You already Have This Mount!" its like the storage value isnt saving anyone no thanks!

Heres console error


[Error - Action Interface] data/actions/scripts/mount.lua:onUse
Description: (luaGetCreatureStorage) Creature Not Found
 
LUA:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	if getPlayerMount(cid, 5) then
		doPlayerSendTextMessage(cid, MESSAGE_EVENT_ORANGE, 'You already have this mount!')
	else
		doPlayerSendTextMessage(cid, MESSAGE_EVENT_ORANGE, 'Now you can use a black sheep as a mount!')
		doPlayerAddMount(cid, 5)
	end
	return true
end
 
LUA:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	if getPlayerMount(cid, 5) then
		doPlayerSendTextMessage(cid, MESSAGE_EVENT_ORANGE, 'You already have this mount!')
	else
		doPlayerSendTextMessage(cid, MESSAGE_EVENT_ORANGE, 'Now you can use a black sheep as a mount!')
		doPlayerAddMount(cid, 5)
	end
	return true
end

hah, dammit, didn't know that there was a function to see if the players has a mount without using storages.
 
Back
Top