diff options
author | Jesusaves <cpntb1@ymail.com> | 2021-04-11 06:48:47 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2021-04-11 06:48:47 -0300 |
commit | 4d9cd1c326b9f0dd3295f7586ddea3e11fd04410 (patch) | |
tree | 8cfb1685de61263dfcb6c983712e04971232b907 | |
parent | 044e2c35ae327d1df1ec747c57f93d4926a29d64 (diff) | |
download | serverdata-4d9cd1c326b9f0dd3295f7586ddea3e11fd04410.tar.gz serverdata-4d9cd1c326b9f0dd3295f7586ddea3e11fd04410.tar.bz2 serverdata-4d9cd1c326b9f0dd3295f7586ddea3e11fd04410.tar.xz serverdata-4d9cd1c326b9f0dd3295f7586ddea3e11fd04410.zip |
I've forgot a few skills
-rw-r--r-- | db/pre-re/skill_tree.conf | 2 | ||||
-rw-r--r-- | npc/magic/config.txt | 99 |
2 files changed, 96 insertions, 5 deletions
diff --git a/db/pre-re/skill_tree.conf b/db/pre-re/skill_tree.conf index e62e584c..934769c0 100644 --- a/db/pre-re/skill_tree.conf +++ b/db/pre-re/skill_tree.conf @@ -33,6 +33,7 @@ Talpan: { EVOL_PHYSICAL_SHIELD: 0 EVOL_MONSTER_IDENTIFY: 0 AC_SHOWER: 0 + MG_FIREWALL: 0 /* EVOL_CRAFTING: 0 @@ -112,7 +113,6 @@ Talpan: { SA_SEISMICWEAPON: 0 SN_WINDWALK: 0 MG_LIGHTNINGBOLT: 0 - MG_FIREWALL: 0 SA_FLAMELAUNCHER: 0 MG_FIREBOLT: 0 MG_FIREBALL: 0 diff --git a/npc/magic/config.txt b/npc/magic/config.txt index 0ea9d3b7..141c2dd3 100644 --- a/npc/magic/config.txt +++ b/npc/magic/config.txt @@ -28,16 +28,16 @@ function script AdjustSpellpower { getunitdata(getcharid(3), UDT_MATKMIN), getunitdata(getcharid(3), UDT_MATKMAX)); // Apply defense - if (.@target) - .@dmg=max(0, .@dmg-getunitdata(.@target, UDT_MDEF)); + //if (.@target) + // .@dmg=max(0, .@dmg-getunitdata(.@target, UDT_MDEF)); } else if (.@type == HARM_PHYS) { .@power+=(readparam2(bStr)/2); .@dmg=rand2( getunitdata(getcharid(3), UDT_ATKMIN), getunitdata(getcharid(3), UDT_ATKMAX)); // Apply defense - if (.@target) - .@dmg=max(0, .@dmg-getunitdata(.@target, UDT_DEF)); + //if (.@target) + // .@dmg=max(0, .@dmg-getunitdata(.@target, UDT_DEF)); } else { .@dmg = .@power; .@power = 100; } @@ -253,6 +253,97 @@ function script SK_summon { return; } +// areasc(range, time, sc, bl, value, filter, target, chances) +// Defaults to 3x3 square, sleep mob for 500ms. Ignores you. +// Centered on player attached, 100% success chance +// Need a player caster. Valid BL: BL_MOB | BL_PC | BL_HOM | BL_MER +function script areasc { + .@r=getarg(0, 3); + .@d=getarg(1, 500); + .@s=getarg(2, SC_SLEEP); + .@b=getarg(3, BL_MOB); + .@val=getarg(4, 1); + .@f$=getarg(5, "filter_notme"); + .@t=getarg(6, playerattached()); + .@sr=getarg(7, 10000); + + getmapxy(.@m$, .@x, .@y, getunittype(.@t), .@t); + .@c=getunits(.@b, .@mbs, false, .@m$, .@x-.@r, .@y-.@r, .@x+.@r, .@y+.@r); + for (.@i = 0; .@i < .@c; .@i++) { + // Filtering + if (!callfunc(.@f$, .@mbs[.@i])) + continue; + sc_start .@s, .@d, .@val, .@sr, SCFLAG_NONE, .@mbs[.@i]; + specialeffect(FX_BUFF, AREA, .@mbs[.@i]); + } + return; +} + +// areasc2(map, x, y, {range, time, sc, bl, value, filter}) - can be used by NPC +// Valid BL: BL_MOB | BL_PC | BL_HOM | BL_MER +function script areasc2 { + .@m$=getarg(0); + .@x=getarg(1); + .@y=getarg(2); + .@r=getarg(3, 3); + .@d=getarg(4, 500); + .@s=getarg(5, SC_SLEEP); + .@b=getarg(6, BL_MOB); + .@val=getarg(7, 1); + .@f$=getarg(8, "filter_always"); + + .@c=getunits(.@b, .@mbs, false, .@m$, .@x-.@r, .@y-.@r, .@x+.@r, .@y+.@r); + for (.@i = 0; .@i < .@c; .@i++) { + // Filtering + if (!callfunc(.@f$, .@mbs[.@i])) + continue; + sc_start .@s, .@d, .@val, 10000, SCFLAG_NONE, .@mbs[.@i]; + specialeffect(FX_BUFF, AREA, .@mbs[.@i]); + } + return; +} + +// areasc3(range, time, sc, bl, val1, val2, filter) +// Defaults to 3x3 square, sleep mob for 500ms. Ignores you. +// Need a player caster. Valid BL: BL_MOB | BL_PC | BL_HOM | BL_MER +function script areasc3 { + .@r=getarg(0, 3); + .@d=getarg(1, 500); + .@s=getarg(2, SC_SLEEP); + .@b=getarg(3, BL_MOB); + .@v1=getarg(4, 1); + .@v2=getarg(5, 1); + .@f$=getarg(6, "filter_notme"); + + getmapxy(.@m$, .@x, .@y, 0); + .@c=getunits(.@b, .@mbs, false, .@m$, .@x-.@r, .@y-.@r, .@x+.@r, .@y+.@r); + for (.@i = 0; .@i < .@c; .@i++) { + // Filtering + if (!callfunc(.@f$, .@mbs[.@i])) + continue; + sc_start2 .@s, .@d, .@v1, .@v2, 10000, SCFLAG_NONE, .@mbs[.@i]; + specialeffect(FX_BUFF, AREA, .@mbs[.@i]); + } + return; +} + +// massprovoke(range, {map, x, y}) - player only +function script massprovoke { + getmapxy(.@m$, .@x, .@y, 0); + .@r=getarg(0, 3); + .@m$=getarg(1, .@m$); + .@x=getarg(2, .@x); + .@y=getarg(3, .@y); + + .@c=getunits(BL_MOB, .@mbs, false, .@m$, .@x-.@r, .@y-.@r, .@x+.@r, .@y+.@r); + for (.@i = 0; .@i < .@c; .@i++) { + //sc_start .@s, .@d, 1, 10000, SCFLAG_NONE, .@mbs[.@i]; + aggravate .@mbs[.@i]; + specialeffect(FX_MAGIC, AREA, .@mbs[.@i]); + } + return; +} + - script Magic Load NPC_HIDDEN,{ OnInit: end; |