Tudo que MaTTch postou
-
[AJUDA] Effect andar com o player!
isso acontece porque o atalho pos esta em um local, desse jeito ele armaneza apenas a primeira position que ele pegar. remova o atalho pos e deixe o getCreaturePosition
-
[PEDIDO] Script fácil, porém não achei
local pl1 = Position({x = 33534, y = 32342, z = 12}) local pl2 = Position({x = 33535, y = 32342, z = 12}) local pl3 = Position({x = 33536, y = 32342, z = 12}) local pl4 = Position({x = 33537, y = 32342, z = 12}) local pl5 = Position({x = 33538, y = 32342, z = 12}) function onUse(cid, item, fromPosition, itemEx, toPosition) local config = { -- {{posição que o player tem que estar}, {posição que o player sera levado}} {{x = 33607, y = 32362, z = 11, stackpos = 253}, {x = 33534, y = 32342, z = 12, stackpos = 253}}, -- 1 {{x = 33608, y = 32362, z = 11, stackpos = 253}, {x = 33535, y = 32342, z = 12, stackpos = 253}}, -- 2 {{x = 33609, y = 32362, z = 11, stackpos = 253}, {x = 33536, y = 32342, z = 12, stackpos = 253}}, -- 3 {{x = 33610, y = 32362, z = 11, stackpos = 253}, {x = 33537, y = 32342, z = 12, stackpos = 253}}, -- 4 {{x = 33611, y = 32362, z = 11, stackpos = 253}, {x = 33538, y = 32342, z = 12, stackpos = 253}}, -- 5 } local from_area, to_area = {x = ?, y = ?, z = ?}, {x = ?, y = ?, z = ?} -- area que vai checar de ponto A a ponto B if itemEx.uid == 22607 then local check = 0 for _, mob in ipairs(config) do if isPlayer(getThingfromPos(mob[1]).uid) then check = check + 1 end end local quant = 0 for i = 1, #config do quant = quant + 1 end if check == quant then for x = from_area.x, to_area.x do for y = from_area.y, to_area.y do if isPlayer(getTopCreature({x=x, y=y, z=from_area.z}).uid) then return doPlayerSendCancel(cid, "Already have players, you have to wait.") end break end end for _, mob in ipairs(config) do doTeleportThing(getThingfromPos(mob[1]).uid, mob[2]) end doRemoveItem(item.uid, 1) pl1:sendMagicEffect(CONST_ME_TELEPORT) pl2:sendMagicEffect(CONST_ME_TELEPORT) pl3:sendMagicEffect(CONST_ME_TELEPORT) pl4:sendMagicEffect(CONST_ME_TELEPORT) pl5:sendMagicEffect(CONST_ME_TELEPORT) doCreatureSay(cid, "your group has 20 minutes to kill the demon prince, when out this time you will be kicked from room.", TALKTYPE_ORANGE_1) Game.createMonster("Prince Drazzak", {x = 33529, y = 32333, z = 12}, false, true) else doPlayerSendCancel(cid, "Need 5 players in correct positions to you use the golden prison key in golden lock pedestal.") end else doPlayerSendCancel(cid, "Use the key in golden lock pedestal to enter in Prince Drazzak's room.") end return true end
-
Estamos prontos para ganhar a guerra...
-
[PEDIDO] Script fácil, porém não achei
Assim? function onUse(cid, item, fromPosition, itemEx, toPosition) local config = { -- {{posição que o player tem que estar}, {posição que o player sera levado}} {{x = ?, y = ?, z = ?}, {x = ?, y = ?, z = ?}}, -- 1 {{x = ?, y = ?, z = ?}, {x = ?, y = ?, z = ?}}, -- 2 {{x = ?, y = ?, z = ?}, {x = ?, y = ?, z = ?}}, -- 3 {{x = ?, y = ?, z = ?}, {x = ?, y = ?, z = ?}}, -- 4 {{x = ?, y = ?, z = ?}, {x = ?, y = ?, z = ?}}, -- 5 } local from_area, to_area = {x = ?, y = ?, z = ?}, {x = ?, y = ?, z = ?} -- area que vai checar de ponto A a ponto B if itemEx.uid == 6030 then for x = from_area.x, to_area.x do for y = from_area.y, to_area.y do if isPlayer(getTopCreature({x=x, y=y, z=from_area.z}).uid) then return doPlayerSendCancel(cid, "Already have players, you have to wait.") end break end end local check = 0 for _, mob in ipairs(config) do if isPlayer(getTopCreature(mob[1]).uid) then check = check + 1 end end local quant = 0 for i = 1, #config do quant = quant + 1 end if check == quant then for _, mob in ipairs(config) do doTeleportThing(getTopCreature(mob[1]).uid, mob[2]) end doRemoveItem(item.uid, 1) doPlayerSendTextMessage(cid, MESSAGE_EVENT_ADVANCE, "Your "..getItemNameById(item.itemid).." as broken.") else doPlayerSendCancel(cid, "Don't have players enough.") end end return true end
-
[PEDIDO] Script fácil, porém não achei
explique melhor como quer esse "check"
-
(Resolvido)ajuda erro [Warning - Houses::loadFromXml] House entry not set for: Unnamed House
Você tem 2 opções: 1 - colocar as saidas corretamente pelo map editor 2 - dentro do script NomeDoSeuMapa-house.xml aperta ctrl + h, e substitua os entryx="0" entryy="0" entryz="0" pela posição inicial de quando o player morre (TEMPLO) ou de qualquer lugar que queira.
-
OLD but GOLD
https://www.youtube.com/watch?v=6YoPhwwzJKI
-
[PEDIDO] Script fácil, porém não achei
Só mudar o 6030 que no caso é o UID do lugar deverá ser clicado o item: function onUse(cid, item, fromPosition, itemEx, toPosition) local config = { -- {{posição que o player tem que estar}, {posição que o player sera levado}} {{x = ?, y = ?, z = ?, stackpos = 253}, {x = ?, y = ?, z = ?, stackpos = 253}}, -- 1 {{x = ?, y = ?, z = ?, stackpos = 253}, {x = ?, y = ?, z = ?, stackpos = 253}}, -- 2 {{x = ?, y = ?, z = ?, stackpos = 253}, {x = ?, y = ?, z = ?, stackpos = 253}}, -- 3 {{x = ?, y = ?, z = ?, stackpos = 253}, {x = ?, y = ?, z = ?, stackpos = 253}}, -- 4 {{x = ?, y = ?, z = ?, stackpos = 253}, {x = ?, y = ?, z = ?, stackpos = 253}}, -- 5 } if itemEx.uid == 6030 then local check = 0 for _, mob in ipairs(config) do if isPlayer(getThingfromPos(mob[1]).uid) then check = check + 1 end end local quant = 0 for i = 1, #config do quant = quant + 1 end if check == quant then for _, mob in ipairs(config) do doTeleportThing(getThingfromPos(mob[1]).uid, mob[2]) end doRemoveItem(item.uid, 1) doPlayerSendTextMessage(cid, MESSAGE_EVENT_ADVANCE, "Your "..getItemNameById(item.itemid).." as broken.") else doPlayerSendCancel(cid, "Don't have players enough.") end end return true end
-
Mais Health/Mana
Coloque para o player começar level 1 e ao logar ganhar os 50 levels para bater com os status da vocação
-
(Resolvido)[Spells] Juntar script sem bugar ajuda
local config = { hits = 3, -- quantos hits vai dar effect = 41, -- efeito distance_effect = 28, -- efeito de distance delay = 350, -- tempo entre os hits damage = COMBAT_PHYSICALDAMAGE -- tipo de combat } local combat = createCombatObject() local function doHitCreature(target, cid, times) if isCreature(cid) and isCreature(target) and times ~= 0 then doTargetCombatHealth(cid, target, config.damage, -getPlayerLevel(cid), -getPlayerLevel(cid), config.effect) doSendDistanceShoot(getThingPos(cid), getThingPos(target), config.distance_effect) addEvent(doHitCreature, config.delay, target, cid, times-1) end return true end function onTargetCreature(cid, target) return addEvent(doHitCreature, 1, target, cid, config.hits) end setCombatCallback(combat, CALLBACK_PARAM_TARGETCREATURE, "onTargetCreature") function onCastSpell(cid, var) return doCombat(cid, combat,var) end
-
Perda de Skill
local config = { onlypremium = true, -- se precisa ser premium para não perder nada exp = true, -- se ao morrer o jogador irá perder exp skills = true, -- se ao morrer vai perder skills magic = true, -- se vai perder magic level loot = false, -- se ao morrer o jogador irá perder o loot level = 700000 -- até que level irá proteger o player } function onDeath(cid, corpse, deathList) if isPlayer(cid) and getPlayerLevel(cid) <= config.level then if config.onlypremium == true and isPremium(cid) then if config.loot == false then doCreatureSetDropLoot(cid, false) end if config.magic == false then doPlayerSetLossPercent(cid, PLAYERLOSS_MANA, 0) end if config.skills == false then doPlayerSetLossPercent(cid, PLAYERLOSS_SKILLS, 0) end if config.exp == false then doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, 0) end end end return true end