boa sempre quiz arrumar uma boa funçao pra esse varinha de estrela e ainda gostei muito do efeito vlw mesmo um belo script.
- Fórum
- OTServ
- Recursos
- Scripting
- Globalevents e Spells
- [Spell] Wand Multitarget
info
Grupo: Conde
Registrado: 07/05/08
Posts: 612
Reputação: +12
Char no Tibia: leviana luciferiana

info
Grupo: Visconde
Registrado: 03/02/09
Posts: 361
Reputação: +200
Char no Tibia: Fearless Man

vlw aew Marcryzius. O único lado ruim é que ninguem comenta
aí desanima de postar.
edited:
eu não sou o gesior. talvez vc tenha confundido nos creditos. eu coloquei pto e virgula (significa que vem outra coisa a seguir) ou seja, eu n sou o gesior. eu peguei o script do gesior no otfans, mas n tava funfando. dava mto erro no console. aí eu arrumei e trouxe pra ca. e coloquei creditos a ele tambem pq ele q fez a parte mais dificil.
Editado Junho 26 por apocarai
info
Grupo: Conde
Registrado: 07/05/08
Posts: 612
Reputação: +12
Char no Tibia: leviana luciferiana

voce e gesior o.0
Location: Poland/Grodzisk Mazowiecki
i Polski?
dlaczego je jako Polska?
po jego prawnym
jego reputację i bardzo duża szkoda, że nie tak jak polski
ale dzięki za miłe skrypt nawet sensacyjny Polak.
Ja nie jestem fanem Polski, ale ta de parabenów co najmniej jeden z nich jest zapisana.


info
Grupo: Visconde
Registrado: 03/02/09
Posts: 361
Reputação: +200
Char no Tibia: Fearless Man
Bom gente, eu achei esse script e achei manero, porém quando add no meu ot tava cheio de erros, então arrumei e to postando aki, espero que gostem
1º Passo: Vá em Data/weapons/scripts e crie um arquivo com isto dentro:
local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_BLOCKARMOR, 0) setCombatParam(combat, COMBAT_PARAM_BLOCKSHIELD, 0) setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_HOLYDAMAGE) setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_HOLYDAMAGE) setCombatParam(combat, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_HOLY) setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, -0.2, -25, -0.2, -3) [color="#FF0000"]local manaNeededPerTarget = 20 local hitExtraTargets = 3 local hitExtraTargetsInRange = 2[/color] function getCreaturesInRange(position, radiusx, radiusy, showMonsters, showPlayers) local creaturesList = {} for x = -radiusx, radiusx do for y = -radiusy, radiusy do if not (x == 0 and y == 0) then if getTilePzInfo({x = position.x+x, y = position.y+y, z = position.z}) ~= TRUE then creature = getTopCreature({x = position.x+x, y = position.y+y, z = position.z, stackpos = STACKPOS_TOP_CREATURE}) if (creature.type == 1 and showPlayers == 1) or (creature.type == 2 and showMonsters == 1) then table.insert(creaturesList, creature.uid) end end end end end return creaturesList end function onUseWeapon(cid, var) local ret = doCombat(cid, combat, var) if(ret == LUA_ERROR) then return LUA_ERROR end doCreatureAddMana(cid, -manaNeededPerTarget) local target = variantToNumber(var) local hitplayers = 0 if(target ~= 0) then if(isPlayer(target) == TRUE) then hitplayers = 1 end local nowHit = 0 local randomId = 0 local otherTargets = getCreaturesInRange(getCreaturePosition(target), hitExtraTargetsInRange, hitExtraTargetsInRange, 1, hitplayers) if(#otherTargets > 0) then for i = 1, hitExtraTargets do if(getCreatureMana(cid) > manaNeededPerTarget) then randomId = math.random(1, #otherTargets) nowHit = otherTargets[randomId] if(isCreature(nowHit) == TRUE) then table.remove(otherTargets, randomId) ret = doCombat(cid, combat, numberToVariant(nowHit)) if(ret ~= LUA_ERROR) then doCreatureAddMana(cid, -manaNeededPerTarget) end end if(#otherTargets == 0) then break end else break end end end end return TRUE endSalve como starshoter.lua
2º: Vá em data/weapons e abra seu weapons.xml. Cole isso lá dentro:
Salve e feche.
3º: Vá em data/items e abra seu items.xml. Substitua o item ID 7735 por:
<item id="7735" article="the" name="star wand"> <attribute key="description" value="This holy wand radiates huge ammount of light."/> <attribute key="weight" value="20"/> <attribute key="hitChance" value="100"/> <attribute key="weaponType" value="wand"/> <attribute key="range" value="7"/> </item>Salve e feche.
Legenda: Vermelho Mude os numeros para mudar:
1-Mana gasta ao usar (por alvo);
2-Quantos alvos além do normal ele irá atingir;
3-Área de efeito do wand.
SS:
Créditos:
Eu;
Gesior (do otfans).
Pra quem quiser ver o post original: Clique Aki
Comenta ae.