• 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!
  • New resources must be posted under Resources tab. A discussion thread will be created automatically, you can't open threads manually anymore.

Action Mount System Quest 1.0

Bntz

Dprethor!
Joined
Mar 16, 2009
Messages
101
Reaction score
1
Location
México
Script by Bntz... Mount BB v1.0 BB = By bntz
tested on TFS 4074

Fix Bi Saint:
(No Tested)
Lua:
 local mount = 
{
	[2161] = 1,
	[2162] = 2,
	[2163] = 3,
	[2164] = 4,
	[2165] = 5,
	[2166] = 6,
	[2167] = 7,
	[2168] = 8,
	[2169] = 9,
	[2170] = 10,
	[2171] = 11,
	[2172] = 12
}
 
function onUse(cid, item, frompos, item2, topos)
	queststatus = getPlayerMount(cid, mount[item.uid])
	if queststatus <= 0 then
		doPlayerSendTextMessage(cid, 19, "Now you can mount id " .. mount[item.uid] .. ".")
		doPlayerAddMount(cid, mount[item.uid])
	else
		doPlayerSendTextMessage(cid,19,"You already have this mount!")
	end
	return true
end


I did not find this script so I started making one for my server and this was

v2 by darkhaos

XML:
<action uniqueid="2161-2172" event="script" value="mount.lua"/>

One Script:

Lua:
 local mount = 
{
	[2161] = {1, 368},
	[2162] = {2, 369},
	[2163] = {3, 370},
	[2164] = {4, 371},
	[2165] = {5, 372},
	[2166] = {6, 373},
	[2167] = {7, 374},
	[2168] = {8, 375},
	[2169] = {9, 376},
	[2170] = {10, 377},
	[2171] = {11, 378},
	[2172] = {12, 379}
}
 
function onUse(cid, item, frompos, item2, topos)
	queststatus = getPlayerStorageValue(cid, mount[item.uid][2])
	if queststatus <= 0 then
		doPlayerSendTextMessage(cid, 19, "Now you can mount id " .. mount[item.uid][1] .. ".")
		doPlayerAddMount(cid, mount[item.uid][1])
		setPlayerStorageValue(cid, mount[item.uid][2], 1)
	else
		doPlayerSendTextMessage(cid,19,"You already has this mount!")
	end
	return true
end





V1 Add this in actions.xml


Lua:
      <!-- mounting by Bntz -->
      <action uniqueid="2161" event="script" value="1.lua"/>
      <action uniqueid="2162" event="script" value="2.lua"/>
      <action uniqueid="2163" event="script" value="3.lua"/>
      <action uniqueid="2164" event="script" value="4.lua"/>
      <action uniqueid="2165" event="script" value="5.lua"/>
      <action uniqueid="2166" event="script" value="6.lua"/>
      <action uniqueid="2167" event="script" value="7.lua"/>
      <action uniqueid="2168" event="script" value="8.lua"/>
      <action uniqueid="2169" event="script" value="9.lua"/>
      <action uniqueid="2170" event="script" value="10.lua"/>
      <action uniqueid="2171" event="script" value="11.lua"/>
      <action uniqueid="2172" event="script" value="12.lua"/>

Add this on .LUA in data/actions/scripts/

