From 4e6774e4173eccff9d0b51b45fe2af07e682e67d Mon Sep 17 00:00:00 2001 From: euphyy Date: Wed, 5 Sep 2012 02:42:20 +0000 Subject: * Follow-up r16742, revised quest sample (doc\sample\npc_test_quest.txt) and whisper system documentation (doc\whisper_sys.txt) * Follow-up r16745, fixed a few typos in atcommand documentation (doc\atcommands.txt) * Minor cleaning - spacing, tabulation, comments, dividers git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16746 54d463be-8e91-2dee-dedb-b68131a5f0ec --- doc/atcommands.txt | 34 +++++++++++++--------------- doc/sample/npc_test_quest.txt | 52 +++++++++++++++++++------------------------ doc/whisper_sys.txt | 38 +++++++++---------------------- 3 files changed, 48 insertions(+), 76 deletions(-) (limited to 'doc') diff --git a/doc/atcommands.txt b/doc/atcommands.txt index 10713e46b..a578bbe21 100644 --- a/doc/atcommands.txt +++ b/doc/atcommands.txt @@ -179,7 +179,7 @@ Toggles weather effects on your map. @clearweather -Stop all weather effects. May require a map change or @refresh +Stops all weather effects. May require a map change or @refresh for the effect to stop client-side. --------------------------------------- @@ -265,7 +265,7 @@ Other Flags: @gat -Give information about terrain/area (debug function). +Gives information about terrain/area (debug function). Output Example: prontera (x= 165, y= 202) 00 00 00 00 00 @@ -347,7 +347,7 @@ Output Example: @idsearch -Find an item ID based on the provided name. +Looks up an item by name (or part of a name). --------------------------------------- @@ -367,7 +367,7 @@ This does not include mobs summoned by scripts. @skillid -Look up a skill by name (or part of a name). +Looks up a skill by name (or part of a name). --------------------------------------- @@ -493,14 +493,14 @@ all: 2 @where -Locate a player on a map. The player must be online. +Locates a player on a map. The player must be online. --------------------------------------- @jailtime Displays remaining jail time. -If the @jail was used, the chat window will display "You have been jailed indefinitely". +If @jail was used, the chat window will display "You have been jailed indefinitely". --------------------------------------- @@ -689,7 +689,7 @@ Warps to a random coordinate on the current map. @go {} -Warps you to predefined locations in major cities. +Warps to predefined locations in major cities. If no ID is given, all available maps will be displayed in the chat window. Locations and coordinates are stored in '/src/map/atcommand.c'. @@ -699,20 +699,16 @@ Locations and coordinates are stored in '/src/map/atcommand.c'. /mm { } /mapmove { } -Warps to a specified map. +Warps to the specified map. If no coordinates are entered, a random location will be chosen. --------------------------------------- @goto - -Warp yourself to a player. - ---------------------------------------- - @follow -Warps to the specified player and follows their movements. +Warps to the specified player. +Aditionally, @follow will track the player's movements until turned off. --------------------------------------- @@ -811,7 +807,7 @@ Default is 150 (0 is fastest, 1000 is slowest). @spiritball <0-100> -Summons X amount of spirit spheres around you. +Summons the specified amount of spirit spheres around you. --------------------------------------- @@ -1056,14 +1052,14 @@ If a time is not specified (jailfor), the player will be jailed indefinitely. @kick @kickall -Disconnects a user (or all users) from the server. +Disconnects a user or all users from the server. --------------------------------------- @ban <+/- time> @unban -Ban (or unban) a player for a limited time. +Bans or unbans a player for a limited time. Time elements: y/a, m, d/j, h, mn, s Example: @@ -1075,7 +1071,7 @@ Example: @block @unblock -Block or unblock a player from logging in indefinitely. +Blocks or unblocks a player from logging in indefinitely. --------------------------------------- @@ -1118,7 +1114,7 @@ Reloads the specified configuration file. @setbattleflag -Change a battle_config flag without rebooting the server. +Changes a battle_config flag without rebooting the server. --------------------------------------- diff --git a/doc/sample/npc_test_quest.txt b/doc/sample/npc_test_quest.txt index 097f7655b..2ac0ae173 100644 --- a/doc/sample/npc_test_quest.txt +++ b/doc/sample/npc_test_quest.txt @@ -2,43 +2,37 @@ // need to add the quest to /db/quest_db.txt - e.g: // 9000,0,1002,3,0,0,0,0,"3 Splats Please!" - prontera,90,95,1 script Jelly 123,{ -set .@n$, "["+strnpcinfo(1)+"]"; -if(checkquest(9000) == -1) goto L_Start; -if(checkquest(9000,HUNTING) == 2) goto L_Reward; -if(checkquest(9000) == 2) goto L_Done; - -L_Start: - mes .@n$; - mes "Hey there! Would you help me?"; - next; + if(checkquest(9000) == -1) { // Quest not yet started. + mes "[Jelly]"; + mes "Hey there! Would you help me?"; + next; switch(select("I'd rather not:What's up?")){ case 1: - mes .@n$; + mes "[Jelly]"; mes "I didn't want your help anyway!"; close; - case 2: - mes .@n$; + mes "[Jelly]"; mes "Those Porings are weirding me out."; mes "Would you kill 3 for me?"; - setquest 9000; // Adds the quest to your Quest Window. + setquest 9000; // Adds the quest to your Quest Window. close; - } } - close; - -L_Reward: - mes .@n$; - mes "Awesome! Than you =)"; - getexp 10000,0; - dispbottom "You have been rewarded with 10,000 Base Exp."; - completequest 9000; - close; - -L_Done: - mes .@n$; - mes "Thanks again for doing that for me =)"; - close; + } else if(checkquest(9000) == 1) { // Quest is active. + mes "[Jelly]"; + mes "Keep going, almost there!"; + close; + } else if(checkquest(9000,HUNTING) == 2) { // All monsters killed. + mes "[Jelly]"; + mes "Awesome! Thank you!"; + getexp 10000,0; + dispbottom "You have been rewarded with 10,000 Base Exp."; + completequest 9000; // Sets quest status to "complete". + close; + } else if(checkquest(9000) == 2) { // Quest finished. + mes "[Jelly]"; + mes "Thanks again for doing that for me!"; + close; + } } \ No newline at end of file diff --git a/doc/whisper_sys.txt b/doc/whisper_sys.txt index 3593c486c..2e71558c3 100644 --- a/doc/whisper_sys.txt +++ b/doc/whisper_sys.txt @@ -3,7 +3,7 @@ //===== By: ================================================== //= lordalfa //===== Current Version: ===================================== -//= 20120826 +//= 20120904 //===== Description: ========================================= //= A description of rAthena's NPC whispering system. //============================================================ @@ -37,34 +37,16 @@ OnWhisperGlobal: end; } -The Whisper System is also useful for hidden event handler NPCs (NPCs that don't -have a sprite on a map for you to click). E.g: +This could also be used for hidden event triggers: +- script EventManager -1,{ OnWhisperGlobal: -if (getgmlevel()<80) goto L_NotGM; -if (@whispervar0$ == "event1") goto L_Event1; -if (@whispervar0$ == "event2") goto L_Event2; -if (@whispervar0$ == "event3") goto L_Event3; - -// If the string sent to this NPC doesn't contain any of the above: -else goto L_NoVar; -end; - -L_NotGM: - dispbottom "NPC : You do not have sufficient access to whisper in my ear."; - end; - -L_NoVar: - dispbottom "NPC : Sorry, i do not recognise that command."; - end; - -L_Event1: - if (@whispervar1$ == "start"){ - // Execute scripts to start Event1 + if (getgmlevel() < 80) end; + if (@whispervar0$ == "pvp") { + // Script for a PVP event. } - if (@whispervar1$ == "stop"){ - //Execute scripts to forcefully stop Event1 + else if (@whispervar0$ == "mvp") { + // Script for an MVP summoning event. } - - - + end; +} \ No newline at end of file -- cgit v1.2.3-60-g2f50