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

Search results

  1. Acedayz

    Use X to X

    You can do what Ninja said if you don't have any other kind of monsters in that area except the ones from the script, which I guess you don't. I did it this way to make sure you wouldn't get any bugs later on.
  2. Acedayz

    Use X to X

    Did you try both scripts? Tell me the errors for both.
  3. Acedayz

    Use X to X

    Try this. local area = {from = {x = 1107, y = 571, z = 7}, to = {x = 1120, y = 584, z = 7}} -- Area to check for monsters local levelReq = 100 -- Level requirement local levers = { [5000] = { -- Action ID of lever monsters = { -- Monsters to spawn {name = "Rat"...
  4. Acedayz

    Use X to X

    You don't need a unique id, just set the lever to action id 5000 and add this to actions.xml. <action actionid="5000" script="lelo.lua"/> I have trouble understanding you.
  5. Acedayz

    Use X to X

    That's exactly what this does, and it supports multiple levers. TFS 0.3.6 local levers = { [5000] = { -- Action ID of lever area = {from = {x = 100, y = 100, z = 7}, to = {x = 200, y = 200, z = 7}}, -- Area to check for monsters levelReq = 100, -- Level requirement...
  6. Acedayz

    Solved Change direction of the monster.

    Yes, in globalevents/scripts/name.lua. <globalevent type="startup" name="Name" script="name.lua"/>
  7. Acedayz

    Lever that gives you items depending on your vocation and only if you have an item

    I think this is what you want. local levers = { [5000] = { -- Action id of the lever vocs = {1, 5}, -- Vocation ids itemCost = {id = 2160, count = 10}, -- The item & count required items = { -- Items {id = 2175, count = 1}, {id = 2190, count =...
  8. Acedayz

    Solved Change direction of the monster.

    If you have the monsters spawned in your map editor you just have to set the position and which direction it should look at.
  9. Acedayz

    Use X to X

    Nvm
  10. Acedayz

    Solved Change direction of the monster.

    You could change the direction of monsters on startup. I assume you want to change the direction of the monsters in your "spawn room". Here's how to do it with TFS 1.x: local monsters = { {position = {x = 100, y = 100, z = 7}, dir = SOUTH}, {position = {x = 101, y = 100, z = 7}, dir =...
  11. Acedayz

    Use X to X

    This is for TFS 1.1 and has not been tested. local levers = { [5000] = { -- Action ID of lever area = {from = {x = 100, y = 100, z = 7}, to = {x = 200, y = 200, z = 7}}, -- Area to check for monsters levelReq = 100, -- Level requirement monsters = { -- Monsters to...
  12. Acedayz

    Lua Is there a "getCreatureLookPosition(cid)" alternative for TFS 1.0

    Send magic effect: function onSay(cid, words, param) local player = Player(cid) local lookPos = player:getPosition():getNextPosition(player:getDirection()) lookPos:sendMagicEffect(CONST_ME_POFF) return false end Get crystal coin from tile: function onSay(cid, words, param)...
  13. Acedayz

    Lua Is there a "getCreatureLookPosition(cid)" alternative for TFS 1.0

    function onSay(cid, words, param) local player = Player(cid) player:getPosition():getNextPosition(player:getDirection()) return false end
  14. Acedayz

    Lua Is there a "getCreatureLookPosition(cid)" alternative for TFS 1.0

    Something like Position.getNextPosition(self, direction, steps)? position:getNextPosition(player:getDirection())
  15. Acedayz

    [TFS 1.1] Trouble adding new attributes [Solved]

    Ahh, I see. Thanks!
  16. Acedayz

    [TFS 1.1] Trouble adding new attributes [Solved]

    What I've had trouble with is this: inline static bool isIntAttrType(itemAttrTypes type) { return (type & 0x7FFE13) != 0; } inline static bool isStrAttrType(itemAttrTypes type) { return (type & 0x1EC) != 0; } So I tried to figure out why my attributes wouldn't work, and this what I've...
  17. Acedayz

    Solved Trying to learn to script some

    That change was meant for your previous script. Try this: local config = { bushId = 2768, pos = {x=2424, y=946, z=7} } function onUse(cid, item, fromPosition, itemEx, toPosition) local bush = getTileItemById(config.pos, config.bushId).uid if bush <= 0 then...
  18. Acedayz

    Solved Trying to learn to script some

    Another thing you should do is change this part: if getTileItemById(config.pos, config.bushId).uid < 0 then doCreatureSay(cid, 'You deleted the bush!', TALKTYPE_ORANGE) doRemoveItem(getTileItemById(config.pos, config.bushId).uid To this: local bush = getTileItemById(config.pos...
Back
Top