diff options
author | mekolat <mekolat@users.noreply.github.com> | 2015-06-11 11:13:11 -0400 |
---|---|---|
committer | mekolat <mekolat@users.noreply.github.com> | 2016-03-30 11:22:47 -0400 |
commit | bc4deaf81d9701261baac6a10d762b0f40e7f65f (patch) | |
tree | e539e3a49756626e27d4491fccb7a6862b12a120 /world/map/npc/items | |
parent | 9e7f46ac732851c1359a15837c82ebf67ea2be39 (diff) | |
download | serverdata-bc4deaf81d9701261baac6a10d762b0f40e7f65f.tar.gz serverdata-bc4deaf81d9701261baac6a10d762b0f40e7f65f.tar.bz2 serverdata-bc4deaf81d9701261baac6a10d762b0f40e7f65f.tar.xz serverdata-bc4deaf81d9701261baac6a10d762b0f40e7f65f.zip |
initial commit for magic v3
Fix Druid Tree and add hug to TMW
Diffstat (limited to 'world/map/npc/items')
-rw-r--r-- | world/map/npc/items/check_wand.txt | 65 | ||||
-rw-r--r-- | world/map/npc/items/magic_gm_top_hat.txt | 16 |
2 files changed, 10 insertions, 71 deletions
diff --git a/world/map/npc/items/check_wand.txt b/world/map/npc/items/check_wand.txt index 5a339049..93993c53 100644 --- a/world/map/npc/items/check_wand.txt +++ b/world/map/npc/items/check_wand.txt @@ -1,67 +1,2 @@ // Wands // Author: Wushin -function|script|WandMana -{ - if(isin("009-7", $@fightclub_x1, $@fightclub_y1, $@fightclub_x2, $@fightclub_y2) && ((@Duel_Fighter != 1) || ($@Duel_NoMagic == 1))) - goto L_Return; - callfunc "CheckWand"; - set @WandCost, (@Wand * (BaseLevel / 15) + 2); - set @WandAttack, 0; - if (!(@Wand)) - goto L_NoWand; - if (Sp >= @WandCost) - goto L_Attack; - goto L_LowSp; - -L_Attack: - set Sp, (Sp - @WandCost); - set @WandAttack, 1; - goto L_Return; - -L_NoWand: - message strcharinfo(0), "You need a wand Equipped!"; - set @WandAttack, 0; - goto L_Return; - -L_LowSp: - message strcharinfo(0), "Out of Mana"; - set @WandAttack, 0; - goto L_Return; - -L_Return: - return; -} -function|script|CheckWand -{ - setarray $@Wands, 758, 1171; - setarray $@WandsPwr, 2, 1; - setarray $@WandsAnim, 35, 33; - set @Wand, 0; - set @wand_loop, 0; - goto L_Loop; - -L_Loop: - if ((getequipid(equip_hand1) == $@Wands[@wand_loop]) || (getequipid(equip_hand2) == $@Wands[@wand_loop])) - goto L_SetWand; - goto L_LoopAgain; - -L_SetWand: - set @Wand, $@WandsPwr[@wand_loop]; - set @WandID, $@WandsAnim[@wand_loop]; - if (QL_MORGAN == 2) - goto L_SetCastOnce; - goto L_Return; - -L_LoopAgain: - set @wand_loop, (@wand_loop + 1); - if (@wand_loop >= getarraysize($@Wands)) - goto L_Return; - goto L_Loop; - -L_SetCastOnce: - set QL_MORGAN, 3; - goto L_Return; - -L_Return: - return; -} diff --git a/world/map/npc/items/magic_gm_top_hat.txt b/world/map/npc/items/magic_gm_top_hat.txt index 129aa5c0..dfd114d2 100644 --- a/world/map/npc/items/magic_gm_top_hat.txt +++ b/world/map/npc/items/magic_gm_top_hat.txt @@ -1,21 +1,25 @@ -function|script|ActivateMagicGMTophat +-|script|ActivateMagicGMTophat|32767 { - if (getgmlevel() < 60) goto L_Return; + if (GM < get(.killthegm, "GM") && GM < G_SYSOP) end; + if (getequipid(equip_head) != 888) end; getinventorylist; if ((checkweight("MurdererCrown", 1) == 0) || (@inventorylist_count == 100)) goto L_Inventory; // Get the current reward of the event. This may be changed later getitem "MurdererCrown", 1; + // Set HP and SP to max + heal MaxHp, MaxSp; // Display an effect misceffect FX_CHANNELLING_CAST, strcharinfo(0); // Log the usage of this spell gmlog strcharinfo(0)+" used the Magic GM Top Hat."; - return; + end; L_Inventory: message strcharinfo(0), "You cannot create this item. You're too heavy or you don't have a free slot."; - return; + end; -L_Return: - return; +OnInit: + registercmd "#pullrabbit", strnpcinfo(0); + end; } |