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

Quest don't work with wooden Floor

armyman

Member
Joined
Feb 15, 2014
Messages
318
Reaction score
13
Hello, anyone know why my new quest don't work with the "tile' wooden floor? i added the actionid and uniqueid on tile, but don't work. (i'm using avesta )
 
Solution
We teamviewered.
Best I can determine.. Is that actions.xml in his server doesn't get triggered by floor tiles.

We tried different floor tiles with a simple print(1) on the first line, and we get a 'sorry, not possible.'
But when the server loads, no errors.

The tile understands that we want to trigger something, but the server acts like it doesn't know that it's registered in actions.xml
If we place the actionID on any object, pot, mud splat, chest.. it works no problem.
So it's not like the script doesn't work.

It's very strange.

Last we spoke, he was going to try to make an invisible, walkable, see-throughable object, to place on top of the tile.

I wish good luck to OP.
Is the wooden floor itemID declared in actions.xml?

If it is, then it may be attempting to load the other script, instead of the one with the action/unique id attached to it.
 
okay.. idk why you won't post a script, but k.

What's the unique ID for?
I think you can just remove that from the tile entirely.

But, without knowing how you scripted the tile..
I'm just guessing in the dark.
 
Lua:
function onUse(cid, item, frompos, item2, topos)

  if item.actionid == 8675 then
         if (getPlayerStorageValue(cid,50002) ~= 1) then
          if (getPlayerFreeCap(cid) >= 25) then
             doPlayerSendTextMessage(cid,22,"You have found a doublet.")
             doPlayerAddItem(cid,2485,1)
             setPlayerStorageValue(cid,50002,1)
          else
             doPlayerSendTextMessage(cid,22,"You have found a doublet. Weighing 25.00 oz it is too heavy.")
          end
         else
             doPlayerSendTextMessage(cid, 22, "The ".. getItemName(item.uid) .." is empty.")
         end
      end
   return 1
end
 
I have no idea what's wrong with the script.
I'm just going to post how I'd normally script and install a simple quest like this.

map
Code:
Tile;
ActionID = 8675
UniqueID = 0
actions.xml
XML:
<action actionid="8675" script="rookgaard/doublet_quest.lua"/>
rookgaard/doublet_quest.lua
Lua:
function onUse(cid, item, frompos, item2, topos)

   -- check quest state
   if getPlayerStorageValue(cid, 50002) == 1 then
       doPlayerSendTextMessage(cid, MESSAGE_STATUS_SMALL, "It is empty.")
       return true
   end   
   
   -- attempt to give reward
   local item = doCreateItemEx(2485, 1)
   if doPlayerAddItemEx(cid, item, false) == RETURNVALUE_NOERROR then
       doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have found a doublet.")
       setPlayerStorageValue(cid, 50002, 1)
       return true
   end
   
   -- tell player why reward was not given
   if getPlayerFreeCap(cid) < 25 then
       doPlayerSendTextMessage(cid, MESSAGE_STATUS_SMALL, "You have found a reward weighing 25.00 oz. It is too heavy.")
   else
       doPlayerSendTextMessage(cid, MESSAGE_STATUS_SMALL, "You have found a reward weighing 25.00 oz. You have no inventory space to receive it.")
   end
   doSendMagicEffect(getCreaturePosition(cid), CONST_ME_POFF)
   
   return true
end
 
We teamviewered.
Best I can determine.. Is that actions.xml in his server doesn't get triggered by floor tiles.

We tried different floor tiles with a simple print(1) on the first line, and we get a 'sorry, not possible.'
But when the server loads, no errors.

The tile understands that we want to trigger something, but the server acts like it doesn't know that it's registered in actions.xml
If we place the actionID on any object, pot, mud splat, chest.. it works no problem.
So it's not like the script doesn't work.

It's very strange.

Last we spoke, he was going to try to make an invisible, walkable, see-throughable object, to place on top of the tile.

I wish good luck to OP.
 
Solution
Back
Top