Histórico de Curtidas
-
BazirFoxer deu reputação a thelifeofpbion em Sumon/msg globalfunction onSay(cid, words, param) local monster = "Demon" local pos = {x=164, y=55, z=7} doSummonCreature(monster, pos) doBroadcastMessage("Monstro foi sumonado") return TRUE end
não esquece da tag.
-
BazirFoxer deu reputação a Noob II em (Resolvido)Alavanca, storage e tile.Isso só acontece dps que adicionei as mensagens? tenta assim:
function onStepIn(cid, item, position, fromPosition) local config = { topos = {x=1408, y=1169, z=7}, -- Posição para onde o player será teleportado. strg = 33339 -- valor da storage. } if getPlayerStorageValue(cid, config.strg) == 0 then doTeleportThing(cid, config.topos) doPlayerSendTextMessage(cid, 27, "Parabéns, você tem acesso a este local") else return doPlayerSendCancel(cid, "Você não concluiu o acesso a este local.") end return true end
<movevent type="StepIn" actionid="13700" event="script" value="tiletibiaking.lua"/>
-
BazirFoxer deu reputação a Noob II em (Resolvido)Alavanca, storage e tile.Script da alavanca:
local config = { topos = {x=1111, y=2222, z=7}, -- Posição para onde o player será teleportado. strg = 33339 -- valor da storage. } function onUse(cid) if doTeleportThing(cid, config.topos) then setPlayerStorageValue(cid, config.strg, 1) doPlayerSendTextMessage(cid,20,"Você foi teleportado e ganhou a storage " .. config.strg .. ".") end end
script do tile:
function onStepIn (cid, position, fromPosition) local config = { topos = {x=1111, y=2222, z=7}, -- Posição para onde o player será teleportado. strg = 33339, -- valor da storage. action = 0000 -- Action ID do Tile } if item.actionid == config.action then ---- if getPlayerStorageValue(cid, config.strg) == 0 then doTeleportThing(cid, config.topos) end end return true end
-
BazirFoxer deu reputação a Wakon em (Resolvido)Alavanca que crie um teleporte.local teleport = {{x = 1015, y = 1042, z = 7}, {x = 1013, y = 1042, z = 7}, 3} -- posição do teleport, posição que irá teleportar, segundos para fechar function onUse(cid, item, fromPos) local function doRemove() local teleportThing = getTileItemById(teleport[1], 1387).uid local lever = getTileItemById(fromPos, 1945) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "O teleporte foi fechado!") doSendMagicEffect(teleport[1], CONST_ME_POFF) doRemoveItem(teleportThing, 1) doTransformItem(lever.uid, 1946) end if (item.itemid == 1946) then doCreateTeleport(1387, teleport[2], teleport[1]) doTransformItem(item.uid, 1945) doCreatureSay(cid, "O teleporte irá fechar em ".. teleport[3] .." segundos!", TALKTYPE_MONSTER) addEvent(doRemove, teleport[3] * 1000, item) else doPlayerSendTextMessage(cid, 28, "O teleporte já está aberto.") doSendMagicEffect(fromPos, CONST_ME_POFF) end return true end Lembre-se, você deve criar a alavanca com o ID 1946! Se der algum problema, me avise :D.