diff options
author | Jesusaves <cpntb1@ymail.com> | 2020-06-25 08:15:35 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2020-06-25 08:15:35 -0300 |
commit | 09e354f68216a91c31341cca9f09c2c1f846c912 (patch) | |
tree | 0b28bd15fe67670cfe9a5d4a184e8b8687bb46f1 /npc/magic | |
parent | 966297f7b40879a453de0b5bfbde938e428bf83f (diff) | |
download | serverdata-09e354f68216a91c31341cca9f09c2c1f846c912.tar.gz serverdata-09e354f68216a91c31341cca9f09c2c1f846c912.tar.bz2 serverdata-09e354f68216a91c31341cca9f09c2c1f846c912.tar.xz serverdata-09e354f68216a91c31341cca9f09c2c1f846c912.zip |
Prepare a couple ressurection skills
EXP will not be reimbursed, it is only useful for MMO maps
WARNING, GAME DESIGNERS, PLEASE TAKE TIMERS IN ACCOUNT
Diffstat (limited to 'npc/magic')
-rw-r--r-- | npc/magic/revive.txt | 28 | ||||
-rw-r--r-- | npc/magic/study.txt | 1 |
2 files changed, 29 insertions, 0 deletions
diff --git a/npc/magic/revive.txt b/npc/magic/revive.txt new file mode 100644 index 000000000..a3f2b4617 --- /dev/null +++ b/npc/magic/revive.txt @@ -0,0 +1,28 @@ +// TMW2 script +// Author: Jesusalva <admin@tmw2.org> +// +// Magic Script: TMW2_REVIVE +// Magic Script: TMW2_RESSURECT +// +// Skill to revive players +// TODO: Reimburse EXP? + +// revives getarg(0) +function script SK_revive { + .@target=getarg(0); + if (getunittype(.@target) != UNITTYPE_PC) { + dispbottom l("This skill can only be used on players!"); + return; + } + recovery(.@target); + return; +} + +// revive in getarg(0) range from caster +function script SK_ressurect { + .@r=getarg(0); + getmapxy(.@m$, .@x, .@y, 0); + recovery(.@m$, .@x-.@r, .@y-.@r, .@x+.@r, .@y+.@r); + return; +} + diff --git a/npc/magic/study.txt b/npc/magic/study.txt index 547e8aa63..6f039ce9d 100644 --- a/npc/magic/study.txt +++ b/npc/magic/study.txt @@ -10,6 +10,7 @@ function script SK_study { .@mobGD=getarg(0); if (getunittype(.@mobGD) != UNITTYPE_MOB) { dispbottom l("This skill can only be used on monsters!"); + return; } .@mobID=getunitdata(.@mobGD, UDT_CLASS); dispbottom l("%s - %d/%d HP, %d/%d MP", |