summaryrefslogtreecommitdiff
path: root/src/map/atcommand.c
diff options
context:
space:
mode:
authorzephyrus <zephyrus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-02-14 20:54:25 +0000
committerzephyrus <zephyrus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-02-14 20:54:25 +0000
commit64ae7b6bc0cd76457aad32f327b816ee6d4bf7a4 (patch)
tree63c5c3d39263c30654e094004c3e4ed6cca5ffb8 /src/map/atcommand.c
parentfc5f99e563e4e88646e0f63f96ad33baba69cfd5 (diff)
downloadhercules-64ae7b6bc0cd76457aad32f327b816ee6d4bf7a4.tar.gz
hercules-64ae7b6bc0cd76457aad32f327b816ee6d4bf7a4.tar.bz2
hercules-64ae7b6bc0cd76457aad32f327b816ee6d4bf7a4.tar.xz
hercules-64ae7b6bc0cd76457aad32f327b816ee6d4bf7a4.zip
- Some optimizations to @noks (now using a Status Change timer).
- Added support to Self|Party|Guild options. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12205 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/atcommand.c')
-rw-r--r--src/map/atcommand.c21
1 files changed, 18 insertions, 3 deletions
diff --git a/src/map/atcommand.c b/src/map/atcommand.c
index 956d32040..0faa040ef 100644
--- a/src/map/atcommand.c
+++ b/src/map/atcommand.c
@@ -8140,9 +8140,24 @@ int atcommand_ksprotection(const int fd, struct map_session_data *sd, const char
if( sd->state.noks ) {
sd->state.noks = 0;
sprintf(atcmd_output, "[ K.S Protection Inactive ]");
- } else {
- sprintf(atcmd_output, "[ K.S Protection Active ]");
- sd->state.noks = 1;
+ }
+ else
+ {
+ if( !message || !*message || !strcmpi(message, "party") )
+ { // Default is Party
+ sd->state.noks = 2;
+ sprintf(atcmd_output, "[ K.S Protection Active - Option: Party ]");
+ }
+ else if( !strcmpi(message, "self") )
+ {
+ sd->state.noks = 1;
+ sprintf(atcmd_output, "[ K.S Protection Active - Option: Self ]");
+ }
+ else if( !strcmpi(message, "guild") )
+ {
+ sd->state.noks = 3;
+ sprintf(atcmd_output, "[ K.S Protection Active - Option: Guild ]");
+ }
}
clif_displaymessage(fd, atcmd_output);