Thorn
Spriting since 2013
Hii, i have a problem, when i catch a mount it says succes and eveything and then when i want to use that mount shows nothing, like i don't have any mounts, i will post my mounts scripts, maybe someone can help me >.<
there are no errors in console, no errors when i open the server or when i catch a mount, i can catch a mount but when i set outfit to use it is not there, none of them, and the version of the server is OTX version 2.52-1500 codename necron
Help plz >.< if someone need anything else just tell me and i will post it
there are no errors in console, no errors when i open the server or when i catch a mount, i can catch a mount but when i set outfit to use it is not there, none of them, and the version of the server is OTX version 2.52-1500 codename necron
Code:
<?xml version="1.0" encoding="UTF-8"?>
<mounts>
<mount id="1" clientid="368" name="Widow Queen" speed="25" premium="yes"/>
<mount id="2" clientid="369" name="Racing Bird" speed="25" premium="yes"/>
<mount id="3" clientid="370" name="War Bear" speed="20" premium="yes"/>
<mount id="4" clientid="371" name="Black Sheep" speed="30" premium="yes"/>
<mount id="5" clientid="372" name="Midnight Panther" speed="30" premium="yes"/>
<mount id="6" clientid="373" name="Draptor" speed="30" premium="yes"/>
<mount id="7" clientid="374" name="Titanica" speed="25" premium="yes"/>
<mount id="8" clientid="375" name="Tin Lizzard" speed="20" premium="yes"/>
<mount id="9" clientid="376" name="Blazebringer" speed="35" premium="yes"/>
<mount id="10" clientid="377" name="Rapid Boar" speed="20" premium="yes"/>
<mount id="11" clientid="378" name="Stampor" speed="25" premium="yes"/>
<mount id="12" clientid="379" name="Undead Cavebear" speed="30" premium="yes"/>
<mount id="13" clientid="387" name="Mule" speed="20" premium="yes"/>
<mount id="14" clientid="388" name="Tiger Slug" speed="20" premium="yes"/>
<mount id="15" clientid="389" name="Uniwheel" speed="25" premium="yes"/>
<mount id="16" clientid="390" name="Crystal Wolf" speed="25" premium="yes"/>
<mount id="17" clientid="392" name="Brown War Horse" speed="20" premium="yes"/>
<mount id="18" clientid="401" name="Kingly Deer" speed="20" premium="yes"/>
<mount id="19" clientid="402" name="Tamed Panda" speed="20" premium="yes"/>
<mount id="20" clientid="405" name="Dromedary" speed="25" premium="yes"/>
<mount id="21" clientid="406" name="Sandstone Scorpion" speed="15" premium="yes"/>
<mount id="22" clientid="426" name="Fire War Horse" speed="15" premium="yes"/>
<mount id="23" clientid="427" name="War Draptor" speed="30" premium="yes"/>
<mount id="24" clientid="219" name="Tarantula" speed="15" premium="yes"/>
<mount id="25" clientid="3" name="War Wolf" speed="20" premium="yes"/>
<mount id="27" clientId="447" name="Ladybug" speed="20" premium="yes"/>
<mount id="28" clientId="450" name="Manta" speed="20" premium="yes"/>
<mount id="29" clientId="437" name="Gray Horse" speed="20" premium="yes"/>
<mount id="30" clientId="502" name="Ironblight" speed="20" premium="yes" />
<mount id="31" clientId="503" name="Magma Crawler" speed="20" premium="yes" />
<mount id="32" clientId="506" name="Dragonling" speed="40" premium="yes" />
<mount id="33" clientId="515" name="Gnarlhound" speed="20" premium="yes" />
<mount id="34" clientid="521" name="Red Manta" speed="20" premium="yes" />
<mount id="35" clientid="522" name="Mechanical Bird" speed="20" premium="yes" />
<mount id="36" clientid="526" name="Water Buffalo" speed="20" premium="yes" />
<mount id="37" clientid="611" name="Cow" speed="40" premium="yes" />
<mount id="38" clientid="614" name="Blue Horse" speed="40" premium="yes" />
<mount id="39" clientid="608" name="Venosaur" speed="40" premium="yes" />
<mount id="40" clientid="609" name="Pura Sangre" speed="40" premium="yes" />
<mount id="41" clientid="695" name="Rizard" speed="40" premium="yes" />
<mount id="42" clientid="639" name="Sacred Fox" speed="40" premium="yes" />
<mount id="43" clientid="551" name="Yellow Syntox" speed="40" premium="yes" />
<mount id="44" clientid="641" name="Black Syntox" speed="40" premium="yes" />
<mount id="45" clientid="643" name="Punk Black Syntox" speed="40" premium="yes" />
<mount id="46" clientid="642" name="Punk Yellow Syntox" speed="40" premium="yes" />
<mount id="47" clientid="843" name="Hellserker" speed="40" premium="yes" />
<mount id="48" clientid="552" name="Choking Fear" speed="40" premium="yes" />
<mount id="49" clientid="856" name="Tauros" speed="40" premium="no" />
<mount id="50" clientid="854" name="sacred tiger" speed="40" premium="no" />
</mounts>
Code:
local function tameMonster(cid, item, itemEx, tame, run, broken)
n = math.random(100)
if n <= broken then
doCreatureSay(cid, "Su item se rompio", TALKTYPE_ORANGE_1)
doRemoveItem(item.uid)
elseif n > broken and n <= (tame+broken) then
doRemoveItem(item.uid)
doCreatureSay(cid, "Capturado con exito", TALKTYPE_ORANGE_1)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "usted domo un "..getCreatureName(itemEx.uid)..".")
return true
elseif n > (tame+broken) and n <= (tame+broken+run) then
doCreatureSay(cid, "O monstro escapou", TALKTYPE_ORANGE_1)
doRemoveCreature(itemEx.uid)
else
doCreatureSay(cid, "Intente de nuevo", TALKTYPE_ORANGE_1)
end
return false
end
local function inArray(table, value)
for i,v in pairs(table) do
if (v.name == string.lower(value)) then
return i
end
end
return 0
end
local mounts = {
{item = 13307, name = "wailing widow", id = 1, tame=60, run=20, broken=20},
{item = 13298, name = "terror bird", id = 2, tame=40, run=20, broken=40},
{item = 5907, name = "bear", id = 3, tame=90, run=5, broken=5},
{item = 13295, name = "black sheep", id = 4, tame=40, run=30, broken=30},
{item = 13293, name = "midnight panther", id = 5, tame=60, run=20, broken=20},
{item = 13538, name = "panda", id = 19, tame=50, run=25, broken=25},
{item = 13539, name = "enraged white deer", id = 18, tame=70, run=15, broken=15},
{item = 13294, name = "draptor", id = 6, tame=60, run=20, broken=20},
{item = 13537, name = "donkey", id =13, tame=40, run=30, broken=30},
{item = 13305, name = "crustacea gigantica", id = 7, tame=80, run=10, broken=10},
{item = 13536, name = "crystal wolf", id = 16, tame=60, run=20, broken=20},
{item = 13247, name = "boar", id = 10, tame=80, run=10, broken=10},
{item = 13498, name = "sandstone scorpion", id = 21, tame=70, run=10, broken=20},
{item = 13508, name = "slug", id = 14, tame=60, run=20, broken=20},
{item = 13535, name = "dromedary", id = 20, tame=60, run=20, broken=20},
{item = 13291, name = "undead cavebear", id = 12, tame=70, run=10, broken=20},
{item = 13939, name = "fire horse", id = 22, tame=60, run=20, broken=20},
{item = 13939, name = "gray horse", id = 29, tame=60, run=20, broken=20},
{item = 13939, name = "brown war horse", id = 17, tame=60, run=20, broken=20},
{item = 15546, name = "lady bug", id = 27, tame=70, run=10, broken=20},
{item = 15545, name = "manta", id = 28, tame=60, run=20, broken=20},
{item = 13938, name = "uniwheel", id = 15, tame=70, run=15, broken=15},
{item = 13292, name = "tin lizzard", id = 8, tame=70, run=15, broken=15},
{item = 15546, name = "lady bug", id = 27, tame=70, run=15, broken=15},
{item = 15545, name = "manta ray", id = 28, tame=70, run=15, broken=15},
{item = 18447, name = "ironblight", id = 30, tame=70, run=15, broken=15},
{item = 18448, name = "magma crawler", id = 31, tame=70, run=15, broken=15},
{item = 18449, name = "dragonling", id = 32, tame=70, run=15, broken=15},
{item = 18516, name = "gnarlhound", id = 33, tame=70, run=15, broken=15},
}
function onUse(cid, item, fromPosition, itemEx, toPosition)
if isCreature(itemEx.uid) then
if inArray(mounts, getCreatureName(itemEx.uid)) > 0 then
i = inArray(mounts, getCreatureName(itemEx.uid))
if item.itemid == mounts[i].item and not getPlayerMount(cid, mounts[i].id) then
if tameMonster(cid, item, itemEx, mounts[i].tame, mounts[i].run, mounts[i].broken) then
doSendMagicEffect(fromPosition, CONST_ME_MAGIC_BLUE)
doRemoveCreature(itemEx.uid)
doPlayerAddMount(cid, mounts[i].id)
else
doSendMagicEffect(toPosition, CONST_ME_POFF)
end
end
end
end
return true
end
Code:
local t = {
[5907] = {'Bear', 3},
[13226] = {'Black Sheep', 4},
[13224] = {'Midnight Panther', 5},
[13229] = {'Terror Bird', 2},
[13178] = {'Boar', 10},
[13236] = {'Crustacea Gigantica', 7},
[13222] = {'Undead Cavebear', 12},
[13307] = {'Wailing Widow', 1},
[13225] = {'Draptor', 6}
}
function onUse(cid, item, fromPosition, itemEx, toPosition)
if isMonster(itemEx.uid) then
local v = t[item.itemid]
if v and v[1] == getCreatureName(itemEx.uid) and not getPlayerMount(cid, v[2]) then
doPlayerAddMount(cid, v[2])
doRemoveCreature(itemEx.uid)
doSendMagicEffect(toPosition, CONST_ME_POFF)
doRemoveItem(item.uid, 1)
return true
end
end
end
Help plz >.< if someone need anything else just tell me and i will post it
Last edited: