summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.travis.yml16
-rw-r--r--conf/map/battle/client.conf9
-rw-r--r--conf/map/battle/feature.conf5
-rw-r--r--db/constants.conf27
-rw-r--r--doc/constants.md29
-rw-r--r--doc/script_commands.txt48
-rw-r--r--sql-files/mob_skill_db.sql100
-rw-r--r--sql-files/mob_skill_db_re.sql150
-rw-r--r--src/char/char.c15
-rw-r--r--src/common/mmo.h5
-rw-r--r--src/common/packets/packets2019_len_main.h23
-rw-r--r--src/common/packets/packets2019_len_re.h23
-rw-r--r--src/common/packets/packets2019_len_zero.h35
-rw-r--r--src/common/socket.c7
-rw-r--r--src/common/socket.h1
-rw-r--r--src/map/achievement.c6
-rw-r--r--src/map/atcommand.c8
-rw-r--r--src/map/battle.c5
-rw-r--r--src/map/battle.h5
-rw-r--r--src/map/clif.c115
-rw-r--r--src/map/clif.h10
-rw-r--r--src/map/guild.c4
-rw-r--r--src/map/homunculus.c2
-rw-r--r--src/map/messages_main.h70
-rw-r--r--src/map/messages_re.h70
-rw-r--r--src/map/messages_zero.h89
-rw-r--r--src/map/mob.c8
-rw-r--r--src/map/npc.c2
-rw-r--r--src/map/packets.h11
-rw-r--r--src/map/packets_keys_main.h9
-rw-r--r--src/map/packets_keys_zero.h7
-rw-r--r--src/map/packets_shuffle_main.h9
-rw-r--r--src/map/packets_shuffle_re.h8
-rw-r--r--src/map/packets_shuffle_zero.h7
-rw-r--r--src/map/packets_struct.h28
-rw-r--r--src/map/pc.c12
-rw-r--r--src/map/pet.c4
-rw-r--r--src/map/script.c141
-rw-r--r--src/map/script.h21
-rw-r--r--src/plugins/HPMHooking/HPMHooking.Defs.inc16
-rw-r--r--src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc32
-rw-r--r--src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc8
-rw-r--r--src/plugins/HPMHooking/HPMHooking_map.Hooks.inc180
-rw-r--r--src/plugins/db2sql.c4
-rw-r--r--src/plugins/sample.c9
45 files changed, 1103 insertions, 290 deletions
diff --git a/.travis.yml b/.travis.yml
index bd1798ca6..d8f07be2f 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -39,7 +39,7 @@ matrix:
- compiler: false
include:
- compiler: gcc
- env: LDFLAGS="-fuse-ld=gold" CONFIGURE_FLAGS="--enable-debug CC=gcc-6 --disable-manager --enable-Werror --enable-packetver=20190306 --enable-packetver-re --enable-buildbot" HPM="1"
+ env: LDFLAGS="-fuse-ld=gold" CONFIGURE_FLAGS="--enable-debug CC=gcc-6 --disable-manager --enable-Werror --enable-packetver=20190403 --enable-packetver-re --enable-buildbot" HPM="1"
addons:
apt:
sources:
@@ -52,7 +52,7 @@ matrix:
- libxml-sax-perl
- libxml-parser-perl
- compiler: clang
- env: CONFIGURE_FLAGS="--enable-debug CC=clang-5.0 --enable-Werror --enable-packetver=20190306 --enable-packetver-re --enable-buildbot"
+ env: CONFIGURE_FLAGS="--enable-debug CC=clang-5.0 --enable-Werror --enable-packetver=20190403 --enable-packetver-re --enable-buildbot"
addons:
apt:
sources:
@@ -72,7 +72,7 @@ matrix:
- gdb
- clang-5.0
- compiler: clang
- env: CONFIGURE_FLAGS="--enable-debug CC=clang-4.0 --enable-Werror --enable-packetver=20190306 --enable-packetver-re --enable-buildbot"
+ env: CONFIGURE_FLAGS="--enable-debug CC=clang-4.0 --enable-Werror --enable-packetver=20190403 --enable-packetver-re --enable-buildbot"
addons:
apt:
sources:
@@ -106,11 +106,11 @@ matrix:
- compiler: clang
env: CONFIGURE_FLAGS="--enable-debug --disable-renewal --enable-Werror --enable-buildbot"
- compiler: gcc
- env: CONFIGURE_FLAGS="--enable-debug --enable-Werror --enable-packetver=20190306 --enable-packetver-re --enable-buildbot"
+ env: CONFIGURE_FLAGS="--enable-debug --enable-Werror --enable-packetver=20190403 --enable-packetver-re --enable-buildbot"
- compiler: gcc
env: CONFIGURE_FLAGS="--enable-debug --disable-renewal --enable-Werror --enable-buildbot"
- compiler: gcc
- env: LDFLAGS="-fuse-ld=gold" CONFIGURE_FLAGS="--enable-debug --enable-sanitize=full CC=gcc-5 --disable-manager --enable-Werror --enable-packetver=20190306 --enable-packetver-re --enable-buildbot"
+ env: LDFLAGS="-fuse-ld=gold" CONFIGURE_FLAGS="--enable-debug --enable-sanitize=full CC=gcc-5 --disable-manager --enable-Werror --enable-packetver=20190403 --enable-packetver-re --enable-buildbot"
addons:
apt:
sources:
@@ -128,7 +128,7 @@ matrix:
- gdb
- gcc-5
- compiler: gcc
- env: LDFLAGS="-fuse-ld=gold" CONFIGURE_FLAGS="--enable-debug --enable-sanitize=full CC=gcc-6 --disable-manager --enable-Werror --enable-packetver=20190306 --enable-packetver-re --enable-buildbot"
+ env: LDFLAGS="-fuse-ld=gold" CONFIGURE_FLAGS="--enable-debug --enable-sanitize=full CC=gcc-6 --disable-manager --enable-Werror --enable-packetver=20190403 --enable-packetver-re --enable-buildbot"
addons:
apt:
sources:
@@ -146,7 +146,7 @@ matrix:
- gdb
- gcc-6
- compiler: gcc
- env: LDFLAGS="-fuse-ld=gold" CONFIGURE_FLAGS="--enable-debug CC=gcc-7 --disable-manager --enable-Werror --enable-packetver=20190306 --enable-packetver-re --enable-buildbot"
+ env: LDFLAGS="-fuse-ld=gold" CONFIGURE_FLAGS="--enable-debug CC=gcc-7 --disable-manager --enable-Werror --enable-packetver=20190403 --enable-packetver-re --enable-buildbot"
addons:
apt:
sources:
@@ -164,7 +164,7 @@ matrix:
- gdb
- gcc-7
- compiler: gcc
- env: LDFLAGS="-fuse-ld=gold" CONFIGURE_FLAGS="--enable-debug --enable-sanitize=full CC=gcc-8 --disable-manager --enable-Werror --enable-packetver=20190306 --enable-packetver-re --enable-buildbot"
+ env: LDFLAGS="-fuse-ld=gold" CONFIGURE_FLAGS="--enable-debug --enable-sanitize=full CC=gcc-8 --disable-manager --enable-Werror --enable-packetver=20190403 --enable-packetver-re --enable-buildbot"
addons:
apt:
sources:
diff --git a/conf/map/battle/client.conf b/conf/map/battle/client.conf
index b7d4ac781..24b1c8157 100644
--- a/conf/map/battle/client.conf
+++ b/conf/map/battle/client.conf
@@ -189,3 +189,12 @@ mvp_exp_reward_message: false
// character has 0 HP when dead.
// Default: true (Official behavior)
display_fake_hp_when_dead: true
+
+// Send ping timer
+// For clients 20190320 Re+
+// Interval in seconds for each timer invoke.
+ping_timer_inverval: 30
+
+// Send packets timeout in seconds before ping packet can be sent.
+// For clients 20190320 Re+
+ping_time: 20
diff --git a/conf/map/battle/feature.conf b/conf/map/battle/feature.conf
index 1ed94b2a4..c306dd97b 100644
--- a/conf/map/battle/feature.conf
+++ b/conf/map/battle/feature.conf
@@ -83,4 +83,9 @@ features: {
// Attendance End time in the format YearMonthDay
feature_attendance_endtime: 20180331
+
+ // Enable Achievement System
+ // true: enable (Default)
+ // false: disable
+ enable_achievement_system: true
}
diff --git a/db/constants.conf b/db/constants.conf
index 2e379cb14..66e0ef066 100644
--- a/db/constants.conf
+++ b/db/constants.conf
@@ -1483,12 +1483,27 @@ constants_db: {
e_panic: 79
e_whisp: 80
- comment__: "petstat"
- PET_CLASS: 1
- PET_NAME: 2
- PET_LEVEL: 3
- PET_HUNGRY: 4
- PET_INTIMATE: 5
+ comment__: "petstat - deprecated, use *getpetinfo"
+ PET_CLASS: {
+ Value: 1
+ Deprecated: true
+ }
+ PET_NAME: {
+ Value: 2
+ Deprecated: true
+ }
+ PET_LEVEL: {
+ Value: 3
+ Deprecated: true
+ }
+ PET_HUNGRY: {
+ Value: 4
+ Deprecated: true
+ }
+ PET_INTIMATE: {
+ Value: 5
+ Deprecated: true
+ }
comment__: "getmonsterinfo"
MOB_NAME: 0
diff --git a/doc/constants.md b/doc/constants.md
index 9225ce924..aedb1755e 100644
--- a/doc/constants.md
+++ b/doc/constants.md
@@ -1407,13 +1407,13 @@
- `e_panic`: 79
- `e_whisp`: 80
-### petstat
+### petstat - deprecated, use *getpetinfo
-- `PET_CLASS`: 1
-- `PET_NAME`: 2
-- `PET_LEVEL`: 3
-- `PET_HUNGRY`: 4
-- `PET_INTIMATE`: 5
+- `PET_CLASS`: 1 **(DEPRECATED)**
+- `PET_NAME`: 2 **(DEPRECATED)**
+- `PET_LEVEL`: 3 **(DEPRECATED)**
+- `PET_HUNGRY`: 4 **(DEPRECATED)**
+- `PET_INTIMATE`: 5 **(DEPRECATED)**
### getmonsterinfo
@@ -3989,6 +3989,7 @@
- `MAX_BG_MEMBERS`: 30
- `MAX_CHAT_USERS`: 20
- `MAX_REFINE`: 20
+- `MAX_ITEM_ID`: 65535
- `MAX_MENU_OPTIONS`: 255
- `MAX_MENU_LENGTH`: 2048
- `MOB_CLONE_START`: 4001
@@ -4294,6 +4295,22 @@
- `MERCINFO_LEVEL`: 7
- `MERCINFO_GID`: 8
+### getpetinfo options
+
+- `PETINFO_ID`: 0
+- `PETINFO_CLASS`: 1
+- `PETINFO_NAME`: 2
+- `PETINFO_INTIMACY`: 3
+- `PETINFO_HUNGRY`: 4
+- `PETINFO_RENAME`: 5
+- `PETINFO_GID`: 6
+- `PETINFO_EGGITEM`: 7
+- `PETINFO_FOODITEM`: 8
+- `PETINFO_ACCESSORYITEM`: 9
+- `PETINFO_ACCESSORYFLAG`: 10
+- `PETINFO_EVO_EGGID`: 11
+- `PETINFO_AUTOFEED`: 12
+
### monster skill states
- `MSS_ANY`: -1
diff --git a/doc/script_commands.txt b/doc/script_commands.txt
index 077895e2b..b53dda2f6 100644
--- a/doc/script_commands.txt
+++ b/doc/script_commands.txt
@@ -716,6 +716,7 @@ MAX_BANK_ZENY - Maximum Zeny in the bank
MAX_BG_MEMBERS - Maximum BattleGround members
MAX_CHAT_USERS - Maximum Chat users
MAX_REFINE - Maximum Refine level
+MAX_ITEM_ID - Maximum Item ID
MAX_MENU_OPTIONS - Maximum NPC menu options
MAX_MENU_LENGTH - Maximum NPC menu string length
MOB_CLONE_START - Clone ID start from this range
@@ -3115,6 +3116,7 @@ invoking character has in its inventory, including all the data needed to
recreate these items perfectly if they are destroyed. Here's what you get:
@inventorylist_id[] - array of item ids.
+@inventorylist_idx[] - array of item inventory index.
@inventorylist_amount[] - their corresponding item amounts.
@inventorylist_equip[] - will return the slot the item is equipped on, if at all.
@inventorylist_refine[] - for how much it is refined.
@@ -3531,20 +3533,21 @@ Examples :
---------------------------------------
-*gettimestr(<format string>, <max length>)
+*gettimestr(<format string>, <max length>{, <timestamp>})
This function will return a string containing time data as specified by
the format string.
-This uses the C function 'strfmtime', which obeys special format
+This uses the C function 'strftime', which obeys special format
characters. For a full description see, for example, the description of
-'strfmtime' at http://www.delorie.com/gnu/docs/glibc/libc_437.html
+'strftime' at http://www.delorie.com/gnu/docs/glibc/libc_437.html
All the format characters given in there should properly work.
Max length is the maximum length of a time string to generate.
The example given in Hercules sample scripts works like this:
mes(gettimestr("%Y-%m/%d %H:%M:%S", 21));
+ mes(gettimestr("%Y-%m/%d %H:%M:%S", 21, getcalendartime(0, 0)));
This will print a full date and time like 'YYYY-MM/DD HH:MM:SS'.
@@ -3833,26 +3836,34 @@ how many skills a character has.
*getpetinfo(<type>)
-This function will return pet information for the pet the invoking
-character currently has active. Valid types are:
+This command will return the currently active pet information of the invoking character.
+These fields are associate in 'db/(pre-)re/pet_db.conf'. Valid types are:
- 0 - Unique pet ID number as stored by the char server and distinguishing
- it from all other pets the characters actually have. This value is
- currently useless, at most you can use it to tell pets apart reliably.
- 1 - Pet class number as per 'db/pet_db.txt' - will tell you what kind of
- a pet it is.
- 2 - Pet name. Will return "null" if there's no pet.
- 3 - Pet friendly level (intimacy score). 1000 is full loyalty.
- 4 - Pet hungry level. 100 is completely full.
- 5 - Pet rename flag. 0 means this pet has not been named yet.
-
-If the invoking player doesn't own a pet, this command will return
-"null" for type 2, and return 0 for other types.
+ PETINFO_ID - Pet Database ID, stored in `pet` table to distinguish from other pets.
+ PETINFO_CLASS - Pet class ID. (Id field)
+ PETINFO_NAME - Pet Name, return "null" if there's no active pet.
+ PETINFO_INTIMACY - Pet Intimacy level. 1000 is full loyalty.
+ PETINFO_HUNGRY - Pet hungry level. 100 is completely full.
+ PETINFO_RENAME - Pet rename flag. 0 means this pet has not been named yet.
+ PETINFO_GID - Pet Game ID
+ PETINFO_EGGITEM - Pet EggItem
+ PETINFO_FOODITEM - Pet FoodItem
+ PETINFO_ACCESSORYITEM - Pet AccessoryItem
+ PETINFO_ACCESSORYFLAG - return 1 if the pet currently equipping accessory, return 0 otherwise.
+ PETINFO_EVO_EGGID - Pet Evolve EggID
+ PETINFO_AUTOFEED - Pet AutoFeed flag.
+
+If the invoking player doesn't own a pet, this command will
+return "null" for type PETINFO_NAME, and return 0 for other types.
---------------------------------------
*petstat(<flag>)
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
+ @ /!\ This command is deprecated @
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
+
Returns current pet status, all are integers except name.
Returns 0 or "" if the player doesn't have pets.
@@ -3866,6 +3877,9 @@ PET_INTIMATE
Example:
.@i = petstat(PET_CLASS);
+This command is deprecated and it should not be used in new scripts, as it is
+likely to be removed at a later time. Please use 'getpetinfo' instead.
+
---------------------------------------
*getmonsterinfo(<mob ID>, <type>)
diff --git a/sql-files/mob_skill_db.sql b/sql-files/mob_skill_db.sql
index c5c51ca77..1610656fb 100644
--- a/sql-files/mob_skill_db.sql
+++ b/sql-files/mob_skill_db.sql
@@ -1413,11 +1413,11 @@ REPLACE INTO `mob_skill_db` VALUES (1306,'Leib Olmai@NPC_STUNATTACK','attack',17
REPLACE INTO `mob_skill_db` VALUES (1306,'Leib Olmai@NPC_SUMMONSLAVE','idle',196,3,10000,2000,60000,'no','self','slavele',NULL,1243,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (1306,'Leib Olmai@SM_ENDURE','chase',8,1,5000,0,10000,'yes','self','longrangeattacked',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
REPLACE INTO `mob_skill_db` VALUES (1306,'Leib Olmai@SM_MAGNUM','attack',7,9,500,500,5000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o' Nine Tails@NPC_EMOTION','idle',197,1,2000,0,5000,'yes','self','always',NULL,22,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o' Nine Tails@AL_TELEPORT','idle',26,1,10000,0,0,'yes','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o' Nine Tails@MC_MAMMONITE','attack',42,9,500,800,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'8',NULL);
-REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o' Nine Tails@NPC_GUIDEDATTACK','attack',172,2,500,1000,20000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o' Nine Tails@NPC_SUMMONSLAVE','idle',196,2,10000,2000,60000,'no','self','slavele',NULL,1180,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o\' Nine Tails@NPC_EMOTION','idle',197,1,2000,0,5000,'yes','self','always',NULL,22,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o\' Nine Tails@AL_TELEPORT','idle',26,1,10000,0,0,'yes','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o\' Nine Tails@MC_MAMMONITE','attack',42,9,500,800,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'8',NULL);
+REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o\' Nine Tails@NPC_GUIDEDATTACK','attack',172,2,500,1000,20000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o\' Nine Tails@NPC_SUMMONSLAVE','idle',196,2,10000,2000,60000,'no','self','slavele',NULL,1180,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (1308,'Panzer Goblin@NPC_SELFDESTRUCTION','attack',173,1,500,2000,5000,'no','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,'23',NULL);
REPLACE INTO `mob_skill_db` VALUES (1308,'Panzer Goblin@NPC_WINDATTACK','attack',187,1,2000,0,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (1308,'Panzer Goblin@SM_MAGNUM','attack',7,9,500,500,5000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
@@ -4645,9 +4645,9 @@ REPLACE INTO `mob_skill_db` VALUES (1887,'Freezer@NPC_EMOTION','walk',197,1,2000
REPLACE INTO `mob_skill_db` VALUES (1887,'Freezer@NPC_WATERATTACK','attack',184,3,500,500,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
REPLACE INTO `mob_skill_db` VALUES (1888,'Garm Baby@MG_FROSTDIVER','chase',15,10,2000,0,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
REPLACE INTO `mob_skill_db` VALUES (1888,'Garm Baby@NPC_WATERATTACK','attack',184,3,500,500,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka's Guard@NPC_GUIDEDATTACK','attack',172,5,500,0,20000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka's Guard@NPC_WATERATTACK','attack',184,5,2000,0,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka's Guard@NPC_WATERATTACK','chase',184,5,2000,0,5000,'no','target','skillused','18',NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka\'s Guard@NPC_GUIDEDATTACK','attack',172,5,500,0,20000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka\'s Guard@NPC_WATERATTACK','attack',184,5,2000,0,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka\'s Guard@NPC_WATERATTACK','chase',184,5,2000,0,5000,'no','target','skillused','18',NULL,NULL,NULL,NULL,NULL,'6',NULL);
REPLACE INTO `mob_skill_db` VALUES (1890,'The Immortal Koshei@AL_TELEPORT','idle',26,1,10000,0,0,'yes','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (1890,'The Immortal Koshei@WZ_QUAGMIRE','chase',92,1,5000,200,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (1890,'The Immortal Koshei@MG_FIREBALL','chase',17,9,10000,0,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
@@ -5408,48 +5408,48 @@ REPLACE INTO `mob_skill_db` VALUES (2021,'Phylla@PR_LEXDIVINA','chase',76,3,500,
REPLACE INTO `mob_skill_db` VALUES (2021,'Phylla@MG_COLDBOLT','attack',14,3,3000,1500,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (2021,'Phylla@NPC_WATERATTACK','attack',184,1,2000,0,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (2021,'Phylla@WZ_WATERBALL','attack',86,3,2000,100,10000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_ALLHEAL','idle',687,1,3000,10000,10000,'no','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_ALLHEAL','walk',687,1,3000,10000,10000,'no','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_CALLSLAVE','attack',352,1,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_CALLSLAVE','idle',352,1,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_SUMMONSLAVE','attack',196,5,10000,700,10000,'no','self','slavele','3',2027,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_SUMMONSLAVE','idle',196,5,10000,700,10000,'no','self','slavele','3',2027,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_SUMMONSLAVE','idle',196,5,10000,700,10000,'no','self','onspawn',NULL,2027,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_MAGICMIRROR','idle',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_MAGICMIRROR','chase',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_MAGICMIRROR','attack',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_STONESKIN','chase',675,3,10000,2500,300000,'no','self','myhpltmaxrate','3',NULL,NULL,NULL,NULL,NULL,NULL,'34');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_STONESKIN','attack',675,3,10000,2500,300000,'no','self','myhpltmaxrate','3',NULL,NULL,NULL,NULL,NULL,NULL,'34');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_POWERUP','attack',349,5,6000,0,60000,'yes','self','myhpltmaxrate','15',NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_EVILLAND','attack',670,4,500,0,25000,'yes','target','myhpltmaxrate','15',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@WZ_QUAGMIRE','chase',92,5,10000,700,5000,'no','target','myhpltmaxrate','28',NULL,NULL,NULL,NULL,NULL,'12',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@WZ_QUAGMIRE','attack',92,5,10000,700,120000,'no','target','myhpltmaxrate','28',NULL,NULL,NULL,NULL,NULL,'12',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_EARTHQUAKE','chase',653,2,10000,10000,180000,'no','self','myhpltmaxrate','30',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_EARTHQUAKE','attack',653,2,10000,10000,180000,'no','self','myhpltmaxrate','30',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_INVISIBLE','idle',353,1,2000,200,5000,'no','target','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_INVISIBLE','chase',353,1,2000,200,5000,'no','target','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDESTONE','chase',666,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDESTONE','attack',666,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_EVILLAND','idle',670,10,500,0,120000,'yes','target','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_EVILLAND','chase',670,10,500,0,120000,'yes','target','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_HELLJUDGEMENT','chase',662,2,10000,7000,25000,'no','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,'32');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_HELLJUDGEMENT','attack',662,2,10000,7000,25000,'no','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,'32');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_DARKNESSBREATH','attack',658,10,10000,800,35000,'no','target','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_SLOWCAST','attack',672,5,10000,0,60000,'yes','self','myhpltmaxrate','70',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_CRITICALWOUND','attack',673,3,2000,0,30000,'yes','target','myhpltmaxrate','70',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDECURSE','chase',677,5,10000,1000,25000,'no','self','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDECURSE','attack',677,5,10000,1000,25000,'no','self','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_FIREBREATH','attack',654,5,10000,800,15000,'no','target','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDESLEEP','chase',668,5,10000,3000,20000,'no','self','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDESLEEP','attack',668,5,30000,1000,20000,'no','self','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_CRITICALSLASH','attack',170,1,1000,0,5000,'yes','target','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@MG_FIREBALL','chase',17,5,10000,0,30000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_DRAGONFEAR','chase',659,5,10000,0,30000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_DRAGONFEAR','attack',659,5,2000,1000,20000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@WZ_METEOR','attack',83,10,2000,1000,10000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'29',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@SA_DISPELL','attack',289,5,10000,0,30000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_PULSESTRIKE','attack',661,5,2000,10000,40000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'31');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_ALLHEAL','idle',687,1,10000,120000,30000,'yes','self','myhpltmaxrate','60',NULL,NULL,NULL,NULL,NULL,'20',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_ALLHEAL','idle',687,1,3000,10000,10000,'no','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_ALLHEAL','walk',687,1,3000,10000,10000,'no','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_CALLSLAVE','attack',352,1,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_CALLSLAVE','idle',352,1,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_SUMMONSLAVE','attack',196,5,10000,700,10000,'no','self','slavele','3',2027,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_SUMMONSLAVE','idle',196,5,10000,700,10000,'no','self','slavele','3',2027,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_SUMMONSLAVE','idle',196,5,10000,700,10000,'no','self','onspawn',NULL,2027,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_MAGICMIRROR','idle',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_MAGICMIRROR','chase',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_MAGICMIRROR','attack',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_STONESKIN','chase',675,3,10000,2500,300000,'no','self','myhpltmaxrate','3',NULL,NULL,NULL,NULL,NULL,NULL,'34');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_STONESKIN','attack',675,3,10000,2500,300000,'no','self','myhpltmaxrate','3',NULL,NULL,NULL,NULL,NULL,NULL,'34');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_POWERUP','attack',349,5,6000,0,60000,'yes','self','myhpltmaxrate','15',NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_EVILLAND','attack',670,4,500,0,25000,'yes','target','myhpltmaxrate','15',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@WZ_QUAGMIRE','chase',92,5,10000,700,5000,'no','target','myhpltmaxrate','28',NULL,NULL,NULL,NULL,NULL,'12',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@WZ_QUAGMIRE','attack',92,5,10000,700,120000,'no','target','myhpltmaxrate','28',NULL,NULL,NULL,NULL,NULL,'12',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_EARTHQUAKE','chase',653,2,10000,10000,180000,'no','self','myhpltmaxrate','30',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_EARTHQUAKE','attack',653,2,10000,10000,180000,'no','self','myhpltmaxrate','30',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_INVISIBLE','idle',353,1,2000,200,5000,'no','target','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_INVISIBLE','chase',353,1,2000,200,5000,'no','target','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDESTONE','chase',666,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDESTONE','attack',666,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_EVILLAND','idle',670,10,500,0,120000,'yes','target','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_EVILLAND','chase',670,10,500,0,120000,'yes','target','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_HELLJUDGEMENT','chase',662,2,10000,7000,25000,'no','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,'32');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_HELLJUDGEMENT','attack',662,2,10000,7000,25000,'no','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,'32');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_DARKNESSBREATH','attack',658,10,10000,800,35000,'no','target','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_SLOWCAST','attack',672,5,10000,0,60000,'yes','self','myhpltmaxrate','70',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_CRITICALWOUND','attack',673,3,2000,0,30000,'yes','target','myhpltmaxrate','70',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDECURSE','chase',677,5,10000,1000,25000,'no','self','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDECURSE','attack',677,5,10000,1000,25000,'no','self','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_FIREBREATH','attack',654,5,10000,800,15000,'no','target','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDESLEEP','chase',668,5,10000,3000,20000,'no','self','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDESLEEP','attack',668,5,30000,1000,20000,'no','self','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_CRITICALSLASH','attack',170,1,1000,0,5000,'yes','target','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@MG_FIREBALL','chase',17,5,10000,0,30000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_DRAGONFEAR','chase',659,5,10000,0,30000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_DRAGONFEAR','attack',659,5,2000,1000,20000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@WZ_METEOR','attack',83,10,2000,1000,10000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'29',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@SA_DISPELL','attack',289,5,10000,0,30000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_PULSESTRIKE','attack',661,5,2000,10000,40000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'31');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_ALLHEAL','idle',687,1,10000,120000,30000,'yes','self','myhpltmaxrate','60',NULL,NULL,NULL,NULL,NULL,'20',NULL);
REPLACE INTO `mob_skill_db` VALUES (2023,'Dark Shadow@NPC_DARKSTRIKE','chase',340,2,2000,0,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (2023,'Dark Shadow@NPC_EMOTION','idle',197,1,2000,0,5000,'yes','self','always',NULL,9,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (2023,'Dark Shadow@NPC_FIREATTACK','attack',186,3,500,500,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
diff --git a/sql-files/mob_skill_db_re.sql b/sql-files/mob_skill_db_re.sql
index 1eb0fbff7..b44ee4979 100644
--- a/sql-files/mob_skill_db_re.sql
+++ b/sql-files/mob_skill_db_re.sql
@@ -1463,11 +1463,11 @@ REPLACE INTO `mob_skill_db` VALUES (1306,'Leib Olmai@NPC_STUNATTACK','attack',17
REPLACE INTO `mob_skill_db` VALUES (1306,'Leib Olmai@NPC_SUMMONSLAVE','idle',196,3,10000,2000,60000,'no','self','slavele',NULL,1243,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (1306,'Leib Olmai@SM_ENDURE','chase',8,1,5000,0,10000,'yes','self','longrangeattacked',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
REPLACE INTO `mob_skill_db` VALUES (1306,'Leib Olmai@SM_MAGNUM','attack',7,9,500,500,5000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o' Nine Tails@AL_TELEPORT','idle',26,1,10000,0,0,'yes','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o' Nine Tails@MC_MAMMONITE','attack',42,9,500,800,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'8',NULL);
-REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o' Nine Tails@NPC_EMOTION','idle',197,1,2000,0,5000,'yes','self','always',NULL,22,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o' Nine Tails@NPC_GUIDEDATTACK','attack',172,2,500,1000,20000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o' Nine Tails@NPC_SUMMONSLAVE','idle',196,2,10000,2000,60000,'no','self','slavele',NULL,1180,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o\' Nine Tails@AL_TELEPORT','idle',26,1,10000,0,0,'yes','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o\' Nine Tails@MC_MAMMONITE','attack',42,9,500,800,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'8',NULL);
+REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o\' Nine Tails@NPC_EMOTION','idle',197,1,2000,0,5000,'yes','self','always',NULL,22,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o\' Nine Tails@NPC_GUIDEDATTACK','attack',172,2,500,1000,20000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (1307,'Cat o\' Nine Tails@NPC_SUMMONSLAVE','idle',196,2,10000,2000,60000,'no','self','slavele',NULL,1180,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (1308,'Panzer Goblin@AC_DOUBLE','attack',46,5,2000,1000,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (1308,'Panzer Goblin@NPC_SELFDESTRUCTION','attack',173,1,500,2000,5000,'no','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,'23',NULL);
REPLACE INTO `mob_skill_db` VALUES (1308,'Panzer Goblin@NPC_WINDATTACK','attack',187,1,2000,0,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
@@ -4680,9 +4680,9 @@ REPLACE INTO `mob_skill_db` VALUES (1887,'Freezer@NPC_EMOTION','walk',197,1,2000
REPLACE INTO `mob_skill_db` VALUES (1887,'Freezer@NPC_WATERATTACK','attack',184,3,500,500,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
REPLACE INTO `mob_skill_db` VALUES (1888,'Hatii Baby@MG_FROSTDIVER','chase',15,10,2000,0,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
REPLACE INTO `mob_skill_db` VALUES (1888,'Hatii Baby@NPC_WATERATTACK','attack',184,3,500,500,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka's Guard@NPC_GUIDEDATTACK','attack',172,5,500,0,20000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka's Guard@NPC_WATERATTACK','attack',184,5,2000,0,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka's Guard@NPC_WATERATTACK','chase',184,5,2000,0,5000,'no','target','skillused','18',NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka\'s Guard@NPC_GUIDEDATTACK','attack',172,5,500,0,20000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka\'s Guard@NPC_WATERATTACK','attack',184,5,2000,0,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (1889,'Marozka\'s Guard@NPC_WATERATTACK','chase',184,5,2000,0,5000,'no','target','skillused','18',NULL,NULL,NULL,NULL,NULL,'6',NULL);
REPLACE INTO `mob_skill_db` VALUES (1890,'Koschei the Immortal@AL_TELEPORT','idle',26,1,10000,0,0,'yes','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (1890,'Koschei the Immortal@MG_FIREBALL','attack',17,10,5000,0,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (1890,'Koschei the Immortal@MG_FIREBALL','chase',17,9,10000,0,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
@@ -5370,50 +5370,50 @@ REPLACE INTO `mob_skill_db` VALUES (2021,'Phylla@MG_COLDBOLT','attack',14,3,3000
REPLACE INTO `mob_skill_db` VALUES (2021,'Phylla@NPC_WATERATTACK','attack',184,1,2000,0,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (2021,'Phylla@PR_LEXDIVINA','chase',76,3,500,1000,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'2',NULL);
REPLACE INTO `mob_skill_db` VALUES (2021,'Phylla@WZ_WATERBALL','attack',86,3,2000,100,10000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@MG_FIREBALL','chase',17,5,10000,0,30000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_ALLHEAL','idle',687,1,10000,120000,30000,'yes','self','myhpltmaxrate','60',NULL,NULL,NULL,NULL,NULL,'20',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_ALLHEAL','idle',687,1,3000,10000,10000,'no','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_ALLHEAL','walk',687,1,3000,10000,10000,'no','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_CALLSLAVE','attack',352,1,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_CALLSLAVE','idle',352,1,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_CRITICALSLASH','attack',170,1,1000,0,5000,'yes','target','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_CRITICALWOUND','attack',673,3,2000,0,30000,'yes','target','myhpltmaxrate','70',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_DARKNESSBREATH','attack',658,10,10000,800,35000,'no','target','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_DRAGONFEAR','attack',659,5,2000,1000,20000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_DRAGONFEAR','chase',659,5,10000,0,30000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_EARTHQUAKE','attack',653,2,10000,10000,180000,'no','self','myhpltmaxrate','30',NULL,NULL,NULL,NULL,NULL,NULL,'33');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_EARTHQUAKE','chase',653,2,10000,10000,180000,'no','self','myhpltmaxrate','30',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_EVILLAND','attack',670,4,500,0,25000,'yes','self','myhpltmaxrate','15',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_EVILLAND','idle',670,10,500,0,120000,'yes','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_EVILLAND','chase',670,10,500,0,120000,'yes','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_FIREBREATH','attack',654,5,10000,800,15000,'no','target','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_HELLJUDGEMENT','attack',662,2,10000,7000,25000,'no','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,'32');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_HELLJUDGEMENT','chase',662,2,10000,7000,25000,'no','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,'32');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_INVISIBLE','idle',353,1,2000,200,5000,'no','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_INVISIBLE','chase',353,1,2000,200,5000,'no','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_MAGICMIRROR','attack',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_MAGICMIRROR','idle',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_MAGICMIRROR','chase',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_POWERUP','attack',349,5,6000,0,60000,'yes','self','myhpltmaxrate','15',NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_PULSESTRIKE','attack',661,5,2000,10000,40000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'31');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_SLOWCAST','attack',672,5,10000,0,60000,'yes','self','myhpltmaxrate','70',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_STONESKIN','attack',675,3,10000,2500,300000,'no','self','myhpltmaxrate','3',NULL,NULL,NULL,NULL,NULL,NULL,'34');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_STONESKIN','chase',675,3,10000,2500,300000,'no','self','myhpltmaxrate','3',NULL,NULL,NULL,NULL,NULL,NULL,'34');
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_SUMMONSLAVE','attack',196,5,10000,700,10000,'no','self','slavele','3',2027,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_SUMMONSLAVE','idle',196,5,10000,700,10000,'no','self','slavele','3',2027,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_SUMMONSLAVE','idle',196,5,10000,700,10000,'no','self','onspawn',NULL,2027,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDEBLEEDING','attack',665,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDEBLEEDING','chase',665,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDECURSE','attack',677,5,10000,1000,25000,'no','self','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDECURSE','chase',677,5,10000,1000,25000,'no','self','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDESLEEP','attack',668,5,10000,1000,20000,'no','self','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDESLEEP','chase',668,5,10000,3000,20000,'no','self','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,'32',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDESTONE','attack',666,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@NPC_WIDESTONE','chase',666,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@SA_DISPELL','attack',289,5,10000,0,30000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@WZ_METEOR','attack',83,10,2000,1000,10000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'29',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@WZ_QUAGMIRE','attack',92,5,10000,700,120000,'no','target','myhpltmaxrate','28',NULL,NULL,NULL,NULL,NULL,'12',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr's Shadow@WZ_QUAGMIRE','chase',92,5,10000,700,5000,'no','target','myhpltmaxrate','28',NULL,NULL,NULL,NULL,NULL,'12',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@MG_FIREBALL','chase',17,5,10000,0,30000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_ALLHEAL','idle',687,1,10000,120000,30000,'yes','self','myhpltmaxrate','60',NULL,NULL,NULL,NULL,NULL,'20',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_ALLHEAL','idle',687,1,3000,10000,10000,'no','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_ALLHEAL','walk',687,1,3000,10000,10000,'no','self','rudeattacked',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_CALLSLAVE','attack',352,1,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_CALLSLAVE','idle',352,1,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_CRITICALSLASH','attack',170,1,1000,0,5000,'yes','target','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_CRITICALWOUND','attack',673,3,2000,0,30000,'yes','target','myhpltmaxrate','70',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_DARKNESSBREATH','attack',658,10,10000,800,35000,'no','target','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_DRAGONFEAR','attack',659,5,2000,1000,20000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_DRAGONFEAR','chase',659,5,10000,0,30000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_EARTHQUAKE','attack',653,2,10000,10000,180000,'no','self','myhpltmaxrate','30',NULL,NULL,NULL,NULL,NULL,NULL,'33');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_EARTHQUAKE','chase',653,2,10000,10000,180000,'no','self','myhpltmaxrate','30',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_EVILLAND','attack',670,4,500,0,25000,'yes','self','myhpltmaxrate','15',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_EVILLAND','idle',670,10,500,0,120000,'yes','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_EVILLAND','chase',670,10,500,0,120000,'yes','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_FIREBREATH','attack',654,5,10000,800,15000,'no','target','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_HELLJUDGEMENT','attack',662,2,10000,7000,25000,'no','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,'32');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_HELLJUDGEMENT','chase',662,2,10000,7000,25000,'no','self','myhpltmaxrate','50',NULL,NULL,NULL,NULL,NULL,NULL,'32');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_INVISIBLE','idle',353,1,2000,200,5000,'no','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_INVISIBLE','chase',353,1,2000,200,5000,'no','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_MAGICMIRROR','attack',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_MAGICMIRROR','idle',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_MAGICMIRROR','chase',671,3,10000,0,120000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_POWERUP','attack',349,5,6000,0,60000,'yes','self','myhpltmaxrate','15',NULL,NULL,NULL,NULL,NULL,'6',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_PULSESTRIKE','attack',661,5,2000,10000,40000,'no','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'31');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_SLOWCAST','attack',672,5,10000,0,60000,'yes','self','myhpltmaxrate','70',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_STONESKIN','attack',675,3,10000,2500,300000,'no','self','myhpltmaxrate','3',NULL,NULL,NULL,NULL,NULL,NULL,'34');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_STONESKIN','chase',675,3,10000,2500,300000,'no','self','myhpltmaxrate','3',NULL,NULL,NULL,NULL,NULL,NULL,'34');
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_SUMMONSLAVE','attack',196,5,10000,700,10000,'no','self','slavele','3',2027,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_SUMMONSLAVE','idle',196,5,10000,700,10000,'no','self','slavele','3',2027,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_SUMMONSLAVE','idle',196,5,10000,700,10000,'no','self','onspawn',NULL,2027,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDEBLEEDING','attack',665,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDEBLEEDING','chase',665,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDECURSE','attack',677,5,10000,1000,25000,'no','self','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDECURSE','chase',677,5,10000,1000,25000,'no','self','myhpltmaxrate','75',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDESLEEP','attack',668,5,10000,1000,20000,'no','self','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDESLEEP','chase',668,5,10000,3000,20000,'no','self','myhpltmaxrate','95',NULL,NULL,NULL,NULL,NULL,'32',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDESTONE','attack',666,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@NPC_WIDESTONE','chase',666,5,10000,0,60000,'yes','self','myhpltmaxrate','40',NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@SA_DISPELL','attack',289,5,10000,0,30000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@WZ_METEOR','attack',83,10,2000,1000,10000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'29',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@WZ_QUAGMIRE','attack',92,5,10000,700,120000,'no','target','myhpltmaxrate','28',NULL,NULL,NULL,NULL,NULL,'12',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2022,'Nidhoggr\'s Shadow@WZ_QUAGMIRE','chase',92,5,10000,700,5000,'no','target','myhpltmaxrate','28',NULL,NULL,NULL,NULL,NULL,'12',NULL);
REPLACE INTO `mob_skill_db` VALUES (2023,'Dark Shadow@NPC_DARKNESSBREATH','attack',658,1,500,1000,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (2023,'Dark Shadow@NPC_DARKSTRIKE','chase',340,2,2000,0,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (2023,'Dark Shadow@NPC_EMOTION','idle',197,1,2000,0,5000,'yes','self','always',NULL,9,NULL,NULL,NULL,NULL,NULL,NULL);
@@ -6138,21 +6138,21 @@ REPLACE INTO `mob_skill_db` VALUES (2137,'Miming@NPC_STUNATTACK','attack',179,2,
REPLACE INTO `mob_skill_db` VALUES (2137,'Miming@SA_REVERSEORCISH','attack',294,1,500,0,30000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'18',NULL);
REPLACE INTO `mob_skill_db` VALUES (2137,'Miming@SA_REVERSEORCISH','chase',294,1,500,0,30000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'18',NULL);
REPLACE INTO `mob_skill_db` VALUES (2137,'Miming@WZ_WATERBALL','attack',86,3,500,1000,5000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2138,'Nydhogg's Memory@NPC_SUMMONSLAVE','idle',196,1,10000,0,0,'no','self','onspawn',NULL,2139,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2138,'Nydhogg's Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'35');
-REPLACE INTO `mob_skill_db` VALUES (2138,'Nydhogg's Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'35');
-REPLACE INTO `mob_skill_db` VALUES (2139,'Nydhogg's Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'36');
-REPLACE INTO `mob_skill_db` VALUES (2139,'Nydhogg's Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'36');
-REPLACE INTO `mob_skill_db` VALUES (2140,'Nydhogg's Memory@NPC_SUMMONSLAVE','idle',196,1,10000,0,0,'no','self','onspawn',NULL,2141,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2140,'Nydhogg's Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'37');
-REPLACE INTO `mob_skill_db` VALUES (2140,'Nydhogg's Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'37');
-REPLACE INTO `mob_skill_db` VALUES (2141,'Nydhogg's Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'40');
-REPLACE INTO `mob_skill_db` VALUES (2141,'Nydhogg's Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'38');
-REPLACE INTO `mob_skill_db` VALUES (2141,'Nydhogg's Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'38');
-REPLACE INTO `mob_skill_db` VALUES (2142,'Nydhogg's Memory@NPC_SUMMONSLAVE','idle',196,1,10000,0,0,'no','self','onspawn',NULL,2143,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2142,'Nydhogg's Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'39');
-REPLACE INTO `mob_skill_db` VALUES (2142,'Nydhogg's Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'39');
-REPLACE INTO `mob_skill_db` VALUES (2143,'Nydhogg's Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'40');
+REPLACE INTO `mob_skill_db` VALUES (2138,'Nydhogg\'s Memory@NPC_SUMMONSLAVE','idle',196,1,10000,0,0,'no','self','onspawn',NULL,2139,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2138,'Nydhogg\'s Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'35');
+REPLACE INTO `mob_skill_db` VALUES (2138,'Nydhogg\'s Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'35');
+REPLACE INTO `mob_skill_db` VALUES (2139,'Nydhogg\'s Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'36');
+REPLACE INTO `mob_skill_db` VALUES (2139,'Nydhogg\'s Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'36');
+REPLACE INTO `mob_skill_db` VALUES (2140,'Nydhogg\'s Memory@NPC_SUMMONSLAVE','idle',196,1,10000,0,0,'no','self','onspawn',NULL,2141,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2140,'Nydhogg\'s Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'37');
+REPLACE INTO `mob_skill_db` VALUES (2140,'Nydhogg\'s Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'37');
+REPLACE INTO `mob_skill_db` VALUES (2141,'Nydhogg\'s Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'40');
+REPLACE INTO `mob_skill_db` VALUES (2141,'Nydhogg\'s Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'38');
+REPLACE INTO `mob_skill_db` VALUES (2141,'Nydhogg\'s Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'38');
+REPLACE INTO `mob_skill_db` VALUES (2142,'Nydhogg\'s Memory@NPC_SUMMONSLAVE','idle',196,1,10000,0,0,'no','self','onspawn',NULL,2143,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2142,'Nydhogg\'s Memory@NPC_TALK','attack',682,10,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'39');
+REPLACE INTO `mob_skill_db` VALUES (2142,'Nydhogg\'s Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'39');
+REPLACE INTO `mob_skill_db` VALUES (2143,'Nydhogg\'s Memory@NPC_TALK','idle',682,10,2500,0,10000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,'40');
REPLACE INTO `mob_skill_db` VALUES (2144,'Antler Scaraba@BS_ADRENALINE','attack',111,10,500,1500,300000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
REPLACE INTO `mob_skill_db` VALUES (2144,'Antler Scaraba@BS_ADRENALINE','chase',111,10,500,1500,300000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,'6',NULL);
REPLACE INTO `mob_skill_db` VALUES (2144,'Antler Scaraba@NPC_BLEEDING','attack',660,3,2000,0,3000,'yes','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'32',NULL);
@@ -7738,14 +7738,14 @@ REPLACE INTO `mob_skill_db` VALUES (2322,'Bakonawa@WZ_VERMILION','attack',85,10,
REPLACE INTO `mob_skill_db` VALUES (2322,'Bakonawa@WZ_VERMILION','chase',85,10,2000,500,2000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (2322,'Bakonawa@WZ_WATERBALL','chase',86,10,5000,500,1000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (2322,'Bakonawa@WZ_WATERBALL','chase',86,10,5000,500,1000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2329,'Buwaya's Egg@NPC_METAMORPHOSIS','idle',193,1,2000,2000,5000,'no','self','always',NULL,2330,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya's Slave@NPC_COMBOATTACK','attack',171,2,500,700,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya's Slave@NPC_EMOTION','chase',197,1,2000,0,5000,'yes','self','always',NULL,32,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya's Slave@NPC_FIREBREATH','attack',654,3,500,1000,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya's Slave@NPC_GROUNDATTACK','attack',185,5,500,500,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya's Slave@NPC_PIERCINGATT','attack',158,5,500,0,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya's Slave@SM_PROVOKE','chase',6,10,2000,600,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'44',NULL);
-REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya's Slave@TF_THROWSTONE','chase',152,1,2000,0,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2329,'Buwaya\'s Egg@NPC_METAMORPHOSIS','idle',193,1,2000,2000,5000,'no','self','always',NULL,2330,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya\'s Slave@NPC_COMBOATTACK','attack',171,2,500,700,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya\'s Slave@NPC_EMOTION','chase',197,1,2000,0,5000,'yes','self','always',NULL,32,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya\'s Slave@NPC_FIREBREATH','attack',654,3,500,1000,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya\'s Slave@NPC_GROUNDATTACK','attack',185,5,500,500,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya\'s Slave@NPC_PIERCINGATT','attack',158,5,500,0,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya\'s Slave@SM_PROVOKE','chase',6,10,2000,600,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'44',NULL);
+REPLACE INTO `mob_skill_db` VALUES (2330,'Buwaya\'s Slave@TF_THROWSTONE','chase',152,1,2000,0,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
REPLACE INTO `mob_skill_db` VALUES (2331,'Seaweed@AL_DECAGI','idle',30,1,10000,1000,5000,'no','target','always',NULL,NULL,NULL,NULL,NULL,NULL,'29',NULL);
REPLACE INTO `mob_skill_db` VALUES (2331,'Seaweed@AL_HEAL','idle',28,9,10000,500,5000,'yes','friend','friendhpltmaxrate','100',NULL,NULL,NULL,NULL,NULL,'3',NULL);
REPLACE INTO `mob_skill_db` VALUES (2337,'Hidden Mob@NPC_INVISIBLE','attack',353,1,10000,0,30000,'yes','self','always',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
diff --git a/src/char/char.c b/src/char/char.c
index 34a3ea7a8..5528fb8aa 100644
--- a/src/char/char.c
+++ b/src/char/char.c
@@ -479,7 +479,8 @@ static int char_mmo_char_tosql(int char_id, struct mmo_charstatus *p)
(p->show_equip != cp->show_equip) || (p->allow_party != cp->allow_party) || (p->font != cp->font) ||
(p->uniqueitem_counter != cp->uniqueitem_counter) || (p->hotkey_rowshift != cp->hotkey_rowshift) ||
(p->clan_id != cp->clan_id) || (p->last_login != cp->last_login) || (p->attendance_count != cp->attendance_count) ||
- (p->attendance_timer != cp->attendance_timer) || (p->title_id != cp->title_id) || (p->inventorySize != cp->inventorySize)
+ (p->attendance_timer != cp->attendance_timer) || (p->title_id != cp->title_id) || (p->inventorySize != cp->inventorySize) ||
+ (p->allow_call != cp->allow_call)
) {
//Save status
unsigned int opt = 0;
@@ -491,10 +492,12 @@ static int char_mmo_char_tosql(int char_id, struct mmo_charstatus *p)
p->inventorySize = FIXED_INVENTORY_SIZE;
}
- if( p->allow_party )
+ if (p->allow_party)
opt |= OPT_ALLOW_PARTY;
- if( p->show_equip )
+ if (p->show_equip)
opt |= OPT_SHOW_EQUIP;
+ if (p->allow_call)
+ opt |= OPT_ALLOW_CALL;
if( SQL_ERROR == SQL->Query(inter->sql_handle, "UPDATE `%s` SET `base_level`='%d', `job_level`='%d',"
"`base_exp`='%"PRIu64"', `job_exp`='%"PRIu64"', `zeny`='%d',"
@@ -1447,10 +1450,12 @@ static int char_mmo_char_fromsql(int char_id, struct mmo_charstatus *p, bool loa
SQL->StmtFree(stmt);
/* load options into proper vars */
- if( opt & OPT_ALLOW_PARTY )
+ if (opt & OPT_ALLOW_PARTY)
p->allow_party = true;
- if( opt & OPT_SHOW_EQUIP )
+ if (opt & OPT_SHOW_EQUIP)
p->show_equip = true;
+ if (opt & OPT_ALLOW_CALL)
+ p->allow_call = true;
cp = idb_ensure(chr->char_db_, char_id, chr->create_charstatus);
memcpy(cp, p, sizeof(struct mmo_charstatus));
diff --git a/src/common/mmo.h b/src/common/mmo.h
index 3a0f73520..2fc464243 100644
--- a/src/common/mmo.h
+++ b/src/common/mmo.h
@@ -487,6 +487,7 @@ enum e_mmo_charstatus_opt {
OPT_NONE = 0x0,
OPT_SHOW_EQUIP = 0x1,
OPT_ALLOW_PARTY = 0x2,
+ OPT_ALLOW_CALL = 0x4,
};
enum e_item_bound_type {
@@ -733,7 +734,9 @@ struct mmo_charstatus {
#ifdef HOTKEY_SAVING
struct hotkey hotkeys[MAX_HOTKEYS];
#endif
- bool show_equip, allow_party;
+ bool show_equip;
+ bool allow_party;
+ bool allow_call;
unsigned short rename;
unsigned short slotchange;
diff --git a/src/common/packets/packets2019_len_main.h b/src/common/packets/packets2019_len_main.h
index 3b46c26cb..79c8d3f51 100644
--- a/src/common/packets/packets2019_len_main.h
+++ b/src/common/packets/packets2019_len_main.h
@@ -3787,7 +3787,7 @@ packetLen(0x0a43, 85) // ZC_ADD_MEMBER_TO_GROUP
packetLen(0x0a44, -1) // ZC_GROUP_LIST
// Packet: 0x0a46
-packetLen(0x0a46, 14)
+packetLen(0x0a46, 14) // CZ_REQ_STYLE_CHANGE
// Packet: 0x0a47
packetLen(0x0a47, 3) // ZC_STYLE_CHANGE_RES
@@ -4288,7 +4288,7 @@ packetLen(0x0afa, 54)
packetLen(0x0afb, -1) // ZC_AUTOSPELLLIST
// Packet: 0x0afc
-packetLen(0x0afc, 16)
+packetLen(0x0afc, 16) // CZ_REQ_STYLE_CHANGE2
// Packet: 0x0afd
packetLen(0x0afd, -1) // ZC_GUILD_POSITION
@@ -4379,17 +4379,17 @@ packetLen(0x0b1a, 29) // ZC_USESKILL_ACK3
// Packet: 0x0b1b
#if PACKETVER >= 20190213
-packetLen(0x0b1b, 2)
+packetLen(0x0b1b, 2) // ZC_ALT_PING
#endif
// Packet: 0x0b1c
#if PACKETVER >= 20190227
-packetLen(0x0b1c, 2)
+packetLen(0x0b1c, 2) // CZ_PING
#endif
// Packet: 0x0b1d
#if PACKETVER >= 20190227
-packetLen(0x0b1d, 2)
+packetLen(0x0b1d, 2) // ZC_PING
#endif
// Packet: 0x0b1e
@@ -4402,15 +4402,24 @@ packetLen(0x0b1e, 10)
packetLen(0x0b1f, 10)
#endif
+// Packet: 0x0b20
+#if PACKETVER >= 20190403
+packetLen(0x0b20, 271)
+#endif
+
// Packet: 0x0b21
-#if PACKETVER >= 20190306
+#if PACKETVER >= 20190403
+packetLen(0x0b21, 13)
+#elif PACKETVER >= 20190306
// removed
#elif PACKETVER >= 20190227
packetLen(0x0b21, 10)
#endif
// Packet: 0x0b22
-#if PACKETVER >= 20190306
+#if PACKETVER >= 20190403
+packetLen(0x0b22, 5)
+#elif PACKETVER >= 20190306
// removed
#elif PACKETVER >= 20190227
packetLen(0x0b22, 6)
diff --git a/src/common/packets/packets2019_len_re.h b/src/common/packets/packets2019_len_re.h
index 6614fa8fd..c43b65cd9 100644
--- a/src/common/packets/packets2019_len_re.h
+++ b/src/common/packets/packets2019_len_re.h
@@ -3793,7 +3793,7 @@ packetLen(0x0a43, 85) // ZC_ADD_MEMBER_TO_GROUP
packetLen(0x0a44, -1) // ZC_GROUP_LIST
// Packet: 0x0a46
-packetLen(0x0a46, 14)
+packetLen(0x0a46, 14) // CZ_REQ_STYLE_CHANGE
// Packet: 0x0a47
packetLen(0x0a47, 3) // ZC_STYLE_CHANGE_RES
@@ -4294,7 +4294,7 @@ packetLen(0x0afa, 54)
packetLen(0x0afb, -1) // ZC_AUTOSPELLLIST
// Packet: 0x0afc
-packetLen(0x0afc, 16)
+packetLen(0x0afc, 16) // CZ_REQ_STYLE_CHANGE2
// Packet: 0x0afd
packetLen(0x0afd, -1) // ZC_GUILD_POSITION
@@ -4385,17 +4385,17 @@ packetLen(0x0b1a, 29) // ZC_USESKILL_ACK3
// Packet: 0x0b1b
#if PACKETVER >= 20190213
-packetLen(0x0b1b, 2)
+packetLen(0x0b1b, 2) // ZC_ALT_PING
#endif
// Packet: 0x0b1c
#if PACKETVER >= 20190220
-packetLen(0x0b1c, 2)
+packetLen(0x0b1c, 2) // CZ_PING
#endif
// Packet: 0x0b1d
#if PACKETVER >= 20190220
-packetLen(0x0b1d, 2)
+packetLen(0x0b1d, 2) // ZC_PING
#endif
// Packet: 0x0b1e
@@ -4408,15 +4408,24 @@ packetLen(0x0b1e, 10)
packetLen(0x0b1f, 10)
#endif
+// Packet: 0x0b20
+#if PACKETVER >= 20190403
+packetLen(0x0b20, 271)
+#endif
+
// Packet: 0x0b21
-#if PACKETVER >= 20190306
+#if PACKETVER >= 20190403
+packetLen(0x0b21, 13)
+#elif PACKETVER >= 20190306
// removed
#elif PACKETVER >= 20190227
packetLen(0x0b21, 10)
#endif
// Packet: 0x0b22
-#if PACKETVER >= 20190306
+#if PACKETVER >= 20190403
+packetLen(0x0b22, 5)
+#elif PACKETVER >= 20190306
// removed
#elif PACKETVER >= 20190227
packetLen(0x0b22, 6)
diff --git a/src/common/packets/packets2019_len_zero.h b/src/common/packets/packets2019_len_zero.h
index 8ddbdcc18..85098505a 100644
--- a/src/common/packets/packets2019_len_zero.h
+++ b/src/common/packets/packets2019_len_zero.h
@@ -3787,7 +3787,7 @@ packetLen(0x0a43, 85) // ZC_ADD_MEMBER_TO_GROUP
packetLen(0x0a44, -1) // ZC_GROUP_LIST
// Packet: 0x0a46
-packetLen(0x0a46, 14)
+packetLen(0x0a46, 14) // CZ_REQ_STYLE_CHANGE
// Packet: 0x0a47
packetLen(0x0a47, 3) // ZC_STYLE_CHANGE_RES
@@ -4288,7 +4288,7 @@ packetLen(0x0afa, 54)
packetLen(0x0afb, -1) // ZC_AUTOSPELLLIST
// Packet: 0x0afc
-packetLen(0x0afc, 16)
+packetLen(0x0afc, 16) // CZ_REQ_STYLE_CHANGE2
// Packet: 0x0afd
packetLen(0x0afd, -1) // ZC_GUILD_POSITION
@@ -4379,17 +4379,42 @@ packetLen(0x0b1a, 29) // ZC_USESKILL_ACK3
// Packet: 0x0b1b
#if PACKETVER >= 20190130
-packetLen(0x0b1b, 2)
+packetLen(0x0b1b, 2) // ZC_ALT_PING
#endif
// Packet: 0x0b1c
#if PACKETVER >= 20190220
-packetLen(0x0b1c, 2)
+packetLen(0x0b1c, 2) // CZ_PING
#endif
// Packet: 0x0b1d
#if PACKETVER >= 20190220
-packetLen(0x0b1d, 2)
+packetLen(0x0b1d, 2) // ZC_PING
+#endif
+
+// Packet: 0x0b1e
+#if PACKETVER >= 20190313
+packetLen(0x0b1e, 10)
+#endif
+
+// Packet: 0x0b1f
+#if PACKETVER >= 20190313
+packetLen(0x0b1f, 10)
+#endif
+
+// Packet: 0x0b20
+#if PACKETVER >= 20190327
+packetLen(0x0b20, 271)
+#endif
+
+// Packet: 0x0b21
+#if PACKETVER >= 20190327
+packetLen(0x0b21, 13)
+#endif
+
+// Packet: 0x0b22
+#if PACKETVER >= 20190327
+packetLen(0x0b22, 5)
#endif
diff --git a/src/common/socket.c b/src/common/socket.c
index faf57f412..dc5b06da0 100644
--- a/src/common/socket.c
+++ b/src/common/socket.c
@@ -488,11 +488,12 @@ static int send_from_fifo(int fd)
return 0;
}
- if( len > 0 )
+ if (len > 0)
{
+ sockt->session[fd]->wdata_tick = sockt->last_tick;
// some data could not be transferred?
// shift unsent data to the beginning of the queue
- if( (size_t)len < sockt->session[fd]->wdata_size )
+ if ((size_t)len < sockt->session[fd]->wdata_size)
memmove(sockt->session[fd]->wdata, sockt->session[fd]->wdata + len, sockt->session[fd]->wdata_size - len);
sockt->session[fd]->wdata_size -= len;
@@ -649,6 +650,7 @@ static int make_listen_bind(uint32 ip, uint16 port)
create_session(fd, sockt->connect_client, null_send, null_parse);
sockt->session[fd]->client_addr = 0; // just listens
sockt->session[fd]->rdata_tick = 0; // disable timeouts on this socket
+ sockt->session[fd]->wdata_tick = 0;
return fd;
}
@@ -731,6 +733,7 @@ static int create_session(int fd, RecvFunc func_recv, SendFunc func_send, ParseF
sockt->session[fd]->func_send = func_send;
sockt->session[fd]->func_parse = func_parse;
sockt->session[fd]->rdata_tick = sockt->last_tick;
+ sockt->session[fd]->wdata_tick = sockt->last_tick;
sockt->session[fd]->session_data = NULL;
sockt->session[fd]->hdata = NULL;
return 0;
diff --git a/src/common/socket.h b/src/common/socket.h
index 193b22645..b20b0b07e 100644
--- a/src/common/socket.h
+++ b/src/common/socket.h
@@ -130,6 +130,7 @@ struct socket_data {
size_t rdata_pos;
uint32 last_head_size;
time_t rdata_tick; // time of last recv (for detecting timeouts); zero when timeout is disabled
+ time_t wdata_tick; // time of last send (for detecting timeouts);
RecvFunc func_recv;
SendFunc func_send;
diff --git a/src/map/achievement.c b/src/map/achievement.c
index 057ea29c3..7ab80e183 100644
--- a/src/map/achievement.c
+++ b/src/map/achievement.c
@@ -301,6 +301,9 @@ static int achievement_validate_type(struct map_session_data *sd, enum achieveme
Assert_ret(criteria->goal != 0);
+ if (battle_config.feature_enable_achievement == 0)
+ return 0;
+
if (type == ACH_QUEST) {
ShowError("achievement_validate_type: ACH_QUEST is not handled by this function. (use achievement_validate())\n");
return 0;
@@ -358,6 +361,9 @@ static bool achievement_validate(struct map_session_data *sd, int aid, unsigned
Assert_retr(false, progress > 0);
Assert_retr(false, obj_idx < MAX_ACHIEVEMENT_OBJECTIVES);
+ if (battle_config.feature_enable_achievement == 0)
+ return false;
+
if ((ad = achievement->get(aid)) == NULL) {
ShowError("achievement_validate: Invalid Achievement %d provided.", aid);
return false;
diff --git a/src/map/atcommand.c b/src/map/atcommand.c
index a9f63fe13..a9bbff7bd 100644
--- a/src/map/atcommand.c
+++ b/src/map/atcommand.c
@@ -7669,9 +7669,9 @@ ACMD(fakename)
if (sd->fakename[0])
{
sd->fakename[0] = '\0';
- clif->charnameack(0, &sd->bl);
+ clif->blname_ack(0, &sd->bl);
if( sd->disguise )
- clif->charnameack(sd->fd, &sd->bl);
+ clif->blname_ack(sd->fd, &sd->bl);
clif->message(sd->fd, msg_fd(fd,1307)); // Returned to real name.
return true;
}
@@ -7687,9 +7687,9 @@ ACMD(fakename)
}
safestrncpy(sd->fakename, message, sizeof(sd->fakename));
- clif->charnameack(0, &sd->bl);
+ clif->blname_ack(0, &sd->bl);
if (sd->disguise) // Another packet should be sent so the client updates the name for sd
- clif->charnameack(sd->fd, &sd->bl);
+ clif->blname_ack(sd->fd, &sd->bl);
clif->message(sd->fd, msg_fd(fd,1310)); // Fake name enabled.
return true;
diff --git a/src/map/battle.c b/src/map/battle.c
index 1b7bf909e..fe7a64b51 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -6361,7 +6361,7 @@ static enum damage_lv battle_weapon_attack(struct block_list *src, struct block_
if (d_bl != NULL
&& ((d_bl->type == BL_MER && d_md->master != NULL && d_md->master->bl.id == target->id)
- || (d_bl->type == BL_PC && d_sd->devotion[sce->val2] == target->id)
+ || (d_sd != NULL && d_bl->type == BL_PC && d_sd->devotion[sce->val2] == target->id)
)
&& check_distance_bl(target, d_bl, sce->val3)
) {
@@ -7414,6 +7414,9 @@ static const struct battle_data {
{ "min_item_sell_price", &battle_config.min_item_sell_price, 0, 0, INT_MAX, },
{ "display_fake_hp_when_dead", &battle_config.display_fake_hp_when_dead, 1, 0, 1, },
{ "magicrod_type", &battle_config.magicrod_type, 0, 0, 1, },
+ { "features/enable_achievement_system", &battle_config.feature_enable_achievement, 1, 0, 1, },
+ { "ping_timer_inverval", &battle_config.ping_timer_interval, 30, 0, 99999999, },
+ { "ping_time", &battle_config.ping_time, 20, 0, 99999999, },
};
static bool battle_set_value_sub(int index, int value)
diff --git a/src/map/battle.h b/src/map/battle.h
index c797e665a..723a86874 100644
--- a/src/map/battle.h
+++ b/src/map/battle.h
@@ -578,6 +578,11 @@ struct Battle_Config {
int display_fake_hp_when_dead;
int magicrod_type;
+
+ int feature_enable_achievement;
+
+ int ping_timer_interval;
+ int ping_time;
};
/* criteria for battle_config.idletime_critera */
diff --git a/src/map/clif.c b/src/map/clif.c
index 4c3c746c4..cd3131181 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -7739,17 +7739,27 @@ static void clif_devotion(struct block_list *src, struct map_session_data *tsd)
static void clif_spiritball(struct block_list *bl)
{
unsigned char buf[16];
- struct map_session_data *sd = BL_CAST(BL_PC,bl);
- struct homun_data *hd = BL_CAST(BL_HOM,bl);
nullpo_retv(bl);
WBUFW(buf, 0) = 0x1d0;
WBUFL(buf, 2) = bl->id;
WBUFW(buf, 6) = 0; //init to 0
- switch(bl->type){
- case BL_PC: WBUFW(buf, 6) = sd->spiritball; break;
- case BL_HOM: WBUFW(buf, 6) = hd->homunculus.spiritball; break;
+ switch (bl->type) {
+ case BL_PC:
+ {
+ struct map_session_data *sd = BL_CAST(BL_PC, bl);
+ nullpo_retv(sd);
+ WBUFW(buf, 6) = sd->spiritball;
+ break;
+ }
+ case BL_HOM:
+ {
+ struct homun_data *hd = BL_CAST(BL_HOM, bl);
+ nullpo_retv(hd);
+ WBUFW(buf, 6) = hd->homunculus.spiritball;
+ break;
+ }
}
clif->send(buf, packet_len(0x1d0), bl, AREA);
}
@@ -9228,7 +9238,7 @@ static void clif_refresh(struct map_session_data *sd)
/// 0095 <id>.L <char name>.24B (ZC_ACK_REQNAME)
/// 0195 <id>.L <char name>.24B <party name>.24B <guild name>.24B <position name>.24B (ZC_ACK_REQNAMEALL)
/// 0A30 <id>.L <char name>.24B <party name>.24B <guild name>.24B <position name>.24B <title id>.L (ZC_ACK_REQNAMEALL2)
-static void clif_charnameack(int fd, struct block_list *bl)
+static void clif_blname_ack(int fd, struct block_list *bl)
{
struct packet_reqnameall_ack packet = { 0 };
int len = sizeof(struct packet_reqnameall_ack);
@@ -9349,7 +9359,7 @@ static void clif_charnameack(int fd, struct block_list *bl)
memcpy(packet.name, BL_UCCAST(BL_ELEM, bl)->db->name, NAME_LENGTH);
break;
default:
- ShowError("clif_charnameack: bad type %u(%d)\n", bl->type, bl->id);
+ ShowError("clif_blname_ack: bad type %u(%d)\n", bl->type, bl->id);
return;
}
@@ -10784,7 +10794,7 @@ static void clif_parse_GetCharNameRequest(int fd, struct map_session_data *sd)
}
#endif // 0
- clif->charnameack(fd, bl);
+ clif->blname_ack(fd, bl);
}
static int clif_undisguise_timer(int tid, int64 tick, int id, intptr_t data)
{
@@ -15662,6 +15672,7 @@ static void clif_parse_FeelSaveOk(int fd, struct map_session_data *sd)
/// 0 = sun
/// 1 = moon
/// 2 = star
+/// 10 = Do you agree to cast the magic spell that consumes 1 Black Gemstone and 1,000,000 Zeny?
static void clif_feel_req(int fd, struct map_session_data *sd, uint16 skill_lv)
{
nullpo_retv(sd);
@@ -17010,6 +17021,9 @@ static void clif_parse_cz_config(int fd, struct map_session_data *sd)
hd->homunculus.autofeed = flag;
break;
}
+ case CZ_CONFIG_CALL:
+ sd->status.allow_call = flag;
+ break;
default:
ShowWarning("clif_parse_cz_config: Unsupported type has been received (%u).\n", type);
return;
@@ -20949,8 +20963,8 @@ static void clif_change_title_ack(int fd, struct map_session_data *sd, int title
WFIFOSET(fd, packet_len(0xa2f));
// Update names
- clif->charnameack(fd, &sd->bl);
- clif->charnameack(0, &sd->bl);
+ clif->blname_ack(fd, &sd->bl);
+ clif->blname_ack(0, &sd->bl);
#endif
}
// End of Achievement System
@@ -21731,6 +21745,18 @@ static void clif_open_ui(struct map_session_data *sd, enum cz_ui_types uiType)
p.data = 0;
#endif
break;
+ case CZ_MACRO_REGISTER_UI:
+ p.UIType = ZC_CAPTCHA_UI;
+#if PACKETVER >= 20171122
+ p.data = 0;
+#endif
+ break;
+ case CZ_MACRO_DETECTOR_UI:
+ p.UIType = ZC_MACRO_UI;
+#if PACKETVER >= 20171122
+ p.data = 0;
+#endif
+ break;
case CZ_ATTENDANCE_UI:
{
if (clif->attendance_getendtime() < time(NULL)) {
@@ -21922,6 +21948,12 @@ static void clif_parse_cz_req_style_change2(int fd, struct map_session_data *sd)
return;
}
+static void clif_parse_cz_style_close(int fd, struct map_session_data *sd) __attribute__((nonnull(2)));
+static void clif_parse_cz_style_close(int fd, struct map_session_data *sd)
+{
+ // do nothing
+}
+
static void clif_style_change_response(struct map_session_data *sd, enum stylist_shop flag)
{
#if PACKETVER >= 20151104
@@ -22141,6 +22173,55 @@ static void clif_parse_clientVersion(int fd, struct map_session_data *sd)
#endif
}
+static void clif_parse_ping(int fd, struct map_session_data *sd) __attribute__((nonnull (2)));
+static void clif_parse_ping(int fd, struct map_session_data *sd)
+{
+ // do nothing, any packet update client tick
+}
+
+static void clif_ping(struct map_session_data *sd)
+{
+#if PACKETVER_MAIN_NUM >= 20190213 || PACKETVER_RE_NUM >= 20190213 || PACKETVER_ZERO_NUM >= 20190130
+ nullpo_retv(sd);
+ struct PACKET_ZC_PING p;
+ p.packetType = HEADER_ZC_PING;
+ clif->send(&p, sizeof(p), &sd->bl, SELF);
+#endif
+}
+
+static int clif_pingTimer(int tid, int64 tick, int id, intptr_t data)
+{
+ map->foreachpc(clif->pingTimerSub, time(NULL));
+ return 0;
+}
+
+static int clif_pingTimerSub(struct map_session_data *sd, va_list ap)
+{
+ nullpo_ret(sd);
+ const int fd = sd->fd;
+
+ if (!sockt->session_is_active(fd))
+ {
+ return 0;
+ }
+
+ time_t tick = va_arg(ap, time_t);
+
+ if (sockt->session[fd]->wdata_tick + battle_config.ping_time < tick)
+ {
+ clif->ping(sd);
+ }
+ return 0;
+}
+
+static void clif_parse_ResetCooldown(int fd, struct map_session_data *sd) __attribute__((nonnull (2)));
+static void clif_parse_ResetCooldown(int fd, struct map_session_data *sd)
+{
+ char cmd[15];
+ sprintf(cmd,"%ccddebug reset", atcommand->at_symbol);
+ atcommand->exec(fd, sd, cmd, true);
+}
+
/*==========================================
* Main client packet processing function
*------------------------------------------*/
@@ -22422,6 +22503,12 @@ static int do_init_clif(bool minimal)
clif->delay_clearunit_ers = ers_new(sizeof(struct block_list),"clif.c::delay_clearunit_ers",ERS_OPT_CLEAR);
clif->delayed_damage_ers = ers_new(sizeof(struct cdelayed_damage),"clif.c::delayed_damage_ers",ERS_OPT_CLEAR);
+#if PACKETVER_MAIN_NUM >= 20190403 || PACKETVER_RE_NUM >= 20190320
+ timer->add_func_list(clif->pingTimer, "clif_pingTimer");
+ if (battle_config.ping_timer_interval != 0)
+ timer->add_interval(timer->gettick() + battle_config.ping_timer_interval * 1000, clif->pingTimer, 0, 0, battle_config.ping_timer_interval * 1000);
+#endif
+
return 0;
}
@@ -22619,7 +22706,7 @@ void clif_defaults(void)
clif->mvp_exp = clif_mvp_exp;
clif->mvp_noitem = clif_mvp_noitem;
clif->changed_dir = clif_changed_dir;
- clif->charnameack = clif_charnameack;
+ clif->blname_ack = clif_blname_ack;
clif->monster_hp_bar = clif_monster_hp_bar;
clif->hpmeter = clif_hpmeter;
clif->hpmeter_single = clif_hpmeter_single;
@@ -23305,6 +23392,7 @@ void clif_defaults(void)
clif->pReqStyleChange = clif_parse_cz_req_style_change;
clif->pReqStyleChange2 = clif_parse_cz_req_style_change2;
+ clif->pStyleClose = clif_parse_cz_style_close;
clif->style_change_response = clif_style_change_response;
clif->camera_showWindow = clif_camera_showWindow;
@@ -23324,4 +23412,9 @@ void clif_defaults(void)
clif->pNPCBarterClosed = clif_parse_NPCBarterClosed;
clif->pNPCBarterPurchase = clif_parse_NPCBarterPurchase;
clif->pClientVersion = clif_parse_clientVersion;
+ clif->pPing = clif_parse_ping;
+ clif->ping = clif_ping;
+ clif->pingTimer = clif_pingTimer;
+ clif->pingTimerSub = clif_pingTimerSub;
+ clif->pResetCooldown = clif_parse_ResetCooldown;
}
diff --git a/src/map/clif.h b/src/map/clif.h
index 6e922bdff..6c9058cba 100644
--- a/src/map/clif.h
+++ b/src/map/clif.h
@@ -556,7 +556,7 @@ enum clif_unittype {
**/
enum CZ_CONFIG {
CZ_CONFIG_OPEN_EQUIPMENT_WINDOW = 0,
- // Unknown = 1,
+ CZ_CONFIG_CALL = 1,
CZ_CONFIG_PET_AUTOFEEDING = 2,
CZ_CONFIG_HOMUNCULUS_AUTOFEEDING = 3,
};
@@ -883,7 +883,7 @@ struct clif_interface {
void (*mvp_exp) (struct map_session_data *sd, unsigned int exp);
void (*mvp_noitem) (struct map_session_data* sd);
void (*changed_dir) (struct block_list *bl, enum send_target target);
- void (*charnameack) (int fd, struct block_list *bl);
+ void (*blname_ack) (int fd, struct block_list *bl);
void (*monster_hp_bar) ( struct mob_data* md, struct map_session_data *sd );
int (*hpmeter) (struct map_session_data *sd);
void (*hpmeter_single) (int fd, int id, unsigned int hp, unsigned int maxhp);
@@ -1566,6 +1566,7 @@ struct clif_interface {
void (*pReqStyleChange) (int fd, struct map_session_data *sd);
void (*pReqStyleChange2) (int fd, struct map_session_data *sd);
+ void (*pStyleClose) (int fd, struct map_session_data *sd);
void (*style_change_response) (struct map_session_data *sd, enum stylist_shop flag);
void (*pPetEvolution) (int fd, struct map_session_data *sd);
void (*petEvolutionResult) (int fd, enum pet_evolution_result result);
@@ -1581,6 +1582,11 @@ struct clif_interface {
void (*pNPCBarterClosed) (int fd, struct map_session_data *sd);
void (*pNPCBarterPurchase) (int fd, struct map_session_data *sd);
void (*pClientVersion) (int fd, struct map_session_data *sd);
+ void (*pPing) (int fd, struct map_session_data *sd);
+ void (*ping) (struct map_session_data *sd);
+ int (*pingTimer) (int tid, int64 tick, int id, intptr_t data);
+ int (*pingTimerSub) (struct map_session_data *sd, va_list ap);
+ void (*pResetCooldown) (int fd, struct map_session_data *sd);
};
#ifdef HERCULES_CORE
diff --git a/src/map/guild.c b/src/map/guild.c
index 0517887d3..ae76b22a3 100644
--- a/src/map/guild.c
+++ b/src/map/guild.c
@@ -1899,7 +1899,7 @@ static int guild_gm_changed(int guild_id, int account_id, int char_id)
if (g->member[pos].sd && g->member[pos].sd->fd) {
clif->message(g->member[pos].sd->fd, msg_sd(g->member[pos].sd,878)); //"You no longer are the Guild Master."
g->member[pos].sd->state.gmaster_flag = 0;
- clif->charnameack(0, &g->member[pos].sd->bl);
+ clif->blname_ack(0, &g->member[pos].sd->bl);
}
if (g->member[0].sd && g->member[0].sd->fd) {
@@ -1907,7 +1907,7 @@ static int guild_gm_changed(int guild_id, int account_id, int char_id)
g->member[0].sd->state.gmaster_flag = 1;
//Block his skills for 5 minutes to prevent abuse.
guild->block_skill(g->member[0].sd, 300000);
- clif->charnameack(0, &g->member[pos].sd->bl);
+ clif->blname_ack(0, &g->member[pos].sd->bl);
}
// announce the change to all guild members
diff --git a/src/map/homunculus.c b/src/map/homunculus.c
index aa3bb5360..f3a4c559a 100644
--- a/src/map/homunculus.c
+++ b/src/map/homunculus.c
@@ -779,7 +779,7 @@ static bool homunculus_change_name_ack(struct map_session_data *sd, const char *
}
safestrncpy(hd->homunculus.name, newname, NAME_LENGTH);
aFree(newname);
- clif->charnameack (0,&hd->bl);
+ clif->blname_ack(0,&hd->bl);
hd->homunculus.rename_flag = 1;
clif->hominfo(sd,hd,0);
return true;
diff --git a/src/map/messages_main.h b/src/map/messages_main.h
index f8129c2ca..52c953ac8 100644
--- a/src/map/messages_main.h
+++ b/src/map/messages_main.h
@@ -24,7 +24,7 @@
/* This file is autogenerated, please do not commit manual changes
-Latest version: 20190306
+Latest version: 20190403
*/
enum clif_messages {
@@ -21521,6 +21521,74 @@ Please try again in a moment.
*/
MSG_ID_E03 = 0xe03,
#endif
+#if PACKETVER >= 20190320
+/*20190320 to latest
+선택 삭제
+*/
+ MSG_ID_E04 = 0xe04,
+/*20190320 to latest
+모두 삭제
+*/
+ MSG_ID_E05 = 0xe05,
+/*20190320 to latest
+[%s]편지함의 모든 메일을 삭제하시겠습니까?
+*/
+ MSG_ID_E06 = 0xe06,
+/*20190320 to latest
+선택 받기
+*/
+ MSG_ID_E07 = 0xe07,
+/*20190320 to latest
+모두 받기
+*/
+ MSG_ID_E08 = 0xe08,
+/*20190320 to latest
+선택한 메일의 첨부 물품을 받으시겠습니까?
+*/
+ MSG_ID_E09 = 0xe09,
+/*20190320 to latest
+[%s]편지함의 모든 첨부 물품을 받으시겠습니까?
+*/
+ MSG_ID_E0A = 0xe0a,
+#endif
+#if PACKETVER >= 20190403
+/*20190403 to latest
+스킬바2
+*/
+ MSG_ID_E0B = 0xe0b,
+/*20190403 to latest
+스킬바 교체
+*/
+ MSG_ID_E0C = 0xe0c,
+/*20190403 to latest
+←
+*/
+ MSG_ID_E0D = 0xe0d,
+/*20190403 to latest
+↑
+*/
+ MSG_ID_E0E = 0xe0e,
+/*20190403 to latest
+→
+*/
+ MSG_ID_E0F = 0xe0f,
+/*20190403 to latest
+↓
+*/
+ MSG_ID_E10 = 0xe10,
+/*20190403 to latest
+▤
+*/
+ MSG_ID_E11 = 0xe11,
+/*20190403 to latest
+←
+*/
+ MSG_ID_E12 = 0xe12,
+/*20190403 to latest
+로딩중에는 창을 닫을 수 없습니다.
+*/
+ MSG_ID_E13 = 0xe13,
+#endif
};
#endif /* MAP_MESSAGES_MAIN_H */
diff --git a/src/map/messages_re.h b/src/map/messages_re.h
index d4b86c619..3823720ad 100644
--- a/src/map/messages_re.h
+++ b/src/map/messages_re.h
@@ -24,7 +24,7 @@
/* This file is autogenerated, please do not commit manual changes
-Latest version: 20190306
+Latest version: 20190403
*/
enum clif_messages {
@@ -21000,6 +21000,74 @@ Please try again in a moment.
*/
MSG_ID_E03 = 0xe03,
#endif
+#if PACKETVER >= 20190320
+/*20190320 to latest
+선택 삭제
+*/
+ MSG_ID_E04 = 0xe04,
+/*20190320 to latest
+모두 삭제
+*/
+ MSG_ID_E05 = 0xe05,
+/*20190320 to latest
+[%s]편지함의 모든 메일을 삭제하시겠습니까?
+*/
+ MSG_ID_E06 = 0xe06,
+/*20190320 to latest
+선택 받기
+*/
+ MSG_ID_E07 = 0xe07,
+/*20190320 to latest
+모두 받기
+*/
+ MSG_ID_E08 = 0xe08,
+/*20190320 to latest
+선택한 메일의 첨부 물품을 받으시겠습니까?
+*/
+ MSG_ID_E09 = 0xe09,
+/*20190320 to latest
+[%s]편지함의 모든 첨부 물품을 받으시겠습니까?
+*/
+ MSG_ID_E0A = 0xe0a,
+#endif
+#if PACKETVER >= 20190403
+/*20190403 to latest
+스킬바2
+*/
+ MSG_ID_E0B = 0xe0b,
+/*20190403 to latest
+스킬바 교체
+*/
+ MSG_ID_E0C = 0xe0c,
+/*20190403 to latest
+←
+*/
+ MSG_ID_E0D = 0xe0d,
+/*20190403 to latest
+↑
+*/
+ MSG_ID_E0E = 0xe0e,
+/*20190403 to latest
+→
+*/
+ MSG_ID_E0F = 0xe0f,
+/*20190403 to latest
+↓
+*/
+ MSG_ID_E10 = 0xe10,
+/*20190403 to latest
+▤
+*/
+ MSG_ID_E11 = 0xe11,
+/*20190403 to latest
+←
+*/
+ MSG_ID_E12 = 0xe12,
+/*20190403 to latest
+로딩중에는 창을 닫을 수 없습니다.
+*/
+ MSG_ID_E13 = 0xe13,
+#endif
};
#endif /* MAP_MESSAGES_RE_H */
diff --git a/src/map/messages_zero.h b/src/map/messages_zero.h
index 0119a9540..90c7e8895 100644
--- a/src/map/messages_zero.h
+++ b/src/map/messages_zero.h
@@ -24,7 +24,7 @@
/* This file is autogenerated, please do not commit manual changes
-Latest version: 20190220
+Latest version: 20190403
*/
enum clif_messages {
@@ -16356,9 +16356,11 @@ http://member.gnjoy.com/user/pay/chargelist.asp
한 번에 구입 가능한 아이템의 가짓수는 8개입니다.
*/
MSG_ID_CF0 = 0xcf0,
-/*20171018 to latest
+/*20171018 to 20190227
http://gift.zhaouc.com/#/index
http://gift.zhaouc.com/
+20190313 to latest
+http://gift.zhaouc.com/
*/
MSG_ID_CF1 = 0xcf1,
/*20171018 to latest
@@ -17568,8 +17570,10 @@ TITLE
자료
*/
MSG_ID_DFC = 0xdfc,
-/*20190213 to latest
+/*20190213 to 20190227
http://rodata.zhaouc.com/renwu.html#container
+20190313 to latest
+http://rodata.zhaouc.com/renwu.html
*/
MSG_ID_DFD = 0xdfd,
/*20190213 to latest
@@ -17591,6 +17595,85 @@ http://rodata.zhaouc.com/renwu.html#container
*/
MSG_ID_E01 = 0xe01,
#endif
+#if PACKETVER >= 20190313
+/*20190313 to latest
+잠시 후 다시 시도해주세요.
+Please try again in a moment.
+*/
+ MSG_ID_E02 = 0xe02,
+/*20190313 to latest
+등록할 수 없는 파일입니다.
+*/
+ MSG_ID_E03 = 0xe03,
+#endif
+#if PACKETVER >= 20190327
+/*20190327 to latest
+선택 삭제
+*/
+ MSG_ID_E04 = 0xe04,
+/*20190327 to latest
+모두 삭제
+*/
+ MSG_ID_E05 = 0xe05,
+/*20190327 to latest
+[%s]편지함의 모든 메일을 삭제하시겠습니까?
+*/
+ MSG_ID_E06 = 0xe06,
+/*20190327 to latest
+선택 받기
+*/
+ MSG_ID_E07 = 0xe07,
+/*20190327 to latest
+모두 받기
+*/
+ MSG_ID_E08 = 0xe08,
+/*20190327 to latest
+선택한 메일의 첨부 물품을 받으시겠습니까?
+*/
+ MSG_ID_E09 = 0xe09,
+/*20190327 to latest
+[%s]편지함의 모든 첨부 물품을 받으시겠습니까?
+*/
+ MSG_ID_E0A = 0xe0a,
+/*20190327 to latest
+스킬바2
+*/
+ MSG_ID_E0B = 0xe0b,
+/*20190327 to latest
+스킬바 교체
+*/
+ MSG_ID_E0C = 0xe0c,
+#endif
+#if PACKETVER >= 20190403
+/*20190403 to latest
+←
+*/
+ MSG_ID_E0D = 0xe0d,
+/*20190403 to latest
+↑
+*/
+ MSG_ID_E0E = 0xe0e,
+/*20190403 to latest
+→
+*/
+ MSG_ID_E0F = 0xe0f,
+/*20190403 to latest
+↓
+*/
+ MSG_ID_E10 = 0xe10,
+/*20190403 to latest
+▤
+*/
+ MSG_ID_E11 = 0xe11,
+/*20190403 to latest
+←
+*/
+ MSG_ID_E12 = 0xe12,
+/*20190403 to latest
+로딩중에는 창을 닫을 수 없습니다.
+*/
+ MSG_ID_E13 = 0xe13,
+#endif
};
#endif /* MAP_MESSAGES_ZERO_H */
diff --git a/src/map/mob.c b/src/map/mob.c
index d82e49bcc..fed4d6c60 100644
--- a/src/map/mob.c
+++ b/src/map/mob.c
@@ -2196,7 +2196,7 @@ static void mob_damage(struct mob_data *md, struct block_list *src, int damage)
}
if (battle_config.show_mob_info&3)
- clif->charnameack (0, &md->bl);
+ clif->blname_ack(0, &md->bl);
#if PACKETVER >= 20131223
// Resend ZC_NOTIFY_MOVEENTRY to Update the HP
@@ -2796,7 +2796,7 @@ static void mob_revive(struct mob_data *md, unsigned int hp)
skill->unit_move(&md->bl,tick,1);
mob->skill_use(md, tick, MSC_SPAWN);
if (battle_config.show_mob_info&3)
- clif->charnameack (0, &md->bl);
+ clif->blname_ack(0, &md->bl);
}
static int mob_guardian_guildchange(struct mob_data *md)
@@ -2921,7 +2921,7 @@ static int mob_class_change(struct mob_data *md, int class_)
md->target_id = md->attacked_id = 0;
//Need to update name display.
- clif->charnameack(0, &md->bl);
+ clif->blname_ack(0, &md->bl);
status_change_end(&md->bl,SC_KEEPING,INVALID_TIMER);
return 0;
}
@@ -2933,7 +2933,7 @@ static void mob_heal(struct mob_data *md, unsigned int heal)
{
nullpo_retv(md);
if (battle_config.show_mob_info&3)
- clif->charnameack (0, &md->bl);
+ clif->blname_ack(0, &md->bl);
#if PACKETVER >= 20131223
// Resend ZC_NOTIFY_MOVEENTRY to Update the HP
if (battle_config.show_monster_hp_bar)
diff --git a/src/map/npc.c b/src/map/npc.c
index 61341744d..4b79a9fed 100644
--- a/src/map/npc.c
+++ b/src/map/npc.c
@@ -3911,7 +3911,7 @@ static void npc_setdisplayname(struct npc_data *nd, const char *newname)
safestrncpy(nd->name, newname, sizeof(nd->name));
if( map->list[nd->bl.m].users )
- clif->charnameack(0, &nd->bl);
+ clif->blname_ack(0, &nd->bl);
}
/// Changes the display class of the npc.
diff --git a/src/map/packets.h b/src/map/packets.h
index 50784f09a..a0b6b7f4b 100644
--- a/src/map/packets.h
+++ b/src/map/packets.h
@@ -1777,8 +1777,10 @@ packet(0x96e,clif->ackmergeitems);
#if PACKETVER >= 20151104
// new packets
packet(0x0a46,clif->pReqStyleChange);
+ packet(0x0a48,clif->pStyleClose);
#endif
+
// 2016-03-23aRagexeRE
#if PACKETVER >= 20160323
// new packets
@@ -1798,6 +1800,11 @@ packet(0x96e,clif->ackmergeitems);
packet(0x0a77,clif->pCameraInfo); // CZ_CAMERA_INFO
#endif
+// all 20160622+
+#if PACKETVER >= 20160622
+ packet(0x0a88,clif->pResetCooldown);
+#endif
+
// 2017-02-28aRagexeRE
#if PACKETVER >= 20170228
// new packets
@@ -1931,4 +1938,8 @@ packet(0x96e,clif->ackmergeitems);
packet(0x0b12,clif->pNPCBarterClosed);
#endif
+#if PACKETVER_MAIN_NUM >= 20190403 || PACKETVER_RE_NUM >= 20190320
+ packet(0x0b1c,clif->pPing);
+#endif
+
#endif /* MAP_PACKETS_H */
diff --git a/src/map/packets_keys_main.h b/src/map/packets_keys_main.h
index 1795e46c2..9505fb454 100644
--- a/src/map/packets_keys_main.h
+++ b/src/map/packets_keys_main.h
@@ -37,7 +37,7 @@
packetKeys(0x49357d72,0x22c370a1,0x5f836591);
#endif
-// 2010-11-23aRagexeRE, 2010-11-24aRagexeRE, 2010-11-24bRagexeRE, 2010-11-25aRagexeRE, 2010-11-26aRagexeRE, 2010-11-30aRagexeRE, 2010-12-07aRagexeRE, 2010-12-14aRagexeRE, 2010-12-21aRagexeRE, 2010-12-23aRagexeRE, 2010-12-28aRagexeRE, 2011-01-04aRagexeRE, 2011-01-05aRagexeRE, 2011-01-11aRagexeRE, 2011-01-18aRagexeRE, 2011-01-25aRagexeRE, 2011-01-26aRagexeRE, 2011-01-26bRagexeRE, 2011-01-31aRagexeRE, 2011-01-31bRagexeRE, 2011-01-31cRagexeRE, 2011-02-08aRagexeRE, 2011-02-15aRagexeRE, 2011-02-22aRagexeRE, 2011-02-23aRagexeRE, 2011-02-23bRagexeRE, 2011-02-24aRagexeRE, 2011-02-25aRagexeRE, 2011-02-28aRagexeRE, 2011-03-08aRagexeRE, 2011-03-09aRagexeRE, 2011-03-09bRagexeRE, 2011-03-09cRagexeRE, 2011-03-09dRagexeRE, 2011-03-15aRagexeRE, 2011-03-22aRagexeRE, 2011-03-29aRagexeRE, 2011-03-30aRagexeRE, 2011-03-30cRagexeRE, 2011-04-05aRagexeRE, 2011-04-12aRagexeRE, 2011-04-19aRagexeRE, 2011-04-20aRagexeRE, 2011-04-26aRagexeRE, 2011-04-27aRagexeRE, 2011-05-03aRagexeRE, 2011-05-11aRagexeRE, 2011-05-17bRagexeRE, 2011-05-24aRagexeRE, 2011-05-26aRagexeRE, 2011-05-31aRagexeRE, 2011-06-07aRagexeRE, 2011-06-08aRagexeRE, 2011-06-08bRagexeRE, 2011-06-08cRagexeRE, 2011-06-09aRagexeRE, 2011-06-14bRagexeRE, 2011-06-22aRagexeRE, 2011-06-28aRagexeRE, 2011-07-06aRagexeRE, 2011-07-13aRagexeRE, 2011-07-13bRagexeRE, 2011-07-13cRagexeRE, 2011-07-19aRagexeRE, 2011-07-26aRagexeRE, 2011-08-03aRagexeRE, 2011-08-03bRagexeRE, 2011-08-10aRagexeRE, 2013-12-23aRagexeRE, 2014-05-08aRagexe, 2014-05-08aRagexeRE, 2014-06-11eRagexe, 2015-02-25hRagexe, 2018-03-15aRagexe, 2018-03-21aRagexe, 2018-03-21aRagexeRE, 2018-03-28bRagexe, 2018-03-28bRagexeRE, 2018-04-04bRagexe, 2018-04-04cRagexeRE, 2018-04-18aRagexe, 2018-04-18bRagexeRE, 2018-04-25cRagexe, 2018-04-25cRagexeRE, 2018-05-02bRagexe, 2018-05-02bRagexeRE, 2018-05-02dRagexeRE, 2018-05-09aRagexe, 2018-05-16cRagexe, 2018-05-16cRagexeRE, 2018-05-23aRagexe, 2018-05-23aRagexeRE, 2018-05-30aRagexe, 2018-05-30bRagexeRE, 2018-05-30cRagexeRE, 2018-06-05bRagexe, 2018-06-05bRagexeRE, 2018-06-12aRagexeRE, 2018-06-12bRagexeRE, 2018-06-20cRagexe, 2018-06-20dRagexeRE, 2018-06-20eRagexe, 2018-06-20eRagexeRE, 2018-06-21aRagexe, 2018-06-21aRagexeRE, 2018-07-04aRagexe, 2018-07-04aRagexeRE, 2018-07-11aRagexeRE, 2018-07-18bRagexe, 2018-07-18bRagexeRE, 2018-07-18bRagexeRE1, 2018-07-18cRagexe, 2018-07-18cRagexeRE, 2018-08-01cRagexe, 2018-08-01cRagexeRE, 2018-08-08bRagexe, 2018-08-08bRagexeRE, 2018-08-22cRagexe, 2018-08-22cRagexeRE, 2018-08-29aRagexe, 2018-08-29aRagexeRE, 2018-08-29bRagexeRE, 2018-08-31aRagexe, 2018-09-12dRagexe, 2018-09-12dRagexeRE, 2018-09-19aRagexe, 2018-09-19aRagexeRE, 2018-10-02aRagexe, 2018-10-02aRagexeRE, 2018-10-02bRagexe, 2018-10-02bRagexeRE, 2018-10-17_02aRagexe, 2018-10-17_02aRagexeRE, 2018-10-17_03aRagexe, 2018-10-17_03aRagexeRE, 2018-10-17bRagexe, 2018-10-17bRagexeRE, 2018-10-24bRagexe, 2018-10-31aRagexe, 2018-10-31bRagexe, 2018-10-31cRagexeRE, 2018-11-07aRagexe, 2018-11-07aRagexeRE, 2018-11-14cRagexe, 2018-11-14cRagexeRE, 2018-11-14dRagexe, 2018-11-14dRagexeRE, 2018-11-21bRagexe, 2018-11-21cRagexeRE, 2018-11-28aRagexe, 2018-11-28aRagexeRE, 2018-11-28bRagexe, 2018-11-28cRagexe, 2018-12-05aRagexe, 2018-12-05bRagexeRE, 2018-12-12aRagexe, 2018-12-12aRagexeRE, 2018-12-12bRagexe, 2018-12-12bRagexeRE, 2018-12-19bRagexe, 2018-12-19bRagexeRE, 2018-12-26aRagexe, 2018-12-26aRagexeRE, 2019-01-09aRagexe, 2019-01-09bRagexeRE, 2019-01-16bRagexe, 2019-01-16bRagexeRE, 2019-01-16cRagexe, 2019-01-16cRagexeRE, 2019-01-23dRagexe, 2019-01-23dRagexeRE, 2019-02-13IRagexeRE, 2019-02-13bRagexe, 2019-02-13eRagexe, 2019-02-20aRagexeRE, 2019-02-27aRagexe, 2019-02-27bRagexeRE, 2019-02-28aRagexe, 2019-02-28aRagexeRE, 2019-03-06bRagexe, 2019-03-06bRagexeRE, 2019-03-06cRagexe, 2019-03-06cRagexeRE
+// 2010-11-23aRagexeRE, 2010-11-24aRagexeRE, 2010-11-24bRagexeRE, 2010-11-25aRagexeRE, 2010-11-26aRagexeRE, 2010-11-30aRagexeRE, 2010-12-07aRagexeRE, 2010-12-14aRagexeRE, 2010-12-21aRagexeRE, 2010-12-23aRagexeRE, 2010-12-28aRagexeRE, 2011-01-04aRagexeRE, 2011-01-05aRagexeRE, 2011-01-11aRagexeRE, 2011-01-18aRagexeRE, 2011-01-25aRagexeRE, 2011-01-26aRagexeRE, 2011-01-26bRagexeRE, 2011-01-31aRagexeRE, 2011-01-31bRagexeRE, 2011-01-31cRagexeRE, 2011-02-08aRagexeRE, 2011-02-15aRagexeRE, 2011-02-22aRagexeRE, 2011-02-23aRagexeRE, 2011-02-23bRagexeRE, 2011-02-24aRagexeRE, 2011-02-25aRagexeRE, 2011-02-28aRagexeRE, 2011-03-08aRagexeRE, 2011-03-09aRagexeRE, 2011-03-09bRagexeRE, 2011-03-09cRagexeRE, 2011-03-09dRagexeRE, 2011-03-15aRagexeRE, 2011-03-22aRagexeRE, 2011-03-29aRagexeRE, 2011-03-30aRagexeRE, 2011-03-30cRagexeRE, 2011-04-05aRagexeRE, 2011-04-12aRagexeRE, 2011-04-19aRagexeRE, 2011-04-20aRagexeRE, 2011-04-26aRagexeRE, 2011-04-27aRagexeRE, 2011-05-03aRagexeRE, 2011-05-11aRagexeRE, 2011-05-17bRagexeRE, 2011-05-24aRagexeRE, 2011-05-26aRagexeRE, 2011-05-31aRagexeRE, 2011-06-07aRagexeRE, 2011-06-08aRagexeRE, 2011-06-08bRagexeRE, 2011-06-08cRagexeRE, 2011-06-09aRagexeRE, 2011-06-14bRagexeRE, 2011-06-22aRagexeRE, 2011-06-28aRagexeRE, 2011-07-06aRagexeRE, 2011-07-13aRagexeRE, 2011-07-13bRagexeRE, 2011-07-13cRagexeRE, 2011-07-19aRagexeRE, 2011-07-26aRagexeRE, 2011-08-03aRagexeRE, 2011-08-03bRagexeRE, 2011-08-10aRagexeRE, 2013-12-23aRagexeRE, 2014-05-08aRagexe, 2014-05-08aRagexeRE, 2014-06-11eRagexe, 2015-02-25hRagexe, 2018-03-15aRagexe, 2018-03-21aRagexe, 2018-03-21aRagexeRE, 2018-03-28bRagexe, 2018-03-28bRagexeRE, 2018-04-04bRagexe, 2018-04-04cRagexeRE, 2018-04-18aRagexe, 2018-04-18bRagexeRE, 2018-04-25cRagexe, 2018-04-25cRagexeRE, 2018-05-02bRagexe, 2018-05-02bRagexeRE, 2018-05-02dRagexeRE, 2018-05-09aRagexe, 2018-05-16cRagexe, 2018-05-16cRagexeRE, 2018-05-23aRagexe, 2018-05-23aRagexeRE, 2018-05-30aRagexe, 2018-05-30bRagexeRE, 2018-05-30cRagexeRE, 2018-06-05bRagexe, 2018-06-05bRagexeRE, 2018-06-12aRagexeRE, 2018-06-12bRagexeRE, 2018-06-20cRagexe, 2018-06-20dRagexeRE, 2018-06-20eRagexe, 2018-06-20eRagexeRE, 2018-06-21aRagexe, 2018-06-21aRagexeRE, 2018-07-04aRagexe, 2018-07-04aRagexeRE, 2018-07-11aRagexeRE, 2018-07-18bRagexe, 2018-07-18bRagexeRE, 2018-07-18bRagexeRE1, 2018-07-18cRagexe, 2018-07-18cRagexeRE, 2018-08-01cRagexe, 2018-08-01cRagexeRE, 2018-08-08bRagexe, 2018-08-08bRagexeRE, 2018-08-22cRagexe, 2018-08-22cRagexeRE, 2018-08-29aRagexe, 2018-08-29aRagexeRE, 2018-08-29bRagexeRE, 2018-08-31aRagexe, 2018-09-12dRagexe, 2018-09-12dRagexeRE, 2018-09-19aRagexe, 2018-09-19aRagexeRE, 2018-10-02aRagexe, 2018-10-02aRagexeRE, 2018-10-02bRagexe, 2018-10-02bRagexeRE, 2018-10-17_02aRagexe, 2018-10-17_02aRagexeRE, 2018-10-17_03aRagexe, 2018-10-17_03aRagexeRE, 2018-10-17bRagexe, 2018-10-17bRagexeRE, 2018-10-24bRagexe, 2018-10-31aRagexe, 2018-10-31bRagexe, 2018-10-31cRagexeRE, 2018-11-07aRagexe, 2018-11-07aRagexeRE, 2018-11-14cRagexe, 2018-11-14cRagexeRE, 2018-11-14dRagexe, 2018-11-14dRagexeRE, 2018-11-21bRagexe, 2018-11-21cRagexeRE, 2018-11-28aRagexe, 2018-11-28aRagexeRE, 2018-11-28bRagexe, 2018-11-28cRagexe, 2018-12-05aRagexe, 2018-12-05bRagexeRE, 2018-12-12aRagexe, 2018-12-12aRagexeRE, 2018-12-12bRagexe, 2018-12-12bRagexeRE, 2018-12-19bRagexe, 2018-12-19bRagexeRE, 2018-12-26aRagexe, 2018-12-26aRagexeRE, 2019-01-09aRagexe, 2019-01-09bRagexeRE, 2019-01-16bRagexe, 2019-01-16bRagexeRE, 2019-01-16cRagexe, 2019-01-16cRagexeRE, 2019-01-23dRagexe, 2019-01-23dRagexeRE, 2019-02-13IRagexeRE, 2019-02-13bRagexe, 2019-02-13eRagexe, 2019-02-20aRagexeRE, 2019-02-27aRagexe, 2019-02-27bRagexeRE, 2019-02-28aRagexe, 2019-02-28aRagexeRE, 2019-03-06bRagexe, 2019-03-06bRagexeRE, 2019-03-06cRagexe, 2019-03-06cRagexeRE, 2019-03-13aRagexe, 2019-03-20aRagexe, 2019-03-20aRagexeRE, 2019-03-22aRagexe, 2019-03-22aRagexeRE, 2019-03-27bRagexe, 2019-03-27bRagexeRE, 2019-04-03aRagexe, 2019-04-03bRagexeRE, 2019-04-03cRagexeRE
#if PACKETVER == 20101123 || \
PACKETVER == 20101124 || \
PACKETVER == 20101125 || \
@@ -140,7 +140,12 @@
PACKETVER == 20190220 || \
PACKETVER == 20190227 || \
PACKETVER == 20190228 || \
- PACKETVER >= 20190306
+ PACKETVER == 20190306 || \
+ PACKETVER == 20190313 || \
+ PACKETVER == 20190320 || \
+ PACKETVER == 20190322 || \
+ PACKETVER == 20190327 || \
+ PACKETVER >= 20190403
packetKeys(0x00000000,0x00000000,0x00000000);
#endif
diff --git a/src/map/packets_keys_zero.h b/src/map/packets_keys_zero.h
index 7388c2756..e36091424 100644
--- a/src/map/packets_keys_zero.h
+++ b/src/map/packets_keys_zero.h
@@ -30,7 +30,7 @@
/* This file is autogenerated, please do not commit manual changes */
-// 2017-10-18aRagexe_zero, 2017-10-19aRagexe_zero, 2017-10-23aRagexe_zero, 2017-10-23bRagexe_zero, 2017-10-23cRagexe_zero, 2017-10-24aRagexe_2_zero, 2017-10-24aRagexe_zero, 2017-10-25bRagexe_zero, 2017-10-27aRagexe_zero, 2017-10-27bRagexe_zero, 2017-10-30aRagexe_zero, 2017-10-31aRagexe_zero, 2017-11-09aRagexe_zero, 2017-11-13aRagexe_zero, 2017-11-13bRagexe_zero, 2018-03-15aRagexe_zero, 2018-03-21aRagexe_zero, 2018-03-21bRagexe_zero, 2018-03-28_1aRagexe_zero, 2018-03-28cRagexe_zero, 2018-04-11aRagexe_zero, 2018-04-25_3aRagexe_zero, 2018-05-09_3aRagexe_zero, 2018-05-23aRagexe_zero, 2018-06-05bRagexe_zero, 2018-06-05cRagexe_zero, 2018-06-27aRagexe_zero, 2018-07-03aRagexe_zero, 2018-07-11_2aRagexe_zero, 2018-07-25_2aRagexe_zero, 2018-08-01aRagexe_zero, 2018-08-08_2aRagexe_zero, 2018-08-22aRagexe_zero, 2018-08-29aRagexe_zero, 2018-09-05aRagexe_zero, 2018-09-12aRagexe_zero, 2018-09-19aRagexe_zero, 2018-09-28aRagexe_zero, 2018-10-10_2aRagexe_zero, 2018-10-24_2aRagexe_zero, 2018-11-14aRagexe_zero, 2018-11-20aRagexe_zero, 2018-11-28aRagexe_zero, 2018-12-12aRagexe_zero, 2018-12-19aRagexe_zero, 2018-12-26_2aRagexe_zero, 2019-01-16_2aRagexe_zero, 2019-01-17_1aRagexe_zero, 2019-01-30_2aRagexe_zero, 2019-02-13aRagexe_zero, 2019-02-20aRagexe_zero, 2019-02-27aRagexe_zero
+// 2017-10-18aRagexe_zero, 2017-10-19aRagexe_zero, 2017-10-23aRagexe_zero, 2017-10-23bRagexe_zero, 2017-10-23cRagexe_zero, 2017-10-24aRagexe_2_zero, 2017-10-24aRagexe_zero, 2017-10-25bRagexe_zero, 2017-10-27aRagexe_zero, 2017-10-27bRagexe_zero, 2017-10-30aRagexe_zero, 2017-10-31aRagexe_zero, 2017-11-09aRagexe_zero, 2017-11-13aRagexe_zero, 2017-11-13bRagexe_zero, 2018-03-15aRagexe_zero, 2018-03-21aRagexe_zero, 2018-03-21bRagexe_zero, 2018-03-28_1aRagexe_zero, 2018-03-28cRagexe_zero, 2018-04-11aRagexe_zero, 2018-04-25_3aRagexe_zero, 2018-05-09_3aRagexe_zero, 2018-05-23aRagexe_zero, 2018-06-05bRagexe_zero, 2018-06-05cRagexe_zero, 2018-06-27aRagexe_zero, 2018-07-03aRagexe_zero, 2018-07-11_2aRagexe_zero, 2018-07-25_2aRagexe_zero, 2018-08-01aRagexe_zero, 2018-08-08_2aRagexe_zero, 2018-08-22aRagexe_zero, 2018-08-29aRagexe_zero, 2018-09-05aRagexe_zero, 2018-09-12aRagexe_zero, 2018-09-19aRagexe_zero, 2018-09-28aRagexe_zero, 2018-10-10_2aRagexe_zero, 2018-10-24_2aRagexe_zero, 2018-11-14aRagexe_zero, 2018-11-20aRagexe_zero, 2018-11-28aRagexe_zero, 2018-12-12aRagexe_zero, 2018-12-19aRagexe_zero, 2018-12-26_2aRagexe_zero, 2019-01-16_2aRagexe_zero, 2019-01-17_1aRagexe_zero, 2019-01-30_2aRagexe_zero, 2019-02-13aRagexe_zero, 2019-02-20aRagexe_zero, 2019-02-27aRagexe_zero, 2019-03-13aRagexe_zero, 2019-03-27_2aRagexe_zero, 2019-03-27_3aRagexe_zero, 2019-04-03aRagexe_zero
#if PACKETVER == 20171018 || \
PACKETVER == 20171019 || \
PACKETVER == 20171023 || \
@@ -74,7 +74,10 @@
PACKETVER == 20190130 || \
PACKETVER == 20190213 || \
PACKETVER == 20190220 || \
- PACKETVER >= 20190227
+ PACKETVER == 20190227 || \
+ PACKETVER == 20190313 || \
+ PACKETVER == 20190327 || \
+ PACKETVER >= 20190403
packetKeys(0x00000000,0x00000000,0x00000000);
#endif
diff --git a/src/map/packets_shuffle_main.h b/src/map/packets_shuffle_main.h
index 7af5c579d..d0c3099b9 100644
--- a/src/map/packets_shuffle_main.h
+++ b/src/map/packets_shuffle_main.h
@@ -9727,7 +9727,7 @@
packet(0x0967,clif->pSolveCharName,2); // CZ_REQNAME_BYGID // 6
#endif
-// 2018-11-21bRagexe, 2018-11-28aRagexe, 2018-11-28bRagexe, 2018-11-28cRagexe, 2018-12-05aRagexe, 2018-12-12aRagexe, 2018-12-12bRagexe, 2018-12-19bRagexe, 2018-12-26aRagexe, 2019-01-09aRagexe, 2019-01-16bRagexe, 2019-01-16cRagexe, 2019-01-23dRagexe, 2019-02-13bRagexe, 2019-02-13eRagexe, 2019-02-27aRagexe, 2019-02-28aRagexe, 2019-03-06bRagexe, 2019-03-06cRagexe
+// 2018-11-21bRagexe, 2018-11-28aRagexe, 2018-11-28bRagexe, 2018-11-28cRagexe, 2018-12-05aRagexe, 2018-12-12aRagexe, 2018-12-12bRagexe, 2018-12-19bRagexe, 2018-12-26aRagexe, 2019-01-09aRagexe, 2019-01-16bRagexe, 2019-01-16cRagexe, 2019-01-23dRagexe, 2019-02-13bRagexe, 2019-02-13eRagexe, 2019-02-27aRagexe, 2019-02-28aRagexe, 2019-03-06bRagexe, 2019-03-06cRagexe, 2019-03-13aRagexe, 2019-03-20aRagexe, 2019-03-22aRagexe, 2019-03-27bRagexe, 2019-04-03aRagexe
#if PACKETVER == 20181121 || \
PACKETVER == 20181128 || \
PACKETVER == 20181205 || \
@@ -9740,7 +9740,12 @@
PACKETVER == 20190213 || \
PACKETVER == 20190227 || \
PACKETVER == 20190228 || \
- PACKETVER >= 20190306
+ PACKETVER == 20190306 || \
+ PACKETVER == 20190313 || \
+ PACKETVER == 20190320 || \
+ PACKETVER == 20190322 || \
+ PACKETVER == 20190327 || \
+ PACKETVER >= 20190403
packet(0x0202,clif->pFriendsListAdd,2); // CZ_ADD_FRIENDS // 26
packet(0x022d,clif->pHomMenu,2,4); // CZ_COMMAND_MER // 5
packet(0x023b,clif->pStoragePassword,0); // CZ_ACK_STORE_PASSWORD // 36
diff --git a/src/map/packets_shuffle_re.h b/src/map/packets_shuffle_re.h
index 8aee76bc7..c41095fb4 100644
--- a/src/map/packets_shuffle_re.h
+++ b/src/map/packets_shuffle_re.h
@@ -9663,7 +9663,7 @@
packet(0x083c,clif->pSearchStoreInfoListItemClick,2,6,10); // CZ_SSILIST_ITEM_CLICK // 12
#endif
-// 2018-07-04aRagexeRE, 2018-07-11aRagexeRE, 2018-07-18bRagexeRE, 2018-07-18bRagexeRE1, 2018-07-18cRagexeRE, 2018-08-01cRagexeRE, 2018-08-08bRagexeRE, 2018-08-22cRagexeRE, 2018-08-29aRagexeRE, 2018-08-29bRagexeRE, 2018-09-12dRagexeRE, 2018-09-19aRagexeRE, 2018-10-02aRagexeRE, 2018-10-02bRagexeRE, 2018-10-17_02aRagexeRE, 2018-10-17_03aRagexeRE, 2018-10-17bRagexeRE, 2018-10-31cRagexeRE, 2018-11-07aRagexeRE, 2018-11-14cRagexeRE, 2018-11-14dRagexeRE, 2018-11-21cRagexeRE, 2018-11-28aRagexeRE, 2018-12-05bRagexeRE, 2018-12-12aRagexeRE, 2018-12-12bRagexeRE, 2018-12-19bRagexeRE, 2018-12-26aRagexeRE, 2019-01-09bRagexeRE, 2019-01-16bRagexeRE, 2019-01-16cRagexeRE, 2019-01-23dRagexeRE, 2019-02-13IRagexeRE, 2019-02-20aRagexeRE, 2019-02-27bRagexeRE, 2019-02-28aRagexeRE, 2019-03-06bRagexeRE, 2019-03-06cRagexeRE
+// 2018-07-04aRagexeRE, 2018-07-11aRagexeRE, 2018-07-18bRagexeRE, 2018-07-18bRagexeRE1, 2018-07-18cRagexeRE, 2018-08-01cRagexeRE, 2018-08-08bRagexeRE, 2018-08-22cRagexeRE, 2018-08-29aRagexeRE, 2018-08-29bRagexeRE, 2018-09-12dRagexeRE, 2018-09-19aRagexeRE, 2018-10-02aRagexeRE, 2018-10-02bRagexeRE, 2018-10-17_02aRagexeRE, 2018-10-17_03aRagexeRE, 2018-10-17bRagexeRE, 2018-10-31cRagexeRE, 2018-11-07aRagexeRE, 2018-11-14cRagexeRE, 2018-11-14dRagexeRE, 2018-11-21cRagexeRE, 2018-11-28aRagexeRE, 2018-12-05bRagexeRE, 2018-12-12aRagexeRE, 2018-12-12bRagexeRE, 2018-12-19bRagexeRE, 2018-12-26aRagexeRE, 2019-01-09bRagexeRE, 2019-01-16bRagexeRE, 2019-01-16cRagexeRE, 2019-01-23dRagexeRE, 2019-02-13IRagexeRE, 2019-02-20aRagexeRE, 2019-02-27bRagexeRE, 2019-02-28aRagexeRE, 2019-03-06bRagexeRE, 2019-03-06cRagexeRE, 2019-03-20aRagexeRE, 2019-03-22aRagexeRE, 2019-03-27bRagexeRE, 2019-04-03bRagexeRE, 2019-04-03cRagexeRE
#if PACKETVER == 20180704 || \
PACKETVER == 20180711 || \
PACKETVER == 20180718 || \
@@ -9691,7 +9691,11 @@
PACKETVER == 20190220 || \
PACKETVER == 20190227 || \
PACKETVER == 20190228 || \
- PACKETVER >= 20190306
+ PACKETVER == 20190306 || \
+ PACKETVER == 20190320 || \
+ PACKETVER == 20190322 || \
+ PACKETVER == 20190327 || \
+ PACKETVER >= 20190403
packet(0x0202,clif->pFriendsListAdd,2); // CZ_ADD_FRIENDS // 26
packet(0x022d,clif->pHomMenu,2,4); // CZ_COMMAND_MER // 5
packet(0x023b,clif->pStoragePassword,0); // CZ_ACK_STORE_PASSWORD // 36
diff --git a/src/map/packets_shuffle_zero.h b/src/map/packets_shuffle_zero.h
index 3e83ae299..ccf11a647 100644
--- a/src/map/packets_shuffle_zero.h
+++ b/src/map/packets_shuffle_zero.h
@@ -742,7 +742,7 @@
packet(0x0968,clif->pStoragePassword,0); // CZ_ACK_STORE_PASSWORD // 36
#endif
-// 2018-11-14aRagexe_zero, 2018-11-20aRagexe_zero, 2018-11-28aRagexe_zero, 2018-12-12aRagexe_zero, 2018-12-19aRagexe_zero, 2018-12-26_2aRagexe_zero, 2019-01-16_2aRagexe_zero, 2019-01-17_1aRagexe_zero, 2019-01-30_2aRagexe_zero, 2019-02-13aRagexe_zero, 2019-02-20aRagexe_zero, 2019-02-27aRagexe_zero
+// 2018-11-14aRagexe_zero, 2018-11-20aRagexe_zero, 2018-11-28aRagexe_zero, 2018-12-12aRagexe_zero, 2018-12-19aRagexe_zero, 2018-12-26_2aRagexe_zero, 2019-01-16_2aRagexe_zero, 2019-01-17_1aRagexe_zero, 2019-01-30_2aRagexe_zero, 2019-02-13aRagexe_zero, 2019-02-20aRagexe_zero, 2019-02-27aRagexe_zero, 2019-03-13aRagexe_zero, 2019-03-27_2aRagexe_zero, 2019-03-27_3aRagexe_zero, 2019-04-03aRagexe_zero
#if PACKETVER == 20181114 || \
PACKETVER == 20181120 || \
PACKETVER == 20181128 || \
@@ -754,7 +754,10 @@
PACKETVER == 20190130 || \
PACKETVER == 20190213 || \
PACKETVER == 20190220 || \
- PACKETVER >= 20190227
+ PACKETVER == 20190227 || \
+ PACKETVER == 20190313 || \
+ PACKETVER == 20190327 || \
+ PACKETVER >= 20190403
packet(0x0202,clif->pFriendsListAdd,2); // CZ_ADD_FRIENDS // 26
packet(0x022d,clif->pHomMenu,2,4); // CZ_COMMAND_MER // 5
packet(0x023b,clif->pStoragePassword,0); // CZ_ACK_STORE_PASSWORD // 36
diff --git a/src/map/packets_struct.h b/src/map/packets_struct.h
index 42b11b718..96337d32b 100644
--- a/src/map/packets_struct.h
+++ b/src/map/packets_struct.h
@@ -3160,6 +3160,34 @@ struct PACKET_CZ_CLIENT_VERSION {
DEFINE_PACKET_HEADER(CZ_CLIENT_VERSION, 0x044a);
#endif
+#if PACKETVER_MAIN_NUM >= 20190227 || PACKETVER_RE_NUM >= 20190220 || PACKETVER_ZERO_NUM >= 20190220
+struct PACKET_CZ_PING {
+ int16 packetType;
+} __attribute__((packed));
+DEFINE_PACKET_HEADER(CZ_PING, 0x0b1c);
+#endif
+
+#if PACKETVER_MAIN_NUM >= 20190213 || PACKETVER_RE_NUM >= 20190213 || PACKETVER_ZERO_NUM >= 20190130
+struct PACKET_ZC_PING {
+ int16 packetType;
+} __attribute__((packed));
+DEFINE_PACKET_HEADER(ZC_PING, 0x0b1d);
+#endif
+
+#if PACKETVER >= 20160622
+struct PACKET_CZ_COOLDOWN_RESET {
+ int16 packetType;
+} __attribute__((packed));
+DEFINE_PACKET_HEADER(CZ_COOLDOWN_RESET, 0x0a88);
+#endif
+
+#if PACKETVER >= 20151104
+struct PACKET_CZ_STYLE_CLOSE {
+ int16 packetType;
+} __attribute__((packed));
+DEFINE_PACKET_HEADER(CZ_STYLE_CLOSE, 0x0a48);
+#endif
+
#if !defined(sun) && (!defined(__NETBSD__) || __NetBSD_Version__ >= 600000000) // NetBSD 5 and Solaris don't like pragma pack but accept the packed attribute
#pragma pack(pop)
#endif // not NetBSD < 6 / Solaris
diff --git a/src/map/pc.c b/src/map/pc.c
index ea18715bb..140cf7ac1 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -8138,7 +8138,7 @@ static int pc_dead(struct map_session_data *sd, struct block_list *src)
if( battle_config.show_mob_info&4 )
{// update name with new level
- clif->charnameack(0, &md->bl);
+ clif->blname_ack(0, &md->bl);
}
}
src = battle->get_master(src); // Maybe Player Summon
@@ -9008,6 +9008,13 @@ static int pc_jobchange(struct map_session_data *sd, int class, int upper)
if (sd->disguise != -1)
pc->disguise(sd, -1);
+ // Fix atcommand @jobchange when the player changing from 3rd job having alternate body style into non-3rd job, crashing the client
+ if (pc->has_second_costume(sd) == false) {
+ sd->status.body = 0;
+ sd->vd.body_style = 0;
+ clif->changelook(&sd->bl, LOOK_BODY2, sd->vd.body_style);
+ }
+
status->set_viewdata(&sd->bl, class);
clif->changelook(&sd->bl, LOOK_BASE, sd->vd.class); // move sprite update to prevent client crashes with incompatible equipment [Valaris]
if(sd->vd.cloth_color)
@@ -12335,7 +12342,8 @@ static bool pc_has_second_costume(struct map_session_data *sd)
{
nullpo_retr(false, sd);
- if ((sd->job & JOBL_THIRD) != 0)
+// FIXME: JOB_SUPER_NOVICE_E(4190) is not supposed to be 3rd Job. (Issue#2383)
+ if ((sd->job & JOBL_THIRD) != 0 && (sd->job & MAPID_BASEMASK) != MAPID_NOVICE)
return true;
return false;
}
diff --git a/src/map/pet.c b/src/map/pet.c
index c9603a76c..96fe63c51 100644
--- a/src/map/pet.c
+++ b/src/map/pet.c
@@ -251,7 +251,7 @@ static int pet_hungry(int tid, int64 tick, int id, intptr_t data)
pd->pet.hungry--;
/* Pet Autofeed */
- if (battle_config.feature_enable_homun_autofeed != 0) {
+ if (battle_config.feature_enable_pet_autofeed != 0) {
if (pd->petDB->autofeed == 1 && pd->pet.autofeed == 1 && pd->pet.hungry <= 25) {
pet->food(sd, pd);
}
@@ -733,7 +733,7 @@ static int pet_change_name_ack(struct map_session_data *sd, const char *name, in
}
safestrncpy(pd->pet.name, newname, NAME_LENGTH);
aFree(newname);
- clif->charnameack (0,&pd->bl);
+ clif->blname_ack(0,&pd->bl);
pd->pet.rename_flag = 1;
clif->send_petdata(NULL, sd->pd, 3, sd->pd->vd.head_bottom);
clif->send_petstatus(sd);
diff --git a/src/map/script.c b/src/map/script.c
index ed8f6b8d2..fe8638ac3 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -10604,24 +10604,36 @@ static BUILDIN(gettime)
return true;
}
-/*==========================================
+/*
* GetTimeStr("TimeFMT", Length);
- *------------------------------------------*/
+ */
static BUILDIN(gettimestr)
{
char *tmpstr;
const char *fmtstr;
int maxlen;
- time_t now = time(NULL);
+ time_t now;
- fmtstr=script_getstr(st,2);
- maxlen=script_getnum(st,3);
+ fmtstr = script_getstr(st, 2);
+ maxlen = script_getnum(st, 3);
- tmpstr=(char *)aMalloc((maxlen+1)*sizeof(char));
- strftime(tmpstr,maxlen,fmtstr,localtime(&now));
- tmpstr[maxlen]='\0';
+ if (script_hasdata(st, 4)) {
+ int timestamp = script_getnum(st, 4);
+ if (timestamp < 0) {
+ ShowWarning("buildin_gettimestr: UNIX timestamp must be in positive value.\n");
+ return false;
+ }
- script_pushstr(st,tmpstr);
+ now = (time_t)timestamp;
+ } else {
+ now = time(NULL);
+ }
+
+ tmpstr = (char *)aMalloc((maxlen +1)*sizeof(char));
+ strftime(tmpstr, maxlen, fmtstr, localtime(&now));
+ tmpstr[maxlen] = '\0';
+
+ script_pushstr(st, tmpstr);
return true;
}
@@ -14857,6 +14869,7 @@ static BUILDIN(getinventorylist)
}
pc->setreg(sd,reference_uid(script->add_variable("@inventorylist_expire"), j),sd->status.inventory[i].expire_time);
pc->setreg(sd,reference_uid(script->add_variable("@inventorylist_bound"), j),sd->status.inventory[i].bound);
+ pc->setreg(sd, reference_uid(script->add_variable("@inventorylist_idx"), j), i);
j++;
}
}
@@ -15573,36 +15586,74 @@ static BUILDIN(recovery)
return true;
}
-/*==========================================
- * Get your pet info: getpetinfo(n)
- * n -> 0:pet_id 1:pet_class 2:pet_name
- * 3:friendly 4:hungry, 5: rename flag.
- *------------------------------------------*/
+/*
+ * Get your current pet information
+ */
static BUILDIN(getpetinfo)
{
struct map_session_data *sd = script->rid2sd(st);
- struct pet_data *pd;
- int type=script_getnum(st,2);
+ if (sd == NULL)
+ return true;
- if (sd == NULL || sd->pd == NULL) {
- if (type == 2)
- script_pushconststr(st,"null");
+ struct pet_data *pd = sd->pd;
+ int type = script_getnum(st, 2);
+ if (pd == NULL) {
+ if (type == PETINFO_NAME)
+ script_pushconststr(st, "null");
else
- script_pushint(st,0);
+ script_pushint(st, 0);
return true;
}
- pd = sd->pd;
+
switch(type) {
- case 0: script_pushint(st,pd->pet.pet_id); break;
- case 1: script_pushint(st,pd->pet.class_); break;
- case 2: script_pushstrcopy(st,pd->pet.name); break;
- case 3: script_pushint(st,pd->pet.intimate); break;
- case 4: script_pushint(st,pd->pet.hungry); break;
- case 5: script_pushint(st,pd->pet.rename_flag); break;
- default:
- script_pushint(st,0);
- break;
+ case PETINFO_ID:
+ script_pushint(st, pd->pet.pet_id);
+ break;
+ case PETINFO_CLASS:
+ script_pushint(st, pd->pet.class_);
+ break;
+ case PETINFO_NAME:
+ script_pushstrcopy(st, pd->pet.name);
+ break;
+ case PETINFO_INTIMACY:
+ script_pushint(st, pd->pet.intimate);
+ break;
+ case PETINFO_HUNGRY:
+ script_pushint(st, pd->pet.hungry);
+ break;
+ case PETINFO_RENAME:
+ script_pushint(st, pd->pet.rename_flag);
+ break;
+ case PETINFO_GID:
+ script_pushint(st, pd->bl.id);
+ break;
+ case PETINFO_EGGITEM:
+ script_pushint(st, pd->pet.egg_id);
+ break;
+ case PETINFO_FOODITEM:
+ script_pushint(st, pd->petDB->FoodID);
+ break;
+ case PETINFO_ACCESSORYITEM:
+ script_pushint(st, pd->petDB->AcceID);
+ break;
+ case PETINFO_ACCESSORYFLAG:
+ script_pushint(st, (pd->pet.equip != 0)? 1:0);
+ break;
+ case PETINFO_EVO_EGGID:
+ if (VECTOR_DATA(pd->petDB->evolve_data) != NULL)
+ script_pushint(st, VECTOR_DATA(pd->petDB->evolve_data)->petEggId);
+ else
+ script_pushint(st, 0);
+ break;
+ case PETINFO_AUTOFEED:
+ script_pushint(st, pd->pet.autofeed);
+ break;
+ default:
+ ShowWarning("buildin_getpetinfo: Invalid type %d.\n", type);
+ script_pushint(st, 0);
+ return false;
}
+
return true;
}
@@ -18926,14 +18977,16 @@ static BUILDIN(setunitdata)
break;
case UDT_LEVEL:
md->level = val;
+ if (battle_config.show_mob_info & 4)
+ clif->blname_ack(0, &md->bl);
break;
case UDT_HP:
status->set_hp(bl, (unsigned int) val, STATUS_HEAL_DEFAULT);
- clif->charnameack(0, &md->bl);
+ clif->blname_ack(0, &md->bl);
break;
case UDT_MAXHP:
md->status.max_hp = (unsigned int) val;
- clif->charnameack(0, &md->bl);
+ clif->blname_ack(0, &md->bl);
break;
case UDT_SP:
status->set_sp(bl, (unsigned int) val, STATUS_HEAL_DEFAULT);
@@ -20307,7 +20360,7 @@ static BUILDIN(setunitname)
}
script_pushint(st, 1);
- clif->charnameack(0, bl); // Send update to client.
+ clif->blname_ack(0, bl); // Send update to client.
return true;
}
@@ -21686,7 +21739,7 @@ static BUILDIN(bg_monster_set_team)
mob_stop_attack(md);
mob_stop_walking(md, STOPWALKING_FLAG_NONE);
md->target_id = md->attacked_id = 0;
- clif->charnameack(0, &md->bl);
+ clif->blname_ack(0, &md->bl);
return true;
}
@@ -25378,7 +25431,7 @@ static void script_parse_builtin(void)
BUILDIN_DEF(savepoint,"sii"),
BUILDIN_DEF(gettimetick,"i"),
BUILDIN_DEF(gettime,"i"),
- BUILDIN_DEF(gettimestr,"si"),
+ BUILDIN_DEF(gettimestr, "si?"),
BUILDIN_DEF(openstorage,""),
BUILDIN_DEF(guildopenstorage,""),
BUILDIN_DEF(itemskill,"vi?"),
@@ -25598,7 +25651,7 @@ static void script_parse_builtin(void)
BUILDIN_DEF(getd,"s"),
BUILDIN_DEF(setd,"sv"),
// <--- [zBuffer] List of dynamic var commands
- BUILDIN_DEF(petstat,"i"),
+ BUILDIN_DEF_DEPRECATED(petstat, "i"), // Deprecated 2019-03-11
BUILDIN_DEF(callshop,"s?"), // [Skotlex]
BUILDIN_DEF(npcshopitem,"sii*"), // [Lance]
BUILDIN_DEF(npcshopadditem,"sii*"),
@@ -25896,6 +25949,7 @@ static void script_hardcoded_constants(void)
script->set_constant("MAX_BG_MEMBERS",MAX_BG_MEMBERS,false, false);
script->set_constant("MAX_CHAT_USERS",MAX_CHAT_USERS,false, false);
script->set_constant("MAX_REFINE",MAX_REFINE,false, false);
+ script->set_constant("MAX_ITEM_ID",MAX_ITEM_ID,false, false);
script->set_constant("MAX_MENU_OPTIONS", MAX_MENU_OPTIONS, false, false);
script->set_constant("MAX_MENU_LENGTH", MAX_MENU_LENGTH, false, false);
script->set_constant("MOB_CLONE_START", MOB_CLONE_START, false, false);
@@ -26182,6 +26236,21 @@ static void script_hardcoded_constants(void)
script->set_constant("MERCINFO_LEVEL", MERCINFO_LEVEL, false, false);
script->set_constant("MERCINFO_GID", MERCINFO_GID, false, false);
+ script->constdb_comment("getpetinfo options");
+ script->set_constant("PETINFO_ID", PETINFO_ID, false, false);
+ script->set_constant("PETINFO_CLASS", PETINFO_CLASS, false, false);
+ script->set_constant("PETINFO_NAME", PETINFO_NAME, false, false);
+ script->set_constant("PETINFO_INTIMACY", PETINFO_INTIMACY, false, false);
+ script->set_constant("PETINFO_HUNGRY", PETINFO_HUNGRY, false, false);
+ script->set_constant("PETINFO_RENAME", PETINFO_RENAME, false, false);
+ script->set_constant("PETINFO_GID", PETINFO_GID, false, false);
+ script->set_constant("PETINFO_EGGITEM", PETINFO_EGGITEM, false, false);
+ script->set_constant("PETINFO_FOODITEM", PETINFO_FOODITEM, false, false);
+ script->set_constant("PETINFO_ACCESSORYITEM", PETINFO_ACCESSORYITEM, false, false);
+ script->set_constant("PETINFO_ACCESSORYFLAG", PETINFO_ACCESSORYFLAG, false, false);
+ script->set_constant("PETINFO_EVO_EGGID", PETINFO_EVO_EGGID, false, false);
+ script->set_constant("PETINFO_AUTOFEED", PETINFO_AUTOFEED, false, false);
+
script->constdb_comment("monster skill states");
script->set_constant("MSS_ANY", MSS_ANY, false, false);
script->set_constant("MSS_IDLE", MSS_IDLE, false, false);
diff --git a/src/map/script.h b/src/map/script.h
index 54c5aad2a..008da9c3c 100644
--- a/src/map/script.h
+++ b/src/map/script.h
@@ -478,6 +478,27 @@ enum script_mercinfo_types {
};
/**
+ * Pet Info types.
+ */
+enum script_petinfo_types {
+ PETINFO_ID = 0,
+ PETINFO_CLASS,
+ PETINFO_NAME,
+ PETINFO_INTIMACY,
+ PETINFO_HUNGRY,
+ PETINFO_RENAME,
+ PETINFO_GID,
+ PETINFO_EGGITEM,
+ PETINFO_FOODITEM,
+ PETINFO_ACCESSORYITEM,
+ PETINFO_ACCESSORYFLAG,
+ PETINFO_EVO_EGGID,
+ PETINFO_AUTOFEED,
+
+ PETINFO_MAX
+};
+
+/**
* Player blocking actions related flags.
*/
enum pcblock_action_flag {
diff --git a/src/plugins/HPMHooking/HPMHooking.Defs.inc b/src/plugins/HPMHooking/HPMHooking.Defs.inc
index fa1eb3a28..c1016d19b 100644
--- a/src/plugins/HPMHooking/HPMHooking.Defs.inc
+++ b/src/plugins/HPMHooking/HPMHooking.Defs.inc
@@ -1378,8 +1378,8 @@ typedef void (*HPMHOOK_pre_clif_mvp_noitem) (struct map_session_data **sd);
typedef void (*HPMHOOK_post_clif_mvp_noitem) (struct map_session_data *sd);
typedef void (*HPMHOOK_pre_clif_changed_dir) (struct block_list **bl, enum send_target *target);
typedef void (*HPMHOOK_post_clif_changed_dir) (struct block_list *bl, enum send_target target);
-typedef void (*HPMHOOK_pre_clif_charnameack) (int *fd, struct block_list **bl);
-typedef void (*HPMHOOK_post_clif_charnameack) (int fd, struct block_list *bl);
+typedef void (*HPMHOOK_pre_clif_blname_ack) (int *fd, struct block_list **bl);
+typedef void (*HPMHOOK_post_clif_blname_ack) (int fd, struct block_list *bl);
typedef void (*HPMHOOK_pre_clif_monster_hp_bar) (struct mob_data **md, struct map_session_data **sd);
typedef void (*HPMHOOK_post_clif_monster_hp_bar) (struct mob_data *md, struct map_session_data *sd);
typedef int (*HPMHOOK_pre_clif_hpmeter) (struct map_session_data **sd);
@@ -2624,6 +2624,8 @@ typedef void (*HPMHOOK_pre_clif_pReqStyleChange) (int *fd, struct map_session_da
typedef void (*HPMHOOK_post_clif_pReqStyleChange) (int fd, struct map_session_data *sd);
typedef void (*HPMHOOK_pre_clif_pReqStyleChange2) (int *fd, struct map_session_data **sd);
typedef void (*HPMHOOK_post_clif_pReqStyleChange2) (int fd, struct map_session_data *sd);
+typedef void (*HPMHOOK_pre_clif_pStyleClose) (int *fd, struct map_session_data **sd);
+typedef void (*HPMHOOK_post_clif_pStyleClose) (int fd, struct map_session_data *sd);
typedef void (*HPMHOOK_pre_clif_style_change_response) (struct map_session_data **sd, enum stylist_shop *flag);
typedef void (*HPMHOOK_post_clif_style_change_response) (struct map_session_data *sd, enum stylist_shop flag);
typedef void (*HPMHOOK_pre_clif_pPetEvolution) (int *fd, struct map_session_data **sd);
@@ -2654,6 +2656,16 @@ typedef void (*HPMHOOK_pre_clif_pNPCBarterPurchase) (int *fd, struct map_session
typedef void (*HPMHOOK_post_clif_pNPCBarterPurchase) (int fd, struct map_session_data *sd);
typedef void (*HPMHOOK_pre_clif_pClientVersion) (int *fd, struct map_session_data **sd);
typedef void (*HPMHOOK_post_clif_pClientVersion) (int fd, struct map_session_data *sd);
+typedef void (*HPMHOOK_pre_clif_pPing) (int *fd, struct map_session_data **sd);
+typedef void (*HPMHOOK_post_clif_pPing) (int fd, struct map_session_data *sd);
+typedef void (*HPMHOOK_pre_clif_ping) (struct map_session_data **sd);
+typedef void (*HPMHOOK_post_clif_ping) (struct map_session_data *sd);
+typedef int (*HPMHOOK_pre_clif_pingTimer) (int *tid, int64 *tick, int *id, intptr_t *data);
+typedef int (*HPMHOOK_post_clif_pingTimer) (int retVal___, int tid, int64 tick, int id, intptr_t data);
+typedef int (*HPMHOOK_pre_clif_pingTimerSub) (struct map_session_data **sd, va_list ap);
+typedef int (*HPMHOOK_post_clif_pingTimerSub) (int retVal___, struct map_session_data *sd, va_list ap);
+typedef void (*HPMHOOK_pre_clif_pResetCooldown) (int *fd, struct map_session_data **sd);
+typedef void (*HPMHOOK_post_clif_pResetCooldown) (int fd, struct map_session_data *sd);
#endif // MAP_CLIF_H
#ifdef COMMON_CORE_H /* cmdline */
typedef void (*HPMHOOK_pre_cmdline_init) (void);
diff --git a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
index 1a4d5b72a..5648dd267 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.HPMHooksCore.inc
@@ -968,8 +968,8 @@ struct {
struct HPMHookPoint *HP_clif_mvp_noitem_post;
struct HPMHookPoint *HP_clif_changed_dir_pre;
struct HPMHookPoint *HP_clif_changed_dir_post;
- struct HPMHookPoint *HP_clif_charnameack_pre;
- struct HPMHookPoint *HP_clif_charnameack_post;
+ struct HPMHookPoint *HP_clif_blname_ack_pre;
+ struct HPMHookPoint *HP_clif_blname_ack_post;
struct HPMHookPoint *HP_clif_monster_hp_bar_pre;
struct HPMHookPoint *HP_clif_monster_hp_bar_post;
struct HPMHookPoint *HP_clif_hpmeter_pre;
@@ -2214,6 +2214,8 @@ struct {
struct HPMHookPoint *HP_clif_pReqStyleChange_post;
struct HPMHookPoint *HP_clif_pReqStyleChange2_pre;
struct HPMHookPoint *HP_clif_pReqStyleChange2_post;
+ struct HPMHookPoint *HP_clif_pStyleClose_pre;
+ struct HPMHookPoint *HP_clif_pStyleClose_post;
struct HPMHookPoint *HP_clif_style_change_response_pre;
struct HPMHookPoint *HP_clif_style_change_response_post;
struct HPMHookPoint *HP_clif_pPetEvolution_pre;
@@ -2244,6 +2246,16 @@ struct {
struct HPMHookPoint *HP_clif_pNPCBarterPurchase_post;
struct HPMHookPoint *HP_clif_pClientVersion_pre;
struct HPMHookPoint *HP_clif_pClientVersion_post;
+ struct HPMHookPoint *HP_clif_pPing_pre;
+ struct HPMHookPoint *HP_clif_pPing_post;
+ struct HPMHookPoint *HP_clif_ping_pre;
+ struct HPMHookPoint *HP_clif_ping_post;
+ struct HPMHookPoint *HP_clif_pingTimer_pre;
+ struct HPMHookPoint *HP_clif_pingTimer_post;
+ struct HPMHookPoint *HP_clif_pingTimerSub_pre;
+ struct HPMHookPoint *HP_clif_pingTimerSub_post;
+ struct HPMHookPoint *HP_clif_pResetCooldown_pre;
+ struct HPMHookPoint *HP_clif_pResetCooldown_post;
struct HPMHookPoint *HP_cmdline_init_pre;
struct HPMHookPoint *HP_cmdline_init_post;
struct HPMHookPoint *HP_cmdline_final_pre;
@@ -7643,8 +7655,8 @@ struct {
int HP_clif_mvp_noitem_post;
int HP_clif_changed_dir_pre;
int HP_clif_changed_dir_post;
- int HP_clif_charnameack_pre;
- int HP_clif_charnameack_post;
+ int HP_clif_blname_ack_pre;
+ int HP_clif_blname_ack_post;
int HP_clif_monster_hp_bar_pre;
int HP_clif_monster_hp_bar_post;
int HP_clif_hpmeter_pre;
@@ -8889,6 +8901,8 @@ struct {
int HP_clif_pReqStyleChange_post;
int HP_clif_pReqStyleChange2_pre;
int HP_clif_pReqStyleChange2_post;
+ int HP_clif_pStyleClose_pre;
+ int HP_clif_pStyleClose_post;
int HP_clif_style_change_response_pre;
int HP_clif_style_change_response_post;
int HP_clif_pPetEvolution_pre;
@@ -8919,6 +8933,16 @@ struct {
int HP_clif_pNPCBarterPurchase_post;
int HP_clif_pClientVersion_pre;
int HP_clif_pClientVersion_post;
+ int HP_clif_pPing_pre;
+ int HP_clif_pPing_post;
+ int HP_clif_ping_pre;
+ int HP_clif_ping_post;
+ int HP_clif_pingTimer_pre;
+ int HP_clif_pingTimer_post;
+ int HP_clif_pingTimerSub_pre;
+ int HP_clif_pingTimerSub_post;
+ int HP_clif_pResetCooldown_pre;
+ int HP_clif_pResetCooldown_post;
int HP_cmdline_init_pre;
int HP_cmdline_init_post;
int HP_cmdline_final_pre;
diff --git a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
index da93da520..6ab056dfd 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.HookingPoints.inc
@@ -508,7 +508,7 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(clif->mvp_exp, HP_clif_mvp_exp) },
{ HP_POP(clif->mvp_noitem, HP_clif_mvp_noitem) },
{ HP_POP(clif->changed_dir, HP_clif_changed_dir) },
- { HP_POP(clif->charnameack, HP_clif_charnameack) },
+ { HP_POP(clif->blname_ack, HP_clif_blname_ack) },
{ HP_POP(clif->monster_hp_bar, HP_clif_monster_hp_bar) },
{ HP_POP(clif->hpmeter, HP_clif_hpmeter) },
{ HP_POP(clif->hpmeter_single, HP_clif_hpmeter_single) },
@@ -1131,6 +1131,7 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(clif->PrivateAirshipResponse, HP_clif_PrivateAirshipResponse) },
{ HP_POP(clif->pReqStyleChange, HP_clif_pReqStyleChange) },
{ HP_POP(clif->pReqStyleChange2, HP_clif_pReqStyleChange2) },
+ { HP_POP(clif->pStyleClose, HP_clif_pStyleClose) },
{ HP_POP(clif->style_change_response, HP_clif_style_change_response) },
{ HP_POP(clif->pPetEvolution, HP_clif_pPetEvolution) },
{ HP_POP(clif->petEvolutionResult, HP_clif_petEvolutionResult) },
@@ -1146,6 +1147,11 @@ struct HookingPointData HookingPoints[] = {
{ HP_POP(clif->pNPCBarterClosed, HP_clif_pNPCBarterClosed) },
{ HP_POP(clif->pNPCBarterPurchase, HP_clif_pNPCBarterPurchase) },
{ HP_POP(clif->pClientVersion, HP_clif_pClientVersion) },
+ { HP_POP(clif->pPing, HP_clif_pPing) },
+ { HP_POP(clif->ping, HP_clif_ping) },
+ { HP_POP(clif->pingTimer, HP_clif_pingTimer) },
+ { HP_POP(clif->pingTimerSub, HP_clif_pingTimerSub) },
+ { HP_POP(clif->pResetCooldown, HP_clif_pResetCooldown) },
/* cmdline_interface */
{ HP_POP(cmdline->init, HP_cmdline_init) },
{ HP_POP(cmdline->final, HP_cmdline_final) },
diff --git a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
index 2bd2d0149..26cf8ef00 100644
--- a/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
+++ b/src/plugins/HPMHooking/HPMHooking_map.Hooks.inc
@@ -12619,13 +12619,13 @@ void HP_clif_changed_dir(struct block_list *bl, enum send_target target) {
}
return;
}
-void HP_clif_charnameack(int fd, struct block_list *bl) {
+void HP_clif_blname_ack(int fd, struct block_list *bl) {
int hIndex = 0;
- if (HPMHooks.count.HP_clif_charnameack_pre > 0) {
+ if (HPMHooks.count.HP_clif_blname_ack_pre > 0) {
void (*preHookFunc) (int *fd, struct block_list **bl);
*HPMforce_return = false;
- for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_charnameack_pre; hIndex++) {
- preHookFunc = HPMHooks.list.HP_clif_charnameack_pre[hIndex].func;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_blname_ack_pre; hIndex++) {
+ preHookFunc = HPMHooks.list.HP_clif_blname_ack_pre[hIndex].func;
preHookFunc(&fd, &bl);
}
if (*HPMforce_return) {
@@ -12634,12 +12634,12 @@ void HP_clif_charnameack(int fd, struct block_list *bl) {
}
}
{
- HPMHooks.source.clif.charnameack(fd, bl);
+ HPMHooks.source.clif.blname_ack(fd, bl);
}
- if (HPMHooks.count.HP_clif_charnameack_post > 0) {
+ if (HPMHooks.count.HP_clif_blname_ack_post > 0) {
void (*postHookFunc) (int fd, struct block_list *bl);
- for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_charnameack_post; hIndex++) {
- postHookFunc = HPMHooks.list.HP_clif_charnameack_post[hIndex].func;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_blname_ack_post; hIndex++) {
+ postHookFunc = HPMHooks.list.HP_clif_blname_ack_post[hIndex].func;
postHookFunc(fd, bl);
}
}
@@ -28858,6 +28858,32 @@ void HP_clif_pReqStyleChange2(int fd, struct map_session_data *sd) {
}
return;
}
+void HP_clif_pStyleClose(int fd, struct map_session_data *sd) {
+ int hIndex = 0;
+ if (HPMHooks.count.HP_clif_pStyleClose_pre > 0) {
+ void (*preHookFunc) (int *fd, struct map_session_data **sd);
+ *HPMforce_return = false;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pStyleClose_pre; hIndex++) {
+ preHookFunc = HPMHooks.list.HP_clif_pStyleClose_pre[hIndex].func;
+ preHookFunc(&fd, &sd);
+ }
+ if (*HPMforce_return) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.clif.pStyleClose(fd, sd);
+ }
+ if (HPMHooks.count.HP_clif_pStyleClose_post > 0) {
+ void (*postHookFunc) (int fd, struct map_session_data *sd);
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pStyleClose_post; hIndex++) {
+ postHookFunc = HPMHooks.list.HP_clif_pStyleClose_post[hIndex].func;
+ postHookFunc(fd, sd);
+ }
+ }
+ return;
+}
void HP_clif_style_change_response(struct map_session_data *sd, enum stylist_shop flag) {
int hIndex = 0;
if (HPMHooks.count.HP_clif_style_change_response_pre > 0) {
@@ -29249,6 +29275,144 @@ void HP_clif_pClientVersion(int fd, struct map_session_data *sd) {
}
return;
}
+void HP_clif_pPing(int fd, struct map_session_data *sd) {
+ int hIndex = 0;
+ if (HPMHooks.count.HP_clif_pPing_pre > 0) {
+ void (*preHookFunc) (int *fd, struct map_session_data **sd);
+ *HPMforce_return = false;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pPing_pre; hIndex++) {
+ preHookFunc = HPMHooks.list.HP_clif_pPing_pre[hIndex].func;
+ preHookFunc(&fd, &sd);
+ }
+ if (*HPMforce_return) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.clif.pPing(fd, sd);
+ }
+ if (HPMHooks.count.HP_clif_pPing_post > 0) {
+ void (*postHookFunc) (int fd, struct map_session_data *sd);
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pPing_post; hIndex++) {
+ postHookFunc = HPMHooks.list.HP_clif_pPing_post[hIndex].func;
+ postHookFunc(fd, sd);
+ }
+ }
+ return;
+}
+void HP_clif_ping(struct map_session_data *sd) {
+ int hIndex = 0;
+ if (HPMHooks.count.HP_clif_ping_pre > 0) {
+ void (*preHookFunc) (struct map_session_data **sd);
+ *HPMforce_return = false;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_ping_pre; hIndex++) {
+ preHookFunc = HPMHooks.list.HP_clif_ping_pre[hIndex].func;
+ preHookFunc(&sd);
+ }
+ if (*HPMforce_return) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.clif.ping(sd);
+ }
+ if (HPMHooks.count.HP_clif_ping_post > 0) {
+ void (*postHookFunc) (struct map_session_data *sd);
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_ping_post; hIndex++) {
+ postHookFunc = HPMHooks.list.HP_clif_ping_post[hIndex].func;
+ postHookFunc(sd);
+ }
+ }
+ return;
+}
+int HP_clif_pingTimer(int tid, int64 tick, int id, intptr_t data) {
+ int hIndex = 0;
+ int retVal___ = 0;
+ if (HPMHooks.count.HP_clif_pingTimer_pre > 0) {
+ int (*preHookFunc) (int *tid, int64 *tick, int *id, intptr_t *data);
+ *HPMforce_return = false;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pingTimer_pre; hIndex++) {
+ preHookFunc = HPMHooks.list.HP_clif_pingTimer_pre[hIndex].func;
+ retVal___ = preHookFunc(&tid, &tick, &id, &data);
+ }
+ if (*HPMforce_return) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ retVal___ = HPMHooks.source.clif.pingTimer(tid, tick, id, data);
+ }
+ if (HPMHooks.count.HP_clif_pingTimer_post > 0) {
+ int (*postHookFunc) (int retVal___, int tid, int64 tick, int id, intptr_t data);
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pingTimer_post; hIndex++) {
+ postHookFunc = HPMHooks.list.HP_clif_pingTimer_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, tid, tick, id, data);
+ }
+ }
+ return retVal___;
+}
+int HP_clif_pingTimerSub(struct map_session_data *sd, va_list ap) {
+ int hIndex = 0;
+ int retVal___ = 0;
+ if (HPMHooks.count.HP_clif_pingTimerSub_pre > 0) {
+ int (*preHookFunc) (struct map_session_data **sd, va_list ap);
+ *HPMforce_return = false;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pingTimerSub_pre; hIndex++) {
+ va_list ap___copy; va_copy(ap___copy, ap);
+ preHookFunc = HPMHooks.list.HP_clif_pingTimerSub_pre[hIndex].func;
+ retVal___ = preHookFunc(&sd, ap___copy);
+ va_end(ap___copy);
+ }
+ if (*HPMforce_return) {
+ *HPMforce_return = false;
+ return retVal___;
+ }
+ }
+ {
+ va_list ap___copy; va_copy(ap___copy, ap);
+ retVal___ = HPMHooks.source.clif.pingTimerSub(sd, ap___copy);
+ va_end(ap___copy);
+ }
+ if (HPMHooks.count.HP_clif_pingTimerSub_post > 0) {
+ int (*postHookFunc) (int retVal___, struct map_session_data *sd, va_list ap);
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pingTimerSub_post; hIndex++) {
+ va_list ap___copy; va_copy(ap___copy, ap);
+ postHookFunc = HPMHooks.list.HP_clif_pingTimerSub_post[hIndex].func;
+ retVal___ = postHookFunc(retVal___, sd, ap___copy);
+ va_end(ap___copy);
+ }
+ }
+ return retVal___;
+}
+void HP_clif_pResetCooldown(int fd, struct map_session_data *sd) {
+ int hIndex = 0;
+ if (HPMHooks.count.HP_clif_pResetCooldown_pre > 0) {
+ void (*preHookFunc) (int *fd, struct map_session_data **sd);
+ *HPMforce_return = false;
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pResetCooldown_pre; hIndex++) {
+ preHookFunc = HPMHooks.list.HP_clif_pResetCooldown_pre[hIndex].func;
+ preHookFunc(&fd, &sd);
+ }
+ if (*HPMforce_return) {
+ *HPMforce_return = false;
+ return;
+ }
+ }
+ {
+ HPMHooks.source.clif.pResetCooldown(fd, sd);
+ }
+ if (HPMHooks.count.HP_clif_pResetCooldown_post > 0) {
+ void (*postHookFunc) (int fd, struct map_session_data *sd);
+ for (hIndex = 0; hIndex < HPMHooks.count.HP_clif_pResetCooldown_post; hIndex++) {
+ postHookFunc = HPMHooks.list.HP_clif_pResetCooldown_post[hIndex].func;
+ postHookFunc(fd, sd);
+ }
+ }
+ return;
+}
/* cmdline_interface */
void HP_cmdline_init(void) {
int hIndex = 0;
diff --git a/src/plugins/db2sql.c b/src/plugins/db2sql.c
index 2ece501b2..159d4e2a6 100644
--- a/src/plugins/db2sql.c
+++ b/src/plugins/db2sql.c
@@ -956,6 +956,7 @@ bool mobskilldb2sql_sub(struct config_setting_t *it, int n, int mob_id)
struct mob_db *md = mob->db(mob_id);
char valname[15];
const char *name = config_setting_name(it);
+ char e_name[NAME_LENGTH*2+1];
nullpo_retr(false, it);
Assert_retr(false, mob_id <= 0 || md != mob->dummy);
@@ -966,7 +967,8 @@ bool mobskilldb2sql_sub(struct config_setting_t *it, int n, int mob_id)
StrBuf->Printf(&buf, "%d,", mob_id);
// Info
- StrBuf->Printf(&buf, "'%s@%s',", md->name, name);
+ SQL->EscapeString(NULL, e_name, md->name);
+ StrBuf->Printf(&buf, "'%s@%s',", e_name, name);
if (mob->lookup_const(it, "SkillState", &i32) && (i32 < MSS_ANY || i32 > MSS_ANYTARGET)) {
ShowWarning("mob_skill_db_libconfig_sub_skill: Invalid skill state %d for skill '%s' in monster %d, defaulting to MSS_ANY.\n", i32, name, mob_id);
diff --git a/src/plugins/sample.c b/src/plugins/sample.c
index b37f7c4f7..7ad6794b3 100644
--- a/src/plugins/sample.c
+++ b/src/plugins/sample.c
@@ -23,6 +23,7 @@
#include "common/hercules.h" /* Should always be the first Hercules file included! (if you don't make it first, you won't be able to use interfaces) */
#include "common/memmgr.h"
#include "common/mmo.h"
+#include "common/random.h"
#include "common/socket.h"
#include "common/strlib.h"
#include "map/clif.h"
@@ -79,13 +80,13 @@ void sample_packet0f3(int fd) {
data->lastMSGPosition.map = sd->status.last_point.map;
data->lastMSGPosition.x = sd->status.last_point.x;
data->lastMSGPosition.y = sd->status.last_point.y;
- data->someNumber = rand()%777;
+ data->someNumber = rnd()%777;
ShowInfo("Created Appended sockt->session[] data, %d %d %d %u\n",data->lastMSGPosition.map,data->lastMSGPosition.x,data->lastMSGPosition.y,data->someNumber);
addToSession(sockt->session[fd],data,0,true);
} else {
ShowInfo("Existent Appended sockt->session[] data, %d %d %d %u\n",data->lastMSGPosition.map,data->lastMSGPosition.x,data->lastMSGPosition.y,data->someNumber);
- if( rand()%4 == 2 ) {
+ if (rnd()%4 == 2) {
ShowInfo("Removing Appended sockt->session[] data\n");
removeFromSession(sockt->session[fd],0);
}
@@ -98,13 +99,13 @@ void sample_packet0f3(int fd) {
data->lastMSGPosition.map = sd->status.last_point.map;
data->lastMSGPosition.x = sd->status.last_point.x;
data->lastMSGPosition.y = sd->status.last_point.y;
- data->someNumber = rand()%777;
+ data->someNumber = rnd()%777;
ShowInfo("Created Appended map_session_data data, %d %d %d %u\n",data->lastMSGPosition.map,data->lastMSGPosition.x,data->lastMSGPosition.y,data->someNumber);
addToMSD(sd,data,0,true);
} else {
ShowInfo("Existent Appended map_session_data data, %d %d %d %u\n",data->lastMSGPosition.map,data->lastMSGPosition.x,data->lastMSGPosition.y,data->someNumber);
- if( rand()%4 == 2 ) {
+ if (rnd()%4 == 2) {
ShowInfo("Removing Appended map_session_data data\n");
removeFromMSD(sd,0);
}