summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2007-10-19 20:31:57 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2007-10-19 20:31:57 +0000
commit9a83b5ad626f8bfd4011277173e8bf385e4971fe (patch)
treefac179a5bb93199cf5f0314ff21e935d7da47b72 /doc
parentca003ef941f7a039a4251f28d0a60b61de66f186 (diff)
downloadhercules-9a83b5ad626f8bfd4011277173e8bf385e4971fe.tar.gz
hercules-9a83b5ad626f8bfd4011277173e8bf385e4971fe.tar.bz2
hercules-9a83b5ad626f8bfd4011277173e8bf385e4971fe.tar.xz
hercules-9a83b5ad626f8bfd4011277173e8bf385e4971fe.zip
- Added bonusautoscript and bonusautoscript2. These are used to attach a script to a player which gets executed on attack (or when attacked). Required for several of the more recent items.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11519 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'doc')
-rw-r--r--doc/script_commands.txt39
1 files changed, 39 insertions, 0 deletions
diff --git a/doc/script_commands.txt b/doc/script_commands.txt
index bf9343cfe..baa73a893 100644
--- a/doc/script_commands.txt
+++ b/doc/script_commands.txt
@@ -4285,6 +4285,45 @@ kind in 'doc/item_bonus.txt'.
---------------------------------------
+*bonusautoscript <script>,<rate>{,<flag>}
+*bonusautoscript2 <script>,<rate>{,<flag>}
+
+These commands are meant to be used in item scripts. They will probably work
+outside item scripts, but the bonus will not persist for long. They, as
+expected, refer only to an invoking character.
+
+What these commands do is 'attach' a script to the player which will get
+executed on attack (or when attacked in the case of bonusautoscript2). Rate is
+the trigger rate of the script (1000 = 100%). The optional argument flag is
+used to classify the type of attack where the script can trigger (it shares
+the same flags as the bAutoSpell bonus script):
+
+Range criteria:
+ BF_SHORT: Trigger on melee attack
+ BF_LONG: Trigger on ranged attack
+ Default: BF_SHORT+BF_LONG
+Attack type criteria:
+ BF_WEAPON: Trigger on weapon skills
+ BF_MAGIC: Trigger on magic skills
+ BF_MISC: Trigger on misc skills
+ Default: BF_WEAPON
+Skill criteria:
+ BF_NORMAL: Trigger on normal attacks
+ BF_SKILL: Trigger on skills
+ default: If the attack type is BF_WEAPON (only) BF_NORMAL is used, otherwise
+ BF_SKILL+BF_NORMAL is used.
+
+In both cases, when the script triggers, the attached player will be the one
+who holds the bonus. There is currently no way of knowing within this script
+who was the other character (the attacker in autoscript2, or the target in
+autoscript).
+
+//Grants a 1% chance of starting the state "all stats +10" for 10 seconds when
+//using weapon or misc attacks (both melee and ranged skills).
+ bonusautoscript "sc_start SC_INCALLSTATUS, 10, 10000;", 10, BF_WEAPON|BF_MISC;
+
+---------------------------------------
+
*skill <skill id>,<level>{,<flag>};
*addtoskill <skill id>,<level>{,<flag>}