1.-

Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2161 then
queststatus = getPlayerStorageValue(cid,368)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 1")
item_uid = doPlayerAddMount(cid, 1)
setPlayerStorageValue(cid,368,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

2.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2162 then
queststatus = getPlayerStorageValue(cid,369)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 2")
item_uid = doPlayerAddMount(cid, 2)
setPlayerStorageValue(cid,369,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

3.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2163 then
queststatus = getPlayerStorageValue(cid,370)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 3")
item_uid = doPlayerAddMount(cid, 3)
setPlayerStorageValue(cid,370,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

4.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2164 then
queststatus = getPlayerStorageValue(cid,371)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 4")
item_uid = doPlayerAddMount(cid, 4)
setPlayerStorageValue(cid,371,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

5.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2165 then
queststatus = getPlayerStorageValue(cid,372)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 5")
item_uid = doPlayerAddMount(cid, 5)
setPlayerStorageValue(cid,372,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

6.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2166 then
queststatus = getPlayerStorageValue(cid,373)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 6")
item_uid = doPlayerAddMount(cid, 6)
setPlayerStorageValue(cid,373,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

7.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2167 then
queststatus = getPlayerStorageValue(cid,374)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 7")
item_uid = doPlayerAddMount(cid, 7)
setPlayerStorageValue(cid,374,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

8.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2168 then
queststatus = getPlayerStorageValue(cid,375)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 8")
item_uid = doPlayerAddMount(cid, 8)
setPlayerStorageValue(cid,375,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

9.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2169 then
queststatus = getPlayerStorageValue(cid,376)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 9")
item_uid = doPlayerAddMount(cid, 9)
setPlayerStorageValue(cid,376,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

10.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2170 then
queststatus = getPlayerStorageValue(cid,377)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 10")
item_uid = doPlayerAddMount(cid, 10)
setPlayerStorageValue(cid,377,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

11.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2171 then
queststatus = getPlayerStorageValue(cid,378)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 11")
item_uid = doPlayerAddMount(cid, 11)
setPlayerStorageValue(cid,378,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

and 12.-
Lua:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2172 then
queststatus = getPlayerStorageValue(cid,379)
if queststatus == -1 or queststatus == 0 then
doPlayerSendTextMessage(cid,19,"Now you can mount id 12")
item_uid = doPlayerAddMount(cid, 12)
setPlayerStorageValue(cid,379,1)

else
doPlayerSendTextMessage(cid,19,"You already has this mount!")
end
else
return 0
end
return 1
end

Download Script?

View attachment scripts.rar



I repeat: This is the first version if you post here any more I change

Greetings I hope you enjoy my first script
 
Last edited:
One xml line:
XML:
<action uniqueid="2161-2172" event="script" value="mount.lua"/>

One script
Lua:
 local mount = 
{
	[2161] = {1, 368},
	[2162] = {2, 369},
	[2163] = {3, 370},
	[2164] = {4, 371},
	[2165] = {5, 372},
	[2166] = {6, 373},
	[2167] = {7, 374},
	[2168] = {8, 375},
	[2169] = {9, 376},
	[2170] = {10, 377},
	[2171] = {11, 378},
	[2172] = {12, 379}
}

function onUse(cid, item, frompos, item2, topos)
	queststatus = getPlayerStorageValue(cid, mount[item.uid][2])
	if queststatus <= 0 then
		doPlayerSendTextMessage(cid, 19, "Now you can mount id " .. mount[item.uid][1] .. ".")
		doPlayerAddMount(cid, mount[item.uid][1])
		setPlayerStorageValue(cid, mount[item.uid][2], 1)
	else
		doPlayerSendTextMessage(cid,19,"You already has this mount!")
	end
	return true
end
 
Last edited:
One xml line:
XML:
<action uniqueid="2161-2172" event="script" value="mount.lua"/>

One script
Lua:
 local mount = 
{
	[2161] = {1, 368},
	[2162] = {2, 369},
	[2163] = {3, 370},
	[2164] = {4, 371},
	[2165] = {5, 372},
	[2166] = {6, 373},
	[2167] = {7, 374},
	[2168] = {8, 375},
	[2169] = {9, 376},
	[2170] = {10, 377},
	[2171] = {11, 378},
	[2172] = {12, 379}
}

function onUse(cid, item, frompos, item2, topos)
	queststatus = getPlayerStorageValue(cid, mount[item.uid][2])
	if queststatus < 1 then
		doPlayerSendTextMessage(cid, 19, "Now you can mount id " .. mount[item.uid][1] .. ".")
		doPlayerAddMount(cid, mount[item.uid][1])
		setPlayerStorageValue(cid, mount[item.uid][2], 1)
	else
		doPlayerSendTextMessage(cid,19,"You already has this mount!")
	end
	return true
end

I think that your script will not work correctly.
Look:
if queststatus < 1 then -- Okay this is true but...
setPlayerStorageValue(cid, mount[item.uid][2], -->1<--)
else -- queststatus > 1 --- :O this dont work correctly

you need put this on the script:

if queststatus < 0 then -- true
setPlayerStorageValue(cid, mount[item.uid][2], -->1<--)

else -- queststatus > 0 -- true
 
I think that your script will not work correctly.
Look:
if queststatus < 1 then -- Okay this is true but...
setPlayerStorageValue(cid, mount[item.uid][2], -->1<--)
else -- queststatus > 1 --- :O this dont work correctly

you need put this on the script:

if queststatus < 0 then -- true
setPlayerStorageValue(cid, mount[item.uid][2], -->1<--)

else -- queststatus > 0 -- true

Fixed now
 
Can someone tell me how this script work?

i Use Chest and see "Now you can mount id"

and nothing happened ; s how i can transform to mount?
 
Hi I first tested only in rev 4074 +

This is the new mounting system warm creatures only works with some

When you open the quest that will leave you have a new mount

then to "Control + Right Click" and select Mount

Where your suit color change there will come the Mounts that you get depends on the quest to put ID gives a different Mount

Well, simply select your Mount das mount and ride a monster

Only works on servers "8.70 +" REV 40XX+
 
doPlayerSendTextMessage(cid,19,"You already has this mount!")
change this to:
doPlayerSendTextMessage(cid,19,"You already have this mount!")
Haha not that important but :p
 
v1 and v2


1. add second script ( v1 ) to action.xml



2. Create Mount.lua



3. Create quest





4. Use Chest








5. Try to found my mounts in outfits



6. But...






I try it with V1 and V2 and I no have idea what I'm doing wrong ;s but I not have Tfs 4074 .

Only have 4072 , 4081 , 4086
 
Last edited:
Your doing it "wrong". Here is an example on how it "should" be:
(Untested, quick edit of your first script)
Lua:
 local mount = 
{
	[2161] = 1,
	[2162] = 2,
	[2163] = 3,
	[2164] = 4,
	[2165] = 5,
	[2166] = 6,
	[2167] = 7,
	[2168] = 8,
	[2169] = 9,
	[2170] = 10,
	[2171] = 11,
	[2172] = 12
}
 
function onUse(cid, item, frompos, item2, topos)
	queststatus = getPlayerMount(cid, mount[item.uid])
	if queststatus <= 0 then
		doPlayerSendTextMessage(cid, 19, "Now you can mount id " .. mount[item.uid] .. ".")
		doPlayerAddMount(cid, mount[item.uid])
	else
		doPlayerSendTextMessage(cid,19,"You already have this mount!")
	end
	return true
end
 
Back
Top