• 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 1 NPC dont sell me the items

Thorn

Spriting since 2013
Joined
Sep 24, 2012
Messages
2,203
Solutions
1
Reaction score
921
Location
Chile
hello guys, well i have a situation and i can't figure why does this happen, i hav compared this npc to others and i don't see a problem
this npc shows you his offer, if u have the money lets you click the item in the shop, but you click to buy it and nothing happens, not even in console, so if u could help me would be great!
tfs 0.3
Code:
<?xml version="1.0" encoding="UTF-8"?>
<npc name="Portos" script="data/npc/scripts/default.lua" walkinterval="2000" floorchange="0">
    <health now="100" max="100"/>
    <look type="472" head="58" body="113" legs="76" feet="57" addons="3"/>
    <parameters>
        <parameter key="module_shop" value="1"/>
        <parameter key="message_greet" value="Hola |PLAYERNAME|. Yo vendo monturas, di {trade}."/>
        <parameter key="shop_buyable" value="Raikou Scroll, 21712, 100000000;Suicune Scroll, 21709, 100000000;
        Fire War Horse Scroll, 21708, 100000000;Blazebringer Scroll, 21707, 100000000;Uniwheel Scroll, 21706, 100000000;
        Mechanical Bird Scroll, 21704, 100000000;Tauros Scroll, 21699, 100000000;Entei Scroll, 21694, 100000000;
        Arcanine Scroll, 21717, 100000000;Shiny Arcanine Scroll, 21718, 100000000;Kinto Scroll, 21722, 100000000;"/>
       
    </parameters>
</npc>

bump plz help
 
Last edited by a moderator:
Seems like you wanted to use a noches from tfs 1.2 in a server that is based in tfs 0.3.7 -0.4
well idk about that, but actually the first post show the original npc i had, that's the same way i have for every npc in my game and didn't work :/
later i started using the another form suggested by people here in the thread
 
hello guys, well i have a situation and i can't figure why does this happen, i hav compared this npc to others and i don't see a problem
this npc shows you his offer, if u have the money lets you click the item in the shop, but you click to buy it and nothing happens, not even in console, so if u could help me would be great!
tfs 0.3
Code:
<?xml version="1.0" encoding="UTF-8"?>
<npc name="Portos" script="data/npc/scripts/default.lua" walkinterval="2000" floorchange="0">
    <health now="100" max="100"/>
    <look type="472" head="58" body="113" legs="76" feet="57" addons="3"/>
    <parameters>
        <parameter key="module_shop" value="1"/>
        <parameter key="message_greet" value="Hola |PLAYERNAME|. Yo vendo monturas, di {trade}."/>
        <parameter key="shop_buyable" value="Raikou Scroll, 21712, 100000000;Suicune Scroll, 21709, 100000000;
        Fire War Horse Scroll, 21708, 100000000;Blazebringer Scroll, 21707, 100000000;Uniwheel Scroll, 21706, 100000000;
        Mechanical Bird Scroll, 21704, 100000000;Tauros Scroll, 21699, 100000000;Entei Scroll, 21694, 100000000;
        Arcanine Scroll, 21717, 100000000;Shiny Arcanine Scroll, 21718, 100000000;Kinto Scroll, 21722, 100000000;"/>
      
    </parameters>
</npc>

bump plz help

I know this may seem retarded buy back when I was making shops for NPCs in XML I encountered a similar error, and what fixed it for me was adding
<parameter key="shop_sellable" value=""/>

Since you have a shop_buyable, you also gotta have a shop_sellable, even if there's nothing in it.

If that doesn't work, other things to check:
1. Having everything in the shop_buyable value in the same line instead of multiple lines.
2. Check whether it'd work if the prices were lower, those are some big numbers there.
 
I know this may seem retarded buy back when I was making shops for NPCs in XML I encountered a similar error, and what fixed it for me was adding
<parameter key="shop_sellable" value=""/>

Since you have a shop_buyable, you also gotta have a shop_sellable, even if there's nothing in it.

If that doesn't work, other things to check:
1. Having everything in the shop_buyable value in the same line instead of multiple lines.
2. Check whether it'd work if the prices were lower, those are some big numbers there.

hello shiva! thanks for this but unfortunately didn't work for me :( i added the line but npc still wont sell me the item, and for the points you pointed:
1)didn't work :(
2) i did tried this too but didn't work, i actually have another npc who sell things of this price and works perfectly
 
Back
Top