diff options
Diffstat (limited to 'world/map/npc/functions')
-rwxr-xr-x | world/map/npc/functions/debug.txt | 40 | ||||
-rw-r--r-- | world/map/npc/functions/global_event_handler.txt | 1 | ||||
-rw-r--r-- | world/map/npc/functions/hug.txt | 24 | ||||
-rw-r--r-- | world/map/npc/functions/strangerquiz.txt | 2 | ||||
-rw-r--r-- | world/map/npc/functions/superdebug.txt | 16 |
5 files changed, 61 insertions, 22 deletions
diff --git a/world/map/npc/functions/debug.txt b/world/map/npc/functions/debug.txt index 44af4d40..556e501b 100755 --- a/world/map/npc/functions/debug.txt +++ b/world/map/npc/functions/debug.txt @@ -5,7 +5,7 @@ function|script|Debug if(!@debug_npc) goto L_Begin; mes "The debug NPCs have been deprecated. Please use this magic spell instead:"; mes ""; - mes "%%E ##a"+ getspellinvocation("debug0") +"##0"; + mes "%%E ##a#debug##0"; set @debug_npc, 0; goto L_Close; @@ -831,13 +831,13 @@ S_Update_Mask: return; L_GetAllMagic: - setskill SKILL_MAGIC, 2; - setskill SKILL_MAGIC_LIFE, 2; - setskill SKILL_MAGIC_WAR, 2; - setskill SKILL_MAGIC_TRANSMUTE, 2; - setskill SKILL_MAGIC_NATURE, 2; - setskill SKILL_MAGIC_ASTRAL, 2; - setskill SKILL_MAGIC_DARK, 2; + setskill SKILL_MAGIC, 5; + setskill SKILL_MAGIC_LIFE, 5; + setskill SKILL_MAGIC_WAR, 5; + setskill SKILL_MAGIC_TRANSMUTE, 5; + setskill SKILL_MAGIC_NATURE, 5; + setskill SKILL_MAGIC_ASTRAL, 5; + setskill SKILL_MAGIC_DARK, 5; set @mexp, 8000; callsub S_Update_Mask; mes "Magic skills added."; @@ -869,13 +869,13 @@ L_AddAll: setskill SKILL_RESIST_POISON, 9; setskill SKILL_ASTRAL_SOUL, 9; setskill SKILL_RAGING, 9; - setskill SKILL_MAGIC, 2; - setskill SKILL_MAGIC_LIFE, 2; - setskill SKILL_MAGIC_WAR, 2; - setskill SKILL_MAGIC_TRANSMUTE, 2; - setskill SKILL_MAGIC_NATURE, 2; - setskill SKILL_MAGIC_ASTRAL, 2; - setskill SKILL_MAGIC_DARK, 2; + setskill SKILL_MAGIC, 5; + setskill SKILL_MAGIC_LIFE, 5; + setskill SKILL_MAGIC_WAR, 5; + setskill SKILL_MAGIC_TRANSMUTE, 5; + setskill SKILL_MAGIC_NATURE, 5; + setskill SKILL_MAGIC_ASTRAL, 5; + setskill SKILL_MAGIC_DARK, 5; set @mexp, 8000; resetstatus; set BaseLevel, 99; @@ -922,6 +922,16 @@ L_Close: } +-|script|Debug Spell|32767 +{ + if(!debug && getgmlevel() < 99) end; + callfunc "Debug"; + end; +OnInit: + registercmd "@debug", "Debug Spell"; + end; +} + 029-2,30,26,0|script|Debug#0|154 { set @debug_npc, 1; diff --git a/world/map/npc/functions/global_event_handler.txt b/world/map/npc/functions/global_event_handler.txt index d5c20b06..e4247d18 100644 --- a/world/map/npc/functions/global_event_handler.txt +++ b/world/map/npc/functions/global_event_handler.txt @@ -28,6 +28,7 @@ OnPCKilledEvent: OnPCDieEvent: callfunc "fightclub_GoBack"; // this used by the battle master callfunc "fightclub_event_die"; // this is used by the 1v1 arena + set @necromancer, 0; end; OnInit: diff --git a/world/map/npc/functions/hug.txt b/world/map/npc/functions/hug.txt new file mode 100644 index 00000000..a663ea1d --- /dev/null +++ b/world/map/npc/functions/hug.txt @@ -0,0 +1,24 @@ +-|script|nonmagic-hug|32767 +{ + explode .@name$[0], @args$, "*"; // strip the trailing * + set @target_id, if_then_else(.@name$[0], getcharid(3, .@name$[0]), BL_ID); + if (@target_id < 1 || !(isloggedin(@target_id))) set @target_id, BL_ID; // fallback to self + if (.@name$[0] == "Tree" || .@name$[0] == "tree") set @target_id, .tree_id; + set .@range, 3; + if (distance(BL_ID, @target_id) >= .@range) end; + misceffect FX_HUG, strcharinfo(0); + if (@target_id != BL_ID) misceffect FX_HUG, @target_id; + if (@target_id != .tree_id) end; + callfunc "QuestTreeTouch"; + close; + +OnInit: + set .tree_id, getnpcid("#DruidTree0#_M"); + registercmd "hug", strnpcinfo(0); + registercmd "*hug", strnpcinfo(0); + registercmd "*hug*", strnpcinfo(0); + registercmd "hugs", strnpcinfo(0); + registercmd "*hugs", strnpcinfo(0); + registercmd "*hugs*", strnpcinfo(0); + end; +} diff --git a/world/map/npc/functions/strangerquiz.txt b/world/map/npc/functions/strangerquiz.txt index 8da3f65a..3427a0ee 100644 --- a/world/map/npc/functions/strangerquiz.txt +++ b/world/map/npc/functions/strangerquiz.txt @@ -3,6 +3,6 @@ function|script|StrangerQuiz { // param @quizparam$$ // return in @quizanswer$ - set @quizanswer$, getspellinvocation(@quizparam$); + set @quizanswer$, (@quizparam$); return; } diff --git a/world/map/npc/functions/superdebug.txt b/world/map/npc/functions/superdebug.txt index 5654dd4c..140e703a 100644 --- a/world/map/npc/functions/superdebug.txt +++ b/world/map/npc/functions/superdebug.txt @@ -34,32 +34,36 @@ L_Holiday: L_XmasDebug: gmlog strcharinfo(0) + " accessed the Xmas debug."; callfunc "XmasDebug"; - end; + goto L_Close; L_HalloweenDebug: gmlog strcharinfo(0) + " accessed the Halloween debug."; callfunc "HalloweenDebug"; - end; + goto L_Close; L_Event: if(getgmlevel() < 60) goto L_GM; gmlog strcharinfo(0) + " accessed the GM event debug."; callfunc "GmDebug"; - close; + goto L_Close; L_StoneBoard: if (getgmlevel() < 30) goto L_GM; callfunc "SBConfig"; - close; + goto L_Close; L_MOTD: if (getgmlevel() < 40) goto L_GM; callfunc "MOTDConfig"; - close; + goto L_Close; L_GM: mes "[Numa]"; mes "I'm awfully sorry."; mes "You do not have the required GM level to perform this action."; - close; + goto L_Close; + +L_Close: + close2; // FIXME: replace with npc action 5 + return; } |