Ir para conteúdo

Tabela de Classificação


Conteúdo Mais Visto

Exibindo conteúdo com a maior reputação em 1em todas áreas

  1. 1 ponto
    Majesty

    [Suporte] Editar script stamina potion

    local config = { storage = 12345, -- Storage vazia time = 120, -- Tempo em minutos de stamina a ser recuperada delay = 60, -- Tempo em minutos para usar novamente effect = 592, -- Efeito remove = true -- Remover ao usar maxstamina = 42 * 60 -- Stamina maxima } function onUse(cid, item, fromPosition, itemEx, toPosition) if (getPlayerStorageValue(cid, config.storage) >= os.time()) then return doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_RED, "You need to wait " .. ((getPlayerStorageValue(cid, config.storage) - os.time()) / 60)..", minutes to refill your stamina again.") end if (getPlayerStamina(cid) >= config.maxstamina) then return doPlayerSendCancel(cid, "Your stamina is already full.") end doPlayerAddStamina(cid, config.time) doSendMagicEffect(getThingPos(cid), config.effect) setPlayerStorageValue(cid, config.storage, os.time() + config.delay * 60) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Your stamina has been refilled in " .. config.time .. " minutes, please relog to activate.") if (config.remove) then doRemoveItem(item.uid, 1) end return true end
  2. 1 ponto
    GryLLo

    Ajuda com script de forja

    Opa @egyptPOWER belê? Vamos fazer um bate e volta, porque eu também não tenho certeza sobre isso. Considerando que o pos é da classe Item, tenta adicionar antes do if pos.itemid.. alguns print, assim: print(pos.itemid) print(pos:getId()) print(pos:getCount()) Fico no aguardo do resultado, é nósssssss!
Esta tabela de classificação está definida como São Paulo/GMT-03:00
×