Histórico de Curtidas
-
Leolinduxo deu reputação a Maste em Piso preto (transparente)Bom dia!
Seria o 460 - nothing special?
-
Leolinduxo recebeu reputação de Maste em Piso preto (transparente)@Maste deve ser, vou dar uma conferida
-
Leolinduxo deu reputação a TioSlash em Falta de conhecimento Vps LinuxVocê precisa acessar como SUPER USUÁRIO
para fazer isso digite no terminal:
sudo su ai você tenta novamente e me posta qual foi o resultado.
-
Leolinduxo deu reputação a Werner em Como faço para hospedar um servidor?Meu conselho é que pegue um servidor windows inicialmente, no entanto se for um grande projeto é bem melhor que inicie ja no linux utilizando VPS cloud + OTPanel.
Aqui segue um tópico pra sanar a suas duvidas sobre VPS
-
Leolinduxo deu reputação a gabriel28 em Ajuda criar servidor:@Leolinduxo Então não faço ideia de como te ajudar.
-
Leolinduxo deu reputação a Werner em Como faço para hospedar um servidor?Este tópico foi movido para a área correta. Esta é uma mensagem automática!
Pedimos que leia as regras do fórum!
Cara, como vc é iniciante e n sabe bem, eu aconselho que o use a Weblara, eles tem um suporte rapido por ticket ou por skype o que é muito bom e planos baratos.
-
Leolinduxo deu reputação a Serpente em [Criar servidor] Ajuda com base.Existem vários distros atualmente, cada um tem seu ponto forte e seu ponto fraco, vou listar alguns que considero os melhores:
TFS 1.3: https://github.com/otland/forgottenserver (Mais estável e mais popular dentre todos, versão 10.98)
TFS 0.3.6 (Crying Damson): https://github.com/peonso/forgottenserver036pl1 (Versão mais antiga do TFS, contém algumas features que foram removidas posteriormente como account manager,etc, versão 8.54)
OTX3 (Baseado no TFS 1.3): https://github.com/mattyx14/otxserver/tree/otxserv3 (Distro com uma comunidade bastante ativa, possui mais recursos que o tfs 1.3, versão: 10.11/7.7/8.5 e 8.6)
OTX2 (Baseado em TFS 0.3.7): https://github.com/mattyx14/otxserver/tree/otxserv2 (versões: 10.0/7.4/8.1/8.5/8.6 e 8.7)
É possível fazer um downgrade de distro para alguma versão anterior, não é uma tarefa muito dificil, só dispensiosa, mais vale a pena.
No seu caso eu recomendaria o distro tfs 1.2 por ser muito estável e um dos mais atuais:
TFS 1.2 para versão 8.60: https://github.com/ninjalulz/forgottenserver/tree/8.6
boa sorte amigo!
-
Leolinduxo deu reputação a 9k22 em [Criar servidor] Ajuda com base.https://github.com/mattyx14/otxserver/tree/otxserv2
-
Leolinduxo deu reputação a Bodak Reborn em [erro VIP SCRIPT]-- Script Feito Por Dark Ownz function onUse(cid, item, fromPosition, itemEx, toPosition) local config={ removeOnUse = "yes" -- remover quando usar ("yes" or "no") } local days = 30 -- coloque os dias que serão a VIP! local daysvalue = days * 24 * 60 * 60 local storageplayer = getPlayerStorageValue(cid,14965) local timenow = os.time() if getPlayerStorageValue(cid, 14965) - os.time() <= 0 then time = timenow + daysvalue else time = storageplayer + daysvalue end doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Foram adicionados ".. days .." dias de VIP no seu character.") setPlayerStorageValue(cid, 14965, time) local quantity = math.floor((getPlayerStorageValue(cid, 14965) - timenow)/(24 * 60 * 60)) doSendMagicEffect(getPlayerPosition(cid), math.random(28,30)) doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Você tem ".. quantity .." dias de VIP restantes.") if (config.removeOnUse == "yes") then doRemoveItem(item.uid, 1) end return TRUE end
-
Leolinduxo deu reputação a ViitinG em (Resolvido)TSF 1.0 NPC BANK {BUG}Tente trocar seu script por este :
local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) local Topic, count, transfer = {}, {}, {} function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end function onThink() npcHandler:onThink() end local function getCount(s) local b, e = s:find('%d+') return b and e and math.min(4294967295, tonumber(s:sub(b, e))) or -1 end local function findPlayer(name) local q = db.getResult('SELECT name FROM players WHERE name=' .. db.escapeString(name) .. ' LIMIT 1'), nil if q:getID() == -1 then return end local r = q:getDataString('name') q:free() return r end function greet(cid) Topic[cid], count[cid], transfer[cid] = nil, nil, nil return true end function creatureSayCallback(cid, type, msg) if not npcHandler:isFocused(cid) then return false elseif msgcontains(msg, 'balance') then npcHandler:say('Your account balance is ' .. getPlayerBalance(cid) .. ' gold.', cid) Topic[cid] = nil elseif msgcontains(msg, 'deposit') and msgcontains(msg, 'all') then if getPlayerMoney(cid) == 0 then npcHandler:say('You don\'t have any gold with you.', cid) Topic[cid] = nil else count[cid] = getPlayerMoney(cid) npcHandler:say('Would you really like to deposit ' .. count[cid] .. ' gold?', cid) Topic[cid] = 2 end elseif msgcontains(msg, 'deposit') then if getCount(msg) == 0 then npcHandler:say('You are joking, aren\'t you??', cid) Topic[cid] = nil elseif getCount(msg) ~= -1 then if getPlayerMoney(cid) >= getCount(msg) then count[cid] = getCount(msg) npcHandler:say('Would you really like to deposit ' .. count[cid] .. ' gold?', cid) Topic[cid] = 2 else npcHandler:say('You do not have enough gold.', cid) Topic[cid] = nil end elseif getPlayerMoney(cid) == 0 then npcHandler:say('You don\'t have any gold with you.', cid) Topic[cid] = nil else npcHandler:say('Please tell me how much gold it is you would like to deposit.', cid) Topic[cid] = 1 end elseif Topic[cid] == 1 then if getCount(msg) == -1 then npcHandler:say('Please tell me how much gold it is you would like to deposit.', cid) Topic[cid] = 1 elseif getPlayerMoney(cid) >= getCount(msg) then count[cid] = getCount(msg) npcHandler:say('Would you really like to deposit ' .. count[cid] .. ' gold?', cid) Topic[cid] = 2 else npcHandler:say('You do not have enough gold.', cid) Topic[cid] = nil end elseif msgcontains(msg, 'yes') and Topic[cid] == 2 then if doPlayerRemoveMoney(cid, count[cid]) then doPlayerSetBalance(cid, getPlayerBalance(cid) + count[cid]) npcHandler:say('Alright, we have added the amount of ' .. count[cid] .. ' gold to your balance. You can withdraw your money anytime you want to.', cid) else npcHandler:say('I am inconsolable, but it seems you have lost your gold. I hope you get it back.', cid) end Topic[cid] = nil elseif msgcontains(msg, 'no') and Topic[cid] == 2 then npcHandler:say('As you wish. Is there something else I can do for you?', cid) Topic[cid] = nil elseif msgcontains(msg, 'withdraw') then if getCount(msg) == 0 then npcHandler:say('Sure, you want nothing you get nothing!', cid) Topic[cid] = nil elseif getCount(msg) ~= -1 then if getPlayerBalance(cid) >= getCount(msg) then count[cid] = getCount(msg) npcHandler:say('Are you sure you wish to withdraw ' .. count[cid] .. ' gold from your bank account?', cid) Topic[cid] = 4 else npcHandler:say('There is not enough gold on your account.', cid) Topic[cid] = nil end elseif getPlayerBalance(cid) == 0 then npcHandler:say('You don\'t have any money on your bank account.', cid) Topic[cid] = nil else npcHandler:say('Please tell me how much gold you would like to withdraw.', cid) Topic[cid] = 3 end elseif Topic[cid] == 3 then if getCount(msg) == -1 then npcHandler:say('Please tell me how much gold you would like to withdraw.', cid) Topic[cid] = 3 elseif getPlayerBalance(cid) >= getCount(msg) then count[cid] = getCount(msg) npcHandler:say('Are you sure you wish to withdraw ' .. count[cid] .. ' gold from your bank account?', cid) Topic[cid] = 4 else npcHandler:say('There is not enough gold on your account.', cid) Topic[cid] = nil end elseif msgcontains(msg, 'yes') and Topic[cid] == 4 then if getPlayerBalance(cid) >= count[cid] then doPlayerAddMoney(cid, count[cid]) doPlayerSetBalance(cid, getPlayerBalance(cid) - count[cid]) npcHandler:say('Here you are, ' .. count[cid] .. ' gold. Please let me know if there is something else I can do for you.', cid) else npcHandler:say('There is not enough gold on your account.', cid) end Topic[cid] = nil elseif msgcontains(msg, 'no') and Topic[cid] == 4 then npcHandler:say('The customer is king! Come back anytime you want to if you wish to withdraw your money.', cid) Topic[cid] = nil elseif msgcontains(msg, 'transfer') then if getCount(msg) == 0 then npcHandler:say('Please think about it. Okay?', cid) Topic[cid] = nil elseif getCount(msg) ~= -1 then count[cid] = getCount(msg) if getPlayerBalance(cid) >= count[cid] then npcHandler:say('Who would you like to transfer ' .. count[cid] .. ' gold to?', cid) Topic[cid] = 6 else npcHandler:say('There is not enough gold on your account.', cid) Topic[cid] = nil end else npcHandler:say('Please tell me the amount of gold you would like to transfer.', cid) Topic[cid] = 5 end elseif Topic[cid] == 5 then if getCount(msg) == -1 then npcHandler:say('Please tell me the amount of gold you would like to transfer.', cid) Topic[cid] = 5 else count[cid] = getCount(msg) if getPlayerBalance(cid) >= count[cid] then npcHandler:say('Who would you like to transfer ' .. count[cid] .. ' gold to?', cid) Topic[cid] = 6 else npcHandler:say('There is not enough gold on your account.', cid) Topic[cid] = nil end end elseif Topic[cid] == 6 then local v = getPlayerByName(msg) if getPlayerBalance(cid) >= count[cid] then if v then transfer[cid] = msg npcHandler:say('Would you really like to transfer ' .. count[cid] .. ' gold to ' .. getPlayerName(v) .. '?', cid) Topic[cid] = 7 elseif findPlayer(msg):lower() == msg:lower() then transfer[cid] = msg npcHandler:say('Would you really like to transfer ' .. count[cid] .. ' gold to ' .. findPlayer(msg) .. '?', cid) Topic[cid] = 7 else npcHandler:say('This player does not exist.', cid) Topic[cid] = nil end else npcHandler:say('There is not enough gold on your account.', cid) Topic[cid] = nil end elseif Topic[cid] == 7 and msgcontains(msg, 'yes') then if getPlayerBalance(cid) >= count[cid] then local v = getPlayerByName(transfer[cid]) if v then doPlayerSetBalance(cid, getPlayerBalance(cid) - count[cid]) doPlayerSetBalance(v, getPlayerBalance(v) + count[cid]) npcHandler:say('Very well. You have transferred ' .. count[cid] .. ' gold to ' .. getPlayerName(v) .. '.', cid) elseif findPlayer(transfer[cid]):lower() == transfer[cid]:lower() then doPlayerSetBalance(cid, getPlayerBalance(cid) - count[cid]) db.executeQuery('UPDATE players SET balance=balance+' .. count[cid] .. ' WHERE name=' .. db.escapeString(transfer[cid]) .. ' LIMIT 1') npcHandler:say('Very well. You have transferred ' .. count[cid] .. ' gold to ' .. findPlayer(transfer[cid]) .. '.', cid) else npcHandler:say('This player does not exist.', cid) end else npcHandler:say('There is not enough gold on your account.', cid) end Topic[cid] = nil elseif Topic[cid] == 7 and msgcontains(msg, 'no') then npcHandler:say('Alright, is there something else I can do for you?', cid) Topic[cid] = nil elseif msgcontains(msg, 'change gold') then npcHandler:say('How many platinum coins would you like to get?', cid) Topic[cid] = 8 elseif Topic[cid] == 8 then if getCount(msg) < 1 then npcHandler:say('Hmm, can I help you with something else?', cid) Topic[cid] = nil else count[cid] = math.min(500, getCount(msg)) npcHandler:say('So you would like me to change ' .. count[cid] * 100 .. ' of your gold coins into ' .. count[cid] .. ' platinum coins?', cid) Topic[cid] = 9 end elseif Topic[cid] == 9 then if msgcontains(msg, 'yes') then if doPlayerRemoveItem(cid, 2148, count[cid] * 100) then npcHandler:say('Here you are.', cid) doPlayerAddItem(cid, 2152, count[cid]) else npcHandler:say('Sorry, you do not have enough gold coins.', cid) end else npcHandler:say('Well, can I help you with something else?', cid) end Topic[cid] = nil elseif msgcontains(msg, 'change platinum') then npcHandler:say('Would you like to change your platinum coins into gold or crystal?', cid) Topic[cid] = 10 elseif Topic[cid] == 10 then if msgcontains(msg, 'gold') then npcHandler:say('How many platinum coins would you like to change into gold?', cid) Topic[cid] = 11 elseif msgcontains(msg, 'crystal') then npcHandler:say('How many crystal coins would you like to get?', cid) Topic[cid] = 13 else npcHandler:say('Well, can I help you with something else?', cid) Topic[cid] = nil end elseif Topic[cid] == 11 then if getCount(msg) < 1 then npcHandler:say('Hmm, can I help you with something else?', cid) Topic[cid] = nil else count[cid] = math.min(500, getCount(msg)) npcHandler:say('So you would like me to change ' .. count[cid] .. ' of your platinum coins into ' .. count[cid] * 100 .. ' gold coins for you?', cid) Topic[cid] = 12 end elseif Topic[cid] == 12 then if msgcontains(msg, 'yes') then if doPlayerRemoveItem(cid, 2152, count[cid]) then npcHandler:say('Here you are.', cid) doPlayerAddItem(cid, 2148, count[cid] * 100) else npcHandler:say('Sorry, you do not have enough platinum coins.', cid) end else npcHandler:say('Well, can I help you with something else?', cid) end Topic[cid] = nil elseif Topic[cid] == 13 then if getCount(msg) < 1 then npcHandler:say('Hmm, can I help you with something else?', cid) Topic[cid] = nil else count[cid] = math.min(500, getCount(msg)) npcHandler:say('So you would like me to change ' .. count[cid] * 100 .. ' of your platinum coins into ' .. count[cid] .. ' crystal coins for you?', cid) Topic[cid] = 14 end elseif Topic[cid] == 14 then if msgcontains(msg, 'yes') then if doPlayerRemoveItem(cid, 2152, count[cid] * 100) then npcHandler:say('Here you are.', cid) doPlayerAddItem(cid, 2160, count[cid]) else npcHandler:say('Sorry, you do not have enough platinum coins.', cid) end else npcHandler:say('Well, can I help you with something else?', cid) end Topic[cid] = nil elseif msgcontains(msg, 'change crystal') then npcHandler:say('How many crystal coins would you like to change into platinum?', cid) Topic[cid] = 15 elseif Topic[cid] == 15 then if getCount(msg) == -1 or getCount(msg) == 0 then npcHandler:say('Hmm, can I help you with something else?', cid) Topic[cid] = nil else count[cid] = math.min(500, getCount(msg)) npcHandler:say('So you would like me to change ' .. count[cid] .. ' of your crystal coins into ' .. count[cid] * 100 .. ' platinum coins for you?', cid) Topic[cid] = 16 end elseif Topic[cid] == 16 then if msgcontains(msg, 'yes') then if doPlayerRemoveItem(cid, 2160, count[cid]) then npcHandler:say('Here you are.', cid) doPlayerAddItem(cid, 2152, count[cid] * 100) else npcHandler:say('Sorry, you do not have enough crystal coins.', cid) end else npcHandler:say('Well, can I help you with something else?', cid) end Topic[cid] = nil elseif msgcontains(msg, 'change') then npcHandler:say('There are three different coin types in Tibia: 100 gold coins equal 1 platinum coin, 100 platinum coins equal 1 crystal coin. So if you\'d like to change 100 gold into 1 platinum, simply say \'{change gold}\' and then \'1 platinum\'.', cid) Topic[cid] = nil elseif msgcontains(msg, 'bank') then npcHandler:say('We can change money for you. You can also access your bank account.', cid) Topic[cid] = nil end return true end npcHandler:setCallback(CALLBACK_GREET, greet) npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new()) -
Leolinduxo deu reputação a DukeeH em (Resolvido)Erro MoveventTenta assim, a tag que você coloca é indiferente, só pra organização mesmo, então criei uma pra você saber onde estão, ai coloca ela em qualquer lugar do arquivo.
No exemplo fiz pra sorcerer/druid, mas só alterar os ids.
Os vocation ids de baixo são as promotions, e o showindescription 0 é pra não aparecer as promotions quando dar look no item.
<!-- Itens Vocações --> <movevent type="Equip" itemid="3983" slot="legs" event="function" value="onEquipItem"> <vocation id="1"/> <vocation id="5" showInDescription="0"/> <vocation id="2"/> <vocation id="6" showInDescription="0"/> </movevent> <movevent type="DeEquip" itemid="3983" slot="legs" event="function" value="onDeEquipItem"/> <movevent type="Equip" itemid="12392" slot="armor" event="function" value="onEquipItem"> <vocation id="1"/> <vocation id="5" showInDescription="0"/> <vocation id="2"/> <vocation id="6" showInDescription="0"/> </movevent> <movevent type="DeEquip" itemid="12392" slot="armor" event="function" value="onDeEquipItem"/> <movevent type="Equip" itemid="12617" slot="helmet" event="function" value="onEquipItem"> <vocation id="1"/> <vocation id="5" showInDescription="0"/> <vocation id="2"/> <vocation id="6" showInDescription="0"/> </movevent> <movevent type="DeEquip" itemid="12617" slot="helmet" event="function" value="onDeEquipItem"/> <movevent type="Equip" itemid="2644" slot="feet" event="function" value="onEquipItem"> <vocation id="1"/> <vocation id="5" showInDescription="0"/> <vocation id="2"/> <vocation id="6" showInDescription="0"/> </movevent> <movevent type="DeEquip" itemid="2644" slot="feet" event="function" value="onDeEquipItem"/> <movevent type="Equip" itemid="7460" slot="shield" event="function" value="onEquipItem"> <vocation id="1"/> <vocation id="5" showInDescription="0"/> <vocation id="2"/> <vocation id="6" showInDescription="0"/> </movevent> <movevent type="DeEquip" itemid="7460" slot="shield" event="function" value="onDeEquipItem"/> -
Leolinduxo deu reputação a LeoTK em Quest Inferno 8.60 By: Brundseae galera do tk estou aqui disponibilizando este mapa pequeno e feito digamos "rapido" então perdoem se não for um mapa bom ainda sou leigo nisso mais foi um pedido do juvenito então fiz rapidinho bom o mapa tem 3 andares sendo o primeiro os bixos normais o segundo bixos medianos e o terceiro andar o boss. é isso espero que gostem
Mapa: 8.60
5 Andares
o ultimo andar é a finalização da quest
prints'
1º andar
2º andar
3º andar
4º Andar
5º Andar
creditos
brunds (pela criação)
juvelino (pela ideia)
se voce gostou +rep
espero ter ajudado
-
Leolinduxo deu reputação a Wise em (Resolvido)[AJUDA] Configurar quantidade alavanca.Com certeza, @Gantz.
Eu só falei pra ele mesmo, caso seja assim.
-
Leolinduxo deu reputação a Gantz em (Resolvido)[AJUDA] Configurar quantidade alavanca.coloquei no script para você definir a quantidade, deixei tudo 1 item.
local coin = 2157 -- sua moeda vip local lever = { [6001] = {10,7424,1}, [6002] = {10,2138,1}, [6003] = {10,2165,1}, [6004] = {10,5949,1}, [6005] = {10,8903,1}, [6006] = {10,7902,1}, [6007] = {10,7897,1}, [6008] = {10,7896,1}, [6009] = {10,7892,1}, [6010] = {10,2410,1}, [6011] = {10,7857,1}, [6012] = {10,7887,1}, [6013] = {10,6300,1}, [6014] = {10,3940,1}, [6015] = {10,2518,1}, [6016] = {10,7903,1}, [6017] = {10,7884,1}, [6018] = {10,7885,1}, [6019] = {10,7886,1}, } local arrows = {5907,7432,7735,7959,10943} -- coloque o ID das arrows function onUse(cid,item,fromPosition,itemEx,toPosition) if doPlayerRemoveItem(cid,coin,lever[item.actionid][1]) == FALSE then return doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR, "você precisa de "..lever[item.actionid][1].." " ..getItemNameById(coin)) end doPlayerAddItem(cid, lever[item.actionid][2], lever[item.actionid][3]) doPlayerSendTextMessage(cid,22,"você comprou um " .. getItemNameById(lever[item.actionid][2])) doSendMagicEffect(getCreaturePosition(cid), math.random(28,30)) doTransformItem(item.uid, item.itemid == 9825 and 9826 or 9825) return true end caso um dia você for editar lembre de colocar a quantidade:
[6001] = {10,7424,1}, sendo o ultimo 1 a quantidade
-
Leolinduxo deu reputação a ViitinG em (Resolvido)Magic Wall nao desaparece!O tópico foi movido para a área correta, preste mais atenção da próxima vez!
Leia as regras do fórum: http://tibiaking.com/forum/topic/1281-regras-gerais/?p=7680
Este tópico foi movido:
De: "OTServ → OTServ Geral"
Para: "OTServ → Suporte OTServ → Suporte de Scripts"
Verifica se a tag do item.xml está assim :
<item id="1497" article="a" name="magic wall"> <attribute key="type" value="magicfield" /> <attribute key="decayTo" value="0" /> <attribute key="duration" value="20" /> </item> -
Leolinduxo deu reputação a Cat em [Resolvido] Magic WallSPELLS/suport/magic wall rune
local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_ENERGY) setCombatParam(combat, COMBAT_PARAM_CREATEITEM, 1497) setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, false) function onCastSpell(cid, var) local position = variantToPosition(var) if getTilePzInfo(position) then return false end return doCombat(cid, combat, var) end tenta ai
-
Leolinduxo deu reputação a Nogard em [Dúvida]Por favor, seja específico quanto a sua dúvida. Tanto nesse tópico como em futuros.
-
Leolinduxo deu reputação a Danihcv em [ajuda XAMPP]Sim. O certo pra ñ dar problemas (o que aconteceu) é colocar o mysql.
-
Leolinduxo deu reputação a Danihcv em [ajuda XAMPP]O phpmyadmin tá ligado? Veja no xampp se está.
-
Leolinduxo deu reputação a Danihcv em [ajuda XAMPP]Dx eu ver como ta seu config.lua
-
Leolinduxo deu reputação a Danihcv em [ajuda XAMPP]A linha que diz: displayGameMasterWithOnlineCommand ta mt pra direita e isso n pode. Apaga esse espaço que ta do lado esquerdo dela, até ela encostar na parte lateral esquerda igual as demais linhas.
-
Leolinduxo deu reputação a Enzo Caue em Distro RuimUé cara, pode ter sido o server save sim ( serve save é diferente de save server.) Mas se não está contente com este, tente trocar '-'..
-
Leolinduxo deu reputação a Wise em [Potion]@Leolinduxo
Nesse caso, o valor da condição de exhaust é calculado a partir do valor que você determinou em timeBetweenExActions (config.lua), subtraindo 100.
Ex: Se em config.lua está:
timeBetweenExActions = 1000 O valor de exhaust será: 1000 - 100 = 900 milissegundos.
Você pode determinar o valor do tempo de exhaustion como quiser, basta alterar a condição.
Ex:
local MIN_HEALTH = 200 local MAX_HEALTH = 400 local MIN_MANA = 110 local MAX_MANA = 190 local EMPTY_POTION = 7635 local E_TIME = 700 -- exhaustion in milliseconds local exhaust = createConditionObject(CONDITION_EXHAUST) setConditionParam(exhaust, CONDITION_PARAM_TICKS, E_TIME) function onUse(cid, item, fromPosition, itemEx, toPosition) if not isPlayer(itemEx.uid) then return false end if hasCondition(cid, CONDITION_EXHAUST_HEAL) then return doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUAREEXHAUSTED) end if not isPaladin(itemEx.uid) or getPlayerLevel(itemEx.uid) < 80 and not getPlayerCustomFlagValue(itemEx.uid, PlayerCustomFlag_GamemasterPrivileges) then return doCreatureSay(itemEx.uid, "Only paladins of level 80 or above may drink this fluid.", TALKTYPE_ORANGE_1) end if doCreatureAddHealth(itemEx.uid, math.random(MIN_HEALTH, MAX_HEALTH)) == LUA_ERROR or doPlayerAddMana(itemEx.uid, math.random(MIN_MANA, MAX_MANA)) == LUA_ERROR then return false end doAddCondition(cid, exhaust) doSendMagicEffect(getThingPos(itemEx.uid), CONST_ME_MAGIC_BLUE) doCreatureSay(itemEx.uid, "Aaaah...", TALKTYPE_ORANGE_1) doRemoveItem(item.uid, 1) doPlayerAddItem(cid, EMPTY_POTION, 1) return true end -
Leolinduxo deu reputação a roriscrave em (Resolvido)[Quest bugada]use assim
function onUse(cid, item, fromPosition, itemEx, toPosition) if getPlayerStorageValue(cid, 21312) >= 1 then doPlayerSendTextMessage(cid,22,"Você ja fez a quest") return true end if getPlayerLevel(cid) >= 135 then doPlayerAddItem(cid, 8886, 1) doPlayerAddItem(cid, 2343, 1) doTeleportThing(cid, {x=1000,y=1000,z=7}) setPlayerStorageValue(cid, 21312, 1) else doPlayerSendCancel(cid, "Isso nao e possivel.") end return true end -
Leolinduxo deu reputação a Wise em (Resolvido)Não Mostra Guildlook.lua (data/creaturescripts/scripts):
function onLook(cid, thing, position, lookDistance) if isPlayer(thing.uid) and thing.uid ~= cid then doPlayerSetSpecialDescription(thing.uid,'[Frags: '..getPlayerFrags(thing.uid)..']') return true elseif thing.uid == cid then doPlayerSetSpecialDescription(cid,'[Frags: '..getPlayerFrags(cid)..']') local string = 'You see yourself.' if getPlayerFlagValue(cid, PLAYERFLAG_SHOWGROUPINSTEADOFVOCATION) then string = string..' You are '.. getPlayerGroupName(cid) ..'.' elseif getPlayerVocation(cid) ~= 0 then string = string..' You are '.. getPlayerVocationName(cid) ..'.' else string = string..' You have no vocation.' end string = string..getPlayerSpecialDescription(cid)..'' if getPlayerNameByGUID(getPlayerPartner(cid), false, false) ~= nil then string = string..' You are '.. (getPlayerSex(cid) == 0 and 'wife' or 'husband') ..' of '.. getPlayerNameByGUID(getPlayerPartner(cid)) ..'.' end if getPlayerGuildId(cid) > 0 then string = string..' You are ' .. (getPlayerGuildRank(cid) == '' and 'a member' or getPlayerGuildRank(cid)) ..' of the '.. getPlayerGuildName(cid) string = getPlayerGuildNick(cid) ~= '' and string..' ('.. getPlayerGuildNick(cid) ..').' or string..'.' end if getPlayerFlagValue(cid, PLAYERCUSTOMFLAG_CANSEECREATUREDETAILS) then string = string..'nHealth: ['.. getCreatureHealth(cid) ..' / '.. getCreatureMaxHealth(cid) ..'], Mana: ['.. getCreatureMana(cid) ..' / '.. getCreatureMaxMana(cid) ..'].' string = string..'nIP: '.. doConvertIntegerToIp(getPlayerIp(cid)) ..'.' end if getPlayerFlagValue(cid, PLAYERCUSTOMFLAG_CANSEEPOSITION) then string = string..'nPosition: [X:'.. position.x..'] [Y:'.. position.y..'] [Z:'.. position.z..'].' end doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, string) return false end return true end
Tag - creaturescripts.xml (data/creaturescripts):
<event type="look" name="Look" event="script" value="look.lua"/>
Registre o creature event em login.lua (data/creaturescripts/scripts):
registerCreatureEvent(cid, "Look")