Quellcode durchsuchen

Merge remote-tracking branch 'upstream/master'

Conflicts:
	src/char/char.c
	src/char/int_storage.c
lighta vor 11 Jahren
Ursprung
Commit
214176ab1b
77 geänderte Dateien mit 8382 neuen und 3950 gelöschten Zeilen
  1. 2 2
      conf/battle/battle.conf
  2. 6 1
      conf/battle/feature.conf
  3. 45 24
      conf/msg_conf/map_msg.conf
  4. 52 2
      db/const.txt
  5. 32 32
      db/import-tmpl/item_db.txt
  6. 2 1
      db/import-tmpl/item_flag.txt
  7. 1 1
      db/pre-re/item_combo_db.txt
  8. 6 6
      db/pre-re/item_db.txt
  9. 2 2
      db/pre-re/item_flag.txt
  10. 4 4
      db/pre-re/skill_cast_db.txt
  11. 7 7
      db/pre-re/skill_db.txt
  12. 13 12
      db/pre-re/skill_require_db.txt
  13. 1 1
      db/re/instance_db.txt
  14. 1227 1124
      db/re/item_buyingstore.txt
  15. 73 17
      db/re/item_combo_db.txt
  16. 360 128
      db/re/item_db.txt
  17. 2 2
      db/re/item_flag.txt
  18. 1 1
      db/re/item_misc.txt
  19. 222 12
      db/re/item_package.txt
  20. 461 36
      db/re/item_trade.txt
  21. 64 4
      db/re/mob_db.txt
  22. 21 21
      db/re/skill_cast_db.txt
  23. 7 7
      db/re/skill_db.txt
  24. 13 12
      db/re/skill_require_db.txt
  25. 3 3
      db/skill_changematerial_db.txt
  26. 16 0
      doc/atcommands.txt
  27. 7 6
      doc/item_bonus.txt
  28. 4 4
      doc/item_db.txt
  29. 26 14
      doc/script_commands.txt
  30. 2 1
      npc/custom/jobmaster.txt
  31. 8 3
      npc/jobs/2-2/alchemist.txt
  32. 208 323
      npc/other/monster_race.txt
  33. 3182 0
      npc/re/instances/WolfchevLaboratory.txt
  34. 2 574
      npc/re/quests/quests_lighthalzen.txt
  35. 1 0
      npc/re/scripts_athena.conf
  36. 354 138
      sql-files/item_db_re.sql
  37. 1 0
      sql-files/main.sql
  38. 1 2
      sql-files/mob_db_re.sql
  39. 1 0
      sql-files/upgrades/upgrade_20140523.sql
  40. 11 8
      src/char/char.c
  41. 2 0
      src/char/char.h
  42. 1 1
      src/char/int_mail.c
  43. 75 8
      src/char/int_storage.c
  44. 38 0
      src/common/mmo.h
  45. 1 6
      src/config/core.h
  46. 1 1
      src/login/loginlog_sql.c
  47. 126 109
      src/map/atcommand.c
  48. 307 238
      src/map/battle.c
  49. 1 0
      src/map/battle.h
  50. 3 2
      src/map/cashshop.c
  51. 5 2
      src/map/chrif.c
  52. 74 23
      src/map/clif.c
  53. 2 1
      src/map/clif.h
  54. 5 5
      src/map/elemental.c
  55. 1 1
      src/map/elemental.h
  56. 2 2
      src/map/guild.c
  57. 30 9
      src/map/homunculus.c
  58. 2 0
      src/map/homunculus.h
  59. 155 184
      src/map/itemdb.c
  60. 39 30
      src/map/itemdb.h
  61. 2 1
      src/map/map.c
  62. 4 1
      src/map/map.h
  63. 7 11
      src/map/mercenary.c
  64. 4 5
      src/map/mob.c
  65. 40 34
      src/map/npc.c
  66. 307 150
      src/map/pc.c
  67. 27 33
      src/map/pc.h
  68. 30 33
      src/map/pet.c
  69. 89 78
      src/map/script.c
  70. 238 202
      src/map/skill.c
  71. 42 38
      src/map/skill.h
  72. 223 173
      src/map/status.c
  73. 31 20
      src/map/status.h
  74. 6 8
      src/map/storage.c
  75. 1 0
      src/map/storage.h
  76. 1 1
      src/map/trade.c
  77. 9 5
      src/map/unit.c

+ 2 - 2
conf/battle/battle.conf

@@ -94,11 +94,11 @@ vit_penalty_num: 5
 
 // Use alternate method of DEF calculation for physical attacks.
 // With 0, disabled (use normal def% reduction with further def2 reduction)
-// At 1 or more defense is subtraction of (DEF* value).
+// At 1 or more defense is subtraction of (DEF * value).
 // eg: 10 + 50 def becomes 0 + (10*type + 50)
 weapon_defense_type: 0
 
-//MDEF‚same as above....(MDEF*value)
+// MDEF‚ same as above. (MDEF * value)
 magic_defense_type: 0
 
 // Change attacker's direction to face opponent on every attack? (Note 3)

+ 6 - 1
conf/battle/feature.conf

@@ -16,9 +16,14 @@ feature.buying_store: on
 feature.search_stores: on
 
 // Atcommand suggestions (Note 1)
-// Show suggestions when typing an incomplete command?
+// If one type incomplete atcommand, it will suggest the complete ones.
 feature.atcommand_suggestions: off
 
+// Auction (Note 1)
+// Feature became unstable on clients 2012 onwards (exact date not known),
+// it has been fixed on clients 2013-05-15 onwards however.
+feature.auction: on
+
 // Warp suggestions (Note 1)
 // Show suggestions when attempting to @warp to a non-existent map?
 feature.warp_suggestions: off

+ 45 - 24
conf/msg_conf/map_msg.conf

@@ -306,7 +306,7 @@
 290: The player is no longer killable.
 291: Weather effects will dispell on warp/refresh
 292: Killer state reset.
-//Item Bound System
+// Item Bound System
 293: This bounded item cannot be traded to that character.
 294: This bounded item cannot be stored there.
 295: Please enter an item name or ID (usage: @item <item name/ID> <quantity> <bound type>).
@@ -392,8 +392,8 @@
 377:  -- Player %s has rejected the duel --
 //etc
 378: Eleanor is now in %s mode.
-379: Item Failed. [%s] is cooling down. Wait %.1f minutes.
-380: Item Failed. [%s] is cooling down. Wait %d seconds.
+379: Able to use %.1f min later.
+380: Able to use %d sec later.
 381: Skill Failed. [%s] requires %dx %s.
 382: You're too close to a stone or emperium to use this skill.
 383: You cannot create a savepoint in an instance.
@@ -516,7 +516,28 @@
 515: Your instance has been reloaded.
 516: Instance database has been reloaded.
 
-//517~534: free
+// @auction
+517: Auction System is disabled.
+
+// @itemlist -- continued
+518: Lower Costume Head, 
+519: Top Costume Head, 
+520: Top/Lower Costume Head, 
+521: Mid Costume Head, 
+522: Mid/Lower Costume Head, 
+523: Top/Mid/Lower Costume Head, 
+524: Costume Robe, 
+525: Costume Floor, 
+526: Ammo, 
+527: Shadow Body, 
+528: Shadow Right Hand, 
+529: Shadow Left Hand, 
+530: Shadow Both Hands, 
+531: Shadow Shoes, 
+532: Shadow Right Accessory, 
+533: Shadow Left Accessory, 
+
+//534: // Free
 
 // Bot detect messages (currently unused)
 535: Possible use of BOT (99%% of chance) or modified client by '%s' (account: %d, char_id: %d). This player ask your name when you are hidden.
@@ -535,7 +556,7 @@
 //542: %.0s%.0sSomeone stole %s
 // 543~548 are not used (previously @away messages)
 
-// @Autotrade
+// @autotrade
 549: You should have a shop open to use @autotrade.
 
 //550 -> 650: Job Names
@@ -714,17 +735,17 @@
 710: Item %d has been removed from your cart.
 711: Item %d has been removed from your storage.
 
-//Item shop
+// Item shop
 712: You do not have enough %s (%d).
 713: You do not have enough '%s'.
 714: Item Shop List: %s (%d)
 715: Point Shop List: '%s'
 716: Your '%s' now: %d
 
-//Item Group
+// Item Group
 717: [%s] has won [%s] from '%s'
 
-//@showrate
+// @showrate
 718: Personal rate information is not displayed now.
 719: Personal rate information will be shown.
 
@@ -1363,21 +1384,21 @@
 
 // @itemlist
 1332: ------ %s items list of '%s' ------
-1333:  | equipped:
-1334: garment,
-1335: left accessory,
-1336: body/armor,
-1337: right hand,
-1338: left hand,
-1339: both hands,
-1340: feet,
-1341: right accessory,
-1342: lower head,
-1343: top head,
-1344: lower/top head,
-1345: mid head,
-1346: lower/mid head,
-1347: lower/mid/top head,
+1333:  | Equipped:
+1334: Garment,
+1335: Left Accessory,
+1336: Body/Armor,
+1337: Right Hand,
+1338: Left Hand,
+1339: Both Hands,
+1340: Feet,
+1341: Right Accessory,
+1342: Lower Head,
+1343: Top Head,
+1344: Top/Lower Head,
+1345: Mid Head,
+1346: Mid/Lower Head,
+1347: Top/Mid/Lower Head,
 1348:  -> (pet egg, pet id: %u, named)
 1349:  -> (pet egg, pet id: %u, unnamed)
 1350:  -> (crafted item, creator id: %u, star crumbs %d, element %d)
@@ -1564,7 +1585,7 @@
 1493: Type List: (default) all = -1, healing = 0, usable = 2, etc = 3, armor = 4, weapon = 5, card = 6, petegg = 7, petarmor = 8, ammo = 10
 1494: %d items are dropped (%d skipped)!
 
-//Banking
+// Banking
 1495: You can't withdraw that much money
 1496: Banking is disabled
 

+ 52 - 2
db/const.txt

@@ -621,6 +621,7 @@ bAddClassDropItem	2070
 bAddClassDropItemGroup	2071
 
 bAddMaxWeight	2072
+bAddItemGroupHealRate	2073
 
 EQI_HEAD_TOP	1
 EQI_ARMOR	2
@@ -1124,6 +1125,36 @@ IG_Sg_Weapon_Supply_Box	388
 IG_Candy_Holder	389
 IG_Lucky_Bag	390
 IG_Holy_Egg_2	391
+IG_Adventurer_Returns_Support_Box	392
+IG_Support_Package	393
+IG_Support_Package10	394
+IG_Event_Almighty_Box	395
+IG_Event_Almighty_Box10	396
+IG_LottoBox1	397
+IG_LottoBox2	398
+IG_LottoBox3	399
+IG_LottoBox4	400
+IG_LottoBox5	401
+IG_Support_Package_III	402
+IG_Support_Package_III10	403
+IG_Unlimited_Box	404
+IG_Unlimited_Box10	405
+IG_Unlimited_Box_II	406
+IG_Unlimited_Box_II10	407
+IG_Three_Master_Package_III	408
+IG_Three_Master_Package_III10	409
+IG_2013_RWC_Scroll	410
+IG_Support_Package_II	411
+IG_Support_Package_II10	412
+IG_Level_Up_Box100	413
+IG_Level_Up_Box120	414
+IG_Level_Up_Box130	415
+IG_Level_Up_Box140	416
+IG_Level_Up_Box150	417
+IG_Level_Up_Box160	418
+IG_Gift_Buff_Set        419
+IG_Lucky_Silvervine_Fruit_Box_III10        420
+IG_Lucky_Silvervine_Fruit_Box_III110        421
 
 SC_ALL	-1
 SC_STONE	0
@@ -1460,7 +1491,7 @@ SC_SPHERE_3	339
 SC_SPHERE_4	340
 SC_SPHERE_5	341
 SC_READING_SB	342
-SC_FREEZINGSPELL	343
+SC_FREEZE_SP	343
 SC_FEARBREEZE	344
 SC_ELECTRICSHOCKER	345
 SC_WUGDASH	346
@@ -1715,6 +1746,7 @@ SC__FEINTBOMB	594
 SC__CHAOS	595
 SC_ELEMENTAL_SHIELD	596
 SC_EXTREMITYFIST2	597
+SC_CHASEWALK2	598
 
 //Status Icon
 SI_BLANK	-1
@@ -1898,7 +1930,7 @@ SI_MAXSPPERCENT	178
 SI_DEFENCE	179
 SI_SLOWDOWN	180
 SI_PRESERVE	181
-SI_INCSTR	182
+SI_CHASEWALK2	182
 SI_NOT_EXTREMITYFIST	183
 SI_INTRAVISION	184
 SI_MOVESLOW_POTION	185
@@ -4513,6 +4545,19 @@ THANATOS_KEEP	10009
 4_M_DEATH2	10092
 4_S_KADOMATSU	10093
 4_B_KADOMATSU	10094
+4_JP_GARM_H	10098
+4_JP_MEDUSA_H	10099
+4_CHN_GVG_01	10100
+4_SPRING_RABBIT	10101
+4_PD_TYRA	10102
+4_PD_TYRANOS	10103
+4_PD_PLESI	10104
+4_PD_PLESIO	10105
+4_PD_BRACHI	10106
+4_PD_BRACHIOS	10107
+4_PD_GOLDDRAGON	10108
+4_PD_ZAEROG	10109
+4_PD_TAMADORA	10110
 
 HAVEQUEST	0
 PLAYTIME	1
@@ -4570,5 +4615,10 @@ IT_AMMO	10
 IT_DELAYCONSUME	11
 IT_CASH	18
 
+Bound_Account	1
+Bound_Guild	2
+Bound_Party	3
+Bound_Char	4
+
 false	0
 true	1

+ 32 - 32
db/import-tmpl/item_db.txt

@@ -11,53 +11,53 @@
 //1999,Zed's_Staff,Zed's Staff,3,,10,10,,,,,,,,,,,,,{},{},{}
 
 // Official Event Items that had their Effects removed after the event was completed
-//585,Wurst,Brusti,11,2,,40,,,,,0xFFFFFFFF,7,2,,,,,,{ itemheal rand(15,20),0; itemskill "PR_MAGNIFICAT",3; },{},{}
-//679,Gold_Pill,Pilule,0,5000,,300,,,,,0xFFFFFFFF,7,2,,,,,,{ percentheal 50,50; },{},{}
-
-//2681,Republic_Ring,Republic Anniversary Ring,4,20,,100,,0,,0,0xFFFFFFFF,7,2,136,,0,0,0,{ bonus bAllStats,3; },{},{}
-
-//5134,Pumpkin_Hat,Pumpkin-Head,4,20,,200,,2,,0,0xFFFFFFFF,7,2,256,,0,1,206,{ bonus2 bSubRace,RC_Demon,5; },{},{}
-//5136,Santa's_Hat_,Louise's Santa Hat,4,20,,100,,3,,0,0xFFFFFFFF,7,2,256,,0,1,20,{ bonus bMdef,1; bonus bLuk,1; bonus3 bAutoSpellWhenHit,"AL_HEAL",3,50; bonus3 bAutoSpellWhenHit,"AL_BLESSING",10,50; },{},{}
-//5145,Carnival_Joker_Jester,Carnival Jester,4,10,,100,,0,,0,0xFFFFFFFF,7,2,256,,0,1,89,{ bonus bAllStats,3; },{},{}
-//5147,Baseball_Cap,Baseball Cap,4,0,,200,,3,,0,0xFFFFFFFF,7,2,256,,0,1,216,{ bonus2 bExpAddRace,RC_Boss,50; bonus2 bExpAddRace,RC_NonBoss,50; },{},{}
-//5201,Party_Hat_B,2nd Anniversary Party Hat,4,20,,300,,3,,0,0xFFFFFFFF,7,2,256,,0,1,144,{ bonus bAllStats,3; },{},{}
-//5202,Pumpkin_Hat_,Pumpkin Hat,4,20,,200,,2,,0,0xFFFFFFFF,7,2,256,,0,1,206,{ bonus bAllStats,2; bonus2 bSubRace,RC_Demon,5; bonus3 bAddMonsterDropItem,529,RC_DemiHuman,1500; },{},{}
-//5204,Event_Pierrot_Nose,Rudolf's Red Nose,4,20,,100,,0,,0,0xFFFFFFFF,7,2,1,,0,0,49,{ bonus2 bResEff,Eff_Blind,3000; bonus2 bAddMonsterDropItem,12130,30; },{},{}
-//5264,Aussie_Flag_Hat,Australian Flag Hat,4,20,,500,,4,,0,0xFFFFFFFF,7,2,256,,0,1,304,{ bonus bAllStats,2; },{},{}
-//5356,Pumpkin_Hat_H,Pumpkin Hat,4,20,,200,,2,,0,0xFFFFFFFF,7,2,256,,0,1,206,{ bonus bAllStats,2; bonus2 bSubRace,RC_Demon,5; bonus2 bMagicAddRace,RC_Demon,5; },{},{}
-//5811,Santa_Beard,Santa Beard,4,20,,100,,5,,0,0xFFFFFFFF,7,2,1,,0,0,25,{ bonus2 bSubRace,RC_Brute,5; },{},{}
-
-//11702,Moon_Cookie,Moon Cookie,11,0,,10,,,,,0xFFFFFFFF,7,2,,,,,,{ sc_end SC_Poison; sc_end SC_Silence; sc_end SC_Blind; sc_end SC_Confusion; sc_end SC_Curse; sc_end SC_Hallucination; itemskill "AL_BLESSING",7; },{},{}
-//12131,Lucky_Potion,Lucky Potion,0,2,,100,,,,,0xFFFFFFFF,7,2,,,,,,{ sc_start SC_LUKFood,180000,15; },{},{}
-//12143,Red_Can,Red Can,2,50000,,300,,,,,0xFFFFFFFF,7,2,,,,,,{ percentheal 25,25; },{},{}
+//585,Wurst,Brusti,11,2,,40,,,,,0xFFFFFFFF,63,2,,,,,,{ itemheal rand(15,20),0; itemskill "PR_MAGNIFICAT",3; },{},{}
+//679,Gold_Pill,Pilule,0,5000,,300,,,,,0xFFFFFFFF,63,2,,,,,,{ percentheal 50,50; },{},{}
+
+//2681,Republic_Ring,Republic Anniversary Ring,4,20,,100,,0,,0,0xFFFFFFFF,63,2,136,,0,0,0,{ bonus bAllStats,3; },{},{}
+
+//5134,Pumpkin_Hat,Pumpkin-Head,4,20,,200,,2,,0,0xFFFFFFFF,63,2,256,,0,1,206,{ bonus2 bSubRace,RC_Demon,5; },{},{}
+//5136,Santa's_Hat_,Louise's Santa Hat,4,20,,100,,3,,0,0xFFFFFFFF,63,2,256,,0,1,20,{ bonus bMdef,1; bonus bLuk,1; bonus3 bAutoSpellWhenHit,"AL_HEAL",3,50; bonus3 bAutoSpellWhenHit,"AL_BLESSING",10,50; },{},{}
+//5145,Carnival_Joker_Jester,Carnival Jester,4,10,,100,,0,,0,0xFFFFFFFF,63,2,256,,0,1,89,{ bonus bAllStats,3; },{},{}
+//5147,Baseball_Cap,Baseball Cap,4,0,,200,,3,,0,0xFFFFFFFF,63,2,256,,0,1,216,{ bonus2 bExpAddRace,RC_Boss,50; bonus2 bExpAddRace,RC_NonBoss,50; },{},{}
+//5201,Party_Hat_B,2nd Anniversary Party Hat,4,20,,300,,3,,0,0xFFFFFFFF,63,2,256,,0,1,144,{ bonus bAllStats,3; },{},{}
+//5202,Pumpkin_Hat_,Pumpkin Hat,4,20,,200,,2,,0,0xFFFFFFFF,63,2,256,,0,1,206,{ bonus bAllStats,2; bonus2 bSubRace,RC_Demon,5; bonus3 bAddMonsterDropItem,529,RC_DemiHuman,1500; },{},{}
+//5204,Event_Pierrot_Nose,Rudolf's Red Nose,4,20,,100,,0,,0,0xFFFFFFFF,63,2,1,,0,0,49,{ bonus2 bResEff,Eff_Blind,3000; bonus2 bAddMonsterDropItem,12130,30; },{},{}
+//5264,Aussie_Flag_Hat,Australian Flag Hat,4,20,,500,,4,,0,0xFFFFFFFF,63,2,256,,0,1,304,{ bonus bAllStats,2; },{},{}
+//5356,Pumpkin_Hat_H,Pumpkin Hat,4,20,,200,,2,,0,0xFFFFFFFF,63,2,256,,0,1,206,{ bonus bAllStats,2; bonus2 bSubRace,RC_Demon,5; bonus2 bMagicAddRace,RC_Demon,5; },{},{}
+//5811,Santa_Beard,Santa Beard,4,20,,100,,5,,0,0xFFFFFFFF,63,2,1,,0,0,25,{ bonus2 bSubRace,RC_Brute,5; },{},{}
+
+//11702,Moon_Cookie,Moon Cookie,11,0,,10,,,,,0xFFFFFFFF,63,2,,,,,,{ sc_end SC_POISON; sc_end SC_SILENCE; sc_end SC_BLIND; sc_end SC_CONFUSION; sc_end SC_CURSE; sc_end SC_HALLUCINATION; itemskill "AL_BLESSING",7; },{},{}
+//12131,Lucky_Potion,Lucky Potion,0,2,,100,,,,,0xFFFFFFFF,63,2,,,,,,{ sc_start SC_LUKFOOD,180000,15; },{},{}
+//12143,Red_Can,Red Can,2,50000,,300,,,,,0xFFFFFFFF,63,2,,,,,,{ percentheal 25,25; },{},{}
 //Event effect: Summon monster? Probably Rice_Cake. x_x
-//12199,Rice_Scroll,Rice Scroll,2,0,,0,,,,,0xFFFFFFFF,7,2,,,,,,{},{},{}
-//12200,Event_Cake,Event Cake,2,20,,50,,,,,0xFFFFFFFF,7,2,,,,,,{ itemskill "PR_MAGNIFICAT",3; },{},{}
-//12238,New_Year_Rice_Cake_1,New Year Rice Cake,0,20,,100,,,,,0xFFFFFFFF,7,2,,,,,,{ percentheal 20,15; sc_start SC_STRFood,1200000,3; sc_start SC_INTFood,1200000,3; sc_start SC_LUKFood,1200000,3; sc_start SC_SpeedUp1,5000,0; },{},{}
-//12239,New_Year_Rice_Cake_2,New Year Rice Cake,0,20,,100,,,,,0xFFFFFFFF,7,2,,,,,,{ percentheal 20,15; sc_start SC_DEXFood,1200000,3; sc_start SC_AGIFood,1200000,3; sc_start SC_VITFood,1200000,3; sc_start SC_SpeedUp1,5000,0; },{},{}
+//12199,Rice_Scroll,Rice Scroll,2,0,,0,,,,,0xFFFFFFFF,63,2,,,,,,{},{},{}
+//12200,Event_Cake,Event Cake,2,20,,50,,,,,0xFFFFFFFF,63,2,,,,,,{ itemskill "PR_MAGNIFICAT",3; },{},{}
+//12238,New_Year_Rice_Cake_1,New Year Rice Cake,0,20,,100,,,,,0xFFFFFFFF,63,2,,,,,,{ percentheal 20,15; sc_start SC_STRFOOD,1200000,3; sc_start SC_INTFOOD,1200000,3; sc_start SC_LUKFOOD,1200000,3; sc_start SC_SPEEDUP1,5000,0; },{},{}
+//12239,New_Year_Rice_Cake_2,New Year Rice Cake,0,20,,100,,,,,0xFFFFFFFF,63,2,,,,,,{ percentheal 20,15; sc_start SC_DEXFOOD,1200000,3; sc_start SC_AGIFOOD,1200000,3; sc_start SC_VITFOOD,1200000,3; sc_start SC_SPEEDUP1,5000,0; },{},{}
 
 // iRO St. Patrick's Day Event 2008
 //=============================================================
-//12715,Black_Treasure_Chest,Black Treasure Chest,2,0,,200,,,,,0xFFFFFFFF,7,2,,,,,,{ callfunc "F_08stpattyseventbox"; },{},{}
+//12715,Black_Treasure_Chest,Black Treasure Chest,2,0,,200,,,,,0xFFFFFFFF,63,2,,,,,,{ callfunc "F_08stpattyseventbox"; },{},{}
 
 // iRO Valentine's Day Event 2009
 //=============================================================
-//12742,Valentine_Gift_Box_M,Valentine Gift Box,2,10,,0,,,,,0xFFFFFFFF,7,2,,,,,,{ getitem 7946,1; },{},{}
-//12743,Valentine_Gift_Box_F,Valentine Gift Box,2,10,,0,,,,,0xFFFFFFFF,7,2,,,,,,{ getitem 7947,1; },{},{}
-//12744,Chocolate_Box,Chocolate Box,2,10,,0,,,,,0xFFFFFFFF,7,2,,,,,,{ getitem 558,1; },{},{}
-//14466,Valentine's_Emblem_Box,Valentine's Emblem Box,2,10,,0,,,,,0xFFFFFFFF,7,2,,,,,,{ getitem 5817,1; },{},{}
+//12742,Valentine_Gift_Box_M,Valentine Gift Box,2,10,,0,,,,,0xFFFFFFFF,63,2,,,,,,{ getitem 7946,1; },{},{}
+//12743,Valentine_Gift_Box_F,Valentine Gift Box,2,10,,0,,,,,0xFFFFFFFF,63,2,,,,,,{ getitem 7947,1; },{},{}
+//12744,Chocolate_Box,Chocolate Box,2,10,,0,,,,,0xFFFFFFFF,63,2,,,,,,{ getitem 558,1; },{},{}
+//14466,Valentine's_Emblem_Box,Valentine's Emblem Box,2,10,,0,,,,,0xFFFFFFFF,63,2,,,,,,{ getitem 5817,1; },{},{}
 //7946,Gold_Ring_Of_Valentine,Gold Ring Of Valentine,3,10,,0,,,,,,,,,,,,,{},{},{}
 //7947,Silver_Ring_Of_Valentine,Silver Ring Of Valentine,3,10,,0,,,,,,,,,,,,,{},{},{}
 //7948,Box,Box,3,10,,10,,,,,,,,,,,,,{},{},{}
-//5817,Valentine's_Emblem,Valentine's Emblem,4,10,,0,,3,,0,0xFFFFFFFF,7,2,136,,0,0,0,{ bonus bAtkRate,3; bonus bMatkRate,3; bonus bAllStats,2; bonus bFlee,10; bonus bAspd,1; bonus bMdef,3; bonus2 bSkillAtk,"AL_HEAL",10; bonus2 bSkillHeal,"AL_HEAL",10; bonus2 bSkillHeal,"AM_POTIONPITCHER",10; bonus2 bAddItemHealRate,IG_Potion,10; },{},{}
+//5817,Valentine's_Emblem,Valentine's Emblem,4,10,,0,,3,,0,0xFFFFFFFF,63,2,136,,0,0,0,{ bonus bAtkRate,3; bonus bMatkRate,3; bonus bAllStats,2; bonus bFlee,10; bonus bAspd,1; bonus bMdef,3; bonus2 bSkillAtk,"AL_HEAL",10; bonus2 bSkillHeal,"AL_HEAL",10; bonus2 bSkillHeal,"AM_POTIONPITCHER",10; bonus2 bAddItemGroupHealRate,IG_Potion,10; },{},{}
 
 // iRO Halloween Event 2009
 //=============================================================
-//5668,Weird_Pumpkin_Hat,Weird Pumpkin Hat,4,20,,0,,5,,0,0xFFFFFFFF,7,2,256,,0,1,206,{ bonus bMdef,5; bonus2 bAddMonsterDropItem,12192,2500; },{},{}
+//5668,Weird_Pumpkin_Hat,Weird Pumpkin Hat,4,20,,0,,5,,0,0xFFFFFFFF,63,2,256,,0,1,206,{ bonus bMdef,5; bonus2 bAddMonsterDropItem,12192,2500; },{},{}
 //6298,Crushed_Pumpkin,Crushed Pumpkin,3,0,,0,,,,,,,,,,,,,{},{},{}
 //6299,Worn_Fabric,Worn Fabric,3,0,,0,,,,,,,,,,,,,{},{},{}
 
 // Old Tuxedo and Wedding Dress, will display the outfit when worn.
 //==================================================================
-//2338,Wedding_Dress,Wedding Dress,4,43000,,500,,0,,0,0xFFFFFFFE,7,0,16,,0,1,0,{},{ setoption Option_Wedding,1; },{ setoption Option_Wedding,0; }
-//7170,Tuxedo,Tuxedo,4,43000,,10,,0,,0,0xFFFFFFFE,7,1,16,,0,1,0,{},{ setoption Option_Wedding,1; },{ setoption Option_Wedding,0; }
+//2338,Wedding_Dress,Wedding Dress,4,43000,,500,,0,,0,0xFFFFFFFE,63,0,16,,0,1,0,{},{ sc_start SC_WEDDING,-1,0; },{ sc_end SC_WEDDING; }
+//7170,Tuxedo,Tuxedo,4,43000,,10,,0,,0,0xFFFFFFFE,63,1,16,,0,1,0,{},{ sc_start SC_WEDDING,-1,0; },{ sc_end SC_WEDDING; }

+ 2 - 1
db/import-tmpl/item_flag.txt

@@ -3,4 +3,5 @@
 //
 // <Flag>:
 // 1 - As Dead Branch item (will be logged at `branchlog` table and cannot be used at 'nobranch' mapflag)
-// 2 - As item group container, check player's inventory and weight before consumed
+// 2 - As item group container, check player's inventory and weight before consumed
+// NOTE: For removing flag by import file, use "-" to remove the flag. Example, 604,-1 will removes flag 1 from Branch_Of_Dead_Tree

+ 1 - 1
db/pre-re/item_combo_db.txt

@@ -146,7 +146,7 @@
 4193:4294,{ bonus bMaxHP,300; bonus bMaxSP,60; }
 4208:4258:4325:4327:4382,{ bonus bInt,3; bonus2 bSkillAtk,"WZ_HEAVENDRIVE",10; bonus2 bSkillAtk,"MG_THUNDERSTORM",10; if(BaseJob==Job_Sage) { bonus bMagicDamageReturn,20; bonus2 bAddMonsterDropItem,716,100; bonus2 bAddMonsterDropItem,715,100; bonus bCastrate,-20; } }
 4218:4269,{ bonus bHPrecovRate,30; bonus bSPrecovRate,30; bonus bVit,4; bonus bInt,4; }
-4220:4246:4311:4319:4331,{ bonus bStr,10; bonus bMaxHPrate,20; bonus bHPrecovRate,50; bonus3 bAutoSpell,"BS_WEAPONPERFECT",1,3; bonus2 bAddMonsterDropItem,501,500; if(BaseClass==Job_Swordman) bonus2 bAddItemHealRate,IG_Potion,50; }
+4220:4246:4311:4319:4331,{ bonus bStr,10; bonus bMaxHPrate,20; bonus bHPrecovRate,50; bonus3 bAutoSpell,"BS_WEAPONPERFECT",1,3; bonus2 bAddMonsterDropItem,501,500; if(BaseClass==Job_Swordman) bonus2 bAddItemGroupHealRate,IG_Potion,50; }
 4229:4244:4299:4313,{ bonus bDef,3; bonus bMdef,3; }
 4237:4238,{ bonus3 bAutoSpell,"MG_LIGHTNINGBOLT",5,20; }
 4268:4277,{ bonus bBaseAtk,20; bonus bLuk,3; }

+ 6 - 6
db/pre-re/item_db.txt

@@ -1328,7 +1328,7 @@
 2414,Novice_Boots,Novice Slippers,4,1,,1,,2,,0,0x00000001,7,2,64,,0,0,0,{},{},{}
 2415,Slipper,Bunny Slipper,4,34000,,300,,3,,1,0xFFFFFFFE,7,0,64,,30,1,0,{ bonus bLuk,3; bonus bMdef,3; },{},{}
 2416,Novice_Shoes,Novice Shoes,4,35000,,500,,2,,1,0x00000001,7,2,64,,40,1,0,{ bonus bMaxHPrate,5; },{},{}
-2417,Fricco_Shoes,Fricco's Shoes,4,30000,,500,,3,,0,0xFFFFFFFE,7,2,64,,65,1,0,{ bonus bAgi,2; bonus2 bAddItemHealRate,IG_Potion,20; },{},{}
+2417,Fricco_Shoes,Fricco's Shoes,4,30000,,500,,3,,0,0xFFFFFFFE,7,2,64,,65,1,0,{ bonus bAgi,2; bonus2 bAddItemGroupHealRate,IG_Potion,20; },{},{}
 2418,Vidar's_Boots,Vidar's Boots,4,30000,,650,,4,,0,0xFFFFFFFE,7,2,64,,65,1,0,{ bonus bMaxHPrate,9; bonus bMaxSPrate,9; },{},{}
 2419,Goibne's_Combat_Boots,Goibne's Greaves,4,30000,,700,,4,,0,0xFFFFFFFE,7,2,64,,54,1,0,{ bonus bMdef,3; bonus bMaxHPrate,5; bonus bMaxSPrate,5; },{},{}
 2420,Angel's_Arrival,Angel's Reincarnation,4,10000,,300,,2,,1,0x00000001,7,2,64,,25,1,0,{ bonus bMaxHP,100; },{},{}
@@ -1777,9 +1777,9 @@
 4149,Gargoyle_Card,Gargoyle Card,6,20,,10,,,,,,,,136,,,,,{ bonus3 bAddMonsterDropItem,12028,RC_Insect,100; },{},{}
 4150,Goat_Card,Goat Card,6,20,,10,,,,,,,,16,,,,,{ if(getrefine()<6) { bonus bDef,2; bonus bMdef,5; } },{},{}
 4151,Gajomart_Card,Gajomart Card,6,20,,10,,,,,,,,64,,,,,{ bonus2 bSubRace,RC_Plant,-20; bonus2 bExpAddRace,RC_Plant,10; },{},{}
-4152,Galapago_Card,Galapago Card,6,20,,10,,,,,,,,136,,,,,{ bonus2 bAddItemHealRate,IG_Juice,50; bonus3 bAddMonsterDropItem,531,RC_Insect,300; bonus3 bAddMonsterDropItem,532,RC_Insect,300; bonus3 bAddMonsterDropItem,534,RC_Insect,300; },{},{}
+4152,Galapago_Card,Galapago Card,6,20,,10,,,,,,,,136,,,,,{ bonus2 bAddItemGroupHealRate,IG_Juice,50; bonus3 bAddMonsterDropItem,531,RC_Insect,300; bonus3 bAddMonsterDropItem,532,RC_Insect,300; bonus3 bAddMonsterDropItem,534,RC_Insect,300; },{},{}
 4153,Crab_Card,Crab Card,6,20,,10,,,,,,,,2,,,,,{ bonus bBaseAtk,5; bonus2 bAddDamageClass,1266,30; },{},{}
-4154,Rice_Cake_Boy_Card,Dumpling Child Card,6,20,,10,,,,,,,,136,,,,,{ bonus2 bAddItemHealRate,IG_Candy,50; bonus3 bAddMonsterDropItem,529,RC_DemiHuman,300; bonus3 bAddMonsterDropItem,529,RC_Player,300; bonus3 bAddMonsterDropItem,530,RC_DemiHuman,100; bonus3 bAddMonsterDropItem,530,RC_Player,100; },{},{}
+4154,Rice_Cake_Boy_Card,Dumpling Child Card,6,20,,10,,,,,,,,136,,,,,{ bonus2 bAddItemGroupHealRate,IG_Candy,50; bonus3 bAddMonsterDropItem,529,RC_DemiHuman,300; bonus3 bAddMonsterDropItem,529,RC_Player,300; bonus3 bAddMonsterDropItem,530,RC_DemiHuman,100; bonus3 bAddMonsterDropItem,530,RC_Player,100; },{},{}
 4155,Goblin_Leader_Card,Goblin Leader Card,6,20,,10,,,,,,,,2,,,,,{ bonus2 bAddRace2,1,30; },{},{}
 4156,Steam_Goblin_Card,Goblin Steamrider Card,6,20,,10,,,,,,,,2,,,,,{ bonus bCritAtkRate,10; bonus2 bCriticalAddRace,RC_Formless,7; },{},{}
 4157,Goblin_Archer_Card,Goblin Archer Card,6,20,,10,,,,,,,,2,,,,,{ bonus bCritAtkRate,10; bonus2 bCriticalAddRace,RC_Undead,7; },{},{}
@@ -1852,12 +1852,12 @@
 4224,Stem_Worm_Card,Stem Worm Card,6,20,,10,,,,,,,,136,,,,,{ bonus3 bAddMonsterDropItem,12032,RC_Brute,100; },{},{}
 4225,Stone_Shooter_Card,Stone Shooter Card,6,20,,10,,,,,,,,2,,,,,{ bonus bBaseAtk,10; bonus bHit,10; },{},{}
 4226,Sting_Card,Sting Card,6,20,,10,,,,,,,,32,,,,,{ bonus bDef,2; if(getrefine()>8) bonus bMdef,5; },{},{}
-4227,Spring_Rabbit_Card,Spring Rabbit Card,6,20,,10,,,,,,,,136,,,,,{ bonus2 bAddItemHealRate,IG_Meat,50; bonus3 bAddMonsterDropItem,517,RC_Brute,200; bonus3 bAddMonsterDropItem,528,RC_Brute,200; },{},{}
+4227,Spring_Rabbit_Card,Spring Rabbit Card,6,20,,10,,,,,,,,136,,,,,{ bonus2 bAddItemGroupHealRate,IG_Meat,50; bonus3 bAddMonsterDropItem,517,RC_Brute,200; bonus3 bAddMonsterDropItem,528,RC_Brute,200; },{},{}
 4228,Sleeper_Card,Sleeper Card,6,20,,10,,,,,,,,136,,,,,{ bonus3 bAddMonsterDropItem,12031,RC_Fish,100; },{},{}
 4229,C_Tower_Manager_Card,Tower Keeper Card,6,20,,10,,,,,,,,769,,,,,{ bonus bInt,1; bonus bCastrate,-5; },{},{}
 4230,Shinobi_Card,Shinobi Card,6,20,,10,,,,,,,,136,,,,,{ bonus bAgi,1; bonus3 bAutoSpellWhenHit,"AS_CLOAKING",5,100; },{},{}
 4231,Increase_Soil_Card,Mi Gao Card,6,20,,10,,,,,,,,32,,,,,{ bonus2 bSubRace2,5,50; },{},{}
-4232,Wild_Ginseng_Card,Hermit Plant Card,6,20,,10,,,,,,,,136,,,,,{ bonus2 bAddItemHealRate,IG_Herb,50; bonus3 bAddMonsterDropItem,507,RC_Plant,300; bonus3 bAddMonsterDropItem,508,RC_Plant,200; bonus3 bAddMonsterDropItem,509,RC_Plant,100; },{},{}
+4232,Wild_Ginseng_Card,Hermit Plant Card,6,20,,10,,,,,,,,136,,,,,{ bonus2 bAddItemGroupHealRate,IG_Herb,50; bonus3 bAddMonsterDropItem,507,RC_Plant,300; bonus3 bAddMonsterDropItem,508,RC_Plant,200; bonus3 bAddMonsterDropItem,509,RC_Plant,100; },{},{}
 4233,Baby_Leopard_Card,Baby Leopard Card,6,20,,10,,,,,,,,16,,,,,{ bonus bLuk,3; if(BaseClass==Job_Merchant) bonus bUnbreakableArmor,0; },{},{}
 4234,Anolian_Card,Anolian Card,6,20,,10,,,,,,,,16,,,,,{ bonus3 bAutoSpellWhenHit,"AC_CONCENTRATION",1+9*(getskilllv("AC_CONCENTRATION")==10),30; },{},{}
 4235,Cookie_XMAS_Card,Christmas Cookie Card,6,20,,10,,,,,,,,64,,,,,{ bonus2 bSubRace,RC_Angel,-20; bonus2 bExpAddRace,RC_Angel,10; },{},{}
@@ -1951,7 +1951,7 @@
 4323,Garm_Baby_Card,Hatii Babe Card,6,20,,10,,,,,,,,2,,,,,{ bonus3 bAutoSpell,"MG_FROSTDIVER",3,50; },{},{}
 4324,Garm_Card,Hatii Card,6,20,,10,,,,,,,,16,,,,,{ bonus2 bAddEffWhenHit,Eff_Freeze,5000; },{},{}
 4325,Harpy_Card,Harpy Card,6,20,,10,,,,,,,,4,,,,,{ bonus2 bSubEle,Ele_Neutral,15; bonus2 bSkillAtk,"MG_NAPALMBEAT",5; },{},{}
-4326,See_Otter_Card,Sea-Otter Card,6,20,,10,,,,,,,,136,,,,,{ bonus2 bAddItemHealRate,IG_Fish,50; bonus3 bAddMonsterDropItem,551,RC_Fish,300; bonus3 bAddMonsterDropItem,544,RC_Fish,300; },{},{}
+4326,See_Otter_Card,Sea-Otter Card,6,20,,10,,,,,,,,136,,,,,{ bonus2 bAddItemGroupHealRate,IG_Fish,50; bonus3 bAddMonsterDropItem,551,RC_Fish,300; bonus3 bAddMonsterDropItem,544,RC_Fish,300; },{},{}
 4327,Blood_Butterfly_Card,Bloody Butterfly Card,6,20,,10,,,,,,,,136,,,,,{ bonus bCastrate,30; bonus bNoCastCancel,0; bonus2 bSkillAtk,"MG_FIREWALL",5; },{},{}
 4328,Hyegun_Card,Yao Jun Card,6,20,,10,,,,,,,,4,,,,,{ bonus bFlee,15; bonus bCritical,1; },{},{}
 4329,Phendark_Card,Phendark Card,6,20,,10,,,,,,,,2,,,,,{ bonus2 bSPGainRace,RC_DemiHuman,5; bonus2 bSPGainRace,RC_Player,5; },{},{ heal 0,-5; }

+ 2 - 2
db/pre-re/item_flag.txt

@@ -4,13 +4,13 @@
 // <Flag>:
 // 1 - As Dead Branch item (will be logged at `branchlog` table and cannot be used at 'nobranch' mapflag)
 // 2 - As item group container, check player's inventory and weight before consumed
+// NOTE: For removing flag by import file, use "-" to remove the flag. Example, 604,-1 will removes flag 1 from Branch_Of_Dead_Tree
 
 // Logged as Dead Branch item
 604,1 //Branch_Of_Dead_Tree
 12103,1 //Bloody_Dead_Branch
 12109,1 //Poring_Box
 12024,1 //Red_Pouch_Of_Surprise
-12258,1 //Bombring_Box
 
 // Item group container
 603,2 //Old_Blue_Box
@@ -50,4 +50,4 @@
 12356,2 //Louise_Costume_Box
 12702,2 //Old_Bleu_Box
 12714,2 //Easter_Scroll
-14596,2 //Pierre_Treasurebox
+14596,2 //Pierre_Treasurebox

+ 4 - 4
db/pre-re/skill_cast_db.txt

@@ -1456,7 +1456,7 @@
 //-- SR_GENTLETOUCH_CURE
 2345,0,1000,0,0,0,1000:1500:2000:2500:3000
 //-- SR_GENTLETOUCH_ENERGYGAIN
-2346,1000,1000,0,240000,0,0
+2346,1000,1000,0,240000,600000,0
 //-- SR_GENTLETOUCH_CHANGE
 2347,1000,1000,0,240000,0,200000:180000:160000:140000:120000
 //-- SR_GENTLETOUCH_REVITALIZE
@@ -1811,11 +1811,11 @@
 //-- MH_OVERED_BOOST
 8023,800:700:600:500:400,0,0,30000:45000:60000:75000:90000,0,0
 //-- MH_ERASER_CUTTER
-8024,1000:1500:2000:2500:3000,0,0,0,0,0
+8024,1000:1500:2000:2500:3000,2000,0,0,0,0
 //-- MH_XENO_SLASHER
-8025,1500:2500:3500:4500:5500,0,0,500,0,0
+8025,1500:2500:3500:4500:5500,5000,0,500,0,0
 //-- MH_SILENT_BREEZE
-8026,2000,0,0,9000:12000:15000:18000:21000,0,0
+8026,1000:1200:1400:1600:1800,0,0,9000:12000:15000:18000:21000,0,0
 //-- MH_STYLE_CHANGE
 //8027,0,0,0,0,0,0,0
 //-- MH_SONIC_CRAW

+ 7 - 7
db/pre-re/skill_db.txt

@@ -544,7 +544,7 @@
 //****
 // Sniper
 380,0,6,4,0,0x1,0,10,1,no,0,0,0,weapon,0,0x0,	SN_SIGHT,Falcon Eyes
-381,5,8,1,0,0x40,0,5,1,yes,0,0,0,misc,0,0x80,		SN_FALCONASSAULT,Falcon Assault
+381,5,8,1,-3,0x40,0,5,1,yes,0,0,0,misc,0,0x80,		SN_FALCONASSAULT,Falcon Assault
 382,9,8,1,-1,0,2,5,1,yes,0,0,13,weapon,0,0x0,	SN_SHARPSHOOTING,Focused Arrow Strike
 383,0,6,4,0,0x3,-1,10,1,yes,0,0,0,weapon,0,0x0,	SN_WINDWALK,Wind Walker
 
@@ -891,7 +891,7 @@
 2009,0,6,4,0,0x3,3:4:5:6:7,5,1,no,0,0,0,none,0,0x0,	RK_DRAGONHOWLING,Dragon Howling
 2010,0,0,0,0,0,0,10,0,no,0,0,0,none,0,0x0,		RK_RUNEMASTERY,Rune Mastery
 2011,0,6,4,0,0x1,0,1,1,no,0,0,0,none,0,0x0,	RK_MILLENNIUMSHIELD,Millenium Shield
-2012,1,6,4,-1,0,0,1,1,yes,0,0,0,weapon,0,0x0,	RK_CRUSHSTRIKE,Crush Strike
+2012,1,6,4,-1,0,0,1,1,yes,0,0,0,none,0,0x0,	RK_CRUSHSTRIKE,Crush Strike
 2013,0,6,4,0,0x1,0,1,1,yes,0,0,0,none,0,0x0,	RK_REFRESH,Refresh
 2014,0,6,4,0,0x1,0,1,1,yes,0,0,0,none,0,0x0,	RK_GIANTGROWTH,Giant Growth
 2015,0,6,4,0,0x1,0,1,1,yes,0,0,0,none,0,0x0,	RK_STONEHARDSKIN,Stone Hard Skin
@@ -994,7 +994,7 @@
 2240,0,6,4,0,0,0,1,1,no,0,0,0,none,0,0x0,		RA_WUGMASTERY,Warg Mastery
 2241,0,6,4,0,0,0,3,1,no,0,0,0,none,0,0x2000,		RA_WUGRIDER,Warg Rider
 2242,0,6,4,-1,0x42,1,1,0,no,0,0,0,weapon,0,0x2000,	RA_WUGDASH,Warg Dash
-2243,9,6,1,0,0x40,0,5,1,no,0,0,0,misc,0,0x2000,	RA_WUGSTRIKE,Warg Strike
+2243,9,6,1,0,0x40,0,5,1,no,0,0,0,weapon,0,0x2000,	RA_WUGSTRIKE,Warg Strike
 2244,9,6,1,0,0x40,0,5,1,no,0,0,0,weapon,0,0x80,	RA_WUGBITE,Warg Bite
 2245,0,0,0,0,0,0,10,0,no,0,0,0,none,0,0x0,		RA_TOOTHOFWUG,Tooth of Warg
 2246,0,6,4,0,0x2,3:4:5:6:7,5,1,no,0,0,0,weapon,0,0x0,	RA_SENSITIVEKEEN,Sensitive Keen
@@ -1021,7 +1021,7 @@
 2264,0,6,4,0,0x1,0,1,1,no,0,0,0,none,7,0x0,		NC_F_SIDESLIDE,Front-Side Slide
 2265,0,6,4,0,0x1,0,1,1,no,0,0,0,none,7,0x0,		NC_B_SIDESLIDE,Back-Side Slide
 2266,0,0,0,0,0,0,4,0,no,0,0,0,none,0,0x0,		NC_MAINFRAME,Mainframe Restructure
-2267,0,6,4,-1,0xCA,2:3:4,3,1,no,0,0,0,misc,5,0x0,	NC_SELFDESTRUCTION,Self Destruction
+2267,0,6,4,0,0xCA,2:3:4,3,1,no,0,0,0,weapon,5,0x0,	NC_SELFDESTRUCTION,Self Destruction
 2268,0,6,4,0,0x1,0,4,1,yes,0,0,0,none,0,0x0,	NC_SHAPESHIFT,Shape Shift
 2269,0,6,4,0,0x1,0,1,1,no,0,0,0,none,0,0x0,		NC_EMERGENCYCOOL,Emergency Cool
 2270,0,6,4,0,0x3,7,1,1,yes,0,0,0,none,0,0x0,	NC_INFRAREDSCAN,Infrared Scan
@@ -1343,9 +1343,9 @@
 8021,1,6,16,0,0x1,0,5,1,no,0,0,0,none,0,0x0,		MH_PAIN_KILLER,Pain Killer
 8022,0,6,4,0,0,0x1,5,1,no,0,0,0,none,0,0x0,		MH_LIGHT_OF_REGENE,Light of Regene
 8023,0,6,4,0,0,0x1,5,1,no,0,0,0,none,0,0x0,		MH_OVERED_BOOST,Overed Boost
-8024,7,6,1,4:0:4:0:4,0,0,5,1,no,0,0,0,magic,0,0x0,	MH_ERASER_CUTTER,Eraser Cutter
-8025,7,6,2,4:0:4:0:4,0,0,5,1,no,0,0,0,magic,0,0x0,	MH_XENO_SLASHER,Xeno Slasher
-8026,5:5:7:7:9,6,16,0,0x1,0,5,1,no,0,0,0,magic,0,0x0,	MH_SILENT_BREEZE,Silent Breeze
+8024,7,8,1,4:0:4:0:4,0,0,5,-6,yes,0,0,0,magic,0,0x0,	MH_ERASER_CUTTER,Eraser Cutter
+8025,7,8,2,4:0:4:0:4,0x2,2:2:3:3:4,5,-6,no,0,0,0,magic,0,0x0,	MH_XENO_SLASHER,Xeno Slasher
+8026,5:5:7:7:9,6,6,0,0x1,0,5,1,no,0,0,0,magic,0,0x0,	MH_SILENT_BREEZE,Silent Breeze
 8027,0,6,4,0,0x1,0,1,1,no,0,0,0,none,0,0x0,		MH_STYLE_CHANGE,Style Change
 8028,1,8,1,0,0,0,5,1,no,0,0x0200,0,weapon,0,0x0,		MH_SONIC_CRAW,Sonic Claw
 8029,1,6,4,0,0,0,5,1,no,0,0x200,0,weapon,0,0x0,	MH_SILVERVEIN_RUSH,Silver Bain Rush

+ 13 - 12
db/pre-re/skill_require_db.txt

@@ -118,7 +118,7 @@
 
 //****
 // WZ Wizard
-80,0,0,75,0,0,0,99,0,0,none,0,0,717,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0								//WZ_FIREPILLAR
+80,0,0,75,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,717,1,717,1,717,1,717,1,717,1,0						//WZ_FIREPILLAR
 81,0,0,35:37:39:41:43:45:47:49:51:53,0,0,0,99,0,0,none,SC_SIGHT,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0	//WZ_SIGHTRASHER
 83,0,0,20:24:30:34:40:44:50:54:60:64,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0	//WZ_METEOR
 84,0,0,20:23:26:29:32:35:38:41:44:47,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0	//WZ_JUPITEL
@@ -623,6 +623,7 @@
 2228,0,0,1,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0								//WL_SUMMON_ATK_GROUND
 2229,0,0,10:12:14:16:18,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0					//WL_SUMMONSTONE
 2230,0,0,3:20,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//WL_RELEASE
+2231,0,0,40,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0								//WL_READING_SB
 //2232,0,0,1,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//WL_FREEZE_SP (Passive Skill)
 
 //****
@@ -678,25 +679,25 @@
 //****
 // NC Mechanic
 2256,0,0,3:6:9:12:15,0,0,0,99,0,0,mado,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0					//NC_BOOSTKNUCKLE
-2257,0,0,50,0,0,0,99,0,0,mado,0,0,1549,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//NC_PILEBUNKER
+2257,0,0,50,0,0,0,99,0,0,mado,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1549							//NC_PILEBUNKER
 2258,0,0,2:4:6,0,0,0,99,0,0,mado,0,0,6145,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_VULCANARM
-2259,0,0,20,0,0,0,99,0,0,mado,0,0,2139,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_FLAMELAUNCHER
+2259,0,0,20,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2139						//NC_FLAMELAUNCHER
 2260,0,0,20,0,0,0,99,0,0,mado,0,0,6146,1,6147,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_COLDSLOWER
 2261,0,0,40:45:50,0,0,0,99,8,1,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0					//NC_ARMSCANNON
-2262,0,0,20:40:60,0,0,0,99,0,0,mado,0,0,2800,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0					//NC_ACCELERATION
-2263,0,0,25,0,0,0,99,0,0,mado,0,0,2801,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_HOVERING
+2262,0,0,20:40:60,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2800					//NC_ACCELERATION
+2263,0,0,25,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2801						//NC_HOVERING
 2264,0,0,5,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//NC_F_SIDESLIDE
 2265,0,0,5,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//NC_B_SIDESLIDE
 
-2267,0,0,1,0,0,0,99,0,0,mado,0,0,2802,0,6146,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_SELFDESTRUCTION
-2268,0,0,100,0,0,0,99,0,0,mado,0,0,2803,0,6360,1,6363,1,6362,1,6361,1,6146,2,0,0,0,0,0,0,0,0,0			//NC_SHAPESHIFT
-2269,0,0,20,0,0,0,99,0,0,mado,0,0,2804,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_EMERGENCYCOOL
+2267,0,0,1,0,0,0,99,0,0,mado,0,0,6146,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2802						//NC_SELFDESTRUCTION
+2268,0,0,100,0,0,0,99,0,0,mado,0,0,6360,1,6363,1,6362,1,6361,1,0,0,0,0,0,0,0,0,0,0,6146,2,2803			//NC_SHAPESHIFT
+2269,0,0,20,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2804						//NC_EMERGENCYCOOL
 2270,0,0,45,0,0,0,99,0,0,mado,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0								//NC_INFRAREDSCAN
 2271,0,0,30,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//NC_ANALYZE
-2272,0,0,90,0,0,0,99,0,0,mado,0,0,2805,0,6146,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_MAGNETICFIELD
-2273,0,0,90,0,0,0,99,0,0,mado,0,0,2806,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_NEUTRALBARRIER
-2274,0,0,100:150:200,0,0,0,99,0,0,mado,0,0,2808,0,6146,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0				//NC_STEALTHFIELD
-2275,0,0,25:30:35:40:45,0,0,0,99,0,0,mado,0,0,2807,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0			//NC_REPAIR
+2272,0,0,90,0,0,0,99,0,0,mado,0,0,6146,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2805						//NC_MAGNETICFIELD
+2273,0,0,90,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2806						//NC_NEUTRALBARRIER
+2274,0,0,100:150:200,0,0,0,99,0,0,mado,0,0,6146,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2808				//NC_STEALTHFIELD
+2275,0,0,25:30:35:40:45,0,0,0,99,0,0,mado,0,0,12392,1,12392,1,12393,1,12393,1,12394,1,0,0,0,0,0,0,0,0,6146,1,2807			//NC_REPAIR
 
 2278,0,0,20:22:24:26:28,0,0,0,6:7,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0				//NC_AXEBOOMERANG
 2279,0,0,20:22:24:26:28,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0					//NC_POWERSWING

+ 1 - 1
db/re/instance_db.txt

@@ -13,5 +13,5 @@
 7,Bangungot Hospital 2F,3600,1@ma_h,40,157,1@ma_h
 8,Buwaya Cave,3600,1@ma_c,35,57,1@ma_c
 9,Bakonawa Lake,7200,1@ma_b,64,51,1@ma_b
-//10,Wolfchev's Laboratory,14400,1@lhz,45,148,1@lhz
+10,Wolfchev's Laboratory,14400,1@lhz,45,148,1@lhz
 11,Old Glast Heim,3600,1@gl_k,150,20,1@gl_k,2@gl_k

+ 1227 - 1124
db/re/item_buyingstore.txt

@@ -8,1128 +8,1231 @@
 //  Items are in same order as data\buyingstoreitemlist.txt, which
 //  must be edited as well for the client to accept added items.
 
-// items from 2011-11-02 update
-714  // Emperium
-6381  // Field_Shovel
-6382  // Urn
-6393  // Round_Feather
-6394  // Golden_Feather
-6395  // Angel_Magic_Power
-//6403
-//6404
-//6405
-//6423
-//6469
-//6470
-//6471
-//6493
-//6496
-//6497
-//6498
-//6499
-//6508
-//6509
-//6510
-//6511
-//6512
-//6513
-//6514
-//6515
-//6516
-//6517
-//6518
-//6523
-//6524
-//6525
-7347  // Lab_Staff_Record
-7760  // Yaga_Magic_Book
-7762  // Yaga_Pestle
-7824  // Spirit_Liquor
-11519  // Beef_Toast
-11520  // Mora_Mandarin
-11521  // Pingui_Berry_Juice
-11522  // Red_Raffle_Sap
-11523  // Yellow_Raffle_Sap
-11524  // White_Raffle_Sap
-11525  // Mora_Hip_Tea
-11526  // Rafflecino
-//11532
-//11533
-//11534
-//11536
-//11537
-//11547
-//11548
-//11549
-12329  // Recall_MaleGM
-12330  // Recall_FemaleGM
-12342  // Manuk's_Opportunity
-12343  // Manuk's_Courage
-12344  // Pinguicula's_fruit_Jam
-12345  // Luciola's_Honey_Jam
-12348  // Manuk's_Faith
-12349  // Cornus'_Tears
-12350  // Angeling_Potion
-12351  // Shout_Megaphone
-12354  // Buche_De_Noel
-12355  // Xmas_Gift
-12356  // Louise_Costume_Box
-12418  // Full_SwingK
-12419  // Mana_Plus
-12422  // HP_Increase_PotionS
-12423  // HP_Increase_PotionM
-12424  // HP_Increase_PotionL
-12425  // SP_Increase_PotionS
-12426  // SP_Increase_PotionM
-12427  // SP_Increase_PotionL
-12428  // Enrich_White_PotionZ
-12429  // Savage_BBQ
-12430  // Wug_Blood_Cocktail
-12431  // Minor_Brisket
-12432  // Siroma_Icetea
-12433  // Drocera_Herb_Stew
-12434  // Petti_Tail_Noodle
-12436  // Vitata500
-12437  // Enrich_Celermine_Juice
-12475  // Cure_Free
-12536  // NY_Rice_Cake_Soup
-12539  // Splendid_Box
-12561  // Mysterious_Seed
-12574  // Mora_Berry
-12575  // Arrow_Of_Elf_Cntr
-12576  // Hunting_Arrow_Cntr
-//12582
-//12608
+//--- 2014 / 04 / 21 - ÃÖÁ¾¼öÁ¤ÀÏ
+6691	//Fire_Feather
+6692	//Patrol_Journal
+6693	//Stone_Blessing
+6694	//Blood_of_The_Monster
+6695	//Tooth_Rock_Of_Fire_Golem
+6696	//Fire_Frill
+12490	//Vivid_Notation
+22516	//Black_As_Night_Piece
+22534	//Closed_Mind_Box
+11563	//Hot_Tea
+11564	//Sweets
+//--- 2013 / 12 / 23
+6832	//Questioned_Parts
+11597	//Iron_Worm
+22699	//Test_Reagent
+22679	//Death_Bin
+22687	//Fragments_Vicious_Mind
+//6615
+//--- 2013 / 08 / 02
+6750	//Failed_Engine
+6751	//Crushed_Can_Iron_Plate
+22648	//Angeling_Package
+22649	//Deviling_Package
+6797	//11th_Coin
+//11556
+6770	//Shark
+6771	//Bluefin_Tuna
+6772	//Octopus
+6773	//Snapper
+6774	//Piranha
+6775	//Salmon
+6776	//Eels
+6777	//Carp
+6778	//Squid_2
+6779	//Mackerel
+6780	//Crucian_Carp
+6781	//Living_Earthworm
+6782	//Fresh_Lobster
+11589	//Iceflake
+11590	//Meat_Skewer5
+22620	//Memorial_Box
+22621	//Squid_Bbq
+//--- 2013 / 04 / 16
+6557	//Fancy_Fairy_Wing
+6558	//Pile_Of_Acorn
+6559	//Eye_Drops
+6560	//Leaf_Bookmark
+6561	//Dustball
+12812	//Snow_Flip
+12813	//Peony_Mommy
+12814	//Slapping_Herb
+12815	//Yggdrasil_Dust
+//6592
+//6594
+//6595
+//6596
+//6597
+//6598
+//6599
+//6600
+//6601
+//6602
+//6603
+//6604
+//6605
+//6668
+7056	//Payroll_Of_Kafra
+//11557
+//11558
+//6607
+6608	//Coagulated_Spell
+//6609
+//6610
+//6611
+//6612
+//6613
+7228	//Gold_Bullion
+7229	//Silver_Bullion
+7230	//White_Gold_Bullion
+//6699
+//6700
+//6701
+//6702
+//6703
+//6704
+//6705
+//6706
+6683	//Dried_Flower
+7640	//Butterfly_Hair_Decoration
+7642	//Bloody_Coin
+7643	//Bloody_Letter
+7644	//Unsent_Letter
+6521	//Royal_Certificate
+6522	//Royal_Certificate_
+6531	//Royal_Certificate__
+6557	//Fancy_Fairy_Wing
+6558	//Pile_Of_Acorn
+6559	//Eye_Drops
+6560	//Leaf_Bookmark
+6561	//Dustball
+12812	//Snow_Flip
+12813	//Peony_Mommy
+12814	//Slapping_Herb
+12815	//Yggdrasil_Dust
+714	//Emperium
+6381	//Field_Shovel
+6382	//Urn
+6393	//Round_Feather
+6394	//Golden_Feather
+6395	//Angel_Magic_Power
+6403	//Comodo_L
+6404	//Caress_H
+6405	//Cendrawasih_F
+6423	//Anger_Seagod
+6469	//Will_Of_Warrior
+6470	//Blood_Thirst
+6471	//Goast_Chill
+6493	//Makibishi
+6496	//Tikbalang_Thick_Spine
+6497	//Lesser_Agimat
+6498	//Jejellopy
+6499	//Ancient_Grudge
+6508	//Silver_Bracelet
+6509	//Mysterious_Flower
+6510	//Elegant_Flower
+6511	//Beautiful_Flower
+6512	//Charm_Fire
+6513	//Charm_Ice
+6514	//Charm_Wind
+6515	//Charm_Earth
+6516	//Bakonawa_Doll
+6517	//Bangungot_Doll
+6518	//Buwaya_Doll
+6523	//Bakonawa_Spirit_Piece
+6524	//Bangungot_Spirit_Piece
+6525	//Buwaya_Spirit_Piece
+7347	//Lab_Staff_Record
+7760	//Yaga_Magic_Book
+7762	//Yaga_Pestle
+7824	//Spirit_Liquor
+11519	//Beef_Toast
+11520	//Mora_Mandarin
+11521	//Pingui_Berry_Juice
+11522	//Red_Raffle_Sap
+11523	//Yellow_Raffle_Sap
+11524	//White_Raffle_Sap
+11525	//Mora_Hip_Tea
+11526	//Rafflecino
+11532	//Nasi_Goreng
+11533	//Satay
+11534	//Coco_Juice
+11536	//Cat_Hard_Biscuit
+11537	//Rice_Weevil_Bug
+11547	//Woe_Violet_Potion
+11548	//Woe_White_Potion
+11549	//Woe_Blue_Potion
+12329	//Recall_MaleGM
+12330	//Recall_FemaleGM
+12342	//Manuk's_Opportunity
+12343	//Manuk's_Courage
+12344	//Pinguicula's_fruit_Jam
+12345	//Luciola's_Honey_Jam
+12348	//Manuk's_Faith
+12349	//Cornus'_Tears
+12350	//Angeling_Potion
+12351	//Shout_Megaphone
+12354	//Buche_De_Noel
+12355	//Xmas_Gift
+12356	//Louise_Costume_Box
+12418	//Full_SwingK
+12419	//Mana_Plus
+12422	//HP_Increase_Potion_(Small)
+12423	//HP_Increase_Potion_(Medium)
+12424	//HP_Increase_Potion_(Large)
+12425	//SP_Increase_Potion_(Small)
+12426	//SP_Increase_Potion_(Medium)
+12427	//SP_Increase_Potion_(Large)
+12428	//Concentrated_White_Potion_Z
+12429	//Savage_Full_Roast
+12430	//Cocktail_Warg_Blood
+12431	//Minor_Stew
+12432	//Siroma_Iced_Tea
+12433	//Drosera_Herb_Salad
+12434	//Petite_Tail_Noodles
+12436	//Vitata_500
+12437	//Concentrated_Ceromain_Soup
+12475	//Cure_Free
+12536	//NY_Rice_Cake_Soup
+12539	//Splendid_Box
+12561	//Mysterious_Seed
+12574	//Mora_Berry
+12575	//Arrow_Of_Elf_Cntr
+12576	//Hunting_Arrow_Cntr
+12582	//Siege_Supply_Box
+12608	//Splendid_Box2
 //12609
-//12612
-//12613
-//12614
-//12615
-//12616
-//12617
-//12618
-//12619
-//12620
-//12621
-//12623
-//12675
-//12676
-//12677
-//12678
-//12679
-//12680
-//12683
-//12690
-//12691
-//12692
-//12693
-//12694
-//12695
-//12698
-//12699
-//12700
-//12775
-
-// items from 2010-03-12 update
-601  // Wing_Of_Fly
-602  // Wing_Of_Butterfly
-603  // Old_Blue_Box
-604  // Branch_Of_Dead_Tree
-605  // Anodyne
-606  // Aloebera
-607  // Yggdrasilberry
-608  // Seed_Of_Yggdrasil
-609  // Amulet
-610  // Leaf_Of_Yggdrasil
-611  // Spectacles
-612  // Portable_Furnace
-613  // Iron_Hammer
-614  // Golden_Hammer
-615  // Oridecon_Hammer
-616  // Old_Card_Album
-617  // Old_Violet_Box
-618  // Worn_Out_Scroll
-619  // Unripe_Apple
-620  // Orange_Juice
-621  // Bitter_Herb
-622  // Rainbow_Carrot
-623  // Earthworm_The_Dude
-624  // Rotten_Fish
-625  // Lusty_Iron
-626  // Monster_Juice
-627  // Sweet_Milk
-628  // Well_Dried_Bone
-629  // Singing_Flower
-630  // Dew_Laden_Moss
-631  // Deadly_Noxious_Herb
-632  // Fatty_Chubby_Earthworm
-633  // Baked_Yam
-634  // Tropical_Banana
-635  // Horror_Of_Tribe
-636  // No_Recipient
-637  // Old_Broom
-638  // Silver_Knife_Of_Chaste
-639  // Armlet_Of_Obedience
-640  // Shining_Stone
-641  // Contracts_In_Shadow
-642  // Book_Of_Devil
-643  // Pet_Incubator
-644  // Gift_Box
-645  // Center_Potion
-656  // Awakening_Potion
-657  // Berserk_Potion
-658  // Union_Of_Tribe
-659  // Heart_Of_Her
-660  // Prohibition_Red_Candle
-661  // Sway_Apron
-662  // Inspector_Certificate
-663  // Korea_Rice_Cake
-664  // Gift_Box_1
-665  // Gift_Box_2
-666  // Gift_Box_3
-667  // Gift_Box_4
-668  // Handsei
-669  // Rice_Cake_Soup
-678  // Poison_Bottle
-679  // Gold_Pill
-681  // Memory_Of_Wedding
-682  // Realgar_Wine
-683  // Exorcize_Herb
-684  // Durian
-686  // Earth_Scroll_1_3
-687  // Earth_Scroll_1_5
-688  // Cold_Scroll_1_3
-689  // Cold_Scroll_1_5
-690  // Fire_Scroll_1_3
-691  // Fire_Scroll_1_5
-692  // Wind_Scroll_1_3
-693  // Wind_Scroll_1_5
-694  // Ghost_Scroll_1_3
-695  // Ghost_Scroll_1_5
-696  // Fire_Scroll_2_1
-697  // Fire_Scroll_2_5
-698  // Fire_Scroll_3_1
-699  // Fire_Scroll_3_5
-700  // Cold_Scroll_2_1
-12000  // Cold_Scroll_2_5
-12001  // Holy_Scroll_1_3
-12002  // Holy_Scroll_1_5
-12003  // Holy_Scroll_2_1
-12004  // Arrow_Container
-12005  // Iron_Arrow_Container
-12006  // Steel_Arrow_Container
-12007  // Ori_Arrow_Container
-12008  // Fire_Arrow_Container
-12009  // Silver_Arrow_Container
-12010  // Wind_Arrow_Container
-12011  // Stone_Arrow_Container
-12012  // Crystal_Arrow_Container
-12013  // Shadow_Arrow_Container
-12014  // Imma_Arrow_Container
-12015  // Rusty_Arrow_Container
-12016  // Speed_Up_Potion
-12017  // Slow_Down_Potion
-12018  // Fire_Cracker
-12020  // Water_Of_Darkness
-12027  // Giggling_Box
-12028  // Box_Of_Thunder
-12029  // Gloomy_Box
-12030  // Box_Of_Grudge
-12031  // Sleepy_Box
-12032  // Box_Of_Storm
-12033  // Box_Of_Sunlight
-12034  // Painting_Box
-12040  // Stone_Of_Intelligence_
-12041  // Str_Dish01
-12042  // Str_Dish02
-12043  // Str_Dish03
-12044  // Str_Dish04
-12045  // Str_Dish05
-12046  // Int_Dish01
-12047  // Int_Dish02
-12048  // Int_Dish03
-12049  // Int_Dish04
-12050  // Int_Dish05
-12051  // Vit_Dish01
-12052  // Vit_Dish02
-12053  // Vit_Dish03
-12054  // Vit_Dish04
-12055  // Vit_Dish05
-12056  // Agi_Dish01
-12057  // Agi_Dish02
-12058  // Agi_Dish03
-12059  // Agi_Dish04
-12060  // Agi_Dish05
-12061  // Dex_Dish01
-12062  // Dex_Dish02
-12063  // Dex_Dish03
-12064  // Dex_Dish04
-12065  // Dex_Dish05
-12066  // Luk_Dish01
-12067  // Luk_Dish02
-12068  // Luk_Dish03
-12069  // Luk_Dish04
-12070  // Luk_Dish05
-12071  // Str_Dish06
-12072  // Str_Dish07
-12073  // Str_Dish08
-12074  // Str_Dish09
-12075  // Str_Dish10
-12076  // Int_Dish06
-12077  // Int_Dish07
-12078  // Int_Dish08
-12079  // Int_Dish09
-12080  // Int_Dish10
-12081  // Vit_Dish06
-12082  // Vit_Dish07
-12083  // Vit_Dish08
-12084  // Vit_Dish09
-12085  // Vit_Dish10
-12086  // Agi_Dish06
-12087  // Agi_Dish07
-12088  // Agi_Dish08
-12089  // Agi_Dish09
-12090  // Agi_Dish10
-12091  // Dex_Dish06
-12092  // Dex_Dish07
-12093  // Dex_Dish08
-12094  // Dex_Dish09
-12095  // Dex_Dish10
-12096  // Luk_Dish06
-12097  // Luk_Dish07
-12098  // Luk_Dish08
-12099  // Luk_Dish09
-12100  // Luk_Dish10
-12101  // Citron
-12102  // Meat_Skewer
-12103  // Bloody_Dead_Branch
-12104  // Random_Quiver
-12105  // Set_Of_Taiming_Item
-12106  // Accessory_Box
-12107  // Wrapped_Mask
-12108  // Bundle_Of_Magic_Scroll
-12109  // Poring_Box
-12110  // First_Aid_Kit
-12111  // Food_Package
-12112  // Tropical_Sograt
-12113  // Vermilion_The_Beach
-12114  // Elemental_Fire
-12115  // Elemental_Water
-12116  // Elemental_Earth
-12117  // Elemental_Wind
-12118  // Resist_Fire
-12119  // Resist_Water
-12120  // Resist_Earth
-12121  // Resist_Wind
-12122  // Sesame_Pastry
-12123  // Honey_Pastry
-12124  // Rainbow_Cake
-12125  // Outdoor_Cooking_Kits
-12126  // Indoor_Cooking_Kits
-12127  // High_end_Cooking_Kits
-12128  // Imperial_Cooking_Kits
-12129  // Fantastic_Cooking_Kits
-12130  // Cookie_Bag
-12132  // Red_Bag
-12144  // Sphere_Case_Wind
-12145  // Sphere_Case_Darkness
-12146  // Sphere_Case_Poison
-12147  // Sphere_Case_Water
-12148  // Sphere_Case_Fire
-12149  // Bullet_Case
-12150  // Bullet_Case_Blood
-12151  // Bullet_Case_Silver
-12183  // Holy_Arrow_Quiver
-12184  // Mercenary_Red_Potion
-12185  // Mercenary_Blue_Potion
-12194  // Hometown_Gift
-12195  // Plain_Rice_Cake
-12196  // Hearty_Rice_Cake
-12197  // Salty_Rice_Cake
-12198  // Lucky_Rice_Cake
-12241  // M_Center_Potion
-12242  // M_Awakening_Potion
-12243  // M_Berserk_Potion
-12246  // Magic_Card_Album
-12260  // Cool_Summer_Outfit
-12290  // Mysterious_Can
-12291  // Mysterious_PET_Bottle
-12292  // Unripe_Fruit
-12293  // Dried_Yggdrasilberry
-12341  // Special_Alloy_Trap_Box
-12346  // Unripe_Acorn
-12347  // Acorn_Jelly
-12353  // Tiny_Waterbottle
-12358  // Fan_Of_Wind
-12359  // Very_Soft_Plant
-12360  // Very_Red_Juice
-12362  // Kuloren
-12364  // Staff_Of_Leader
-12365  // Charming_Lotus
-12366  // Gril_Doll
-12367  // Luxury_Whisky_Bottle
-12368  // Splendid_Mirror
-12369  // Coconut
-12371  // Magical_Lithography
-12372  // Hell_Contract
-12373  // Boy's_Naivety
-12374  // Flaming_Ice
-12376  // Mysterious_Can2
-12377  // Mysterious_PET_Bottle2
-12379  // Pope's_Cookie
-12383  // Vulcan_Bullet_Magazine
-12392  // RepairA
-12393  // RepairB
-12394  // RepairC
-12395  // Tantanmen
-12414  // Guarana_Candy
-12717  // Poison_Paralysis
-12718  // Poison_Leech
-12719  // Poison_Oblivion
-12720  // Poison_Contamination
-12721  // Poison_Numb
-12722  // Poison_Fever
-12723  // Poison_Laughing
-12724  // Poison_Fatigue
-12734  // Runstone_Quality
-12735  // Runstone_Ancient
-12736  // Runstone_Mystic
-12737  // Runstone_Ordinary
-12738  // Runstone_Rare
-506  // Green_Potion
-507  // Red_Herb
-508  // Yellow_Herb
-509  // White_Herb
-510  // Blue_Herb
-511  // Green_Herb
-512  // Apple
-513  // Banana
-514  // Grape
-515  // Carrot
-516  // Sweet_Potato
-517  // Meat
-518  // Honey
-519  // Milk
-520  // Leaflet_Of_Hinal
-521  // Leaflet_Of_Aloe
-522  // Fruit_Of_Mastela
-523  // Holy_Water
-525  // Panacea
-526  // Royal_Jelly
-528  // Monster's_Feed
-529  // Candy
-530  // Candy_Striper
-531  // Apple_Juice
-532  // Banana_Juice
-533  // Grape_Juice
-534  // Carrot_Juice
-535  // Pumpkin
-536  // Ice_Cream
-537  // Pet_Food
-538  // Well_Baked_Cookie
-539  // Piece_Of_Cake
-544  // Fish_Slice
-548  // Cheese
-549  // Nice_Sweet_Potato
-550  // Popped_Rice
-551  // Shusi
-553  // Bun
-564  // Rice_Ball
-566  // Tomyumkung
-567  // Prawn
-568  // Lemon
-569  // Novice_Potion
-570  // Lucky_Candy
-571  // Lucky_Candy_Cane
-572  // Lucky_Cookie
-574  // Egg
-576  // Prickly_Fruit
-577  // Grain
-578  // Strawberry
-579  // Delicious_Fish
-580  // Bread
-581  // Mushroom
-582  // Orange
-584  // Fish_Ball_Soup
-587  // Prickly_Fruit_
-591  // Caviar_Pancake
-592  // Jam_Pancake
-593  // Honey_Pancake
-594  // Sour_Cream_Pancake
-595  // Mushroom_Pancake
-11513  // Protect_Neck_Candy
-11515  // Coconut
-11516  // Acai_Fruit
-11517  // Puri_Potion
-701  // Ora_Ora
-702  // Animal_Blood
-703  // Hinalle
-704  // Aloe
-705  // Clover
-706  // Four_Leaf_Clover
-707  // Singing_Plant
-708  // Ment
-709  // Izidor
-710  // Illusion_Flower
-711  // Shoot
-712  // Flower
-713  // Empty_Bottle
-715  // Yellow_Gemstone
-716  // Red_Gemstone
-717  // Blue_Gemstone
-718  // Dark_Red_Jewel
-719  // Violet_Jewel
-720  // Skyblue_Jewel
-721  // Azure_Jewel
-722  // Scarlet_Jewel
-723  // Cardinal_Jewel
-724  // Cardinal_Jewel_
-725  // Red_Jewel
-726  // Blue_Jewel
-727  // White_Jewel
-728  // Golden_Jewel
-729  // Bluish_Green_Jewel
-730  // Crystal_Jewel
-731  // Crystal_Jewel_
-732  // Crystal_Jewel__
-733  // Crystal_Jewel___
-734  // Red_Frame
-735  // Blue_Porcelain
-736  // White_Platter
-737  // Black_Ladle
-738  // Pencil_Case
-739  // Rouge
-740  // Stuffed_Doll
-741  // Poring_Doll
-742  // Chonchon_Doll
-743  // Spore_Doll
-744  // Bunch_Of_Flowers
-745  // Wedding_Bouquet
-746  // Glass_Bead
-747  // Crystal_Mirror
-748  // Witherless_Rose
-749  // Frozen_Rose
-750  // Baphomet_Doll
-751  // Osiris_Doll
-752  // Grasshopper_Doll
-753  // Monkey_Doll
-754  // Raccoondog_Doll
-756  // Oridecon_Stone
-757  // Elunium_Stone
-901  // Danggie
-902  // Tree_Root
-903  // Reptile_Tongue
-904  // Scorpion's_Tail
-905  // Stem
-906  // Pointed_Scale
-907  // Resin
-908  // Spawn
-909  // Jellopy
-910  // Garlet
-911  // Scell
-912  // Zargon
-913  // Tooth_Of_Bat
-914  // Fluff
-915  // Chrysalis
-916  // Feather_Of_Birds
-917  // Talon
-918  // Sticky_Webfoot
-919  // Animal's_Skin
-920  // Claw_Of_Wolves
-921  // Mushroom_Spore
-922  // Orcish_Cuspid
-923  // Evil_Horn
-924  // Powder_Of_Butterfly
-925  // Bill_Of_Birds
-926  // Scale_Of_Snakes
-928  // Insect_Feeler
-929  // Immortal_Heart
-930  // Rotten_Bandage
-931  // Orcish_Voucher
-932  // Skel_Bone
-934  // Mementos
-935  // Shell
-936  // Scales_Shell
-937  // Posionous_Canine
-938  // Sticky_Mucus
-939  // Bee_Sting
-940  // Grasshopper's_Leg
-941  // Nose_Ring
-942  // Yoyo_Tail
-943  // Solid_Shell
-944  // Horseshoe
-945  // Raccoon_Leaf
-946  // Snail's_Shell
-947  // Horn
-948  // Bear's_Foot
-949  // Feather
-950  // Heart_Of_Mermaid
-951  // Fin
-952  // Cactus_Needle
-953  // Stone_Heart
-954  // Shining_Scales
-955  // Worm_Peelings
-956  // Gill
-957  // Decayed_Nail
-958  // Horrendous_Mouth
-959  // Rotten_Scale
-960  // Nipper
-961  // Conch
-962  // Tentacle
-963  // Sharp_Scale
-964  // Crap_Shell
-965  // Clam_Shell
-966  // Flesh_Of_Clam
-967  // Turtle_Shell
-968  // Voucher_Of_Orcish_Hero
-969  // Gold
-971  // Detrimindexta
-972  // Karvodailnirol
-973  // Counteragent
-974  // Mixture
-975  // Scarlet_Dyestuffs
-976  // Lemon_Dyestuffs
-978  // Cobaltblue_Dyestuffs
-979  // Darkgreen_Dyestuffs
-980  // Orange_Dyestuffs
-981  // Violet_Dyestuffs
-982  // White_Dyestuffs
-983  // Black_Dyestuffs
-984  // Oridecon
-985  // Elunium
-986  // Anvil
-987  // Oridecon_Anvil
-988  // Golden_Anvil
-989  // Emperium_Anvil
-990  // Boody_Red
-991  // Crystal_Blue
-992  // Wind_Of_Verdure
-993  // Yellow_Live
-994  // Flame_Heart
-995  // Mistic_Frozen
-996  // Rough_Wind
-997  // Great_Nature
-998  // Iron
-999  // Steel
-1000  // Star_Crumb
-1001  // Sparkling_Dust
-1002  // Iron_Ore
-1003  // Coal
-1004  // Patriotism_Marks
-1005  // Hammer_Of_Blacksmith
-1006  // Old_Magic_Book
-1007  // Penetration
-1008  // Frozen_Heart
-1009  // Sacred_Marks
-1010  // Phracon
-1011  // Emveretarcon
-1012  // Lizard_Scruff
-1013  // Colorful_Shell
-1014  // Jaws_Of_Ant
-1015  // Thin_N'_Long_Tongue
-1016  // Rat_Tail
-1017  // Moustache_Of_Mole
-1018  // Nail_Of_Mole
-1019  // Wooden_Block
-1020  // Long_Hair
-1021  // Dokkaebi_Horn
-1022  // Fox_Tail
-1023  // Fish_Tail
-1024  // Chinese_Ink
-1025  // Spiderweb
-1026  // Acorn
-1027  // Porcupine_Spike
-1028  // Wild_Boar's_Mane
-1029  // Tiger's_Skin
-1030  // Tiger_Footskin
-1031  // Limb_Of_Mantis
-1032  // Blossom_Of_Maneater
-1033  // Root_Of_Maneater
-1034  // Cobold_Hair
-1035  // Dragon_Canine
-1036  // Dragon_Scale
-1037  // Dragon_Train
-1038  // Petite_DiablOfs_Horn
-1039  // Petite_DiablOfs_Wing
-1040  // Elder_Pixie's_Beard
-1041  // Lantern
-1042  // Short_Leg
-1043  // Nail_Of_Orc
-1044  // Tooth_Of_
-1045  // Sacred_Masque
-1046  // Tweezer
-1047  // Head_Of_Medusa
-1048  // Slender_Snake
-1049  // Skirt_Of_Virgin
-1050  // Tendon
-1051  // Detonator
-1052  // Single_Cell
-1053  // Tooth_Of_Ancient_Fish
-1054  // Lip_Of_Ancient_Fish
-1055  // Earthworm_Peeling
-1056  // Grit
-1057  // Moth_Dust
-1058  // Wing_Of_Moth
-1059  // Transparent_Cloth
-1060  // Golden_Hair
-1061  // Starsand_Of_Witch
-1062  // Pumpkin_Head
-1063  // Sharpened_Cuspid
-1064  // Reins
-1065  // Booby_Trap
-1066  // Tree_Of_Archer_1
-1067  // Tree_Of_Archer_2
-1068  // Tree_Of_Archer_3
-1088  // Morocc_Potion
-1089  // Payon_Potion
-1092  // Empty_Cylinder
-1093  // Empty_Potion
-1094  // Short_Daenggie
-1095  // Needle_Of_Alarm
-1096  // Round_Shell
-1097  // Worn_Out_Page
-1098  // Manacles
-1099  // Worn_Out_Prison_Uniform
-6001  // Essence_Of_Fire
-6002  // Token_Of_Apostle
-6003  // Soul_Pendant
-6004  // Bapho_Doll
-6008  // Wood
-6010  // Pickaxe
-6020  // Fur
-6021  // Peaked_Hat
-6022  // Hard_Skin
-6023  // Mystic_Horn
-6032  // Horn_Of_Hilsrion
-6033  // Horn_Of_Tendrilion
-6073  // Dragon's_Mane
-6075  // Crystalized_Teardrop
-6086  // Withered_Flower
-6087  // Crystal_Of_Soul_01
-6088  // Crystal_Of_Soul_02
-6089  // Piece_Of_Darkness
-6090  // Purified_Bradium
-6091  // Dark_Red_Scale
-6095  // Flavored_Alcohol
-6096  // Fish_With_Blue_Back
-6097  // Pumpkin_Pie_
-6098  // Small_Snow_Flower
-6099  // Grilled_Rice_Cake
-6100  // Damp_Darkness
-6104  // Big_Cell
-6105  // Morning_Dew
-6106  // Well_Ripened_Berry
-6107  // Sunset_On_The_Rock
-6108  // Apple_Pudding
-6109  // Plant_Neutrient
-6110  // Vital_Flower
-6111  // Mystic_Stone
-6112  // Fresh_Plant
-6113  // Vital_Flower_
-6114  // Flame_Gemstone
-6115  // Bun_
-6120  // Face_Paint
-6123  // Surface_Paint
-6128  // Guillotine_Antidote
-6144  // Heartbroken_Tears
-6145  // Vulcan_Bullet
-6146  // Magic_Gear_Fuel
-6147  // Liquid_Condensed_Bullet
-6186  // Monkey_Wrench
-6189  // Magic_Book_FB
-6190  // Magic_Book_CB
-6191  // Magic_Book_LB
-6192  // Magic_Book_SG
-6193  // Magic_Book_LOV
-6194  // Magic_Book_MS
-6195  // Magic_Book_CM
-6196  // Magic_Book_TV
-6197  // Magic_Book_TS
-6198  // Magic_Book_JT
-6199  // Magic_Book_WB
-6200  // Magic_Book_HD
-6201  // Magic_Book_ES
-6202  // Magic_Book_ES_
-6203  // Magic_Book_CL
-6204  // Magic_Book_CR
-6205  // Magic_Book_DL
-6210  // Seed_Of_Thorny_Plant
-6211  // Bloodsuck_Plant_Seed
-6212  // Bomb_Mushroom_Spore
-6213  // Explosive_Powder
-6214  // Smokes_Powder
-6215  // Tear_Gas
-6216  // Oil_Bottle
-6217  // Mandragora_Flowerpot
-6223  // Carnium
-6224  // Bradium
-6244  // Dark_Powder
-6245  // Black_Powder
-6246  // Yellow_Powder
-6247  // White_Powder
-6248  // Chowder_Pot
-6249  // Savage_Meat
-6250  // Iron_Cooking_Skewer
-6251  // Black_Charcoal
-6252  // Wolf's_Blood
-6253  // Cold_Ice
-6254  // Seasoned_Tough_Meat
-6255  // Large_Pan
-6256  // Powdered_Ice
-6257  // Ice_Crystal
-6258  // Comodo_Tropical_Fruit
-6259  // Drosera_Feeler
-6260  // Petite_Tail
-6261  // Fine_Noodles
-6262  // Cold_Broth
-6263  // Coconut
-6264  // Melon
-6265  // Pineapple
-6279  // Apple_Bomb_Guidebook
-6280  // Pineapple_Bomb_Guidebook
-6281  // Coconut_Bomb_Guidebook
-6282  // Melon_Bomb_Guidebook
-6283  // Banana_Bomb_Guidebook
-6284  // Plant_Genetic_Cultivation_Guide
-6285  // Improved_Potion_Creation_Manual
-6297  // Empty_Potion_Bottle
-6321  // Rake_Helmet
-6322  // Antler_Helmet
-6323  // Two-Horn_Helmet
-6324  // One-Horn_Helmet
-6325  // White_Spider_Legs
-6326  // Queen_Scraba_Shell
-6360  // Scarlet_Point
-6361  // Indigo_Point
-6362  // Yellow_Wish_Point
-6363  // Lime_Green_Point
-7001  // Mould_Powder
-7002  // Ogre_Tooth
-7003  // Anolian_Skin
-7004  // Mud_Lump
-7005  // Skull
-7006  // Wing_Of_Red_Bat
-7007  // Claw_Of_Rat
-7008  // Stiff_Horn
-7009  // Glitter_Shell
-7010  // Tail_Of_Steel_Scorpion
-7011  // Claw_Of_Monkey
-7012  // Tough_Scalelike_Stem
-7013  // Coral_Reef
-7014  // Old_Portrait
-7015  // Bookclip_In_Memory
-7016  // Spoon_Stub
-7017  // Executioner's_Mitten
-7018  // Young_Twig
-7019  // Loki's_Whispers
-7020  // Mother's_Nightmare
-7021  // Foolishness_Of_Blind
-7022  // Old_Hilt
-7023  // Blade_Lost_In_Darkness
-7024  // Bloody_Edge
-7026  // Key_Of_Clock_Tower
-7027  // Underground_Key
-7030  // Claw_Of_Desert_Wolf
-7031  // Old_Frying_Pan
-7032  // Piece_Of_Egg_Shell
-7033  // Poison_Spore
-7034  // Red_Socks_With_Holes
-7035  // Matchstick
-7036  // Fang_Of_Garm
-7038  // Yarn
-7041  // Fine_Grit
-7043  // Fine_Sand
-7047  // Alice's_Apron
-7048  // Talon_Of_Griffin
-7049  // Stone
-7053  // Cyfar
-7054  // Brigan
-7055  // Animal_Pooopoo
-7056  // Payroll_Of_Kafra
-7057  // Gallar_Horn
-7058  // Gullraifnir
-7063  // Soft_Feather
-7064  // Dragon_Fly_Wing
-7065  // Sea_Otter_Leather
-7066  // Ice_Piece
-7067  // Stone_Piece
-7068  // Burn_Tree
-7069  // Broken_Armor_Piece
-7070  // Broken_Shell
-7071  // Tatters_Clothes
-7072  // Rust_Suriken
-7073  // Jewel_Of_Prayer
-7074  // Iron_Glove
-7075  // Iron_Maiden
-7076  // Mystery_Wheel
-7077  // Silver_Fancy
-7078  // Anger_Of_Valkurye
-7079  // Feather_Of_Angel
-7080  // Foot_Step_Of_Cat
-7081  // Beard_Of_Women
-7082  // Root_Of_Stone
-7083  // Soul_Of_Fish
-7084  // Saliva_Of_Bird
-7085  // Tendon_Of_Bear
-7086  // Symbol_Of_Sun
-7087  // Breath_Of_Soul
-7088  // Crystal_Of_Snow
-7089  // Indication_Of_Tempest
-7090  // Slilince_Wave
-7091  // Rough_Billows
-7092  // Air_Stream
-7093  // Wheel
-7094  // Mystery_Piece
-7095  // Broken_Steel_Piece
-7096  // Cold_Magma
-7097  // Burning_Heart
-7098  // Live_Coal
-7099  // Old_Magic_Circle
-7100  // Sharp_Leaf
-7101  // Peco_Wing_Feather
-7102  // Hideous_Dream
-7103  // Unknown_Liquid_Bottle
-7104  // Fake_Angel_Wing
-7105  // Fake_Angel_Loop
-7106  // Goat's_Horn
-7107  // Gaoat's_Skin
-7108  // Boroken_Shiled_Piece
-7109  // Shine_Spear_Blade
-7110  // Vroken_Sword
-7111  // Smooth_Paper
-7112  // Fright_Paper_Blade
-7113  // Broken_Pharaoh_Symbol
-7114  // Tutankhamen's_Mask
-7115  // Harpy's_Feather
-7116  // Harpy's_Claw
-7117  // Rent_Spell_Book
-7118  // Rent_Scroll
-7119  // Spawns
-7120  // Burning_Horse_Shoe
-7121  // Honey_Jar
-7122  // Hot_Hair
-7123  // Dragon's_Skin
-7124  // Sand_Lump
-7125  // Scropion's_Nipper
-7126  // Large_Jellopy
-7127  // Alcol_Create_Book
-7128  // FireBottle_Create_Book
-7129  // Acid_Create_Book
-7130  // Plant_Create_Book
-7131  // Mine_Create_Book
-7132  // Coating_Create_Book
-7133  // Slim_Potion_Create_Book
-7134  // Medicine_Bowl
-7140  // Seed_Of_Life
-7141  // Yggdrasilberry_Dew
-7143  // Life_Force_Pot
-7144  // Normal_Potion_Book
-7147  // Jasmin
-7149  // Yellow_Plate
-7150  // Bamboo_Cut
-7151  // Oil_Paper
-7152  // Glossy_Hair
-7153  // Old_Japaness_Clothes
-7154  // Poison_Powder
-7155  // Poison_Toad's_Skin
-7156  // Broken_Shuriken
-7157  // Black_Mask
-7158  // Broken_Wine_Vessel
-7159  // Tengu's_Nose
-7160  // Lord's_Passable_Ticket
-7161  // Black_Bear's_Skin
-7162  // Cloud_Piece
-7163  // Sharp_Feeler
-7164  // Hard_Peach
-7165  // Limpid_Celestial_Robe
-7166  // Soft_Silk_Cloth
-7167  // Mystery_Iron_Bit
-7168  // Great_Wing
-7169  // Taegeuk_Plate
-7170  // Tuxedo
-7171  // Leopard_Skin
-7172  // Leopard_Talon
-7174  // Packing_Ribbon
-7175  // Packing_Paper
-7182  // Cacao
-7186  // Thin_Stem
-7187  // Festival_Mask
-7188  // Browny_Root
-7189  // Heart_Of_Tree
-7190  // Solid_Peeling
-7191  // Lamplight
-7192  // Blade_Of_Pinwheel
-7193  // Germinating_Sprout
-7194  // Soft_Leaf
-7195  // Air_Rifle
-7196  // Shoulder_Protection
-7197  // Tough_Vines
-7198  // Great_Leaf
-7199  // Coupon
-7200  // Flexible_String
-7201  // Log
-7202  // Beetle_Nipper
-7203  // Solid_Twig
-7204  // Gunpowder
-7205  // Piece_Of_Black_Cloth
-7206  // Black_Kitty_Doll
-7207  // Old_Manteau
-7208  // Rusty_Cleaver
-7209  // Dullahan's_Helm
-7210  // Dullahan_Armor
-7211  // Rojerta_Piece
-7212  // Hanging_Doll
-7213  // Needle_Pouch
-7214  // Bat_Cage
-7215  // Broken_Needle
-7216  // Red_Scarf
-7217  // Spool
-7218  // Rotten_Rope
-7219  // Striped_Socks
-7220  // Ectoplasm
-7221  // Tangled_Chain
-7222  // Tree_Knot
-7223  // Distorted_Portrait
-7225  // Pumpkin_Bucket
-7226  // Pill
-7262  // Fan
-7263  // Cat_Eyed_Stone
-7264  // Dried_Sand
-7265  // Dragon_Horn
-7266  // Dragon_Fang
-7267  // Tiger_Skin_Panties
-7268  // Little_Blacky_Ghost
-7269  // Bib
-7270  // Milk_Bottle
-7277  // Munak_Doll
-7286  // Chilli
-7289  // Olivine
-7290  // Phlogopite
-7291  // Agate
-7292  // Muscovite
-7293  // Rose_Quartz
-7294  // Turquoise
-7295  // Citrine
-7296  // Pyroxene
-7297  // Biotite
-7298  // Leaf_Clothes
-7299  // Bamboo_Basket
-7300  // Gemstone
-7301  // Sword_Accessory
-7303  // Bag_Of_Rice
-7312  // Jubilee
-7315  // Dark_Crystal_Fragment
-7316  // Long_Limb
-7317  // Screw
-7318  // Old_Pick
-7319  // Old_Steel_Plate
-7320  // Air_Pollutant
-7321  // Fragment_Of_Crystal
-7322  // Poisonous_Gas
-7323  // Battered_Kettle
-7325  // Tube
-7326  // Fluorescent_Liquid
-7327  // Headlamp
-7340  // Will_Of_Darkness
-7345  // Armlet_Of_Prisoner
-7352  // Transparent_Plate01
-7353  // Transparent_Plate02
-7354  // Transparent_Plate03
-7355  // Transparent_Plate04
-7356  // Piece_Of_Crest1
-7357  // Piece_Of_Crest2
-7358  // Piece_Of_Crest3
-7359  // Piece_Of_Crest4
-7419  // Embryo_HandBook
-7433  // Scroll
-7434  // Elemental_Potion_Book
-7435  // Golden_Bracelet
-7436  // Piece_Of_Memory_Green
-7437  // Piece_Of_Memory_Purple
-7438  // Piece_Of_Memory_Blue
-7439  // Piece_Of_Memory_Red
-7440  // Red_Feather
-7441  // Blue_Feather
-7442  // Cursed_Seal
-7443  // Tri_Headed_Dragon_Head
-7444  // Treasure_Box
-7445  // Dragonball_Green
-7446  // Dragonball_Blue
-7447  // Dragonball_Red
-7448  // Dragonball_Yellow
-7449  // Bloody_Page
-7450  // Piece_Of_Bone_Armor
-7451  // Scale_Of_Red_Dragon
-7452  // Yellow_Spice
-7453  // Sweet_Sauce
-7454  // Plain_Sauce
-7455  // Hot_Sauce
-7456  // Red_Spice
-7457  // Cooking_Oil
-7472  // Cookbook01
-7473  // Cookbook02
-7474  // Cookbook03
-7475  // Cookbook04
-7476  // Cookbook05
-7477  // Cookbook06
-7478  // Cookbook07
-7479  // Cookbook08
-7480  // Cookbook09
-7481  // Cookbook10
-7482  // Pot
-7507  // Sturdy_Iron_Piece
-7510  // Valhalla_Flower
-7511  // Rune_Of_Darkness
-7512  // Burnt_Parts
-7513  // Pocket_Watch
-7521  // Flame_Stone
-7522  // Ice_Stone
-7523  // Wind_Stone
-7524  // Shadow_Orb
-7561  // Ice_Heart
-7562  // Ice_Scale
-7563  // Bloody_Rune
-7564  // Rotten_Meat
-7565  // Sticky_Poison
-7566  // Will_Of_Darkness_
-7567  // Suspicious_Hat
-7568  // White_Mask
-7574  // Ice_Particle
-7751  // Old_White_Cloth
-7752  // Clattering_Skull
-7753  // Broken_Farming_Utensil
-7754  // Broken_Crown
-7830  // Goddess_Tear
-7831  // Valkyrie_Token
-7832  // Brynhild_Armor_Piece
-7833  // Hero_Remains
-7834  // Andvari_Ring
-7835  // Dusk_Glow
-7836  // Dawn_Essence
-7837  // Cold_Moonlight
-7838  // Hazy_Starlight
-7931  // Poison_Kit
-7932  // Poison_Herb_Nerium
-7933  // Poison_Herb_Rantana
-7934  // Poison_Herb_Makulata
-7935  // Poison_Herb_Seratum
-7936  // Poison_Herb_Scopolia
-7937  // Poison_Herb_Amoena
-7938  // Light_Granule
-7939  // Elder_Branch
-7940  // Special_Alloy_Trap
-11000  // Prontera_Book_01
-11001  // Adventure_Story01
-11002  // Great_Chef_Orleans01
-11003  // Legend_Of_Kafra01
-11004  // Mercenary_Rebellion
-11005  // Tyrant_Schmidt
-11006  // Blood_Flower01
-11007  // Blood_Flower02
-11008  // Barmund
-11009  // Adventure_Story02
-11020  // Japan_Book1
-11021  // Japan_Book2
-11022  // Mix_Cooking_Ingredient_Book_1
-11023  // Vitality_Boost_Research_Book
-11024  // Energy_Drink_Formula
+12612	//Old_Coin_Pocket
+12613	//High_Coin_Pocket
+12614	//Mid_Coin_Pocket
+12615	//Low_Coin_Pocket
+12616	//Sgrade_Pocket
+12617	//Agrade_Pocket
+12618	//Bgrade_Pocket
+12619	//Cgrade_Pocket
+12620	//Dgrade_Pocket
+12621	//Egrade_Pocket
+12623	//High_Weapon_Box
+12675	//Sg_Weapon_Supply_Box
+12676	//Sg_Violet_Potion_Box
+12677	//Siege_Arrow_Quiver_S
+12678	//Siege_Arrow_Quiver_A
+12679	//Sg_White_Potion_Box
+12680	//Sg_Blue_Potion_Box
+12683	//Sg_Vi_Potion_Box200
+12690	//Old_C_Album_Helm
+12691	//Old_C_Album_Armor
+12692	//Old_C_Album_Shield
+12693	//Old_C_Album_Garment
+12694	//Old_C_Album_Shoes
+12695	//Old_C_Album_Acc
+12698	//Old_C_Album_Weapon
+12699	//Tikbalang_Belt
+12700	//Insideout_Shirt
+12775	//Ancient_Spirit_Agimat
+//--- 2010 / 03 / 12
+601	//Wing_Of_Fly
+602	//Wing_Of_Butterfly
+603	//Old_Blue_Box
+604	//Branch_Of_Dead_Tree
+605	//Anodyne
+606	//Aloebera
+607	//Yggdrasilberry
+608	//Seed_Of_Yggdrasil
+609	//Amulet
+610	//Leaf_Of_Yggdrasil
+611	//Spectacles
+612	//Portable_Furnace
+613	//Iron_Hammer
+614	//Golden_Hammer
+615	//Oridecon_Hammer
+616	//Old_Card_Album
+617	//Old_Violet_Box
+618	//Worn_Out_Scroll
+619	//Unripe_Apple
+620	//Orange_Juice
+621	//Bitter_Herb
+622	//Rainbow_Carrot
+623	//Earthworm_The_Dude
+624	//Rotten_Fish
+625	//Lusty_Iron
+626	//Monster_Juice
+627	//Sweet_Milk
+628	//Well_Dried_Bone
+629	//Singing_Flower
+630	//Dew_Laden_Moss
+631	//Deadly_Noxious_Herb
+632	//Fatty_Chubby_Earthworm
+633	//Baked_Yam
+634	//Tropical_Banana
+635	//Horror_Of_Tribe
+636	//No_Recipient
+637	//Old_Broom
+638	//Silver_Knife_Of_Chaste
+639	//Armlet_Of_Obedience
+640	//Shining_Stone
+641	//Contracts_In_Shadow
+642	//Book_Of_Devil
+643	//Pet_Incubator
+644	//Gift_Box
+645	//Center_Potion
+656	//Awakening_Potion
+657	//Berserk_Potion
+658	//Union_Of_Tribe
+659	//Heart_Of_Her
+660	//Prohibition_Red_Candle
+661	//Sway_Apron
+662	//Inspector_Certificate
+663	//Korea_Rice_Cake
+664	//Gift_Box_1
+665	//Gift_Box_2
+666	//Gift_Box_3
+667	//Gift_Box_4
+668	//Handsei
+669	//Rice_Cake_Soup
+678	//Poison_Bottle
+679	//Gold_Pill
+681	//Memory_Of_Wedding
+682	//Realgar_Wine
+683	//Exorcize_Herb
+684	//Durian
+686	//Earth_Scroll_1_3
+687	//Earth_Scroll_1_5
+688	//Cold_Scroll_1_3
+689	//Cold_Scroll_1_5
+690	//Fire_Scroll_1_3
+691	//Fire_Scroll_1_5
+692	//Wind_Scroll_1_3
+693	//Wind_Scroll_1_5
+694	//Ghost_Scroll_1_3
+695	//Ghost_Scroll_1_5
+696	//Fire_Scroll_2_1
+697	//Fire_Scroll_2_5
+698	//Fire_Scroll_3_1
+699	//Fire_Scroll_3_5
+700	//Cold_Scroll_2_1
+12000	//Cold_Scroll_2_5
+12001	//Holy_Scroll_1_3
+12002	//Holy_Scroll_1_5
+12003	//Holy_Scroll_2_1
+12004	//Arrow_Container
+12005	//Iron_Arrow_Container
+12006	//Steel_Arrow_Container
+12007	//Ori_Arrow_Container
+12008	//Fire_Arrow_Container
+12009	//Silver_Arrow_Container
+12010	//Wind_Arrow_Container
+12011	//Stone_Arrow_Container
+12012	//Crystal_Arrow_Container
+12013	//Shadow_Arrow_Container
+12014	//Imma_Arrow_Container
+12015	//Rusty_Arrow_Container
+12016	//Speed_Up_Potion
+12017	//Slow_Down_Potion
+12018	//Fire_Cracker
+12020	//Water_Of_Darkness
+12027	//Giggling_Box
+12028	//Box_Of_Thunder
+12029	//Gloomy_Box
+12030	//Box_Of_Grudge
+12031	//Sleepy_Box
+12032	//Box_Of_Storm
+12033	//Box_Of_Sunlight
+12034	//Painting_Box
+12040	//Stone_Of_Intelligence_
+12041	//Str_Dish01
+12042	//Str_Dish02
+12043	//Str_Dish03
+12044	//Str_Dish04
+12045	//Str_Dish05
+12046	//Int_Dish01
+12047	//Int_Dish02
+12048	//Int_Dish03
+12049	//Int_Dish04
+12050	//Int_Dish05
+12051	//Vit_Dish01
+12052	//Vit_Dish02
+12053	//Vit_Dish03
+12054	//Vit_Dish04
+12055	//Vit_Dish05
+12056	//Agi_Dish01
+12057	//Agi_Dish02
+12058	//Agi_Dish03
+12059	//Agi_Dish04
+12060	//Agi_Dish05
+12061	//Dex_Dish01
+12062	//Dex_Dish02
+12063	//Dex_Dish03
+12064	//Dex_Dish04
+12065	//Dex_Dish05
+12066	//Luk_Dish01
+12067	//Luk_Dish02
+12068	//Luk_Dish03
+12069	//Luk_Dish04
+12070	//Luk_Dish05
+12071	//Str_Dish06
+12072	//Str_Dish07
+12073	//Str_Dish08
+12074	//Str_Dish09
+12075	//Str_Dish10
+12076	//Int_Dish06
+12077	//Int_Dish07
+12078	//Int_Dish08
+12079	//Int_Dish09
+12080	//Int_Dish10
+12081	//Vit_Dish06
+12082	//Vit_Dish07
+12083	//Vit_Dish08
+12084	//Vit_Dish09
+12085	//Vit_Dish10
+12086	//Agi_Dish06
+12087	//Agi_Dish07
+12088	//Agi_Dish08
+12089	//Agi_Dish09
+12090	//Agi_Dish10
+12091	//Dex_Dish06
+12092	//Dex_Dish07
+12093	//Dex_Dish08
+12094	//Dex_Dish09
+12095	//Dex_Dish10
+12096	//Luk_Dish06
+12097	//Luk_Dish07
+12098	//Luk_Dish08
+12099	//Luk_Dish09
+12100	//Luk_Dish10
+12101	//Citron
+12102	//Meat_Skewer
+12103	//Bloody_Dead_Branch
+12104	//Random_Quiver
+12105	//Set_Of_Taiming_Item
+12106	//Accessory_Box
+12107	//Wrapped_Mask
+12108	//Bundle_Of_Magic_Scroll
+12109	//Poring_Box
+12110	//First_Aid_Kit
+12111	//Food_Package
+12112	//Tropical_Sograt
+12113	//Vermilion_The_Beach
+12114	//Elemental_Fire
+12115	//Elemental_Water
+12116	//Elemental_Earth
+12117	//Elemental_Wind
+12118	//Resist_Fire
+12119	//Resist_Water
+12120	//Resist_Earth
+12121	//Resist_Wind
+12122	//Sesame_Pastry
+12123	//Honey_Pastry
+12124	//Rainbow_Cake
+12125	//Outdoor_Cooking_Kits
+12126	//Indoor_Cooking_Kits
+12127	//High_end_Cooking_Kits
+12128	//Imperial_Cooking_Kits
+12129	//Fantastic_Cooking_Kits
+12130	//Cookie_Bag
+12132	//Red_Bag
+12144	//Sphere_Case_Wind
+12145	//Sphere_Case_Darkness
+12146	//Sphere_Case_Poison
+12147	//Sphere_Case_Water
+12148	//Sphere_Case_Fire
+12149	//Bullet_Case
+12150	//Bullet_Case_Blood
+12151	//Bullet_Case_Silver
+12183	//Holy_Arrow_Quiver
+12184	//Mercenary_Red_Potion
+12185	//Mercenary_Blue_Potion
+12194	//Hometown_Gift
+12195	//Plain_Rice_Cake
+12196	//Hearty_Rice_Cake
+12197	//Salty_Rice_Cake
+12198	//Lucky_Rice_Cake
+12241	//M_Center_Potion
+12242	//M_Awakening_Potion
+12243	//M_Berserk_Potion
+12246	//Magic_Card_Album
+12260	//Cool_Summer_Outfit
+12290	//Mysterious_Can
+12291	//Mysterious_PET_Bottle
+12292	//Unripe_Fruit
+12293	//Dried_Yggdrasilberry
+12341	//Special_Alloy_Trap_Box
+12346	//Unripe_Acorn
+12347	//Acorn_Jelly
+12353	//Tiny_Waterbottle
+12358	//Fan_Of_Wind
+12359	//Very_Soft_Plant
+12360	//Very_Red_Juice
+12362	//Kuloren
+12364	//Staff_Of_Leader
+12365	//Charming_Lotus
+12366	//Gril_Doll
+12367	//Luxury_Whisky_Bottle
+12368	//Splendid_Mirror
+12369	//Oilpalm_Coconut
+12371	//Magical_Lithography
+12372	//Hell_Contract
+12373	//Boy's_Naivety
+12374	//Flaming_Ice
+12376	//Mysterious_Can2
+12377	//Mysterious_PET_Bottle2
+12379	//Pope's_Cookie
+12383	//Vulcan_Bullet_Magazine
+12392	//Repair_A
+12393	//Repair_B
+12394	//Repair_C
+12395	//Tantanmen
+12414	//Guarana_Candy
+12717	//Poison_Paralysis
+12718	//Poison_Leech
+12719	//Poison_Oblivion
+12720	//Poison_Disheart
+12721	//Poison_Numb
+12722	//Poison_Fever
+12723	//Poison_Laughing
+12724	//Poison_Fatigue
+12734	//Runstone_Quality
+12735	//Runstone_Ancient
+12736	//Runstone_Mystic
+12737	//Runstone_Ordinary
+12738	//Runstone_Rare
+506	//Green_Potion
+507	//Red_Herb
+508	//Yellow_Herb
+509	//White_Herb
+510	//Blue_Herb
+511	//Green_Herb
+512	//Apple
+513	//Banana
+514	//Grape
+515	//Carrot
+516	//Sweet_Potato
+517	//Meat
+518	//Honey
+519	//Milk
+520	//Leaflet_Of_Hinal
+521	//Leaflet_Of_Aloe
+522	//Fruit_Of_Mastela
+523	//Holy_Water
+525	//Panacea
+526	//Royal_Jelly
+528	//Monster's_Feed
+529	//Candy
+530	//Candy_Striper
+531	//Apple_Juice
+532	//Banana_Juice
+533	//Grape_Juice
+534	//Carrot_Juice
+535	//Pumpkin
+536	//Ice_Cream
+537	//Pet_Food
+538	//Well_Baked_Cookie
+539	//Piece_Of_Cake
+544	//Fish_Slice
+548	//Cheese
+549	//Nice_Sweet_Potato
+550	//Popped_Rice
+551	//Shusi
+553	//Bun
+564	//Rice_Ball
+566	//Tomyumkung
+567	//Prawn
+568	//Lemon
+569	//Novice_Potion
+570	//Lucky_Candy
+571	//Lucky_Candy_Cane
+572	//Lucky_Cookie
+574	//Egg
+576	//Prickly_Fruit
+577	//Grain
+578	//Strawberry
+579	//Delicious_Fish
+580	//Bread
+581	//Mushroom
+582	//Orange
+584	//Fish_Ball_Soup
+587	//Prickly_Fruit_
+591	//Caviar_Pancake
+592	//Jam_Pancake
+593	//Honey_Pancake
+594	//Sour_Cream_Pancake
+595	//Mushroom_Pancake
+11513	//Protect_Neck_Candy
+11515	//Coconut
+11516	//Asai_Fruit
+11517	//Puri_Potion
+701	//Ora_Ora
+702	//Animal_Blood
+703	//Hinalle
+704	//Aloe
+705	//Clover
+706	//Four_Leaf_Clover
+707	//Singing_Plant
+708	//Ment
+709	//Izidor
+710	//Illusion_Flower
+711	//Shoot
+712	//Flower
+713	//Empty_Bottle
+715	//Yellow_Gemstone
+716	//Red_Gemstone
+717	//Blue_Gemstone
+718	//Dark_Red_Jewel
+719	//Violet_Jewel
+720	//Skyblue_Jewel
+721	//Azure_Jewel
+722	//Scarlet_Jewel
+723	//Cardinal_Jewel
+724	//Cardinal_Jewel_
+725	//Red_Jewel
+726	//Blue_Jewel
+727	//White_Jewel
+728	//Golden_Jewel
+729	//Bluish_Green_Jewel
+730	//Crystal_Jewel
+731	//Crystal_Jewel_
+732	//Crystal_Jewel__
+733	//Crystal_Jewel___
+734	//Red_Frame
+735	//Blue_Porcelain
+736	//White_Platter
+737	//Black_Ladle
+738	//Pencil_Case
+739	//Rouge
+740	//Stuffed_Doll
+741	//Poring_Doll
+742	//Chonchon_Doll
+743	//Spore_Doll
+744	//Bunch_Of_Flowers
+745	//Wedding_Bouquet
+746	//Glass_Bead
+747	//Crystal_Mirror
+748	//Witherless_Rose
+749	//Frozen_Rose
+750	//Baphomet_Doll
+751	//Osiris_Doll
+752	//Grasshopper_Doll
+753	//Monkey_Doll
+754	//Raccoondog_Doll
+756	//Oridecon_Stone
+757	//Elunium_Stone
+901	//Danggie
+902	//Tree_Root
+903	//Reptile_Tongue
+904	//Scorpion's_Tail
+905	//Stem
+906	//Pointed_Scale
+907	//Resin
+908	//Spawn
+909	//Jellopy
+910	//Garlet
+911	//Scell
+912	//Zargon
+913	//Tooth_Of_Bat
+914	//Fluff
+915	//Chrysalis
+916	//Feather_Of_Birds
+917	//Talon
+918	//Sticky_Webfoot
+919	//Animal's_Skin
+920	//Claw_Of_Wolves
+921	//Mushroom_Spore
+922	//Orcish_Cuspid
+923	//Evil_Horn
+924	//Powder_Of_Butterfly
+925	//Bill_Of_Birds
+926	//Scale_Of_Snakes
+928	//Insect_Feeler
+929	//Immortal_Heart
+930	//Rotten_Bandage
+931	//Orcish_Voucher
+932	//Skel_Bone
+934	//Mementos
+935	//Shell
+936	//Scales_Shell
+937	//Posionous_Canine
+938	//Sticky_Mucus
+939	//Bee_Sting
+940	//Grasshopper's_Leg
+941	//Nose_Ring
+942	//Yoyo_Tail
+943	//Solid_Shell
+944	//Horseshoe
+945	//Raccoon_Leaf
+946	//Snail's_Shell
+947	//Horn
+948	//Bear's_Foot
+949	//Feather
+950	//Heart_Of_Mermaid
+951	//Fin
+952	//Cactus_Needle
+953	//Stone_Heart
+954	//Shining_Scales
+955	//Worm_Peelings
+956	//Gill
+957	//Decayed_Nail
+958	//Horrendous_Mouth
+959	//Rotten_Scale
+960	//Nipper
+961	//Conch
+962	//Tentacle
+963	//Sharp_Scale
+964	//Crap_Shell
+965	//Clam_Shell
+966	//Flesh_Of_Clam
+967	//Turtle_Shell
+968	//Voucher_Of_Orcish_Hero
+969	//Gold
+971	//Detrimindexta
+972	//Karvodailnirol
+973	//Counteragent
+974	//Mixture
+975	//Scarlet_Dyestuffs
+976	//Lemon_Dyestuffs
+978	//Cobaltblue_Dyestuffs
+979	//Darkgreen_Dyestuffs
+980	//Orange_Dyestuffs
+981	//Violet_Dyestuffs
+982	//White_Dyestuffs
+983	//Black_Dyestuffs
+984	//Oridecon
+985	//Elunium
+986	//Anvil
+987	//Oridecon_Anvil
+988	//Golden_Anvil
+989	//Emperium_Anvil
+990	//Boody_Red
+991	//Crystal_Blue
+992	//Wind_Of_Verdure
+993	//Yellow_Live
+994	//Flame_Heart
+995	//Mistic_Frozen
+996	//Rough_Wind
+997	//Great_Nature
+998	//Iron
+999	//Steel
+1000	//Star_Crumb
+1001	//Sparkling_Dust
+1002	//Iron_Ore
+1003	//Coal
+1004	//Patriotism_Marks
+1005	//Hammer_Of_Blacksmith
+1006	//Old_Magic_Book
+1007	//Penetration
+1008	//Frozen_Heart
+1009	//Sacred_Marks
+1010	//Phracon
+1011	//Emveretarcon
+1012	//Lizard_Scruff
+1013	//Colorful_Shell
+1014	//Jaws_Of_Ant
+1015	//Thin_N'_Long_Tongue
+1016	//Rat_Tail
+1017	//Moustache_Of_Mole
+1018	//Nail_Of_Mole
+1019	//Wooden_Block
+1020	//Long_Hair
+1021	//Dokkaebi_Horn
+1022	//Fox_Tail
+1023	//Fish_Tail
+1024	//Chinese_Ink
+1025	//Spiderweb
+1026	//Acorn
+1027	//Porcupine_Spike
+1028	//Wild_Boar's_Mane
+1029	//Tiger's_Skin
+1030	//Tiger_Footskin
+1031	//Limb_Of_Mantis
+1032	//Blossom_Of_Maneater
+1033	//Root_Of_Maneater
+1034	//Cobold_Hair
+1035	//Dragon_Canine
+1036	//Dragon_Scale
+1037	//Dragon_Train
+1038	//Petite_DiablOfs_Horn
+1039	//Petite_DiablOfs_Wing
+1040	//Elder_Pixie's_Beard
+1041	//Lantern
+1042	//Short_Leg
+1043	//Nail_Of_Orc
+1044	//Tooth_Of_
+1045	//Sacred_Masque
+1046	//Tweezer
+1047	//Head_Of_Medusa
+1048	//Slender_Snake
+1049	//Skirt_Of_Virgin
+1050	//Tendon
+1051	//Detonator
+1052	//Single_Cell
+1053	//Tooth_Of_Ancient_Fish
+1054	//Lip_Of_Ancient_Fish
+1055	//Earthworm_Peeling
+1056	//Grit
+1057	//Moth_Dust
+1058	//Wing_Of_Moth
+1059	//Transparent_Cloth
+1060	//Golden_Hair
+1061	//Starsand_Of_Witch
+1062	//Pumpkin_Head
+1063	//Sharpened_Cuspid
+1064	//Reins
+1065	//Booby_Trap
+1066	//Tree_Of_Archer_1
+1067	//Tree_Of_Archer_2
+1068	//Tree_Of_Archer_3
+1088	//Morocc_Potion
+1089	//Payon_Potion
+1092	//Empty_Cylinder
+1093	//Empty_Potion
+1094	//Short_Daenggie
+1095	//Needle_Of_Alarm
+1096	//Round_Shell
+1097	//Worn_Out_Page
+1098	//Manacles
+1099	//Worn_Out_Prison_Uniform
+6001	//Essence_Of_Fire
+6002	//Token_Of_Apostle
+6003	//Soul_Pendant
+6004	//Bapho_Doll
+6008	//Wood
+6010	//Pickaxe
+6020	//Fur
+6021	//Peaked_Hat
+6022	//Hard_Skin
+6023	//Mystic_Horn
+6032	//Horn_Of_Hilsrion
+6033	//Horn_Of_Tendrilion
+6073	//Dragon's_Mane
+6075	//Crystalized_Teardrop
+6086	//Withered_Flower
+6087	//Crystal_Of_Soul_01
+6088	//Crystal_Of_Soul_02
+6089	//Piece_Of_Darkness
+6090	//Purified_Bradium
+6091	//Dark_Red_Scale
+6095	//Flavored_Alcohol
+6096	//Fish_With_Blue_Back
+6097	//Pumpkin_Pie_
+6098	//Small_Snow_Flower
+6099	//Grilled_Rice_Cake
+6100	//Damp_Darkness
+6104	//Big_Cell
+6105	//Morning_Dew
+6106	//Well_Ripened_Berry
+6107	//Sunset_On_The_Rock
+6108	//Apple_Pudding
+6109	//Plant_Neutrient
+6110	//Vital_Flower
+6111	//Mystic_Stone
+6112	//Fresh_Plant
+6113	//Vital_Flower_
+6114	//Flame_Gemstone
+6115	//Bun_
+6120	//Face_Paint
+6123	//Surface_Paint
+6128	//Guillotine_Antidote
+6144	//Heartbroken_Tears
+6145	//Vulcan_Bullet
+6146	//Magic_Gear_Fuel
+6147	//Liquid_Condensed_Bullet
+6186	//Monkey_Wrench
+6189	//Magic_Book_FB
+6190	//Magic_Book_CB
+6191	//Magic_Book_LB
+6192	//Magic_Book_SG
+6193	//Magic_Book_LOV
+6194	//Magic_Book_MS
+6195	//Magic_Book_CM
+6196	//Magic_Book_TV
+6197	//Magic_Book_TS
+6198	//Magic_Book_JT
+6199	//Magic_Book_WB
+6200	//Magic_Book_HD
+6201	//Magic_Book_ES
+6202	//Magic_Book_ES_
+6203	//Magic_Book_CL
+6204	//Magic_Book_CR
+6205	//Magic_Book_DL
+6210	//Seed_Of_Horny_Plant
+6211	//Bloodsuck_Plant_Seed
+6212	//Bomb_Mushroom_Spore
+6213	//Explosive_Powder
+6214	//Smoke_Powder
+6215	//Tear_Gas
+6216	//Oil_Bottle
+6217	//Mandragora_Flowerpot
+6223	//Carnium
+6224	//Bradium
+6244	//Gun_Powder
+6245	//Black_Powder
+6246	//Yellow_Powder
+6247	//White_Powder
+6248	//Melange_Pot
+6249	//Savage_Meat
+6250	//Cooking_Skewer
+6251	//Black_Charcoal
+6252	//Wolf_Blood
+6253	//Cold_Ice
+6254	//Beef_Head_Meat
+6255	//Large_Cookpot
+6256	//Ice_Fragment
+6257	//Ice_Crystal
+6258	//Comodo_Tropic_Fruit
+6259	//Drocera_Tentacle
+6260	//Petti_Tail
+6261	//Fine_Noodle
+6262	//Cool_Gravy
+6263	//Coconut_Fruit
+6264	//Melon
+6265	//Pineapple
+6279	//Apple_Bomb_CB
+6280	//Pinepple_Bomb_CB
+6281	//Coconut_Bomb_CB
+6282	//Melon_Bomb_CB
+6283	//Banana_Bomb_CB
+6284	//Plant_Genetic_Grow
+6285	//Quality_Potion_Book
+6297	//Bottle_To_Throw
+6321	//Rakehorn_Helm
+6322	//Antler_Helm
+6323	//Twinhorn_Helm
+6324	//Singlehorn_Helm
+6325	//White_Spider_Limb
+6326	//Queen_Wing_Piece
+6360	//Scarlet_Pts
+6361	//Indigo_Pts
+6362	//Yellow_Wish_Pts
+6363	//Lime_Green_Pts
+7001	//Mould_Powder
+7002	//Ogre_Tooth
+7003	//Anolian_Skin
+7004	//Mud_Lump
+7005	//Skull
+7006	//Wing_Of_Red_Bat
+7007	//Claw_Of_Rat
+7008	//Stiff_Horn
+7009	//Glitter_Shell
+7010	//Tail_Of_Steel_Scorpion
+7011	//Claw_Of_Monkey
+7012	//Tough_Scalelike_Stem
+7013	//Coral_Reef
+7014	//Old_Portrait
+7015	//Bookclip_In_Memory
+7016	//Spoon_Stub
+7017	//Executioner's_Mitten
+7018	//Young_Twig
+7019	//Loki's_Whispers
+7020	//Mother's_Nightmare
+7021	//Foolishness_Of_Blind
+7022	//Old_Hilt
+7023	//Blade_Lost_In_Darkness
+7024	//Bloody_Edge
+7026	//Key_Of_Clock_Tower
+7027	//Underground_Key
+7030	//Claw_Of_Desert_Wolf
+7031	//Old_Frying_Pan
+7032	//Piece_Of_Egg_Shell
+7033	//Poison_Spore
+7034	//Red_Socks_With_Holes
+7035	//Matchstick
+7036	//Fang_Of_Garm
+7038	//Yarn
+7041	//Fine_Grit
+7043	//Fine_Sand
+7047	//Alice's_Apron
+7048	//Talon_Of_Griffin
+7049	//Stone
+7053	//Cyfar
+7054	//Brigan
+7055	//Animal_Pooopoo
+7056	//Payroll_Of_Kafra
+7057	//Gallar_Horn
+7058	//Gullraifnir
+7063	//Soft_Feather
+7064	//Dragon_Fly_Wing
+7065	//Sea_Otter_Leather
+7066	//Ice_Piece
+7067	//Stone_Piece
+7068	//Burn_Tree
+7069	//Broken_Armor_Piece
+7070	//Broken_Shell
+7071	//Tatters_Clothes
+7072	//Rust_Suriken
+7073	//Jewel_Of_Prayer
+7074	//Iron_Glove
+7075	//Iron_Maiden
+7076	//Mystery_Wheel
+7077	//Silver_Fancy
+7078	//Anger_Of_Valkurye
+7079	//Feather_Of_Angel
+7080	//Foot_Step_Of_Cat
+7081	//Beard_Of_Women
+7082	//Root_Of_Stone
+7083	//Soul_Of_Fish
+7084	//Saliva_Of_Bird
+7085	//Tendon_Of_Bear
+7086	//Symbol_Of_Sun
+7087	//Breath_Of_Soul
+7088	//Crystal_Of_Snow
+7089	//Indication_Of_Tempest
+7090	//Slilince_Wave
+7091	//Rough_Billows
+7092	//Air_Stream
+7093	//Wheel
+7094	//Mystery_Piece
+7095	//Broken_Steel_Piece
+7096	//Cold_Magma
+7097	//Burning_Heart
+7098	//Live_Coal
+7099	//Old_Magic_Circle
+7100	//Sharp_Leaf
+7101	//Peco_Wing_Feather
+7102	//Hideous_Dream
+7103	//Unknown_Liquid_Bottle
+7104	//Fake_Angel_Wing
+7105	//Fake_Angel_Loop
+7106	//Goat's_Horn
+7107	//Gaoat's_Skin
+7108	//Boroken_Shiled_Piece
+7109	//Shine_Spear_Blade
+7110	//Vroken_Sword
+7111	//Smooth_Paper
+7112	//Fright_Paper_Blade
+7113	//Broken_Pharaoh_Symbol
+7114	//Tutankhamen's_Mask
+7115	//Harpy's_Feather
+7116	//Harpy's_Claw
+7117	//Rent_Spell_Book
+7118	//Rent_Scroll
+7119	//Spawns
+7120	//Burning_Horse_Shoe
+7121	//Honey_Jar
+7122	//Hot_Hair
+7123	//Dragon's_Skin
+7124	//Sand_Lump
+7125	//Scropion's_Nipper
+7126	//Large_Jellopy
+7127	//Alcol_Create_Book
+7128	//FireBottle_Create_Book
+7129	//Acid_Create_Book
+7130	//Plant_Create_Book
+7131	//Mine_Create_Book
+7132	//Coating_Create_Book
+7133	//Slim_Potion_Create_Book
+7134	//Medicine_Bowl
+7140	//Seed_Of_Life
+7141	//Yggdrasilberry_Dew
+7143	//Life_Force_Pot
+7144	//Normal_Potion_Book
+7147	//Jasmin
+7149	//Yellow_Plate
+7150	//Bamboo_Cut
+7151	//Oil_Paper
+7152	//Glossy_Hair
+7153	//Old_Japaness_Clothes
+7154	//Poison_Powder
+7155	//Poison_Toad's_Skin
+7156	//Broken_Shuriken
+7157	//Black_Mask
+7158	//Broken_Wine_Vessel
+7159	//Tengu's_Nose
+7160	//Lord's_Passable_Ticket
+7161	//Black_Bear's_Skin
+7162	//Cloud_Piece
+7163	//Sharp_Feeler
+7164	//Hard_Peach
+7165	//Limpid_Celestial_Robe
+7166	//Soft_Silk_Cloth
+7167	//Mystery_Iron_Bit
+7168	//Great_Wing
+7169	//Taegeuk_Plate
+7170	//Tuxedo
+7171	//Leopard_Skin
+7172	//Leopard_Talon
+7174	//Packing_Ribbon
+7175	//Packing_Paper
+7182	//Cacao
+7186	//Thin_Stem
+7187	//Festival_Mask
+7188	//Browny_Root
+7189	//Heart_Of_Tree
+7190	//Solid_Peeling
+7191	//Lamplight
+7192	//Blade_Of_Pinwheel
+7193	//Germinating_Sprout
+7194	//Soft_Leaf
+7195	//Air_Rifle
+7196	//Shoulder_Protection
+7197	//Tough_Vines
+7198	//Great_Leaf
+7200	//Flexible_String
+7201	//Log
+7202	//Beetle_Nipper
+7203	//Solid_Twig
+7204	//Gunpowder
+7205	//Piece_Of_Black_Cloth
+7206	//Black_Kitty_Doll
+7207	//Old_Manteau
+7208	//Rusty_Cleaver
+7209	//Dullahan's_Helm
+7210	//Dullahan_Armor
+7211	//Rojerta_Piece
+7212	//Hanging_Doll
+7213	//Needle_Pouch
+7214	//Bat_Cage
+7215	//Broken_Needle
+7216	//Red_Scarf
+7217	//Spool
+7218	//Rotten_Rope
+7219	//Striped_Socks
+7220	//Ectoplasm
+7221	//Tangled_Chain
+7222	//Tree_Knot
+7223	//Distorted_Portrait
+7225	//Pumpkin_Bucket
+7226	//Pill
+7262	//Fan
+7263	//Cat_Eyed_Stone
+7264	//Dried_Sand
+7265	//Dragon_Horn
+7266	//Dragon_Fang
+7267	//Tiger_Skin_Panties
+7268	//Little_Blacky_Ghost
+7269	//Bib
+7270	//Milk_Bottle
+7277	//Munak_Doll
+7286	//Chilli
+7289	//Olivine
+7290	//Phlogopite
+7291	//Agate
+7292	//Muscovite
+7293	//Rose_Quartz
+7294	//Turquoise
+7295	//Citrine
+7296	//Pyroxene
+7297	//Biotite
+7298	//Leaf_Clothes
+7299	//Bamboo_Basket
+7300	//Gemstone
+7301	//Sword_Accessory
+7303	//Bag_Of_Rice
+7312	//Jubilee
+7315	//Dark_Crystal_Fragment
+7316	//Long_Limb
+7317	//Screw
+7318	//Old_Pick
+7319	//Old_Steel_Plate
+7320	//Air_Pollutant
+7321	//Fragment_Of_Crystal
+7322	//Poisonous_Gas
+7323	//Battered_Kettle
+7325	//Tube
+7326	//Fluorescent_Liquid
+7327	//Headlamp
+7340	//Will_Of_Darkness
+7345	//Armlet_Of_Prisoner
+7352	//Transparent_Plate01
+7353	//Transparent_Plate02
+7354	//Transparent_Plate03
+7355	//Transparent_Plate04
+7356	//Piece_Of_Crest1
+7357	//Piece_Of_Crest2
+7358	//Piece_Of_Crest3
+7359	//Piece_Of_Crest4
+7419	//Embryo_HandBook
+7433	//Scroll
+7434	//Elemental_Potion_Book
+7435	//Golden_Bracelet
+7436	//Piece_Of_Memory_Green
+7437	//Piece_Of_Memory_Purple
+7438	//Piece_Of_Memory_Blue
+7439	//Piece_Of_Memory_Red
+7440	//Red_Feather
+7441	//Blue_Feather
+7442	//Cursed_Seal
+7443	//Tri_Headed_Dragon_Head
+7444	//Treasure_Box
+7445	//Dragonball_Green
+7446	//Dragonball_Blue
+7447	//Dragonball_Red
+7448	//Dragonball_Yellow
+7449	//Bloody_Page
+7450	//Piece_Of_Bone_Armor
+7451	//Scale_Of_Red_Dragon
+7452	//Yellow_Spice
+7453	//Sweet_Sauce
+7454	//Plain_Sauce
+7455	//Hot_Sauce
+7456	//Red_Spice
+7457	//Cooking_Oil
+7472	//Cookbook01
+7473	//Cookbook02
+7474	//Cookbook03
+7475	//Cookbook04
+7476	//Cookbook05
+7477	//Cookbook06
+7478	//Cookbook07
+7479	//Cookbook08
+7480	//Cookbook09
+7481	//Cookbook10
+7482	//Pot
+7507	//Sturdy_Iron_Piece
+7510	//Valhalla_Flower
+7511	//Rune_Of_Darkness
+7512	//Burnt_Parts
+7513	//Pocket_Watch
+7521	//Flame_Stone
+7522	//Ice_Stone
+7523	//Wind_Stone
+7524	//Shadow_Orb
+7561	//Ice_Heart
+7562	//Ice_Scale
+7563	//Bloody_Rune
+7564	//Rotten_Meat
+7565	//Sticky_Poison
+7566	//Will_Of_Darkness_
+7567	//Suspicious_Hat
+7568	//White_Mask
+7574	//Ice_Particle
+7751	//Old_White_Cloth
+7752	//Clattering_Skull
+7753	//Broken_Farming_Utensil
+7754	//Broken_Crown
+7830	//Goddess_Tear
+7831	//Valkyrie_Token
+7832	//Brynhild_Armor_Piece
+7833	//Hero_Remains
+7834	//Andvari_Ring
+7835	//Dusk_Glow
+7836	//Dawn_Essence
+7837	//Cold_Moonlight
+7838	//Hazy_Starlight
+7931	//Poison_Kit
+7932	//Poison_Herb_Nerium
+7933	//Poison_Herb_Rantana
+7934	//Poison_Herb_Makulata
+7935	//Poison_Herb_Seratum
+7936	//Poison_Herb_Scopolia
+7937	//Poison_Herb_Amoena
+7938	//Light_Granule
+7939	//Elder_Branch
+7940	//Special_Alloy_Trap
+11000	//Prontera_Book_01
+11001	//Adventure_Story01
+11002	//Great_Chef_Orleans01
+11003	//Legend_Of_Kafra01
+11004	//Mercenary_Rebellion
+11005	//Tyrant_Schmidt
+11006	//Blood_Flower01
+11007	//Blood_Flower02
+11008	//Barmund
+11009	//Adventure_Story02
+11020	//Japan_Book1
+11021	//Japan_Book2
+11022	//Mix_Cook_Book
+11023	//Increase_Stamina_Study
+11024	//Vital_Drink_CB
+//--- 2010 / 03 / 12

+ 73 - 17
db/re/item_combo_db.txt

@@ -15,10 +15,10 @@
 1422:2133,{ bonus2 bAddClass,Class_All,4; bonus bDef,2; }
 1428:2115,{ bonus3 bAutoSpellWhenHit,"HP_ASSUMPTIO",2,5; }
 1433:2153,{ bonus2 bSkillAtk,"CR_GRANDCROSS",10; bonus2 bSkillAtk,"LG_RAYOFGENESIS",10; }
-1472:2677,{ bonus bMatkRate,6; bonus bDex,2; bonus bCastrate,-getequiprefinerycnt(EQI_HEAD_TOP); }
-1472:2711,{ bonus bMatkRate,6; bonus bDex,2; bonus bCastrate,-getequiprefinerycnt(EQI_HAND_R); }
-1473:2677,{ bonus bMatkRate,6; bonus bDex,2; bonus bCastrate,-getequiprefinerycnt(EQI_HEAD_TOP); }
-1473:2711,{ bonus bMatkRate,6; bonus bDex,2; bonus bCastrate,-getequiprefinerycnt(EQI_HAND_R); }
+1472:2677,{ bonus bMatkRate,6; bonus bDex,2; bonus bVariableCastrate,-getequiprefinerycnt(EQI_HEAD_TOP); }
+1472:2711,{ bonus bMatkRate,6; bonus bDex,2; bonus bVariableCastrate,-getequiprefinerycnt(EQI_HAND_R); }
+1473:2677,{ bonus bMatkRate,6; bonus bDex,2; bonus bVariableCastrate,-getequiprefinerycnt(EQI_HEAD_TOP); }
+1473:2711,{ bonus bMatkRate,6; bonus bDex,2; bonus bVariableCastrate,-getequiprefinerycnt(EQI_HAND_R); }
 1474:2527,{ bonus2 bAddRace,RC_Dragon,5; }
 1474:2527:5467,{ bonus2 bAddRace,RC_Dragon,25; }
 1477:2700,{ bonus2 bResEff,Eff_Confusion,9500; }
@@ -42,6 +42,7 @@
 1646:2161,{ set .@i,getequiprefinerycnt(EQI_HAND_L)*4; bonus2 bVariableCastrate,"WZ_STORMGUST",-.@i; bonus2 bVariableCastrate,"WL_FROSTMISTY",-.@i; bonus2 bVariableCastrate,"WL_JACKFROST",-.@i; }
 1657:2471:2569:15029,{ bonus bHealPower,25; bonus2 bSkillUseSP,"AL_HEAL",-20; bonus2 bSkillCooldown,"AB_SECRAMENT",-2000; bonus2 bSkillCooldown,"AB_LAUDAAGNUS",-2000; bonus2 bSkillCooldown,"AB_LAUDARAMUS",-2000; }
 1660:2471:2569:15029,{ bonus bHealPower,45; bonus2 bSkillUseSP,"AL_HEAL",-50; bonus3 bAutoSpellWhenHit,"AB_SILENTIUM",1,100; bonus2 bSkillCooldown,"AB_CLEARANCE",-3000; bonus2 bSkillCooldown,"AB_LAUDAAGNUS",-3000; bonus2 bSkillCooldown,"AB_LAUDARAMUS",-3000; }
+1668:15089,{ bonus bDelayrate,-10; }
 1718:1774,{ bonus bLongAtkRate,50; }
 1723:2718,{ bonus bDex,1; bonus bMaxSP,50; bonus bSPrecovRate,10; }
 1724:5467,{ bonus bAspd,1; bonus bFlee2,3; }
@@ -107,6 +108,7 @@
 2371:2522,{ bonus bAgi,5; bonus bFlee,10; }
 2371:2523,{ bonus bAgi,5; bonus bFlee,10; }
 2374:2729,{ bonus2 bAddClass,Class_All,3; bonus bMatkRate,3; }
+2375:2729,{ bonus2 bAddClass,Class_All,3; bonus bMatkRate,3; }
 2376:2435:2538,{ bonus2 bSubRace,RC_All,-300; bonus2 bSubRace,RC_DemiHuman,300; bonus2 bSubRace,RC_Player,300; bonus bVit,3; bonus bMaxHPRate,12; bonus bHealpower2,10; bonus bAddItemHealRate,10; autobonus2 "{ bonus2 bHPRegenRate,600,1000; }",5,10000,BF_WEAPON,"{ specialeffect2 EF_HEAL; }"; }
 2377:2435:2538,{ bonus2 bSubRace,RC_All,-300; bonus2 bSubRace,RC_DemiHuman,300; bonus2 bSubRace,RC_Player,300; bonus bStr,3; bonus bMaxHPRate,12; bonus2 bSkillAtk,"MC_MAMMONITE",20; bonus2 bSkillHeal,"AM_POTIONPITCHER",10; bonus2 bSkillHeal2,"AM_POTIONPITCHER",10; bonus2 bSkillHeal2,"AL_HEAL",10; bonus bUnbreakableArmor,0; }
 2378:2435:2538,{ bonus2 bSubRace,RC_All,-300; bonus2 bSubRace,RC_DemiHuman,300; bonus2 bSubRace,RC_Player,300; bonus bAgi,3; bonus bMaxHPRate,12; bonus bCritical,5; bonus bAspdRate,5; autobonus "{ bonus2 bHPRegenRate,300,1000; }",10,10000,BF_WEAPON,"{ specialeffect2 EF_HEAL; }"; }
@@ -137,7 +139,7 @@
 2478:2578:2887:15039,{ bonus3 bAutoSpell,"ASC_BREAKER",(getskilllv("ASC_BREAKER"))?getskilllv("ASC_BREAKER"):1,20; if(readparam(bStr)>119) { bonus bBaseAtk,30; } bonus2 bAddClass,Class_All,10; bonus bMatkRate,10; bonus bCritical,-20; }
 2479:2580:2890:15042,{ bonus bAspd,2; bonus2 bSkillAtk,"RA_ARROWSTORM",50; bonus bLongAtkRate,30; bonus3 bAutoSpell,"AC_DOUBLE",(getskilllv("AC_DOUBLE") < 3)?3:getskilllv("AC_DOUBLE"),20; }
 2480:2581:2891:15043,{ bonus bMaxHPRate,15; bonus bFlee2,20; bonus2 bSkillAtk,"RA_CLUSTERBOMB",20; bonus bLongAtkRate,-30; bonus bAspd,-7; }
-2483:2586:15046,{ bonus2 bSubRace,RC_DemiHuman,15; bonus2 bSubRace,RC_Player,15; }
+2483:2586:15046,{ bonus bVit,5; bonus2 bSubRace,RC_DemiHuman,15; bonus2 bSubRace,RC_Player,15; }
 2484:2586:15047,{ bonus bDex,5; bonus2 bSubRace,RC_DemiHuman,15; bonus2 bSubRace,RC_Player,15; }
 2485:2587:15048,{ bonus bInt,5; bonus bMdef,10; bonus2 bSubRace,RC_DemiHuman,15; bonus2 bSubRace,RC_Player,15; }
 2518:2648:2649:5126,{ bonus bInt,5; bonus bMdef,11; bonus bMaxSPrate,20; bonus bNoCastCancel,0; bonus bVariableCastrate,25; }
@@ -158,12 +160,12 @@
 2626:2786,{ bonus2 bSkillAtk,"AL_HEAL",50; bonus2 bSkillAtk,"PR_MAGNUS",30; bonus bSPrecovRate,9; }
 2678:2679,{ bonus4 bAutoSpell,"MO_EXTREMITYFIST",1,3,1; bonus3 bAutoSpell,"PR_LEXAETERNA",1,20; bonus3 bAutoSpell,"AS_SONICBLOW",5,50; bonus3 bAutoSpell,"MO_INVESTIGATE",5,20; bonus3 bAutoSpell,"ASC_METEORASSAULT",2,50; }
 //2679:2792,{ bonus4 bAutoSpell,"MO_EXTREMITYFIST",1,3,1; bonus3 bAutoSpell,"PR_LEXAETERNA",1,20; bonus3 bAutoSpell,"AS_SONICBLOW",5,50; bonus3 bAutoSpell,"MO_INVESTIGATE",5,20; bonus3 bAutoSpell,"ASC_METEORASSAULT",2,50; }
-2720:2772,{ bonus2 bAddClass,Class_All,3; bonus bHealPower,5; }
-2721:2772,{ bonus2 bAddClass,Class_All,3; bonus bHealPower,5; }
-2722:2772,{ bonus2 bAddClass,Class_All,3; bonus bHealPower,5; }
-2723:2772,{ bonus2 bAddClass,Class_All,3; bonus bHealPower,5; }
-2724:2772,{ bonus2 bAddClass,Class_All,3; bonus bHealPower,5; }
-2725:2772,{ bonus2 bAddClass,Class_All,3; bonus bHealPower,5; }
+2720:2772,{ bonus2 bAddClass,Class_All,5; bonus bMatkRate,3; bonus bHealPower,5; }
+2721:2772,{ bonus2 bAddClass,Class_All,5; bonus bMatkRate,3; bonus bHealPower,5; }
+2722:2772,{ bonus2 bAddClass,Class_All,5; bonus bMatkRate,3; bonus bHealPower,5; }
+2723:2772,{ bonus2 bAddClass,Class_All,5; bonus bMatkRate,3; bonus bHealPower,5; }
+2724:2772,{ bonus2 bAddClass,Class_All,5; bonus bMatkRate,3; bonus bHealPower,5; }
+2725:2772,{ bonus2 bAddClass,Class_All,5; bonus bMatkRate,3; bonus bHealPower,5; }
 2726:2727,{ bonus bUseSPrate,-25; }
 2733:2772,{ bonus2 bAddClass,Class_All,5; bonus bMatkRate,3; bonus bHealPower,5; }
 2747:13061,{ bonus bHit,5; bonus bMatk,5; bonus2 bSkillUseSP,"SC_ENERVATION",20; bonus2 bSkillUseSP,"SC_GROOMY",20; }
@@ -179,6 +181,14 @@
 2967:2968,{ bonus bAtkRate,4; bonus bMatkRate,4; }
 2967:2969,{ bonus bAtkRate,4; bonus bMatkRate,4; }
 2968:13092,{ bonus bMatk,10*getequiprefinerycnt( (getequipid(EQI_HAND_R) == 13092) ? EQI_HAND_R : EQI_HAND_L ); }
+2971:5135:2109,{ bonus bHPrecovRate,15; bonus bSPrecovRate,15; bonus bMatkRate,7; }
+2971:5135:2121,{ bonus bHPrecovRate,15; bonus bSPrecovRate,15; bonus bMatkRate,7; }
+2971:18874:2109,{ bonus bHPrecovRate,15; bonus bSPrecovRate,15; bonus bMatkRate,7; }
+2971:18874:2121,{ bonus bHPrecovRate,15; bonus bSPrecovRate,15; bonus bMatkRate,7; }
+2983:4218,{ bonus bVit,-3; bonus bHPrecovRate,-20; bonus bMaxHP,1000; }
+2983:4269,{ bonus bInt,-3; bonus bSPrecovRate,-20; bonus bMaxSP,150; }
+2983:4218:4269,{ bonus bVit,-3; bonus bHPrecovRate,-20; bonus bMaxHP,1000; bonus bInt,-3; bonus bSPrecovRate,-20; bonus bMaxSP,150; }
+2984:4239:4245:4267:4151:4249:4235:4164:4221:4275:4204,{ bonus2 bExpAddRace,RC_All,2; }
 2986:18872,{ bonus bBaseAtk,BaseLevel/4; }
 2986:2987:18872,{ bonus2 bAddMonsterDropItem,22559,50; }
 2987:18872,{ bonus bMatk,BaseLevel/4; }
@@ -210,13 +220,14 @@
 4193:4294,{ bonus bMaxHP,300; bonus bMaxSP,60; }
 4208:4258:4325:4327:4382,{ bonus bInt,3; bonus2 bSkillAtk,"WZ_HEAVENDRIVE",10; bonus2 bSkillAtk,"MG_THUNDERSTORM",10; if(BaseJob==Job_Sage) { bonus bMagicDamageReturn,20; bonus2 bAddMonsterDropItem,716,100; bonus2 bAddMonsterDropItem,715,100; bonus bVariableCastrate,-20; } }
 4218:4269,{ bonus bHPrecovRate,30; bonus bSPrecovRate,30; bonus bVit,4; bonus bInt,4; }
-4220:4246:4311:4319:4331,{ bonus bStr,10; bonus bMaxHPrate,20; bonus bHPrecovRate,50; bonus3 bAutoSpell,"BS_WEAPONPERFECT",1,3; bonus2 bAddMonsterDropItem,501,500; if(BaseClass==Job_Swordman) bonus2 bAddItemHealRate,IG_Potion,50; }
+4220:4246:4311:4319:4331,{ bonus bStr,10; bonus bMaxHPrate,20; bonus bHPrecovRate,50; bonus3 bAutoSpell,"BS_WEAPONPERFECT",1,3; bonus2 bAddMonsterDropItem,501,500; if(BaseClass==Job_Swordman) bonus2 bAddItemGroupHealRate,IG_Potion,50; }
 4229:4244:4299:4313,{ bonus bDef,3; bonus bMdef,3; }
 4237:4238,{ bonus3 bAutoSpell,"MG_LIGHTNINGBOLT",5,20; }
 4268:4277,{ bonus bBaseAtk,20; bonus bLuk,3; }
 4311:4319:4331:4371,{ bonus bInt,1; bonus bStr,1; bonus bDef,2; bonus bSPrecovRate,10; bonus2 bSkillAtk,"PA_SHIELDCHAIN",10; bonus2 bSkillAtk,"PA_SACRIFICE",10; bonus bVariableCastrate,-10; if(BaseJob==Job_Crusader) bonus bDefEle,Ele_Holy; }
 4323:4324,{ bonus3 bAutoSpell,"MG_FROSTDIVER",3,250; }
 4435:4436,{ bonus2 bSPGainRace,RC_DemiHuman,2; bonus2 bSPGainRace,RC_Player,2; }
+4488:4169,{ if(getequiprefinerycnt(EQI_SHOES) >= 15) { bonus bMaxHPrate,15; bonus bMaxSPrate,15; } else { bonus bMaxHPrate,10; bonus bMaxSPrate,10; } }
 4545:18730,{ bonus bMatk,5; bonus bBaseAtk,5; }
 4605:4606,{ bonus2 bSubEle,Ele_Neutral,20; bonus bFlee,20; bonus2 bHPLossRate,100,6000; bonus2 bSPLossRate,6,6000; }
 4608:4609,{ bonus2 bAddSize,Size_Medium,15; bonus2 bAddSize,Size_Large,15; bonus2 bSubSize,Size_Medium,5; bonus2 bSubSize,Size_Large,5; }
@@ -225,7 +236,7 @@
 5074:5653,{ bonus bStr,1; bonus bAspdRate,2; }
 5086:18527,{ bonus2 bAddItemHealRate,12192,200; }
 5176:18527,{ bonus bAspdRate,5; }
-//5184:5657,{ bonus bLongAtkRate,getrefine(); }
+//5184:5657,{ bonus bLongAtkRate,getequiprefinerycnt(EQI_HEAD_TOP); }
 //5206:5768,{ bonus bDex,1; if(getequiprefinerycnt(EQI_HEAD_TOP) > 4) bonus bDelayRate,4-getequiprefinerycnt(EQI_HEAD_TOP); }
 5358:5653,{ bonus bAgi,1; bonus bFlee,3; }
 //5359:5657,{ bonus bLongAtkRate,getequiprefinerycnt(EQI_HEAD_TOP); }
@@ -237,13 +248,20 @@
 15068:20710,{ bonus bAgi,5; bonus bFlee,10; }
 15088:18816:18818,{ bonus bMatk,BaseLevel/3; bonus2 bExpAddClass,Class_All,5; }
 15088:18817:18819,{ bonus bBaseAtk,BaseLevel/3; bonus2 bExpAddClass,Class_All,5; }
+15116:20743:22046,{ bonus bMaxSPrate,25; bonus bMaxSPrate,25; bonus bSpeedAddRate,10; }
 18507:18539,{ bonus bUseSPrate,-3; }
+18538:5041,{ bonus2 bSubRace,RC_Angel,9; }
+18538:5048,{ bonus2 bSubRace,RC_Demon,9; }
 18559:18560,{ bonus bCritAtkRate,5; }
+18656:2278,{ bonus2 bAddMonsterDropItem,12192,400; }
+18656:5043,{ bonus bFlee,10; bonus2 bAddEff,Eff_Stun,1000; }
+18656:5086,{ bonus2 bAddItemHealRate,538,100; bonus2 bAddItemHealRate,12192,100; bonus2 bAddMonsterDropItem,538,400; bonus2 bAddMonsterDropItem,12192,400; }
+18656:5176,{ bonus bAspd,1; autobonus "{ bonus bBaseAtk,50; }",20,10000,0,"{ specialeffect2 EF_POTION_BERSERK; }"; }
+18656:5475,{ bonus bBaseAtk,30; bonus bMatk,30; bonus2 bAddMonsterDropItem,529,400; bonus2 bAddMonsterDropItem,530,400; bonus2 bAddMonsterDropItem,538,400; bonus2 bAddMonsterDropItem,12192,400;}
 18776:20710,{ bonus bBaseAtk,10; }
 18776:22015,{ bonus bMatk,20; }
-24072:24075,{ bonus bMaxHPrate,1; bonus bMaxSPrate,1; }
-24073:24076,{ bonus bMaxHPrate,1; bonus bMaxSPrate,1; }
-24074:24077,{ bonus bMaxHPrate,1; bonus bMaxSPrate,1; }
+18997:28326:28327,{ bonus bSpeed,25; bonus bBaseAtk,50; bonus bMatk,50; }
+24012:24013:24014:24015:24016:24017,{ bonus bAllStats,9; }
 24018:24019:24020,{ if(getequiprefinerycnt(EQI_SHADOW_ACC_R) + getequiprefinerycnt(EQI_SHADOW_ACC_L) + getequiprefinerycnt(EQI_SHADOW_WEAPON) >= 23) { bonus bAtkRate,1; } }
 24021:24022:24023,{ if(getequiprefinerycnt(EQI_SHADOW_ACC_R) + getequiprefinerycnt(EQI_SHADOW_ACC_L) + getequiprefinerycnt(EQI_SHADOW_WEAPON) >= 23) { bonus bMatkRate,1; } }
 24025:24028,{ set .@i,getequiprefinerycnt(EQI_SHADOW_ARMOR) + getequiprefinerycnt(EQI_SHADOW_SHOES); bonus bMaxHP,.@i; bonus bMaxSP,.@i; if(.@i >= 15) { bonus bMaxHPrate,1; } }
@@ -256,7 +274,7 @@
 24037:24043,{ bonus bDex,1; }
 24038:24044,{ bonus bVit,1; }
 24039:24045,{ bonus bAgi,1; }
-24046:24051,{ bonus2 bSubEle,Ele_Neutral,1; if(getequiprefinerycnt(EQI_SHADOW_ACC_R) + getequiprefinerycnt(EQI_SHADOW_ACC_L)) { bonus2 bSubEle,Ele_Neutral,1; } }
+24046:24051,{ bonus2 bSubEle,Ele_Neutral,1; if(getequiprefinerycnt(EQI_SHADOW_ACC_R) + getequiprefinerycnt(EQI_SHADOW_ACC_L) >= 15) { bonus2 bSubEle,Ele_Neutral,1; } }
 24052:24062,{ bonus2 bExpAddRace,RC_DemiHuman,3; bonus2 bExpAddRace,RC_Player,3; }
 24053:24063,{ bonus2 bAddRace,10,5; bonus2 bMagicAddRace,10,5; }
 24054:24065,{ bonus2 bExpAddRace,RC_Brute,3; }
@@ -267,5 +285,43 @@
 24059:24069,{ bonus2 bExpAddRace,RC_Formless,3; }
 24060:24070,{ bonus2 bExpAddRace,RC_Undead,3; }
 24061:24064,{ bonus2 bExpAddRace,RC_Plant,3; }
+24072:24075,{ bonus bMaxHPrate,1; bonus bMaxSPrate,1; }
+24073:24076,{ bonus bMaxHPrate,1; bonus bMaxSPrate,1; }
+24074:24077,{ bonus bMaxHPrate,1; bonus bMaxSPrate,1; }
 24078:24079:24080,{ bonus3 bSPDrainRate,10,1+(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)/10),0; }
 24081:24082:24083,{ bonus3 bHPDrainRateRace,11,40,2+(getequiprefinerycnt(EQI_SHADOW_ARMOR)+getequiprefinerycnt(EQI_SHADOW_SHIELD)+getequiprefinerycnt(EQI_SHADOW_SHOES)/5); }
+24084:24085;24086:24087:24088:24089,{ bonus bAllStats,1; set .@i,getequiprefinerycnt(EQI_SHADOW_ARMOR)+getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_SHIELD)+getequiprefinerycnt(EQI_SHADOW_SHOES)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L); if (.@i >= 45) { bonus bNoGemStone,1; } bonus bUseSPrate,100-.@i; }
+24090:24091:24092,{ bonus bDef,5; if (getequiprefinerycnt(EQI_SHADOW_SHIELD)+getequiprefinerycnt(EQI_SHADOW_ARMOR)+getequiprefinerycnt(EQI_SHADOW_SHOES) >= 20) bonus2 bResEff,Eff_Stone,100; }
+24090:24093:24094,{ bonus bDef,5; if (getequiprefinerycnt(EQI_SHADOW_SHIELD)+getequiprefinerycnt(EQI_SHADOW_ARMOR)+getequiprefinerycnt(EQI_SHADOW_SHOES) >= 20) bonus2 bResEff,Eff_Sleep,100; }
+24090:24095:24096,{ bonus bDef,5; if (getequiprefinerycnt(EQI_SHADOW_SHIELD)+getequiprefinerycnt(EQI_SHADOW_ARMOR)+getequiprefinerycnt(EQI_SHADOW_SHOES) >= 20) bonus2 bResEff,Eff_Silence,100; }
+24090:24097:24098,{ bonus bDef,5; if (getequiprefinerycnt(EQI_SHADOW_SHIELD)+getequiprefinerycnt(EQI_SHADOW_ARMOR)+getequiprefinerycnt(EQI_SHADOW_SHOES) >= 20) bonus2 bResEff,Eff_Blind,100; }
+24090:24099:24100:24101,{ bonus bDef,4; if (getequiprefinerycnt(EQI_SHADOW_SHIELD)+getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_L)+getequiprefinerycnt(EQI_SHADOW_ACC_R) >= 30) bonus2 bResEff,Eff_Freeze,100; }
+24090:24104:24105:24106,{ bonus bDef,4; if (getequiprefinerycnt(EQI_SHADOW_SHIELD)+getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_L)+getequiprefinerycnt(EQI_SHADOW_ACC_R) >= 30) bonus2 bResEff,Eff_Stun,100; }
+24090:24107:24108,{ bonus bDef,5; if (getequiprefinerycnt(EQI_SHADOW_SHIELD)+getequiprefinerycnt(EQI_SHADOW_ACC_L)+getequiprefinerycnt(EQI_SHADOW_ACC_R) >= 20) bonus2 bResEff,Eff_Curse,100; }
+24090:24102:24103,{ bonus bDef,5; if (getequiprefinerycnt(EQI_SHADOW_SHIELD)+getequiprefinerycnt(EQI_SHADOW_ACC_L)+getequiprefinerycnt(EQI_SHADOW_ACC_R) >= 20) bonus2 bResEff,Eff_Bleeding,100; }
+24109:24110,{ bonus bFixedCastrate,-(getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)); }
+24111:24112:24113,{ bonus bNoCastCancel,1; bonus bUseSPrate,40-getequiprefinerycnt(EQI_SHADOW_SHIELD)-getequiprefinerycnt(EQI_SHADOW_ARMOR)-getequiprefinerycnt(EQI_SHADOW_SHOES); }
+24150:24151,{ bonus bAtkRate,1; if (getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L) >= 15) bonus bNoSizeFix,1; }
+24152:24153,{ bonus bAtk,getequiprefinerycnt(EQI_SHADOW_WEAPON); if (getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R) >= 15) bonus bUnbreakableWeapon,1; }
+24154:24155,{ bonus bDef,getequiprefinerycnt(EQI_SHADOW_ARMOR); if (getequiprefinerycnt(EQI_SHADOW_ARMOR)+getequiprefinerycnt(EQI_SHADOW_ACC_L) >= 15) bonus bUnbreakableArmor,1; }
+24156:24166:24167,{ bonus bBaseAtk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreDefRace,RC_DemiHuman; }
+24157:24166:24167,{ bonus bBaseAtk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreDefRace,RC_Demon; }
+24158:24166:24167,{ bonus bBaseAtk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreDefRace,RC_Brute; }
+24159:24166:24167,{ bonus bBaseAtk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreDefRace,RC_Insect; }
+24160:24166:24167,{ bonus bBaseAtk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreDefRace,RC_Fish; }
+24161:24166:24167,{ bonus bBaseAtk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreDefRace,RC_Dragon; }
+24162:24166:24167,{ bonus bBaseAtk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreDefRace,RC_Angel; }
+24163:24166:24167,{ bonus bBaseAtk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreDefRace,RC_Formless; }
+24164:24166:24167,{ bonus bBaseAtk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreDefRace,RC_Undead; }
+24165:24166:24167,{ bonus bBaseAtk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreDefRace,RC_Plant; }
+24170:24168:24169,{ bonus bMatk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreMDefRace,RC_DemiHuman; }
+24171:24168:24169,{ bonus bMatk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreMDefRace,RC_Demon; }
+24172:24168:24169,{ bonus bMatk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreMDefRace,RC_Brute; }
+24173:24168:24169,{ bonus bMatk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreMDefRace,RC_Insect; }
+24174:24168:24169,{ bonus bMatk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreMDefRace,RC_Fish; }
+24175:24168:24169,{ bonus bMatk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreMDefRace,RC_Dragon; }
+24176:24168:24169,{ bonus bMatk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreMDefRace,RC_Angel; }
+24177:24168:24169,{ bonus bMatk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreMDefRace,RC_Formless; }
+24178:24168:24169,{ bonus bMatk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreMDefRace,RC_Undead; }
+24179:24168:24169,{ bonus bMatk,5; if(getequiprefinerycnt(EQI_SHADOW_WEAPON)+getequiprefinerycnt(EQI_SHADOW_ACC_R)+getequiprefinerycnt(EQI_SHADOW_ACC_L)>=25) bonus bIgnoreMDefRace,RC_Plant; }
+28326:28327,{ bonus bInt,8; bonus bStr,8; }

Datei-Diff unterdrückt, da er zu groß ist
+ 360 - 128
db/re/item_db.txt


+ 2 - 2
db/re/item_flag.txt

@@ -4,13 +4,13 @@
 // <Flag>:
 // 1 - As Dead Branch item (will be logged at `branchlog` table and cannot be used at 'nobranch' mapflag)
 // 2 - As item group container, check player's inventory and weight before consumed
+// NOTE: For removing flag by import file, use "-" to remove the flag. Example, 604,-1 will removes flag 1 from Branch_Of_Dead_Tree
 
 // Logged as Dead Branch item
 604,1 //Branch_Of_Dead_Tree
 12103,1 //Bloody_Dead_Branch
 12109,1 //Poring_Box
 12024,1 //Red_Pouch_Of_Surprise
-12258,1 //Bombring_Box
 
 // Item group container
 603,2 //Old_Blue_Box
@@ -365,4 +365,4 @@
 22514,2 //Candy_Holder
 22558,2 //Lucky_Bag
 22669,2 //HALLOWEEN_G_BOX
-22685,2 //Solo_Christmas_Gift
+22685,2 //Solo_Christmas_Gift

+ 1 - 1
db/re/item_misc.txt

@@ -706,7 +706,7 @@
 61,1473,1	// Wizardy_Staff
 61,1474,1	// Gae_Bolg
 61,1477,1	// Spectral_Spear
-61,1478,1	// Ahlspiess,
+61,1478,1	// Ahlspiess
 61,1479,1	// Spectral_Spear_
 61,1480,1	// Gae_Bolg_
 61,1481,1	// Zephyrus_

+ 222 - 12
db/re/item_package.txt

@@ -1149,24 +1149,24 @@ IG_Ox_Tail_Scroll,Eyes_Of_Ifrit,5,1,1,1,0,1
 IG_Ox_Tail_Scroll,Majoruros_Horn,100,1,1,1,0,1
 IG_Ox_Tail_Scroll,Sealed_D_Lord_Card,5,1,1,1,0,1
 
-IG_Buddah_Scroll,Mental_Potion,1,3,1,0,0,0
+IG_Buddah_Scroll,Mental_Potion,0,3,0,0,0,0
 IG_Buddah_Scroll,Bubble_Gum_Box,1400,1,1,0,0,0
 IG_Buddah_Scroll,Str_Dish_Box,1400,1,1,0,0,0
 IG_Buddah_Scroll,Megaphone_Box,1400,1,1,0,0,0
-IG_Buddah_Scroll,Battle_Manual_Box,1352,1,,0,0,0,0
+IG_Buddah_Scroll,Battle_Manual_Box,1352,1,1,0,0,0,0
 IG_Buddah_Scroll,Token_Of_Siegfried_Box,1250,1,1,0,0,0
 IG_Buddah_Scroll,Shadow_Armor_S_Box10,1400,1,1,0,0,0
 IG_Buddah_Scroll,Guyak_Pudding,1400,10,1,0,0,0
-IG_Buddah_Scroll,Poker_Card_In_Mouth,30,1,0,0,0,0
-IG_Buddah_Scroll,Sleeping_Kitty_Cat,100,1,0,0,0,0
-IG_Buddah_Scroll,18600,10,1,0,0,0,0
-IG_Buddah_Scroll,Guarantee_Weapon_5Up,70,1,0,0,0,0
-IG_Buddah_Scroll,Red_Hood,100,0,1,0,0,0
-IG_Buddah_Scroll,Spirit_Of_Chung_E,20,1,0,0,0,0
-IG_Buddah_Scroll,Guarantee_Weapon_9Up,5,1,0,0,0,0
-IG_Buddah_Scroll,Sealed_Samurai_Card,3,1,0,0,0,0
-IG_Buddah_Scroll,Kirin_Wing,10,1,0,0,0,0
-IG_Buddah_Scroll,Unbreak_Weap_Box,50,1,0,0,0,0
+IG_Buddah_Scroll,Poker_Card_In_Mouth,30,1,1,1,0,0
+IG_Buddah_Scroll,Sleeping_Kitty_Cat,100,1,1,1,0,0
+IG_Buddah_Scroll,18600,10,1,1,1,0,0
+IG_Buddah_Scroll,Guarantee_Weapon_5Up,70,1,1,1,0,0
+IG_Buddah_Scroll,Red_Hood,100,1,1,1,0,0
+IG_Buddah_Scroll,Spirit_Of_Chung_E,20,1,1,1,0,0
+IG_Buddah_Scroll,Guarantee_Weapon_9Up,5,1,1,1,0,0
+IG_Buddah_Scroll,Sealed_Samurai_Card,3,1,1,1,0,0
+IG_Buddah_Scroll,Kirin_Wing,10,1,1,1,0,0
+IG_Buddah_Scroll,Unbreak_Weap_Box,50,1,1,1,0,0
 
 IG_Evil_Incarnation,Dead_Tree_Branch_Box2,224,1,1,0,0,1
 IG_Evil_Incarnation,Guyak_Pudding,124,10,1,0,0,1
@@ -3147,3 +3147,213 @@ IG_Sg_Weapon_Supply_Box,Velum_Spear,8,1,1
 IG_Sg_Weapon_Supply_Box,Velum_Stunner,3,1,1
 IG_Sg_Weapon_Supply_Box,Siege_Arrow_Quiver_A,13,1,1
 IG_Sg_Weapon_Supply_Box,Siege_Arrow_Quiver_S,13,1,1
+
+//TODO: Confirm the items & rates
+IG_Adventurer_Returns_Support_Box,16505,1
+IG_Adventurer_Returns_Support_Box,16506,1
+IG_Adventurer_Returns_Support_Box,16507,1
+IG_Adventurer_Returns_Support_Box,16508,1
+IG_Adventurer_Returns_Support_Box,16509,1
+IG_Adventurer_Returns_Support_Box,16510,1
+IG_Adventurer_Returns_Support_Box,16514,1
+IG_Adventurer_Returns_Support_Box,16515,1
+
+//TODO: Confirm the items & rates
+IG_Support_Package,Battle_Manual,1,2,1
+IG_Support_Package,Bubble_Gum,1,2,1
+IG_Support_Package,Almighty,1,2,1
+IG_Support_Package,Mental_Potion,1,2,1
+//IG_Support_Package,,1,6,1 //6x Mysterious Water of Life
+IG_Support_Package,Scroll_Sealed_Dark_Lord,1,1,1
+
+//TODO: Confirm the items & rates
+IG_Support_Package10,Battle_Manual,1,20,1
+IG_Support_Package10,Bubble_Gum,1,20,1
+IG_Support_Package10,Almighty,1,20,1
+IG_Support_Package10,Mental_Potion,1,20,1
+//IG_Support_Package10,,1,60,1 //60x Mysterious Water of Life
+IG_Support_Package10,Scroll_Sealed_Dark_Lord,1,11,1
+
+//TODO: Confirm the items & rates
+IG_Event_Almighty_Box,Almighty,1,10,1
+IG_Event_Almighty_Box,Sealed_Kiel-D-01_Scroll,1,1,1
+
+//TODO: Confirm the items & rates
+IG_Event_Almighty_Box10,Almighty,1,100,1
+IG_Event_Almighty_Box10,Sealed_Kiel-D-01_Scroll,1,11,1
+
+IG_LottoBox1,Lotto01,1,1,1
+IG_LottoBox1,Lotto02,1,1,1
+IG_LottoBox1,Lotto03,1,1,1
+IG_LottoBox1,Lotto04,1,1,1
+IG_LottoBox1,Lotto05,1,1,1
+IG_LottoBox1,Lotto06,1,1,1
+IG_LottoBox1,Lotto07,1,1,1
+IG_LottoBox1,Lotto08,1,1,1
+IG_LottoBox1,Lotto09,1,1,1
+IG_LottoBox1,Lotto10,1,1,1
+IG_LottoBox2,Lotto11,1,1,1 
+IG_LottoBox2,Lotto12,1,1,1
+IG_LottoBox2,Lotto13,1,1,1
+IG_LottoBox2,Lotto14,1,1,1
+IG_LottoBox2,Lotto15,1,1,1
+IG_LottoBox2,Lotto16,1,1,1
+IG_LottoBox2,Lotto17,1,1,1
+IG_LottoBox2,Lotto18,1,1,1
+IG_LottoBox2,Lotto19,1,1,1
+IG_LottoBox2,Lotto20,1,1,1
+IG_LottoBox3,Lotto21,1,1,1 
+IG_LottoBox3,Lotto22,1,1,1
+IG_LottoBox3,Lotto23,1,1,1
+IG_LottoBox3,Lotto24,1,1,1
+IG_LottoBox3,Lotto25,1,1,1
+IG_LottoBox3,Lotto26,1,1,1
+IG_LottoBox3,Lotto27,1,1,1
+IG_LottoBox3,Lotto28,1,1,1
+IG_LottoBox3,Lotto29,1,1,1
+IG_LottoBox3,Lotto30,1,1,1
+IG_LottoBox4,Lotto31,1,1,1 
+IG_LottoBox4,Lotto32,1,1,1
+IG_LottoBox4,Lotto33,1,1,1
+IG_LottoBox4,Lotto34,1,1,1
+IG_LottoBox4,Lotto35,1,1,1
+IG_LottoBox4,Lotto36,1,1,1
+IG_LottoBox4,Lotto37,1,1,1
+IG_LottoBox4,Lotto38,1,1,1
+IG_LottoBox4,Lotto39,1,1,1
+IG_LottoBox4,Lotto40,1,1,1
+IG_LottoBox5,Lotto41,1,1,1 
+IG_LottoBox5,Lotto42,1,1,1
+IG_LottoBox5,Lotto43,1,1,1
+IG_LottoBox5,Lotto44,1,1,1
+IG_LottoBox5,Lotto45,1,1,1
+
+//TODO: Confirm the items & rates
+IG_Support_Package_III,Battle_Manual,1,2,1
+IG_Support_Package_III,Bubble_Gum,1,2,1
+IG_Support_Package_III,Almighty,1,2,1
+IG_Support_Package_III,Mental_Potion,1,2,1
+//IG_Support_Package_III,,1,6,1 //6x Mysterious Water of Life
+IG_Support_Package_III,Sealed_Bacsojin_Scroll,1,1,1
+
+//TODO: Confirm the items & rates
+IG_Support_Package_III10,Battle_Manual,1,20,1
+IG_Support_Package_III10,Bubble_Gum,1,20,1
+IG_Support_Package_III10,Almighty,1,20,1
+IG_Support_Package_III10,Mental_Potion,1,20,1
+//IG_Support_Package_III10,,1,60,1 //60x Mysterious Water of Life
+IG_Support_Package_III10,Sealed_Bacsojin_Scroll,1,11,1
+
+//TODO: Confirm the items & rates
+//IG_Unlimited_Box,,0,5,0 //5 ASPD Enhanced Potion
+//IG_Unlimited_Box,,0,10,0 //10 Red Boost
+IG_Unlimited_Box,Golden_Treasure_Box,0,1,0
+
+//TODO: Confirm the items & rates
+//IG_Unlimited_Box_II,,0,5,0 //50 ASPD Enhanced Potion
+//IG_Unlimited_Box_II,,0,10,0 //100 Red Boost
+IG_Unlimited_Box_II,Golden_Treasure_Box,0,11,0
+
+//TODO: Confirm the items & rates
+//IG_Unlimited_Box_II,,0,5,0 //5 ASPD Enhanced Potion
+//IG_Unlimited_Box_II,,0,10,0 //10 Red Boost
+IG_Unlimited_Box_II,Sealed_Pharaoh_Scroll,0,1,0
+
+//TODO: Confirm the items & rates
+//IG_Unlimited_Box_II10,,0,5,0 //50 ASPD Enhanced Potion
+//IG_Unlimited_Box_II10,,0,10,0 //100 Red Boost
+IG_Unlimited_Box_II10,Sealed_Pharaoh_Scroll,0,11,0
+
+//TODO: Confirm the items & rates
+IG_Three_Master_Package_III,Small_Life_Potion,1,20,1
+IG_Three_Master_Package_III,Med_Life_Potion,1,20,1
+//IG_Three_Master_Package_III,,1,20,1 //60x Mysterious Water of Life
+IG_Three_Master_Package_III,Sealed_Moonlight_Flower_Scroll,1,1,1
+
+//TODO: Confirm the items & rates
+IG_Three_Master_Package_III10,Small_Life_Potion,1,200,1
+IG_Three_Master_Package_III10,Med_Life_Potion,1,200,1
+//IG_Three_Master_Package_III10,,1,200,1 //200x Mysterious Water of Life
+IG_Three_Master_Package_III10,Sealed_Moonlight_Flower_Scroll,1,11,1
+
+//TODO: Confirm the items & rates
+IG_2013_RWC_Scroll,Neutral_Shadow_Weapon,0,1,0
+IG_2013_RWC_Scroll,Neutral_Shadow_Earring,0,1,0
+IG_2013_RWC_Scroll,Neutral_Shadow_Pendant,0,1,0
+IG_2013_RWC_Scroll,Frozen_Curse_Shadow_Earring,0,1,0
+IG_2013_RWC_Scroll,Frozen_Curse_Shadow_Pendant,0,1,0
+IG_2013_RWC_Scroll,Guarantee_Weapon_11Up,0,1,0
+IG_2013_RWC_Scroll,Guarantee_Armor_11Up,0,1,0
+IG_2013_RWC_Scroll,Guarantee_Weapon_9Up,0,1,0
+IG_2013_RWC_Scroll,Guarantee_Armor_9Up,0,1,0
+IG_2013_RWC_Scroll,C_Wings_Of_Victory,0,1,0
+IG_2013_RWC_Scroll,Succu_Pet_Coupon,0,1,0
+
+//TODO: Confirm the items & rates
+IG_Support_Package_II,Battle_Manual,1,2,1
+IG_Support_Package_II,Bubble_Gum,1,2,1
+IG_Support_Package_II,Almighty,1,2,1
+IG_Support_Package_II,Mental_Potion,1,2,1
+//IG_Support_Package_II,,1,6,1 //6x Mysterious Water of Life
+IG_Support_Package_II,14717,1,1,1 //1x 2013_RWC_Scroll
+
+//TODO: Confirm the items & rates
+IG_Support_Package_II10,Battle_Manual,1,20,1
+IG_Support_Package_II10,Bubble_Gum,1,20,1
+IG_Support_Package_II10,Almighty,1,20,1
+IG_Support_Package_II10,Mental_Potion,1,20,1
+//IG_Support_Package_II10,,1,60,1 //60x Mysterious Water of Life
+IG_Support_Package_II10,14717,1,1,1 //1x 2013_RWC_Scroll
+
+IG_Level_Up_Box100,Guarantee_Weapon_6Up,0,1,0
+IG_Level_Up_Box100,Level_Up_Box120,0,1,0
+
+IG_Level_Up_Box120,Battle_Manual,0,5,0
+IG_Level_Up_Box120,Bubble_Gum,0,5,0
+IG_Level_Up_Box120,Insurance,0,5,0
+IG_Level_Up_Box120,Job_Manual50,0,5,0
+IG_Level_Up_Box120,Guarantee_Armor_6Up,0,1,0
+IG_Level_Up_Box120,Level_Up_Box130,0,1,0
+
+IG_Level_Up_Box130,Battle_Manual,0,5,0
+IG_Level_Up_Box130,Bubble_Gum,0,5,0
+IG_Level_Up_Box130,Insurance,0,5,0
+IG_Level_Up_Box130,Job_Manual50,0,5,0
+IG_Level_Up_Box130,Guarantee_Weapon_7Up,0,1,0
+IG_Level_Up_Box130,Level_Up_Box140,0,1,0
+
+IG_Level_Up_Box140,Battle_Manual,0,5,0
+IG_Level_Up_Box140,Bubble_Gum,0,5,0
+IG_Level_Up_Box140,Insurance,0,5,0
+IG_Level_Up_Box140,Job_Manual50,0,5,0
+IG_Level_Up_Box140,Guarantee_Armor_7Up,0,1,0
+IG_Level_Up_Box140,Level_Up_Box150,0,1,0
+
+IG_Level_Up_Box150,Battle_Manual,0,5,0
+IG_Level_Up_Box150,Bubble_Gum,0,5,0
+IG_Level_Up_Box150,Insurance,0,5,0
+IG_Level_Up_Box150,Job_Manual50,0,5,0
+IG_Level_Up_Box150,Guarantee_Weapon_8Up,0,1,0
+IG_Level_Up_Box150,Level_Up_Box160,0,1,0
+
+IG_Level_Up_Box160,Battle_Manual,0,5,0
+IG_Level_Up_Box160,Bubble_Gum,0,5,0
+IG_Level_Up_Box160,Insurance,0,5,0
+IG_Level_Up_Box160,Job_Manual50,0,5,0
+IG_Level_Up_Box160,Guarantee_Armor_8Up,0,2,0
+
+IG_Gift_Buff_Set,14534,0,5,0
+IG_Gift_Buff_Set,12215,0,5,0
+IG_Gift_Buff_Set,12216,0,5,0
+IG_Gift_Buff_Set,12075,0,2,0
+IG_Gift_Buff_Set,12080,0,2,0
+IG_Gift_Buff_Set,12085,0,2,0
+IG_Gift_Buff_Set,12090,0,2,0
+IG_Gift_Buff_Set,12095,0,2,0
+IG_Gift_Buff_Set,12100,0,2,0
+
+IG_Lucky_Silvervine_Fruit_Box_III10,Silvervine,0,10,0,0,0,0
+IG_Lucky_Silvervine_Fruit_Box_III10,Sealed_Vesper_Scroll,0,1,0,0,0,0
+
+IG_Lucky_Silvervine_Fruit_Box_III110,Silvervine,0,110,0,0,0,0
+IG_Lucky_Silvervine_Fruit_Box_III110,Sealed_Vesper_Scroll,0,11,0,0,0,0

+ 461 - 36
db/re/item_trade.txt

@@ -2052,50 +2052,475 @@
 4543,457,100	// Sealed Hatii Card
 4544,457,100	// Sealed Evil Snake Lord Card
 
+12507,475,100	//E_WOB_Rune
+12508,475,100	//E_WOB_Schwaltz
+12509,475,100	//E_WOB_Rachel
+12510,475,100	//E_WOB_Local
+12511,475,100	//E_Siege_Teleport_Scroll
+12512,475,100	//E_Greed_Scroll
+12513,475,100	//E_Glass_Of_Illusion
+12514,475,100	//E_Abrasive
+12515,475,100	//E_Med_Life_Potion
+12516,475,100	//E_Small_Life_Potion
+12517,475,100	//E_Regeneration_Potion
+12518,475,100	//E_B_Mdef_Potion
+12519,475,100	//E_S_Mdef_Potion
+12520,475,100	//E_B_Def_Potion
+12521,475,100	//E_S_Def_Potion
+12522,475,100	//E_Blessing_10_Scroll
+12523,475,100	//E_Inc_Agi_10_Scroll
+12524,475,100	//E_Aspersio_5_Scroll
+12525,475,100	//E_Assumptio_5_Scroll
+12526,475,100	//E_Wind_Walk_10_Scroll
+12527,475,100	//E_Adrenaline_Scroll
+12528,475,100	//E_Convex_Mirror
+
+16481,475,100	//Small_Life_Potion_Box_10
+16483,475,100	//Abrasive_Box_10
+16505,475,100	//Steamed_Tongue_Box_10
+16506,475,100	//Steamed_Desert_Scorpions_Box_10
+
+// kRO 2012-07-16
+7630,475,100	//Clean_Beach_Brush
+7631,475,100	//Trash_Debris
+12884,475,100	//Infinite_Concentration_Potion
+12885,475,100	//Infinite_Awakening_Potion
+12886,475,100	//Infinite_Berserk_Potion
+12887,475,100	//C_Wing_Of_Fly
+17226,475,100	//Infinite_Concentration_Potion
+17227,475,100	//Infinite_Awakening_Potion
+17228,475,100	//Infinite_Berserk_Potion
+17229,475,100	//Infinite_Flywing_Box
+18760,475,100	//Remodel_Wizardry_Hat
+18761,475,100	//Remodel_Magician_Hat
+18762,475,100	//Remodel_Mask_Of_Fox
+18763,475,100	//Remodel_Joker_Jester
+18764,475,100	//Remodel_Bunny_Band
+18765,475,100	//Enhanced_Corsair
+18766,475,100	//Enhanced_Helm_Of_Angel
+18767,475,100	//Enhanced_Helm_Of_Sun
+18768,475,100	//Enhanced_Bone_Helm
+18769,475,100	//Remodel_Munak_Turban,
+18770,475,100	//Remodel_Bongun_Hat
+18771,475,100	//Remodel_Opera_Mask
+18772,475,100	//Improved_Binoculars
+18773,475,100	//Improved_Fin_Helm
+18774,475,100	//Improved_Assassin_Mask
+18775,475,100	//Improved_Welding_Mask
+18776,475,100	//Improved_Kiss_Of_Angel
+
+// kRO 2012-07-25
+17231,475,100	//Refinement_Ore_Box
+17232,475,100	//Refinement_box(7)
+17241,475,100	//Amistr_Cap_Box
+22508,475,100	//Para_Team_Mark_
+
+// kRO 2012-08-01
+22510,475,100	//King_Wolf_Scroll
+
+// kRO 2012-08-15
+18779,475,100	//RWC_Champ_Crown_First_Place
+18780,475,100	//RWC_Champ_Crown_Second_Place
+18781,475,100	//RWC_Champ_Crown_Third_Place
+18796,475,100	//RWC_Champ_Crown_Fourth_Place
+
+// kRO 2012-08-30
+22513,475,100	//King_of_Gift_Box
+
+// kRO 2012-10-10
+6671,475,100	//Geffen_Coin_Magic_Tournament
+17263,475,100	//Infinite_Concentration_Potion_3rd_Box
+17264,475,100	//Infinite_Awakening_Potion_3rd_Box
+17265,475,100	//Infinite_Berserk_Potion_3rd_Box
+17266,475,100	//Limited_Battle_Manual_Package
+
+// kRO 2012-10-17
+6654,475,100	//Needle_And_Thread
+6655,475,100	//Firm_Pumpkin
+6656,475,100	//Goast_Free_Charm
+6657,475,100	//Memory_Of_Jack
+6658,475,100	//Halloween_Coin
+6672,475,100	//RWC_Inicializer
+
+// kRO 2012-10-23
+6673,475,100	//Bossnia_Tickets
+14613,475,100	//RWC_Scroll_2012
+14614,475,100	//Ex_Def_Potion
+17262,475,100	//Ex_Def_Potion_Box
+
+// kRO 2012-11-07
+14616,475,100	//STR_Biscuit_Stick
+14617,475,100	//VIT_Biscuit_Stick
+14618,475,100	//AGI_Biscuit_Stick
+14619,475,100	//INT_Biscuit_Stick
+14620,475,100	//DEX_Biscuit_Stick
+14621,475,100	//LUK_Biscuit_Stick
+17270,475,100	//STR_Biscuit_Stick_Box
+17271,475,100	//VIT_Biscuit_Stick_Box
+17272,475,100	//AGI_Biscuit_Stick_Box
+17273,475,100	//INT_Biscuit_Stick_Box
+17274,475,100	//DEX_Biscuit_Stick_Box
+17275,475,100	//LUK_Biscuit_Stick_Box
+
+// kRO 2012-11-21
+14623,475,100	//Golden_Treasure_Box
+17277,475,100	//Unlimited_Box
+17278,475,100	//Unlimited_Box(10)
+
+// kRO 2012-12-09
+5864,475,100	//Shadow_Booster
+17292,475,100	//Shadow_Box
+17293,475,100	//Shadow_Physical_Package
+17294,475,100	//Shadow_Magical_Package
+
+// kRO 2012-12-12 Ep 14.3
+22535,475,100	//Scroll_Summoning_Workers(Male)
+22536,475,100	//Scroll_Summoning_Workers(Female)
+
+// kRO 2012-12-18
+14627,475,100	//Christmas_Scroll
+14628,475,100	//Costume_Festival_Box
+17281,475,100	//Refinement_Ore_Box_IV
+17282,475,100	//Refinement_Ore_Box_IV(10)
+17283,475,100	//Refinement_Ore_Box_IV(20)
+
+// kRO 2012-12-27
+6710,475,100	//Tied_Snake
+
+// kRO 2013-02-06 White Day's & Valentine Day's Event kRO
+11565,475,100	//White_Potion
+11566,475,100	//Yellow_Potion
+11567,475,100	//Novice_Potion
+11568,475,100	//Red_Slim_Potion
+11569,475,100	//Orange_Potion
+11570,475,100	//Red_Potion
+11571,475,100	//Green_Potion
+11572,475,100	//Blue_Potion
+11573,475,100	//White_Slim_Potion
+11574,475,100	//Yellow_Slim_Potion
+11575,475,100	//Lucky_Cookie
+11576,475,100	//Lucky_Lollipop
+11577,475,100	//Rice_Ball
+11578,475,100	//Candy_Bar
+11579,475,100	//Lucky_Candy
+11580,475,100	//Candy
+11581,475,100	//Piece_of_Cake
+11582,475,100	//Well-baked_Cookie
+11583,475,100	//Chocolate_Drink
+11584,475,100	//White_Chocolate
+11585,475,100	//Hand-made_Chocolate
+11586,475,100	//Hand-made_Chocolate_
+11587,475,100	//Chocolate
+22542,475,100	//Concentration_Potion
+22543,475,100	//Berserk_Potion
+22544,475,100	//Awakening_Potion
+22545,475,100	//Speed_Potion
+22546,475,100	//Slow_Potion
+22547,475,100	//Anti-Payne_Moment
+22548,475,100	//Wed_Cursed
+22549,475,100	//Poison_Bottle
+22550,475,100	//Sweets_Pocket
+22551,475,100	//Teacake
+22552,475,100	//Fried_Pastry
+22553,475,100	//Rainbow_Bread
+22554,475,100	//First_Aid_Box
+
+// kRO 2013-02-15
+14663,475,100	//Scroll_Sealed_Dark_Lord
+17298,475,100	//Support_Package
+17299,475,100	//Support_Package(10)
+
+// kRO 2013-02-27
+22541,475,100	//PC_Room_Coupon_Box_VI
+
 // kRO 2013-03-06 Items
-6700,457,100
-22540,457,100
-18122,457,100
-18123,457,100
-6714,457,100
-6715,457,100
-16378,457,100
-16382,457,100
-16821,457,100
-16822,457,100
-16837,457,100
-16838,457,100
-16864,457,100
-16865,457,100
-16866,457,100
-16867,457,100
-17159,457,100
-17160,457,100
+6713,457,100	//Heart_of_Soul
+6714,457,100	//Sheenas_Soul
+6715,457,100	//Gods_Soul_Piece
+16378,457,100	//Siege_Tele_Scroll_Box_30
+16382,457,100	//WoE_Teleport_Scroll_30_Box
+16821,457,100	//Dungeon_Teleport_Scroll_Box_5
+16822,457,100	//Dungeon_Teleport_Scroll_Box_10
+16837,457,100	//Dungeon_Teleport_Scroll_II_Box_5
+16838,457,100	//Dungeon_Teleport_Scroll_II_Box_10
+16864,457,100	//Siege_Map_Teleport_Scroll_Box_10
+16865,457,100	//Siege_Map_Teleport_Scroll_Box_30
+16866,457,100	//Siege_Map_Teleport_Scroll_II_Box_10
+16867,457,100	//Siege_Map_Teleport_Scroll_II_Box_30
+17159,457,100	//Name_Change_Box
+17160,457,100	//Character_Name_Change_Card_Box
+22540,457,100	//Runstone_Luxanima
+
+// kRO 2013-03-20
+6713,475,100	//Heart_of_Soul
+6720,475,100	//Status_Reset_Coupon
+6721,475,100	//Status_Reset_Coupon_
+14675,475,100	//Shadow_Box_II
+17302,475,100	//Shadow_Box_II_
+17303,475,100	//Shadow_Set_Box_II
+17304,475,100	//Neuralizer_Box_3
+17306,475,100	//Status_Reset_Coupon_Box
+19764,475,100	//C_Monster_Card
+22540,475,100	//Runstone_Luxanima
+22569,475,100	//Gift_New_start
+
+// kRO 2013-04-03
+22592,475,100	//Happy_Call_Box
+
+// kRO 2013-04-17
+14679,475,100	//Article_Sealed_Storm_Scroll
+17314,475,100	//Infinite_Giant_Fly_Wing_Box
+
+// kRO 2013-05-22
+14682,475,100	//Sealed_Beelzebub_Scroll
+17321,475,100	//Three_Master_Package
+17322,475,100	//Three_Master_Package(10)
+
+// kRO 2013-06-05 Ep.15.1
+6748,475,100	//Daily_Report_He_And_His_Team
+6749,475,100	//Operation_Control_Device
+22610,475,100	//New_Beginnings_Box
+
+// kRO 2013-06-19
+22614,475,100	//Premium_Manual
+
+// kRO 2013-06-26
+6752,475,100	//Charleston_Parts
+6753,475,100	//Token_Of_Destruction
+6754,475,100	//Collected_Medicinal_Herbs
+14689,475,100	//Sealed_Kiel-D-01_Scroll
+17331,475,100	//Event_Almighty_Box
+17332,475,100	//Event_Almighty_Box(100)
+22617,475,100	//Clear_Box_S
+22618,475,100	//Clear_Box_A
 
 // kRO 2013-07-17 Items
-6746,475,100
-6747,475,100
-13118,475,100
+6746,475,100	//Iron_Artifacts
+6747,475,100	//Steel_Workpiece
+13118,475,100	//Spark_Light
+
+// kRO 2013-07-24
+14696,475,100	//Sealed_Gloom_Under_Night_Gachapon
+17338,475,100	//Ore_Box_V
+17339,475,100	//Ore_Box_V(10)
+22525,475,100	//Level_Up_Box(140)
+
+// kRO 2013-08-21
+17429,475,100	//11_Anniversary_Shadow_Box
+17430,475,100	//11_Anniversary_Shadow_Package
+
+// kRO 2013-09-25
+14704,475,100	//Gemstone_Shadow_Box
+14705,475,100	//Sealed_Fallen_Bishop_Hibram_Scroll
+15116,475,100	//Armor_Of_Airship
+20743,475,100	//Cloak_Of_Airship
+28310,475,100	//Sarah's_Left_Earring
+28311,475,100	//Sarah's_Right_Earring
+
+// kRO 2013-11-06 Bar Cookie Festival
+17440,475,100	//Name_Change_Card_Box
+17443,475,100	//Reinforcement_Buckler_Box
+
+// kRO 2013-11-20
+14717,475,100	//2013_RWC_Scroll
+17455,475,100	//Premium_Battle_Manual_Box
+
+// kRO 2013-12-18 Casualties Of The Sepulcher & Xmas Event
+6814,475,100	//Swordman_Soul
+6815,475,100	//Merchant_Soul
+6816,475,100	//Thief_Soul
+6817,475,100	//Mage_Soul
+6818,475,100	//Archer_Soul
+6819,475,100	//Acolyte_Soul
+6820,475,100	//Energy_Debris
+18971,475,100	//Old_Rune_Circlet
+18972,475,100	//Old_Mitra
+18973,475,100	//Old_Driver_Band
+18974,475,100	//Old_Driver_Band(Yellow)
+18975,475,100	//Old_Shadow_Handicraft
+18976,475,100	//Old_Minstrel_Song's_Hat
+18977,475,100	//Old_Midas_Whisper
+18978,475,100	//Old_Magic_Stone_Hat
+18979,475,100	//Old_Blazing_Soul
+18980,475,100	//Old_Wind_Whisper
+18981,475,100	//Old_Dying_Swan
+18982,475,100	//Old_Circlet_Of_Bones
+18983,475,100	//Old_Protect_Of_Crown
+18984,475,100	//Old_Camouflage_Rabbit_Hood
+22521,475,100	//Level_Up_Box
+22522,475,100	//Level_Up_Box100
+22523,475,100	//Level_Up_Box120
+22524,475,100	//Level_Up_Box130
+22525,475,100	//Level_Up_Box140
+22526,475,100	//Level_Up_Box150
+22527,475,100	//Level_Up_Box160
+22533,475,100	//New_Year_Gift_Box
+
+// kRO 2013-12-25 Episode 15.2
+6824,475,100	//Experimental_Dong_Memory_Record
+6825,475,100	//Air_Cleaner_Box
+6826,475,100	//Fresh_Grapes
+6827,475,100	//Complete_Machine_Parts
+6828,475,100	//Gravity_Safety_Device
+6832,475,100	//Questioned_Parts
+6833,475,100	//(Limited)_Token_of_Ziegfried
 
 // kRO 2013-10-02 Items
-2997,475,100
-2999,475,100
-18829,475,100
-18830,475,100
-22652,475,100
+2997,475,100	//RWC_Gold_Brooch
+2999,475,100	//RWC_Brooch
+18828,475,100	//2013 RWC Winners Helmet
+18829,475,100	//2013 RWC Runners-Up Helmet
+18830,475,100	//2013 RWC 3rd Helmet
+22652,475,100	//Briliant_Hat_Box
 
 // kRO 2013-10-08
-22675,475,100
+22675,475,100	//Mysterious_Scroll
 
 // kRO 2013-11-06
-17442,475,100
-17449,475,100
-14616,475,100
-14617,475,100
-14618,475,100
-14619,475,100
-14620,475,100
-14621,475,100
+17442,475,100	//Emperium_G_Box
+17449,475,100	//Cookies_Bar_Set
 
 // kRO 2013-11-13
-16628,475,100
+16628,475,100	//Brynhild_Box
+
+// kRO 2014-01-08
+6674,475,100	//GM_Coin
+12314,475,100	//Noive_Box
+12497,475,100	//E_Bubble_Gum
+12501,475,100	//E_Str_Dish10_
+12502,475,100	//E_Agi_Dish10_
+12503,475,100	//E_Int_Dish10_
+12504,475,100	//E_Dex_Dish10_
+12505,475,100	//E_Luk_Dish10_
+12506,475,100	//E_Vit_Dish10_
+12514,475,100	//E_Abrasive
+12515,475,100	//E_Med_Life_Potion
+12516,475,100	//E_Small_Life_Potion
+12522,475,100	//E_Blessing_10_Scroll
+12523,475,100	//E_Inc_Agi_10_Scroll
+13125,475,100	//Metal_Revolver
+13322,475,100	//Huuma_Metal_Shuriken
+14723,475,100	//(Limited)Neuralizer_I
+14724,475,100	//(Limited)Neuralizer_II
+16481,475,100	//Small_Life_Potion_Box_10
+16483,475,100	//Abrasive_Box_10
+16503,475,100	//E_Insurance_Package
+16504,475,100	//Bubble_Gum_Box(10)
+16505,475,100	//Steamed_Tongue_Box_10
+16506,475,100	//Steamed_Desert_Scorpions_Box_10
+16507,475,100	//Dragon_Breath_Cocktail_Box_10
+16508,475,100	//Hwergelmir's_Tonic_Box_10
+16509,475,100	//Cooked_Nine_Tail_Box_10
+16510,475,100	//Immortal_Stew_Box_10
+16514,475,100	//Blessing_Scroll_Box_10
+16515,475,100	//Increase_Agility_Scroll_Box_10
+17468,475,100	//Neuralizer_II_Box_3
+17469,475,100	//Neuralizer_I_Box
+22700,475,100	//Jumping_Support_Box
+
+// kRO 2014-01-22
+14725,475,100	//Sealed_Bacsojin_Scroll
+14726,475,100	//Grid_Shadow_Box
+14727,475,100	//Heal_Shadow_Box
+14728,475,100	//Hiding_Shadow_Box
+14729,475,100	//Cloaking_Shadow_Box
+14730,475,100	//Costume_Festival_Box_II
+17472,475,100	//Support_Package_III
+17473,475,100	//Support_Package_III(10)
+17474,475,100	//Infinite_Giant_Fly_Wing_Box_V
+
+// kRO 2014-01-29 New Year Day Event
+6836,475,100	//Talisman_Of_Soul
+6837,475,100	//Piece_Of_Soul_Mouse
+6838,475,100	//Secret_Orders_Of_Prophet_K
+7690,475,100	//Special_Exchange_Coupons
+19999,475,100	//C_Mouse_Hat1
+20000,475,100	//C_Mouse_Hat2
+20001,475,100	//C_Mouse_Hat3
+20002,475,100	//C_Mouse_Hat4
+20003,475,100	//C_Mouse_Hat5
+
+// kRO 2014-02-05
+17475,475,100	//(Limited)Gym_Membership_Card_Box(10)
+
+// kRO 2014-02-12 San Valentin
+6839,475,100	//Gold_Choco_Coin
+6840,475,100	//Silver_Choco_Coin
+6841,475,100	//Bronze_Choco_Coin
+6842,475,100	//Huge_Jewery
+6843,475,100	//Thin_Ring
+6844,475,100	//Mild_Stone
+6845,475,100	//That_Thing
+22708,475,100	//Exciting_Box
+
+// kRO 2014-02-19
+14731,475,100	//Teleport_Shadow_Box
+14732,475,100	//Steal_Shadow_Box
+14733,475,100	//Sealed_Pharaoh_Scroll
+17477,475,100	//Unlimited_Box_II
+17478,475,100	//Unlimited_Box_II(10)
+
+// kRO 2014-02-26
+6860,475,100	//Piece_Of_Soul_Cow
+20025,475,100	//C_Cow_Hat
+20026,475,100	//C_Cow_Hat
+20027,475,100	//C_Cow_Hat
+20028,475,100	//C_Cow_Hat
+
+// kRO 2014-03-12
+28333,475,100	//Gold_PC_Room_Ring
+
+// kRO 2014-03-19
+17483,475,100	//Three_Master_Package_III
+17484,475,100	//Three_Master_Package_III(10)
+22734,475,100	//Revolution_Quiz_Box
+22735,475,100	//Sealed_Moonlight_Flower_Scroll
+
+// kRO 2014-03-26
+6862,475,100	//Piece_Of_Soul_Tiger
+6863,475,100	//Strong_Piece_Of_Soul_Tiger
+20053,475,100	//C_White_King_Tiger_Doll_Hat
+20063,475,100	//C_Yellow_Brain_Hat
+20064,475,100	//C_Blue_Brain_Hat
+
+// kRO 2014-04-23
+6866,475,100        //Piece_Of_Soul_Rabbit
+14739,475,100        //Sealed_General_Egnigem_Cenia_Scroll
+17491,475,100        //Refinement_Ore_Box_VII
+17492,475,100        //Refinement_Ore_Box_VII(10)
+
+// kRO 2014-04-30
+6864,475,100        //Safe_to_19_Weapon_Certificate
+6865,475,100        //Safe_to_19_Armor_Certificate
+6870,475,100        //Safe_to_13_Weapon_Certificate
+6871,475,100        //Safe_to_14_Weapon_Certificate
+6872,475,100        //Safe_to_15_Weapon_Certificate
+6873,475,100        //Safe_to_16_Weapon_Certificate
+6874,475,100        //Safe_to_17_Weapon_Certificate
+6875,475,100        //Safe_to_18_Weapon_Certificate
+6876,475,100        //Safe_to_13_Armor_Certificate
+6877,475,100        //Safe_to_14_Armor_Certificate
+6878,475,100        //Safe_to_15_Armor_Certificate
+6879,475,100        //Safe_to_16_Armor_Certificate
+6880,475,100        //Safe_to_17_Armor_Certificate
+6881,475,100        //Safe_to_18_Armor_Certificate
+6883,475,100        //Pet_Snow_Bunny_Exchange_Ticket
+6884,475,100        //Pet_Tikbalang_Exchange_Ticket
+22764,475,100        //Pet_Exchange_Ticket_Box
+
+// kRO 2014-05-14
+22777,475,100        //Gift_Buff_Set
+
+// kRO 2014-05-21
+14740,475,100        //Sealed_Vesper_Scroll
+17285,475,100        //Events_Beauty_Gift_Box
+17495,475,100        //Lucky_Silvervine_Fruit_Box_III10
+17496,475,100        //Lucky_Silvervine_Fruit_Box_III110
+6886,475,100	//Strong_Piece_Of_Soul_Dragon
+20086,475,100	//C_Dragon_Cintamani_Hat1
+20087,475,100	//C_Dragon_Cintamani_Hat2
+20088,475,100	//C_Dragon_Cintamani_Hat3
+20089,475,100	//C_Dragon_Cintamani_Hat4
+
+// kRO 2014-05-28
+6885,475,100	//Piece_Of_Soul_Dragon

+ 64 - 4
db/re/mob_db.txt

@@ -1376,8 +1376,7 @@
 2241,B_TRENTINI,Gypsy Trentini,Gypsy Trentini,160,3894278,0,4463758,2563096,1,1070,1498,181,112,176,258,155,132,309,95,10,12,1,7,84,0x37B5,100,76,384,288,2231879,0,0,0,0,0,0,12623,9000,12616,9000,616,9000,6224,9000,18103,5000,18110,5000,1963,5000,0,0,0,0,0,0
 2242,MD_DESERT_WOLF,Desert Wolf,Desert Wolf,135,551578,0,0,0,1,1040,1158,151,39,93,69,63,61,82,42,10,12,1,6,20,0x37B5,200,1120,420,288,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
 2243,MD_DESERT_WOLF_B,Desert Wolf,Desert Wolf,130,274531,0,0,0,1,66,82,13,0,10,12,8,5,17,7,10,12,0,6,20,0x37B5,300,1600,900,240,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
-// Fix me! 2244 needs new info.
-2244,QUEST_CHEN,Champion Chen,Champion Chen,99,15000,2000,0,0,1,1700,3000,216,134,126,74,71,123,99,65,10,12,1,7,68,0x37B5,180,1152,384,288,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
+2244,QUEST_CHEN,Champion Chen,Champion Chen,130,300,1,0,0,1,103,126,25,56,122,81,83,130,201,61,10,12,1,7,81,0x37B5,300,200,768,288,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
 2245,EXP_TEST,Exp Test,Exp Test,1,100,1,100,100,1,8,9,2,5,6,1,1,0,6,5,10,12,1,7,21,0x83,400,1000,480,288,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
 2246,Q_WOOTAN_FIGHTER,Wootan Fighter,Wootan Fighter,95,9000,1,1400,2000,1,255,291,103,8,63,14,36,5,62,15,10,12,1,7,43,0x83,200,912,1344,480,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
 2247,Q_INCREASE_SOIL,Increase Soil,Mi Gao,95,20000,1,1400,2000,1,365,395,112,39,67,23,41,49,94,30,10,12,1,0,62,0x83,445,106,1056,576,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
@@ -2284,5 +2283,66 @@
 3203,INORGANIC_JAKK,Inorganic Pumpkin,Inorganic Pumpkin,10,40,1,20,13,1,100,100,160,99,1,1,1,1,999,1,0,0,0,3,21,0x61,200,0,0,0,0,0,0,0,0,0,0,6805,5000,6805,5000,6805,1000,2267,100,1062,1000,664,100,546,1000,12192,100,0,0,0,0
 //3204,JT_PIXY_PINK_PORING,Poring,Poring,1,60,1,27,20,1,8,9,2,5,6,1,1,0,6,5,10,12,1,3,21,0x83,400,1872,672,480,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
 //3205,JT_PIXY_BLUE_PORING,Poring,Poring,1,60,1,27,20,1,8,9,2,5,6,1,1,0,6,5,10,12,1,3,21,0x83,400,1872,672,480,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
-//3206,JT_LITTLE_GOLDPORING
-//3207,JT_E_AQUA_ELEMENTAL
+//3206,JT_LITTLE_GOLDPORING,Poring,Poring,1,60,1,27,20,1,8,9,2,5,6,1,1,0,6,5,10,12,1,3,21,0x83,400,1872,672,480,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
+//3207,JT_E_AQUA_ELEMENTAL,Poring,Poring,1,60,1,27,20,1,8,9,2,5,6,1,1,0,6,5,10,12,1,3,21,0x83,400,1872,672,480,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
+//
+//3295,JT_G_MOBSTER
+//3296,JT_HIDDEN_TEST
+//3297,JT_PAD_LEVIATHAN
+//3299,JT_PAD_IFRIT
+//3300,JT_PAD_HORAI
+//3301,JT_PAD_SHANGRILA
+//3302,JT_PAD_NIRAIKANAI
+//3303,JT_PAD_HELHEIM
+//3304,JT_PAD_MUSPELHEIM
+//3305,JT_PAD_ZAEROG
+//3306,JT_PAD_TAMADORA
+//3307,JT_PAD_TAMADORABABY
+//3308,JT_ROC_EMPELIUM
+//3309,JT_ROC_OBJ_A
+//3310,JT_ROC_OBJ_B
+//3311,JT_ROC_OBJ_N
+//3312,JT_ROC_TOWER_A
+//3313,JT_ROC_TOWER_B
+//3314,JT_SMOKIE_THIEF
+//3315,JT_PAD_KINGGOLD
+//3316,JT_PAD_KINGMETAL
+//3317,JT_PAD_RUBYLIT
+//3318,JT_PAD_SAPPHILIT
+//3319,JT_PAD_EMELIT
+//3320,JT_PAD_TOPALIT
+//3321,JT_PAD_AMELIT
+//3322,JT_PAD_METAL_DRAGON
+//3323,JT_PAD_M_FLAME_KNIGHT
+//3324,JT_PAD_M_ICE_KNIGHT
+//3325,JT_PAD_M_STONE_KNIGHT
+//3326,JT_PAD_M_LIGHT_KNIGHT
+//3327,JT_PAD_M_DARK_KNIGHT
+//3328,JT_PAD_C_D_DRAGON
+//3329,JT_PAD_ECHIDNA
+//3330,JT_PAD_SIREN
+//3331,JT_PAD_LILITH
+//3332,JT_PAD_HERA
+//3333,JT_PAD_RUBYLIT_H
+//3334,JT_PAD_SAPPHILIT_H
+//3335,JT_PAD_EMELIT_H
+//3336,JT_PAD_TOPALIT_H
+//3337,JT_PAD_AMELIT_H
+//3338,JT_PAD_METAL_DRAGON_H
+//3339,JT_PAD_M_FLAME_KNIGHT_H
+//3340,JT_PAD_M_ICE_KNIGHT_H
+//3341,JT_PAD_M_STONE_KNIGHT_H
+//3342,JT_PAD_M_LIGHT_KNIGHT_H
+//3343,JT_PAD_M_DARK_KNIGHT_H
+//3344,JT_PAD_C_D_DRAGON_H
+//3345,JT_PAD_ECHIDNA_H
+//3346,JT_PAD_SIREN_H
+//3347,JT_PAD_LILITH_H
+//3348,JT_PAD_HERA_H
+//3349,JT_PAD_MYTHLIT
+//3350,JT_PAD_TYRRA
+//3351,JT_PAD_TYRANNOS
+//3352,JT_PAD_PLESSIE
+//3353,JT_PAD_PLESIOS
+//3354,JT_PAD_BRACHY
+//3355,JT_PAD_BRACHYS

+ 21 - 21
db/re/skill_cast_db.txt

@@ -1091,11 +1091,11 @@
 //-- RK_DRAGONHOWLING
 2009,0,0,0,15000,0,10000,-1
 //-- RK_MILLENNIUMSHIELD
-2011,0,1000,0,180000,60000,0,-1
+2011,0,1000,0,180000,60000,60000,-1
 //-- RK_CRUSHSTRIKE
-2012,0,0,0,30000,30000,0,1000
+2012,0,0,0,30000,30000,30000,1000
 //-- RK_REFRESH
-2013,0,0,0,60000,120000,0,1000
+2013,0,0,0,60000,120000,120000,1000
 //-- RK_GIANTGROWTH
 2014,0,0,0,180000,0,0,1000
 //-- RK_STONEHARDSKIN
@@ -1451,7 +1451,7 @@
 //-- SR_GENTLETOUCH_CURE
 2345,0,1000,0,0,0,1000:1500:2000:2500:3000,-1
 //-- SR_GENTLETOUCH_ENERGYGAIN
-2346,1000,1000,0,240000,0,0,1000:1500:2000:2500:3000
+2346,1000,1000,0,240000,600000,0,1000:1500:2000:2500:3000
 //-- SR_GENTLETOUCH_CHANGE
 2347,1000,1000,0,240000,0,200000:180000:160000:140000:120000,1000
 //-- SR_GENTLETOUCH_REVITALIZE
@@ -1795,49 +1795,49 @@
 //-- MH_PAIN_KILLER
 8021,1000:1200:1400:1600:1800,0,0,20000:30000:40000:50000:60000,0,0,1000:800:600:400:200
 //-- MH_LIGHT_OF_REGENE
-8022,1600:1400:1200:1000:800,0,0,360000:420000:480000:540000:600000,0,0,1600:1400:1200:1000:800
+8022,0,0,0,360000:420000:480000:540000:600000,0,0,1600:1400:1200:1000:800
 //-- MH_OVERED_BOOST
 8023,800:700:600:500:400,0,0,30000:45000:60000:75000:90000,0,0,200:300:400:500:600
 //-- MH_ERASER_CUTTER
 8024,1000:1500:2000:2500:3000,2000,0,0,0,0,-1
 //-- MH_XENO_SLASHER
-8025,1500:2500:3500:4500:5500,0,0,500,120000,0,500
+8025,1500:2500:3500:4500:5500,5000,0,500,0,0,500
 //-- MH_SILENT_BREEZE
-8026,2000,0,0,9000:12000:15000:18000:21000,0,0,1000:800:600:400:200
+8026,1000:1200:1400:1600:1800,0,0,9000:12000:15000:18000:21000,0,0,1000:800:600:400:200
 //-- MH_STYLE_CHANGE
-8027,0,1000,0,0,0,0,500
+//8027,0,0,0,0,0,0,0
 //-- MH_SONIC_CRAW
 //8028,0,0,0,0,0,0,0
 //-- MH_SILVERVEIN_RUSH
-8029,0,0,0,5000,0,2000,0
+//8029,0,0,0,0,0,0,0
 //-- MH_MIDNIGHT_FRENZY
-8030,0,0,0,10000,0,2000,0
+//8030,0,0,0,0,0,0,0
 //-- MH_STAHL_HORN
-8031,800:600:400:200:0,3000,0,5000,0,0,200:400:600:800:1000
+8031,800:600:400:200:0,0,0,5000,0,0,200:400:600:800:1000
 //-- MH_GOLDENE_FERSE
 8032,1000:1200:1400:1600:1800,0,0,30000:45000:60000:75000:90000,0,0,-1
 //-- MH_STEINWAND
-8033,500,0,0,30000:45000:60000:75000:90000,0,0,1000
+8033,1000,0,0,30000:45000:60000:75000:90000,0,0,-1
 //-- MH_HEILIGE_STANGE
-8034,200:400:600:800:1000,5000,0,0,0,0,1800:1600:1400:1200:1000
+8034,200:400:600:800:1000,0,0,0,0,0,1800:1600:1400:1200:1000
 //-- MH_ANGRIFFS_MODUS
 8035,200:400:600:800:1000,0,0,30000:45000:60000:75000:90000,0,0,-1
 //-- MH_TINDER_BREAKER
-8036,1000,0,0,5000,0,0,0
+//8036,0,0,0,5000,0,0,0
 //-- MH_CBC
-8037,0,0,0,0,0,0,0
+//8037,0,0,0,0,0,0,0
 //-- MH_EQC
-8038,0,1000,0,0,0,0,0
+//8038,0,0,0,0,0,0,0
 //-- MH_MAGMA_FLOW
-8039,2000:2500:3000:3500:4000,1000,0,30000:45000:60000:75000:90000,0,0,2000:1500:1000:500:-1
+8039,2000:2500:3000:3500:4000,0,0,30000:45000:60000:75000:90000,0,0,2000:1500:1000:500:-1
 //-- MH_GRANITIC_ARMOR
-8040,5000:4500:4000:3500:3000,1000,0,60000,0,0,1000
+8040,6000:5500:5000:4500:4000,0,0,60000,0,0,1000
 //-- MH_LAVA_SLIDE
-8041,5000:4500:4000:3500:3000,1000,0,12000:14000:16000:18000:20000,10000,0,1000
+8041,6000:5500:5000:4500:4000,0,0,12000:14000:16000:18000:20000,0,0,1000
 //-- MH_PYROCLASTIC
-8042,1000:1500:2000:2500:3000,1000,0,60000:90000:120000:150000:180000,0,0,200
+8042,5000:4500:4000:3500:3000,0,0,60000:90000:120000:150000:180000,0,0,1000
 //-- MH_VOLCANIC_ASH
-8043,4000:3500:3000:2500:2000,0,0,12000:14000:16000:18000:20000,0,0,1000
+8043,5000:4500:4000:3500:3000,0,0,12000:14000:16000:18000:20000,0,0,1000
 
 //===== Mercenary Skills ===================
 //-- MS_MAGNUM

+ 7 - 7
db/re/skill_db.txt

@@ -544,7 +544,7 @@
 //****
 // Sniper
 380,0,6,4,0,0x1,0,10,1,no,0,0,0,weapon,0,0x0,	SN_SIGHT,Falcon Eyes
-381,5,8,1,0,0x40,0,5,1,yes,0,0,0,misc,0,0x80,		SN_FALCONASSAULT,Falcon Assault
+381,5,8,1,-3,0x40,0,5,1,yes,0,0,0,misc,0,0x80,		SN_FALCONASSAULT,Falcon Assault
 382,9,8,1,-1,0,2,5,1,yes,0,0,13,weapon,0,0x0,	SN_SHARPSHOOTING,Focused Arrow Strike
 383,0,6,4,0,0x3,-1,10,1,yes,0,0,0,weapon,0,0x0,	SN_WINDWALK,Wind Walker
 
@@ -891,7 +891,7 @@
 2009,0,6,4,0,0x3,3:4:5:6:7,5,1,no,0,0,0,none,0,0x0,	RK_DRAGONHOWLING,Dragon Howling
 2010,0,0,0,0,0,0,10,0,no,0,0,0,none,0,0x0,		RK_RUNEMASTERY,Rune Mastery
 2011,0,6,4,0,0x1,0,1,1,no,0,0,0,none,0,0x0,	RK_MILLENNIUMSHIELD,Millenium Shield
-2012,1,6,4,-1,0,0,1,1,yes,0,0,0,weapon,0,0x0,	RK_CRUSHSTRIKE,Crush Strike
+2012,1,6,4,-1,0,0,1,1,yes,0,0,0,none,0,0x0,	RK_CRUSHSTRIKE,Crush Strike
 2013,0,6,4,0,0x1,0,1,1,yes,0,0,0,none,0,0x0,	RK_REFRESH,Refresh
 2014,0,6,4,0,0x1,0,1,1,yes,0,0,0,none,0,0x0,	RK_GIANTGROWTH,Giant Growth
 2015,0,6,4,0,0x1,0,1,1,yes,0,0,0,none,0,0x0,	RK_STONEHARDSKIN,Stone Hard Skin
@@ -994,7 +994,7 @@
 2240,0,6,4,0,0,0,1,1,no,0,0,0,none,0,0x0,		RA_WUGMASTERY,Warg Mastery
 2241,0,6,4,0,0,0,3,1,no,0,0,0,none,0,0x2000,		RA_WUGRIDER,Warg Rider
 2242,0,6,4,-1,0x42,1,1,0,no,0,0,0,weapon,0,0x2000,	RA_WUGDASH,Warg Dash
-2243,9,6,1,0,0x40,0,5,1,no,0,0,0,misc,0,0x2000,	RA_WUGSTRIKE,Warg Strike
+2243,9,6,1,0,0x40,0,5,1,no,0,0,0,weapon,0,0x2000,	RA_WUGSTRIKE,Warg Strike
 2244,9,6,1,0,0x40,0,5,1,no,0,0,0,weapon,0,0x80,	RA_WUGBITE,Warg Bite
 2245,0,0,0,0,0,0,10,0,no,0,0,0,none,0,0x0,		RA_TOOTHOFWUG,Tooth of Warg
 2246,0,6,4,0,0x2,3:4:5:6:7,5,1,no,0,0,0,weapon,0,0x0,	RA_SENSITIVEKEEN,Sensitive Keen
@@ -1021,7 +1021,7 @@
 2264,0,6,4,0,0x1,0,1,1,no,0,0,0,none,7,0x0,		NC_F_SIDESLIDE,Front-Side Slide
 2265,0,6,4,0,0x1,0,1,1,no,0,0,0,none,7,0x0,		NC_B_SIDESLIDE,Back-Side Slide
 2266,0,0,0,0,0,0,4,0,no,0,0,0,none,0,0x0,		NC_MAINFRAME,Mainframe Restructure
-2267,0,6,4,-1,0xCA,2:3:4,3,1,no,0,0,0,misc,5,0x0,	NC_SELFDESTRUCTION,Self Destruction
+2267,0,6,4,0,0xCA,2:3:4,3,1,no,0,0,0,weapon,5,0x0,	NC_SELFDESTRUCTION,Self Destruction
 2268,0,6,4,0,0x1,0,4,1,yes,0,0,0,none,0,0x0,	NC_SHAPESHIFT,Shape Shift
 2269,0,6,4,0,0x1,0,1,1,no,0,0,0,none,0,0x0,		NC_EMERGENCYCOOL,Emergency Cool
 2270,0,6,4,0,0x3,7,1,1,yes,0,0,0,none,0,0x0,	NC_INFRAREDSCAN,Infrared Scan
@@ -1346,9 +1346,9 @@
 8021,1,6,16,0,0x1,0,5,1,no,0,0,0,none,0,0x0,		MH_PAIN_KILLER,Pain Killer
 8022,0,6,4,0,0,0x1,5,1,no,0,0,0,none,0,0x0,		MH_LIGHT_OF_REGENE,Light of Regene
 8023,0,6,4,0,0,0x1,5,1,no,0,0,0,none,0,0x0,		MH_OVERED_BOOST,Overed Boost
-8024,7,6,1,4:0:4:0:4,0,0,5,1,no,0,0,0,magic,0,0x0,	MH_ERASER_CUTTER,Eraser Cutter
-8025,7,6,2,4:0:4:0:4,0,0,5,1,no,0,0,0,magic,0,0x0,	MH_XENO_SLASHER,Xeno Slasher
-8026,5:5:7:7:9,6,16,0,0x1,0,5,1,no,0,0,0,magic,0,0x0,	MH_SILENT_BREEZE,Silent Breeze
+8024,7,8,1,4:0:4:0:4,0,0,5,-6,yes,0,0,0,magic,0,0x0,	MH_ERASER_CUTTER,Eraser Cutter
+8025,7,8,2,4:0:4:0:4,0x2,2:2:3:3:4,5,-6,no,0,0,0,magic,0,0x0,	MH_XENO_SLASHER,Xeno Slasher
+8026,5:5:7:7:9,6,6,0,0x1,0,5,1,no,0,0,0,magic,0,0x0,	MH_SILENT_BREEZE,Silent Breeze
 8027,0,6,4,0,0x1,0,1,1,no,0,0,0,none,0,0x0,		MH_STYLE_CHANGE,Style Change
 8028,1,8,1,0,0,0,5,1,no,0,0x0200,0,weapon,0,0x0,		MH_SONIC_CRAW,Sonic Claw
 8029,1,6,4,0,0,0,5,1,no,0,0x200,0,weapon,0,0x0,	MH_SILVERVEIN_RUSH,Silver Bain Rush

+ 13 - 12
db/re/skill_require_db.txt

@@ -118,7 +118,7 @@
 
 //****
 // WZ Wizard
-80,0,0,75,0,0,0,99,0,0,none,0,0,717,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0								//WZ_FIREPILLAR
+80,0,0,75,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,717,1,717,1,717,1,717,1,717,1,0						//WZ_FIREPILLAR
 81,0,0,35:37:39:41:43:45:47:49:51:53,0,0,0,99,0,0,none,SC_SIGHT,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0	//WZ_SIGHTRASHER
 83,0,0,20:24:30:34:40:44:50:54:60:64,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0	//WZ_METEOR
 84,0,0,20:23:26:29:32:35:38:41:44:47,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0	//WZ_JUPITEL
@@ -623,6 +623,7 @@
 2228,0,0,1,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0								//WL_SUMMON_ATK_GROUND
 2229,0,0,10:12:14:16:18,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0					//WL_SUMMONSTONE
 2230,0,0,3:20,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//WL_RELEASE
+2231,0,0,40,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0								//WL_READING_SB
 //2232,0,0,1,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//WL_FREEZE_SP
 
 //****
@@ -678,25 +679,25 @@
 //****
 // NC Mechanic
 2256,0,0,3:6:9:12:15,0,0,0,99,0,0,mado,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0					//NC_BOOSTKNUCKLE
-2257,0,0,50,0,0,0,99,0,0,mado,0,0,1549,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//NC_PILEBUNKER
+2257,0,0,50,0,0,0,99,0,0,mado,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1549							//NC_PILEBUNKER
 2258,0,0,2:4:6,0,0,0,99,0,0,mado,0,0,6145,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_VULCANARM
-2259,0,0,20,0,0,0,99,0,0,mado,0,0,2139,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_FLAMELAUNCHER
+2259,0,0,20,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2139						//NC_FLAMELAUNCHER
 2260,0,0,20,0,0,0,99,0,0,mado,0,0,6146,1,6147,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_COLDSLOWER
 2261,0,0,40:45:50,0,0,0,99,8,1,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0					//NC_ARMSCANNON
-2262,0,0,20:40:60,0,0,0,99,0,0,mado,0,0,2800,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0					//NC_ACCELERATION
-2263,0,0,25,0,0,0,99,0,0,mado,0,0,2801,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_HOVERING
+2262,0,0,20:40:60,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2800					//NC_ACCELERATION
+2263,0,0,25,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2801						//NC_HOVERING
 2264,0,0,5,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//NC_F_SIDESLIDE
 2265,0,0,5,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//NC_B_SIDESLIDE
 
-2267,0,0,1,0,0,0,99,0,0,mado,0,0,2802,0,6146,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_SELFDESTRUCTION
-2268,0,0,100,0,0,0,99,0,0,mado,0,0,2803,0,6360,1,6363,1,6362,1,6361,1,6146,2,0,0,0,0,0,0,0,0,0			//NC_SHAPESHIFT
-2269,0,0,20,0,0,0,99,0,0,mado,0,0,2804,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_EMERGENCYCOOL
+2267,0,0,1,0,0,0,99,0,0,mado,0,0,6146,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2802						//NC_SELFDESTRUCTION
+2268,0,0,100,0,0,0,99,0,0,mado,0,0,6360,1,6363,1,6362,1,6361,1,0,0,0,0,0,0,0,0,0,0,6146,2,2803			//NC_SHAPESHIFT
+2269,0,0,20,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2804						//NC_EMERGENCYCOOL
 2270,0,0,45,0,0,0,99,0,0,mado,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0								//NC_INFRAREDSCAN
 2271,0,0,30,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0							//NC_ANALYZE
-2272,0,0,90,0,0,0,99,0,0,mado,0,0,2805,0,6146,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_MAGNETICFIELD
-2273,0,0,90,0,0,0,99,0,0,mado,0,0,2806,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0						//NC_NEUTRALBARRIER
-2274,0,0,100:150:200,0,0,0,99,0,0,mado,0,0,2808,0,6146,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0				//NC_STEALTHFIELD
-2275,0,0,25:30:35:40:45,0,0,0,99,0,0,mado,0,0,2807,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0			//NC_REPAIR
+2272,0,0,90,0,0,0,99,0,0,mado,0,0,6146,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2805						//NC_MAGNETICFIELD
+2273,0,0,90,0,0,0,99,0,0,mado,0,0,6146,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2806						//NC_NEUTRALBARRIER
+2274,0,0,100:150:200,0,0,0,99,0,0,mado,0,0,6146,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2808				//NC_STEALTHFIELD
+2275,0,0,25:30:35:40:45,0,0,0,99,0,0,mado,0,0,12392,1,12392,1,12393,1,12393,1,12394,1,0,0,0,0,0,0,0,0,6146,1,2807			//NC_REPAIR
 
 2278,0,0,20:22:24:26:28,0,0,0,6:7,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0				//NC_AXEBOOMERANG
 2279,0,0,20:22:24:26:28,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0					//NC_POWERSWING

+ 3 - 3
db/skill_changematerial_db.txt

@@ -7,7 +7,7 @@
 // Up to 5 ID/Amount pairs can be specified.
 // Rate = n/10%
 
-703,4,800,2,200		// Hinalle 
+703,1000,4,800,2,200		// Hinalle 
 958,800,9,1000		// Horrendous_Mouth
 959,800,7,1000		// Rotten_Scale
 960,1000,6,800,9,200	// Nipper 
@@ -30,8 +30,8 @@
 1010,800,8,1000		// Phracon
 1011,800,4,1000		// Emveretarcon
 1012,800,3,1000		// Lizard_Scruff
-1013,9,800,13,200	// Colorful_Shell
-1014,4,800,6,200	// Jaws_Of_Ant
+1013,1000,9,800,13,200	// Colorful_Shell
+1014,1000,4,800,6,200	// Jaws_Of_Ant
 1016,1000,7,800,10,200	// Rat_Tail 
 1019,800,2,1000		// Wooden_Block
 1020,1000,4,800,6,200	// Long_Hair 

+ 16 - 0
doc/atcommands.txt

@@ -972,6 +972,22 @@ If no position is given, the command defaults to headgear.
 
 ---------------------------------------
 
+@costume {<costume name>}
+
+Changes the player's visible appearance to that of the selected costume.
+
+Available costumes:
+Wedding,
+Xmas,
+Summer,
+Hanbok,
+Oktoberfest
+
+Typing the command without a costume name will display available costumes. If the
+player is wearing a costume it will be removed.
+
+---------------------------------------
+
 @fakename {<text string>}
 
 Temporarily changes name to the specified string (lasts until player logs out).

+ 7 - 6
doc/item_bonus.txt

@@ -161,12 +161,13 @@ bonus bNoMiscDamage,n;  		Adds n% reduction to received misc damage
 
 Healing
 -------
-bonus bHealPower,n;      		Increases heal amount of all heal skills by n%
-bonus bHealPower2,n;     		Increases heal amount if you are healed by any skills by n%
-bonus2 bSkillHeal,sk,n;  		Increases heal amount of skill sk by n%
-bonus2 bSkillHeal2,sk,n; 		Increases heal amount if you are healed by skill sk by n%
-bonus bAddItemHealRate,n;		Increases HP recovered by n% for healing items
-bonus2 bAddItemHealRate,iid/ig,n;	Increases HP recovered by n% for items of either id iid or item group ig
+bonus bHealPower,n;      			Increases heal amount of all heal skills by n%
+bonus bHealPower2,n;     			Increases heal amount if you are healed by any skills by n%
+bonus2 bSkillHeal,sk,n;  			Increases heal amount of skill sk by n%
+bonus2 bSkillHeal2,sk,n; 			Increases heal amount if you are healed by skill sk by n%
+bonus bAddItemHealRate,n;			Increases HP recovered by n% for healing items
+bonus2 bAddItemHealRate,iid,n;		Increases HP recovered by n% for item iid
+bonus2 bAddItemGroupHealRate,ig,n;	Increases HP recovered by n% for items of item group ig
 
 Cast time/delay
 ---------------

+ 4 - 4
doc/item_db.txt

@@ -132,8 +132,8 @@ Loc: Equipment's placement. Values are:
 	2^5      032 = Shield
 	2^2      004 = Garment
 	2^6      064 = Footgear
-	2^3      008 = Accessory 1
-	2^7      128 = Accessory 2
+	2^3      008 = Accessory Right
+	2^7      128 = Accessory Left
 	2^10    1024 = Costume Top Headgear
 	2^11    2048 = Costume Mid Headgear
 	2^12    4096 = Costume Low Headgear
@@ -143,8 +143,8 @@ Loc: Equipment's placement. Values are:
 	2^17  131072 = Shadow Weapon
 	2^18  262144 = Shadow Shield
 	2^18  524288 = Shadow Shoes
-	2^20 1048576 = Shadow Accessory 2
-	2^21 2097152 = Shadow Accessory 1
+	2^20 1048576 = Shadow Accessory Right (Earring)
+	2^21 2097152 = Shadow Accessory Left (Pendant)
 
 ---------------------------------------
 

+ 26 - 14
doc/script_commands.txt

@@ -2803,14 +2803,24 @@ and return the info set by TYPE argument.
 It will return -1 if there is no such item.
 
 Valid types are:
-	0 - Buy Price; 1 - Sell Price; 2 - Item Type;
-	3 - maxchance (max drop chance of this item, e.g. 1 = 0.01%)
-		if = 0, then monsters don't drop it at all (rare or a quest item)
-		if = 10000, then this item is sold in NPC shops only
-	4 - sex; 5 - equip; 6 - weight; 7 - atk; 8 - def; 9 - range;
-	10 - slot; 11 - look; 12 - elv; 13 - wlv; 14 - view id (from 'db/item_avail.txt')
-	
-	If RENEWAL is defined, 15 - matk
+	0  - Buy Price
+	1  - Sell Price
+	2  - Type
+	3  - maxchance (max drop chance of this item, e.g. 1 = 0.01%)
+		 if = 0, then monsters don't drop it at all (rare or a quest item)
+		 if = 10000, then this item is sold in NPC shops only
+	4  - Gender
+	5  - Loc
+	6  - Weight
+	7  - ATK
+	8  - DEF
+	9  - Range
+	10 - Slot
+	11 - View
+	12 - eLV
+	13 - wLV
+	14 - SpriteID from 'db/item_avail.txt'
+	15 - matk if RENEWAL is defined
 
 See the sample in 'doc/sample/getiteminfo.txt'.
 
@@ -4353,10 +4363,10 @@ in this manner cannot be dropped, sold, vended, auctioned, or mailed, and in
 some cases cannot be traded or stored.
 
 Valid bound types are:
- 1 - Account Bound
- 2 - Guild Bound
- 3 - Party Bound
- 4 - Character Bound
+ Bound_Account : Account Bound item
+ Bound_Guild   : Guild Bound item
+ Bound_Party   : Party Bound item
+ Bound_Char    : Character Bound item
 
 ---------------------------------------
 
@@ -4506,8 +4516,8 @@ See 'getitem2' for an explanation of the expanded parameters.
 
 *cartdelitem2 <item id>,<amount>,<identify>,<refine>,<attribute>,<card1>,<card2>,<card3>,<card4>{,<account ID>};
 *cartdelitem2 "<item name>",<amount>,<identify>,<refine>,<attribute>,<card1>,<card2>,<card3>,<card4>{,<account ID>};
-*storageitem2 <item id>,<amount>,<identify>,<refine>,<attribute>,<card1>,<card2>,<card3>,<card4>{,<account ID>};
-*storageitem2 "<item name>",<amount>,<identify>,<refine>,<attribute>,<card1>,<card2>,<card3>,<card4>{,<account ID>};
+*storagedelitem2 <item id>,<amount>,<identify>,<refine>,<attribute>,<card1>,<card2>,<card3>,<card4>{,<account ID>};
+*storagedelitem2 "<item name>",<amount>,<identify>,<refine>,<attribute>,<card1>,<card2>,<card3>,<card4>{,<account ID>};
 
 Same like delitem2, but deletes item from cart or storage.
 If cart is not mounted, it will be failed.
@@ -5637,6 +5647,8 @@ command, simply use 1 for type. Any other number won't be recognized.
 
 This function will return information about a monster record in the database, as 
 per 'db/(pre-)re/mob_db.txt'. Type is the kind of information returned. Valid types are:
+It will return 0 if there is no such monster (or the type value is invalid),
+or an empty string if you requested the monster's name.
 
  1 - 'english name' field in the database, a string.
  2 - 'japanese name' field in the database, a string.

+ 2 - 1
npc/custom/jobmaster.txt

@@ -131,7 +131,8 @@ function Job_Menu {
 			mes "You are now "+callfunc("F_InsertArticle",jobname(.@i))+"!";
 			if (.@i==4001 && .LastJob) set lastJob, Class;
 			jobchange .@i;
-			if (.@i==4001 || .@i==4023) resetlvl(1);
+			if (.@i==4001) resetlvl(1);
+			else if (.@i==Job_Baby) resetstatus;
 			specialeffect2 EF_ANGEL2; specialeffect2 EF_ELECTRIC;
 			if (.Platinum) callsub Get_Platinum;
 			close;

+ 8 - 3
npc/jobs/2-2/alchemist.txt

@@ -3,7 +3,7 @@
 //===== By: ==================================================
 //= nestor_zulueta (Fusion), converted by Darkchild
 //===== Current Version: ===================================== 
-//= 3.0
+//= 3.1
 //===== Compatible With: ===================================== 
 //= rAthena Project
 //===== Description: ========================================= 
@@ -17,6 +17,7 @@
 //= 2.8 Fixed minor typo in test section. [L0ne_W0lf]
 //= 2.9 Added Quest Log commands. [Kisuka]
 //= 3.0 Removed the need for use of 'goto.' [L0ne_W0lf]
+//= 3.1 Added missing changequest commands. [Kisuka]
 //============================================================ 
 
 alde_alche,27,185,5	script	Alchemist Guildsman#am	744,{
@@ -467,6 +468,7 @@ alde_alche,175,107,3	script	Fastidious Alchemist#am	749,{
 				mes "He'll teach you how to do the experiments. Just tell him that";
 				mes "I sent you.";
 				set ALCH_Q,6;
+				changequest 2031,2032;
 				close;
 			}
 			else {
@@ -1092,6 +1094,7 @@ alde_alche,13,15,7	script	Studying Man#am	750,{
 			mes "and cast away the last";
 			mes "vestiges of Merchant life!!";
 			set ALCH_Q,40;
+			changequest 2033,2034;
 			close;
 		}
 		else if (countitem(7134) > 2 && countitem(713) > 2 && countitem(507) > 0 && countitem(508) > 0 && countitem(509) > 0) {
@@ -1686,9 +1689,12 @@ alde_alche,101,184,4	script	Master Alchemist#am	122,{
 			cutin "",255;
 			end;
 		}
-		if(checkquest(2039) != -1) {
+		if (checkquest(2039) != -1) {
 			changequest 2039,2040;
 		}
+		if (checkquest(2034) != -1) {
+			changequest 2034,2040;
+		}
 		mes "Ah, well done.";
 		mes "I can see that you";
 		mes "have learned all of";
@@ -1705,7 +1711,6 @@ alde_alche,101,184,4	script	Master Alchemist#am	122,{
 		mes "illustrious Union.";
 		mes "I hope you learn a lot...";
 		next;
-
 		if (.@jlevel == 50) {
 			getitem 7133,1; //Slim_Potion_Create_Book
 			mes "[Vincent Carsciallo]";

Datei-Diff unterdrückt, da er zu groß ist
+ 208 - 323
npc/other/monster_race.txt


+ 3182 - 0
npc/re/instances/WolfchevLaboratory.txt

@@ -0,0 +1,3182 @@
+//===== rAthena Script =======================================
+//= Wolfchev's Laboratory
+//===== By: ==================================================
+//= Kisuka
+//===== Current Version: =====================================
+//= 1.0
+//===== Compatible With: =====================================
+//= rAthena Project
+//===== Description: =========================================
+//= Defeat Wolfchev's human experimentations.
+//===== Additional Comments: =================================
+//= 1.0 First version, edited. [Euphy]
+//============================================================
+
+// Giacomo Girolam
+//============================================================
+lighthalzen,303,303,6	script	Giacomo Girolamo#kiup2	4_M_KHMAN,3,3,{
+	if ((MaxWeight - Weight) < 1000 || !checkweight(1201, 1)) {
+		mes "^FF0000 Check up your inventory. You got too many items to carry out the quest. ^000000";
+		close;
+	}
+	if (lhz_boss > 30) {
+		if (!lght_duk01) {
+			if (Sex) {
+				emotion e_pif, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "....a guy....?";
+				next;
+				mes "[Giacomo Girolamo]";
+				mes "Ah! Hey! Man!";
+				next;
+				select("What's up?");
+				emotion e_what, 1;
+				mes "[Giacomo Girolamo]";
+				mes "Have you ever heard of horrific human experimentation committed in Rekenber Corporation whose head office is here in Lighthalzen?";
+				next;
+				select("Whaaat?! human experimentation?");
+				emotion e_omg, 1;
+				mes "[Giacomo Girolamo]";
+				mes "Yea! human experimentation!!";
+				mes "There are a lot of rumors that horrible human experimentation is actually performed, but these people in the slum....don't want to believe that due to the welfare movement from Rekenber.";
+				next;
+				emotion e_swt2, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "Well! and those rich people, seem to know something but they never mention that...";
+				next;
+				mes "[Giacomo Girolamo]";
+				mes "Ahh!! And this is a secret that just SOME PEOPLE know. I heard that from Rekenber Lab.,.. a person named...um...Wol....";
+				next;
+				emotion e_hmm, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "Anyway!! A scientist named Wolf.. something suddenly got sacked. and he must be related with this rumor, I think...";
+				next;
+				select("You mean... Wolfchev?");
+				emotion e_gasp, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "Ohhhh?! yeah Wolfchev!! That's right, the name was Wolfchev.. The mad scientist..";
+				next;
+				emotion e_ok, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "I suppose you can then understand the story faster... I am sure that he's involved in the rumor. I swear.";
+				next;
+				mes "[Giacomo Girolamo]";
+				mes "By the way..what about you? Is there anything that you know about him?";
+				next;
+				if (select("Pretend you know nothing.", "Tell him what you know.") == 1) {
+					mes "["+ strcharinfo(0) +"]";
+					mes "Not really. I've ever heard of his name, but I don't know anything about him..";
+					next;
+					mes "[Giacomo Girolamo]";
+					mes "Hm.... You sound suspicious, dude! huh?";
+					next;
+				} else {
+					mes "["+ strcharinfo(0) +"]";
+					mes "He happens to research into Human 'Homunculus' without telling that to Rekenber Corp., and there was a whistle-blower who reported to the corp. so he was fired.";
+					next;
+					emotion e_no1, "Giacomo Girolamo#kiup2";
+					mes "[Giacomo Girolamo]";
+					mes "Oh! Man..! You seem to know pretty much! By any chance, are you concerned with Rekenber??";
+					next;
+					emotion e_dots;
+					mes "["+ strcharinfo(0) +"]";
+					mes "... .... ...";
+					next;
+				}
+				emotion e_hmm, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "Don't worry. I didn't mean anything.";
+				next;
+				mes "[Giacomo Girolamo]";
+				mes "Well! I am just curious only because some people in the slum and some adventurers were missing,";
+				mes "and I heard that Rekenber was doing human experimentation with those missing people. Hope you don't get me wrong.";
+				next;
+				lght_duk01 = 1;
+				setquest 5109;
+				mes "Actually, it is not a funny rumor.";
+				mes "Should investigate the lab where the experiment was carried out.";
+				close;
+			} else {
+				emotion e_lv, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "Oh! What a beautiful lady!!";
+				next;
+				emotion e_what, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "How come a beauty is here, in a place with dangerous rumor?";
+				next;
+				switch(select("Walking...", "To hang out...", "Shopping...")) {
+				case 1:
+					mes "[Giacomo Girolamo]";
+					mes "Ahh.. Lady, you are so graceful even when you are just walking.....";
+					next;
+					break;
+				case 2:
+					mes "[Giacomo Girolamo]";
+					mes "Lady. You are a dignified lady even if you hang out in this poor town...";
+					next;
+					break;
+				case 3:
+					mes "[Giacomo Girolamo]";
+					mes "Ahh.. Lady.. Shopping in the slum!!.. Are you a type who needs to look around every single shop?";
+					next;
+					break;
+				}
+			}
+			select("... .... ... ....");
+			mes "[Giacomo Girolamo]";
+			mes "Well, how dare I ask you and be interested in what the lady does...";
+			next;
+			emotion e_ok, "Giacomo Girolamo#kiup2";
+			mes "[Giacomo Girolamo]";
+			mes "I just hope that the lady gets out of this town with dangerous rumors..";
+			next;
+			select("Dangerous rumors?");
+			emotion e_what, 1;
+			mes "[Giacomo Girolamo]";
+			mes "Ah... Lady may not have heard of the rumor.";
+			next;
+			mes "[Giacomo Girolamo]";
+			mes "Recently, some people from this town, actually from the slum...and some adventurers are missing...";
+			next;
+			mes "[Giacomo Girolamo]";
+			mes "and then the rumor came up, since disappearance cases happen pretty often, that Rekenber is committing a horrible human experimentation in their secret lab.";
+			next;
+			select("Excuse me?! human experimentation?");
+			emotion e_omg, 1;
+			mes "[Giacomo Girolamo]";
+			mes "Yea! human experimentation!!";
+			mes "There are a lot of rumors that horrible human experimentation is actually performed, but these people in the slum....don't want to believe that due to the welfare movement from Rekenber.";
+			next;
+			mes "[Giacomo Girolamo]";
+			mes "Well! the rich people either want to believe..I think.. Ah!! And couple of weeks ago. um. what's his name? Wolfchev??";
+			next;
+			mes "[Giacomo Girolamo]";
+			mes "Anyway!! that research got fired from the lab. I think he must be involved with this rumor.";
+			next;
+			mes "[Giacomo Girolamo]";
+			mes "So, please, lady. Please don't be in a place like this and stay in safe ways.";
+			next;
+			lght_duk01 = 1;
+			setquest 5109;
+			mes "............ It seems a pretty serious matter.";
+			mes "Should investigate the lab where the experiment was carried out.";
+			close;
+		} else {
+			mes "[Giacomo Girolamo]";
+			if (Sex) {
+				emotion e_paper, "Giacomo Girolamo#kiup2";
+				mes "Take care yourself and don't disappear!";
+			} else {
+				emotion e_lv2, "Giacomo Girolamo#kiup2";
+				mes "Be careful, Lady.";
+			}
+			close;
+		}
+	} else {
+		if (Sex) {
+			emotion e_ho, "Giacomo Girolamo#kiup2";
+			mes "[Giacomo Girolamo]";
+			mes "Only those beautiful ladies are the reason of my life~!";
+			mes "I, Giacomo Girolamo Casanova de Seingalt am never interested in guys like you though!!";
+			next;
+			emotion e_an, "Giacomo Girolamo#kiup2";
+			mes "[Giacomo Girolamo]";
+			mes "but I can listen to you...you wanna say anything to me?";
+			next;
+			switch(select("No..?", "About ladies..", "You Womanizer!!", "Envy you...", "What's the rumor lately?")) {
+			case 1:
+				emotion e_hmm, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "Hey you, get out of my way then..";
+				close;
+			case 2:
+				emotion e_an, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "I don't feel like talking about my precious ladies making fun of them. You do it with your friends.";
+				close;
+			case 3:
+				mes "[Giacomo Girolamo]";
+				mes "Hey.. Excuse me!!! but I'm not a 'Womanizer', I am just a person who adores ladies.";
+				next;
+				emotion e_ok, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "Of course..... Yea... If I'm a womanizer, all the men on earth are too! I'm just Casanova. umhahahaha.";
+				close;
+			case 4:
+				emotion e_what, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "Haa.. Do you....? not have any woman but your sister and mother around you?";
+				next;
+				mes "[Giacomo Girolamo]";
+				mes "... .... ...";
+				next;
+				emotion e_swt2, "Giacomo Girolamo#kiup2";
+				mes "[Giacomo Girolamo]";
+				mes "Oh...... sorry.. I got your point....";
+				close;
+			case 5:
+				mes "[Giacomo Girolamo]";
+				mes "You.. are not like how you seem? Interesting..";
+				next;
+				mes "[Giacomo Girolamo]";
+				mes "Yea, actually recently a lot of people from the slum and some wandering adventurers got disappeared. and I don't know why.";
+				next;
+				mes "[Giacomo Girolamo]";
+				mes "You gotta be careful too..";
+				close;
+			}
+		} else {
+			emotion e_what, "Giacomo Girolamo#kiup2";
+			mes "[Giacomo Girolamo]";
+			mes "Hey, lady?";
+			next;
+			mes "[Giacomo Girolamo]";
+			switch(rand(1,10)) {
+			case 1:
+				mes "Wasn't it painful when you fell down from Heaven, my Angel?";
+				next;
+				break;
+			case 2:
+				mes "You must be tired. Because you are always wandering my mind.";
+				next;
+				break;
+			case 3:
+				mes "Are you not tired of walking around in my dream last night?";
+				next;
+				break;
+			case 4:
+				mes "Excuse me. But I think I lost my heart. Could you please borrow me yours?";
+				next;
+				break;
+			case 5:
+				mes "Do you believe in love at first sight?? Or can we start again..?";
+				next;
+				break;
+			case 6:
+				mes "I am so sorry but, can you kiss with a person who just met?? Noo? Ok then let me introduce myself.";
+				next;
+				break;
+			case 7:
+				mes "I'm so lost here since it's the first time. Can you let me know which is the way to your heart?";
+				next;
+				break;
+			case 8:
+				mes "Give me a map please.. To get a way....I'm fallen in your eyes.";
+				next;
+				break;
+			case 9:
+				mes "Your eyes....I wanna be forever there.";
+				next;
+				break;
+			case 10:
+				mes "I promise that I will be your everything in any case, in any difficult situation.";
+				next;
+				break;
+			}
+			emotion e_lv2, "Giacomo Girolamo#kiup2";
+			mes "[Giacomo Girolamo]";
+			mes "Today is the first day we met, but I love you, Lady <3 ";
+			next;
+			mes "[Giacomo Girolamo]";
+			mes "And I am telling you this because I'm just worried about you. You need to get out of this town which is full of disappearance cases.";
+			close;
+		}
+	}
+
+OnTouch:
+	if (!lght_duk01)
+		emotion (Sex ? e_pif : e_lv2), "Giacomo Girolamo#kiup2";
+	end;
+}
+
+// Weird Old Man (Rewards)
+//============================================================
+lighthalzen,342,291,4	script	Weird old man#Bio4Reward	4_M_EINOLD,{
+	if ((MaxWeight - Weight) < 2800 || !checkweight(1201, 1)) {
+		mes "^FF0000 Check up your inventory. You got too many items to carry out the quest. ^000000";
+		close;
+	}
+	mes "[Weird old man]";
+	mes "Phew, those young people nowadays, are so rude and have no manners.";
+	next;
+	if (select("Ignore him", "Talk with him") == 1) {
+		mes "[Weird old man]";
+		mes "You, Very bad young man!";
+		close;
+	}
+	mes "["+ strcharinfo(0) +"]";
+	mes "Sir, Are you alright??";
+	next;
+	mes "[Weird old man]";
+	mes "....?? You are not like other young people. You have good manners! You know what happened to me..?";
+	next;
+	switch(rand(1,2)) {
+	case 1:
+		mes "[Weird old man]";
+		mes "I was on the way to visit my son who lives in Rune Midgarts. It's really far away, so I took the airplane, and..";
+		next;
+		mes "[Weird old man]";
+		mes "those young people...so noisy.... I was standing but non of them offered me a seat..and they were just talking in loud voices which bothered everyone.";
+		next;
+		mes "[Weird old man]";
+		mes "I could lecture them if I were 10 years younger than now..";
+		next;
+		mes "[Weird old man]";
+		mes "Pffff.. Never like the time passing....";
+		next;
+		mes "[Weird old man]";
+		mes "So, you... what would you do??";
+		next;
+		mes "[Weird old man]";
+		mes "In an open, public place, you are supposed to stay quiet to the destination and offer your seat to the elderly and the infirm.";
+		next;
+		break;
+	case 2:
+		mes "[Weird old man]";
+		mes "I was on the way to visit my son who lives in Rune Midgarts. It's really far away, so I took the airplane, and..";
+		next;
+		mes "[Weird old man]";
+		mes "those young people...so noisy.... I was standing but non of them offered me a seat..and they were just talking in loud voices which bothered everyone.";
+		next;
+		mes "[Weird old man]";
+		mes "I could lecture them if I were 10 years younger than now..";
+		next;
+		mes "[Weird old man]";
+		mes "Pffff.. Never like the time passing....";
+		next;
+		mes "[Weird old man]";
+		mes "So, you... what would you do??";
+		next;
+		mes "[Weird old man]";
+		mes "In an open, public place, you are supposed to stay quiet to the destination and offer your seat to the elderly and the infirm. Right?";
+		next;
+		mes "[Weird old man]";
+		mes "Isn't that right?!";
+		next;
+		switch(rand(1,2)) {
+		case 1:
+			mes "[Weird old man]";
+			mes "Oh, and then! you know what...?";
+			next;
+			mes "[Weird old man]";
+			mes "Once I was walking in the town, and some boy were spitting on the street, and were bothering girls who were passing by...tut tut!";
+			next;
+			mes "[Weird old man]";
+			mes "The world is going to the dogs.. How will it be?? It was even a day time when they were doing it..tut tut.";
+			next;
+			switch(rand(1,2)) {
+			case 1:
+				mes "[Weird old man]";
+				mes "Oh, and then! you know what...?";
+				next;
+				break;
+			case 2:
+				mes "[Weird old man]";
+				mes "Oh, and then! you know what...?";
+				next;
+				mes "[Weird old man]";
+				mes "Lately young people are not so patient!!!!";
+				next;
+				mes "[Weird old man]";
+				mes "That often, they say they will quit.. they say they can't more. How will they live all the lift with that kind of mentality..tut tut.";
+				next;
+				mes "[Weird old man]";
+				mes "It's not easy to find a job, it is very difficult to be hired. But then they even cannot stand a week there, and leave the work already.";
+				next;
+				mes "[Weird old man]";
+				mes "How impatient and irresponsible!!";
+				next;
+				mes "[Weird old man]";
+				mes "Oh, and then! you know what...?";
+				next;
+				break;
+			}
+		case 2:
+			mes "[Weird old man]";
+			mes "Oh, and then! you know what...?";
+			next;
+			break;
+		}
+	}
+	mes "^E7A43DThe old man talked over and over again.^000000";
+	next;
+	mes "[Weird old man]";
+	mes "Hm......You are not like common young people, you seem pretty patient too. I like that!!!";
+	next;
+	mes "[Weird old man]";
+	mes "Now I am just an old, weak man but when I was young, I was a famous merchant in the town.";
+	next;
+	mes "[Weird old man]";
+	mes "It's been a while since I stopped the business,";
+	mes "but a former client of mine contacted me and asked me";
+	next;
+	mes "[Weird old man]";
+	mes "If I could get him some unknown objects named 'Will of Warrior', 'Thirst for Blood', 'Chill of the Dead'.";
+	next;
+	mes "[Weird old man]";
+	mes "I liked your politeness which is not like most of young people, so if you get me those, I will dare to give you some stuffs that I consider as my treasures.";
+	next;
+	while(1) {
+		switch(select("When I gather them, I will come back", "Show me the armors", "Show me the weapons")) {
+		case 1:
+			mes "[Weird old man]";
+			mes "OK, young man. See you later.";
+			close;
+		case 2:
+			mes "[Weird old man]";
+			mes "So, you are interested in armors.";
+			next;
+			mes "[Weird old man]";
+			mes "These are the armors I have.";
+			next;
+			for(.@i = 1; .@i < 8; .@i++) {
+				if (((.@i == 1 || .@i == 5) && (countitem(6469) >= 100) && (countitem(6470) >= 50) && (countitem(6471) >= 35)) || 
+				    ((.@i == 2 || .@i == 3) && (countitem(6469) >= 100) && (countitem(6470) >= 50) && (countitem(6471) >= 22)) ||
+				    ((.@i == 4 || .@i == 7) && (countitem(6469) >= 300) && (countitem(6470) >= 300) && (countitem(6471) >= 400)) ||
+				    ((.@i == 6) && (countitem(6469) >= 100) && (countitem(6470) >= 50) && (countitem(6471) >= 30))) {
+					.@armor$[.@i] = "^0000FF";
+				} else {
+					.@armor$[.@i] = "^FF0000";
+				}
+			}
+			while(1) {
+				switch(select(
+					"Show me other items.",
+					""+.@armor$[1]+"Giant Shield^000000",
+					""+.@armor$[2]+"Acient Book of Geffenia-Water^000000",
+					""+.@armor$[3]+"Bible of Promise(2nd Vol.)^000000",
+					""+.@armor$[4]+"Salvage Cape^000000",
+					""+.@armor$[5]+"Assassin's Handcuffs^000000",
+					""+.@armor$[6]+"Green Operating Gown^000000",
+					""+.@armor$[7]+"Ancient Gold Decoration^000000"
+				)) {
+				case 1:
+					mes "[Weird old man]";
+					mes "Have a look.";
+					next;
+					.@break = 1;
+					break;
+				case 2:
+					mes "<<Giant Shield[1]>>";
+					mes "Decrease 5% of Damage from Large Monsters, if Refine Lv is 9, decrease 5% more of the Damage.";
+					mes "Shield / Def 130 / Weight 280 / Required Lv 100 / Socket 1 / for 3rd Swordman Classes";
+					callsub L_Reward, 2160, 100, 50, 35; //Giant_Shield
+					break;
+				case 3:
+					mes "<<Acient Book of Geffenia-Water[1]>>";
+					mes "INT + 1, MDEF + 2. If Original INT point is 120, MATK + 10, MHP + 800.";
+					mes "When equipping with Lacryma Stick, the casting % from Storm Gust, Frost Misty and Jack frost will discount equivalent to 4 times Refine Lv.";
+					mes "Shield / Def 30 / Weight 100 / Required Lv 100 / Socket 1 / for Warlock";
+					callsub L_Reward, 2161, 100, 50, 22; //Geffenia_Book_Water
+					break;
+				case 4:
+					mes "<<Bible of Promise(2nd Vol.)[1]>>";
+					mes "MDEF + 5, Allow to use 'Odin's Power'(Lv 2). Increase 5% more for Heal skill.";
+					mes "Shield / Def 20 / Weight 50 / Required Lv 140 / Socket 1 / for Archbishop";
+					callsub L_Reward, 2162, 100, 50, 22; //Bible_Of_Promise2
+					break;
+				case 5:
+					mes "<<Salvage Cape[0]>>";
+					mes "Allow to use 'Cicada Skin Shed'(Lv 1). Cool time for this skill will be 30 seconds. When equiping it, SP consumption for using any skill will be doubled, When taking it off, SP - 1200.";
+					mes "Garment / Def 1 / Weight 40 / Required Lv 130 / Socket 0 / for Archbishop";
+					callsub L_Reward, 2582, 100, 50, 35; //Salvage_Cape
+					break;
+				case 6:
+					mes "<<Assassin's Handcuffs[1]>>";
+					mes "MSP + 20, CRI + 3. When equipping with Krishna, ATK + 50, ATK power from 'Sonic Blow' 50% increased, FLEE - 30. When equipping with Cakram CRI + 4, Critical ATK power 40% increased, MHP - 10%.";
+					mes "Accessory / Def 3 / Weight 40 / Required Lv 100 / Socket 1 / for Guillotine Cross";
+					callsub L_Reward, 2892, 300, 300, 400; //Assassin_Handcuffs
+					break;
+				case 7:
+					mes "<<Green Operating Gown[1]>>";
+					mes "DEX + 1, MSP + 30. Equipping with Scalpel will let to drop 'Immortal Heart', 'Alcohol' with a certain chance when hunting Human, Animal type monsters. Refine Lv affects the drop rate.";
+					mes "Armor / Def 66 / Weight 66 / Required Lv 100 / Socket 1 / for Generic";
+					callsub L_Reward, 15044, 100, 50, 30; //Green_Operation_Coat
+					break;
+				case 8:
+					mes "<<Green Operating Gown[1]>>";
+					mes "DEX + 1, MSP + 30. Equipping with Scalpel will let to drop 'Immortal Heart', 'Alcohol' with a certain chance when hunting Human, Animal type monsters. Refine Lv affects the drop rate.";
+					mes "Armor / Def 66 / Weight 66 / Required Lv 100 / Socket 1 / for Generic";
+					callsub L_Reward, 18570, 300, 300, 400; //Ancient_Gold_Deco
+					break;
+				}
+				if (.@break) {
+					.@break = 0;
+					break;
+				}
+			}
+			break;
+		case 3:
+			mes "[Weird old man]";
+			mes "So, you are interested in weapons.";
+			next;
+			mes "[Weird old man]";
+			mes "These are the weapons I've got.";
+			next;
+			for(.@i = 1; .@i < 15; .@i++) {
+				if (((.@i == 1) && (countitem(6469) >= 50) && (countitem(6470) >= 100) && (countitem(6471) >= 10)) ||
+				((.@i == 2) && (countitem(6469) >= 50) && (countitem(6470) >= 100) && (countitem(6471) >= 85)) ||
+				((.@i == 3 || .@i == 4 || (.@i >= 8 && .@i < 11) || .@i >= 12) && (countitem(6469) >= 50) && (countitem(6470) >= 100) && (countitem(6471) >= 35)) ||
+				((.@i == 5 || .@i == 7 || .@i == 11) && (countitem(6469) >= 50) && (countitem(6470) >= 100) && (countitem(6471) >= 40)) ||
+				((.@i == 6) && (countitem(6469) >= 300) && (countitem(6470) >= 300) && (countitem(6471) >= 400))) {
+					.@weapon$[.@i] = "^0000FF";
+				} else {
+					.@weapon$[.@i] = "^FF0000";
+				}
+			}
+			while(1) {
+				switch(select(
+					"Show me other items.",
+					""+.@weapon$[1]+"Agent Katar^000000",
+					""+.@weapon$[2]+"Guillotine Katar^000000",
+					""+.@weapon$[3]+"Ygnus Stale^000000",
+					""+.@weapon$[4]+"End Sektura^000000",
+					""+.@weapon$[5]+"Cannon Spear^000000",
+					""+.@weapon$[6]+"Giant Lance^000000",
+					""+.@weapon$[7]+"Chilly Spell Book^000000",
+					""+.@weapon$[8]+"Recovery Light^000000",
+					""+.@weapon$[9]+"Aztoe Nail^000000",
+					""+.@weapon$[10]+"Scarletto Nail^000000",
+					""+.@weapon$[11]+"Bloody Cross^000000",
+					""+.@weapon$[12]+"Catapult^000000",
+					""+.@weapon$[13]+"Big CrossBow^000000",
+					""+.@weapon$[14]+"Creeper Bow^000000"
+				)) {
+				case 1:
+					mes "[Weird old man]";
+					mes "Have a look.";
+					next;
+					.@break = 1;
+					break;
+				case 2:
+					mes "<<Agent Katar[1]>>";
+					mes "Every 2 Original LUK points gets additional 1 HIT point";
+					mes "Katar / ATK 170 / Weight 120 / Weapon Lv 3 / Required Lv 100 / Socket 1 / for Guillotine Cross";
+					callsub L_Reward, 1290, 50, 100, 10; //Agent_Katar
+					break;
+				case 3:
+					mes "<<Guillotine Katar[1]>>";
+					mes "DEX + 2. FLEE - 30. 50% more damage to Human monsters. Add 30% more damage for Cross Impact skill.";
+					mes "Katar / ATK 200 / Weight 150 / Weapon Lv 4 / Required Lv 140 / Socket 1 / for Guillotine Cross";
+					callsub L_Reward, 1291, 50, 100, 85; //Guillotine_Katar
+					break;
+				case 4:
+					mes "<<Ygnus Stale[1]>>";
+					mes "When doing short distance attack, cast ¹ßÈ­ to the player and to the enemy with a certain chance.";
+					mes "Two-Handed Axe / ATK 250 / Weight 190 / Fire Property / Weapon Lv 4 / Required Lv 95 / Socket 1 / for High Swordman/Merchant Classes";
+					callsub L_Reward, 1392, 50, 100, 35; //Ygnus_Stale
+					break;
+				case 5:
+					mes "<<End Sektura[1]>>";
+					mes "When doing short distance attack, cast Freezing to the player and to the enemy with a certain chance.";
+					mes "Two-Handed Axe / ATK 250 / Weight 190 / Water Property / Weapon Lv 4 / Required Lv 95 / Socket 1 / for High Swordman/Merchant Classes";
+					callsub L_Reward, 1393, 50, 100, 35; //End_Sektura
+					break;
+				case 6:
+					mes "<<Cannon Spear[1]>>";
+					mes "MSP - 100, Increases 10% of Damage impacted with Cannon Spear, Additional ATK power of Cannon Spear equivalent to 3 times Refine Lv.";
+					mes "One-Handed Spear / ATK 180 / Weight 160 / Weapon Lv 4 / Required Lv 100 / Socket 1 / for Royal Guard";
+					callsub L_Reward, 1435, 50, 100, 40; //Cannon_Spear
+					break;
+				case 7:
+					mes "<<Giant Lance[0]>>";
+					mes "ASPD - 10, When it's taken off, the character gets SP - 600. 20 more seconds of Delay time exists before using back the Clashing Spiral. If the original STR points are 120, + ATK 300.";
+					mes "Two-Handed Lance / ATK 20 / Weight 2000 / Weapon Lv 4 / Required Lv 140 / Socket 0 / for Rune Knight";
+					callsub L_Reward, 1490, 300, 300, 400; //Giant_Lance
+					break;
+				case 8:
+					mes "<<Chilly Spell Book[2]>>";
+					mes "MATK + 160, DEX + 1. Increases ATK % of Cold Bolt, Diamond Dust equivalent to 3 times Refine Lv, also SP consumption from those skills increased equivalent to 5 times Refine Lv. Undestroyable.";
+					mes "Book / ATK 100 / Weight 100 / Water Property / Weapon Lv 4 / Required Lv 100 / Socket 2 / for Sorcerer";
+					callsub L_Reward, 1584, 50, 100, 40; //Chilly_Spell_Book
+					break;
+				case 9:
+					mes "<<Recovery Light[1]>>";
+					mes "MATK + 160. Depending on its Refine Lv, Heal Ability and SP consumption for the skill increased. Indestructible.";
+					mes "One-Handed Staff / ATK 30 / Weight 40 / Saint Property / Weapon Lv 4 / Required Lv 110 / Socket 1 / for Archbishop.";
+					callsub L_Reward, 1659, 50, 100, 35; //Recovery_Light
+					break;
+				case 10:
+					mes "<<Aztoe Nail[0]>>";
+					mes "MATK + 80. For Physical Melee Attack, cast Freezing to the target with a certain chance. The chance is affected by Refine Lv.";
+					mes "Dagger / ATK 160 / Weight 50 / Wind Property / Weapon Lv 4 / Required Lv 110 / Socket 0 / for High Swordman/Merchant/Theif Classes";
+					callsub L_Reward, 13069, 50, 100, 35; //Aztoe_Nail
+					break;
+				case 11:
+					mes "<<Scarletto Nail[0]>>";
+					mes "MATK + 80. For Physical Melee Attack, cast Stone curse to the target with a certain chance. The chance is affected by Refine Lv.";
+					mes "Dagger / ATK 160 / Weight 50 / Fire Property / Weapon Lv 4 / Required Lv 110 / Socket 0 / for High Swordman/Merchant/Theif Classes";
+					callsub L_Reward, 13070, 50, 100, 35; //Scarletto_Nail
+					break;
+				case 12:
+					mes "<<Bloody Cross[0]>>";
+					mes "For Physical Melee Attack, autocast 'Hell Inferno'(Lv 1) with a certain chance. The chance is affected by Refine Lv.";
+					mes "Mace / ATK 170 / Weight 150 / Darkness Property / Weapon Lv 4 / Required Lv 100 / Socket 0 / for High Acolyte Classes";
+					callsub L_Reward, 16017, 50, 100, 40; //Bloody_Cross
+					break;
+				case 13:
+					mes "<<Catapult[2]>>";
+					mes "Increases ATK % of 'Triangle Shot' equivalent to 2 times Refine Lv, Also SP consumption from the skill increased.";
+					mes "Bow / ATK 150 / Weight 110 / Weapon Lv 4 / Required Lv 100 / Socket 2 / for Shadow Chaser";
+					callsub L_Reward, 18109, 50, 100, 35; //Catapult
+					break;
+				case 14:
+					mes "<<Big CrossBow[2]>>";
+					mes "Increases ATK % of 'Arrow Storm' equivalent to 5 times Refine Lv. Also SP consumption from the skill increased, If the Original AGI points are 120, ASPD + 1.";
+					mes "Bow / ATK 160 / Weight 90 / Weapon Lv 4 / Required Lv 110 / Socket 2 / for Ranger";
+					callsub L_Reward, 18110, 50, 100, 35; //Big_CrossBow
+					break;
+				case 15:
+					mes "<<Creeper Bow[2]>>";
+					mes "DEX + 1, For Physical Attack, auto-cast 'Fiber Lock'(Lv 1) with a certain chance.";
+					mes "Bow / ATK 150 / Weight 150 / Weapon Lv 3 / Required Lv 120 / Socket 2 / for 3rd Archer Classes";
+					callsub L_Reward, 18111, 50, 100, 35; //Creeper_Bow
+					break;
+				}
+				if (.@break) {
+					.@break = 0;
+					break;
+				}
+			}
+		}
+	}
+	close;
+
+L_Reward:
+	next;
+	mes ""+getarg(1)+" Will of Warrior, "+getarg(2)+" Thirst for Blood, "+getarg(3)+" Chill of the Dead are needed for the exchange.";
+	next;
+	if (countitem(6469) >= getarg(1) && countitem(6470) >= getarg(2) && countitem(6471) >= getarg(3)) {
+		if (select("Don't exchange", "Exchange") == 1) {
+			mes "[Weird old man]";
+			mes "Okay..";
+			close;
+		}
+		emotion e_swt2, "Weird old man#Bio4Reward";
+		progressbar "FF00FF", 2;
+		delitem 6469, getarg(1); //Will_Of_Warrior
+		delitem 6470, getarg(2); //Blood_Thirst
+		delitem 6471, getarg(3); //Goast_Chill
+		getitem getarg(0), 1;
+		mes "[Weird old man]";
+		mes "There you go. Visit me sometimes and we could talk.";
+		close;
+	}
+	return;
+}
+
+// Sorcerer (Rewards)
+//============================================================
+lhz_cube,233,24,4	script	Sorcerer#Bio4Reward	4_M_UMDANCEKID,{
+	if ((MaxWeight - Weight) < 1200 || !checkweight(1201, 1)) {
+		mes "^FF0000 Check up your inventory. You got too many items to carry out the quest. ^000000";
+		close;
+	}
+	disable_items;
+	mes "[Pudding]";
+	mes "... .... ...";
+	next;
+	switch(select("Umba umba humbaa", "What are you doing here?", "Which are the equipments found so far?", "Here you are, Sir.")) {
+	case 1:
+		emotion e_an;
+		mes "[Pudding]";
+		mes "Hey, excuse me, but I'm not from Umbala! You are so rude.";
+		close;
+	case 2:
+		mes "[Pudding]";
+		mes "As you can see, I'm a training Sorcerer, and my name is Pudding.";
+		next;
+		select("....?");
+		emotion e_an;
+		mes "[Pudding]";
+		mes "... What's that face? I'm starting to feel unpleasant..";
+		next;
+		emotion e_ok;
+		mes "[Pudding]";
+		mes "Couple of days ago, while I was undergoing discipline, I felt a strange, bizzare tinge. So I followed that and it brought me here.";
+		next;
+		select("I see.");
+		mes "[Pudding]";
+		mes "OK, let me continue. I am so bothered if you disturb me while I'm talking.";
+		next;
+		mes "[Pudding]";
+		mes "And I entered to the laboratory here in order to investigate, and oh gosh! I found those monsters which were like doppelgangers from 'Geffen Dungeon'. It was full of them.";
+		next;
+		mes "[Pudding]";
+		mes "From those monsters, I could find rare items like '^F2766EWill of Warrior^000000' '^952420Thirst for Blood^000000' '^88C6F7Chill of the Dead^000000' which you cannot find from any other place.";
+		next;
+		emotion e_what, "Sorcerer#Bio4Reward";
+		mes "[Pudding]";
+		mes "And after many hours of research on my own, I finally figured out a way to use those items. Do you wanna know?";
+		next;
+		switch(select("Oh....pardon?!", "Of course, I really wanna know.")) {
+		case 1:
+			emotion e_omg, 1;
+			emotion e_an, "Sorcerer#Bio4Reward";
+			mes "[Pudding]";
+			mes "Oh my! You fell asleep after you asked me something? Well, anyway I feel lazy to explain again so I will just continue.";
+			next;
+			break;
+		case 2:
+			emotion e_heh, "Sorcerer#Bio4Reward";
+			mes "[Pudding]";
+			mes "Good, I am content that you are listening to my story carefully. Then I will keep explaining.";
+			next;
+			break;
+		}
+		mes "[Pudding]";
+		mes "Those '^F2766EWill of Warrior^000000' and '^952420Thirst for Blood^000000'..... are aggresive but warm materials.";
+		next;
+		mes "[Pudding]";
+		mes "So '^F2766EWill of Warrior^000000' can dwell a special power to the 4th slot of an equipment,";
+		next;
+		mes "[Pudding]";
+		mes "and '^952420Thirst for Blood^000000' can dwell a special power to the 3rd slot.";
+		next;
+		mes "[Pudding]";
+		mes "Whereas!!!";
+		mes "'^88C6F7Chill of the Dead^000000' is a cold type material.";
+		mes "which allows to return the power from '^F2766EWill of Warrior^000000' or '^952420Thirst for Blood^000000' so it let the equipment to be 'ZERO'.";
+		next;
+		mes "[Pudding]";
+		mes "What do you say? Doesn't it sound interesting? But, there's a problem...";
+		next;
+		mes "[Pudding]";
+		mes "Since those materials can only be found from the monsters in the Lab., the special power also can be dwelt into certain equipments which can be obtained from the Lab.";
+		next;
+		select("So what's the conclusion?");
+		emotion e_what, 1;
+		emotion e_an;
+		mes "[Pudding]";
+		mes "Gee.. I told you not to cut while I talk, didn't I? Well, I will answer that becuase that's important.";
+		next;
+		mes "[Pudding]";
+		mes "If you bring me 10 '^F2766EWill of Warrior^000000' or 10 '^952420Thirst for Blood^000000', I will dwell some power to certain equipments that you can find in the Lab..";
+		next;
+		mes "[Pudding]";
+		mes "And if you are not satisfied with the power you got, bring me 10 '^88C6F7Chill of the Dead^000000', and I will take off that power.";
+		next;
+		mes "[Pudding]";
+		mes "WHat do you say? Having both options.....quite nice, huh?";
+		next;
+		mes "[Pudding]";
+		mes "If you obtain '^F2766EWill of Warrior^000000' or '^952420Thirst for Blood^000000', and obtain also equipment which is capable to accept their power, bring them to me. I will be waiting.";
+		close;
+	case 3:
+		mes "[Pudding]";
+		mes "Hm.... Equipment which are discovered so far are....";
+		next;
+		mes "- checking -";
+		mes "Pudding takes some paper out from a pocket.";
+		next;
+		mes "[Pudding]";
+		mes "Let me see.. the equipments discovered until now are....";
+		mes "6 Armors, 14 Weapons.";
+		next;
+		while(1) {
+			switch(select("Ok, I don't have to know more.", "6 Armors", "14 Weapons")) {
+			case 1:
+				mes "[Pudding]";
+				mes "If you obtain '^F2766EWill of Warrior^000000' or '^952420Thirst for Blood^000000', and obtain also equipment which is capable to accept their power, bring them to me. I will be waiting.";
+				close;
+			case 2:
+				mes "< Armor List >";
+				mes "Giant Shield[1]";
+				mes "Acient Book of Geffenia-Water[1]";
+				mes "Bible of Promise(2nd Vol.)[1]";
+				mes "Salvage Cape[0]";
+				mes "Assassin's Handcuffs[1]";
+				mes "Green Operating Gown[1]";
+				mes "Ancient Gold Decoration[1]";
+				next;
+				mes "[Pudding]";
+				mes "So far these are the Armors discovered. Do you wanna see other things?";
+				next;
+				break;
+			case 3:
+				mes "< Weapon List >";
+				mes "Agent Katar[1]";
+				mes "Guillotine Katar[1]";
+				mes "Ygnus Stale[1]";
+				mes "End Sektura[1]";
+				mes "Cannon Spear[1]";
+				mes "Giant Lance[0]";
+				mes "Chilly Spell Book[2]";
+				mes "Recovery Light[1]";
+				mes "Aztoe Nail[0]";
+				mes "Scarletto Nail[0]";
+				mes "Bloody Cross[0]";
+				mes "Catapult[2]";
+				mes "Big CrossBow[2]";
+				mes "Creeper Bow[2]";
+				next;
+				mes "[Pudding]";
+				mes "So far these are the Weapons discovered. Do you wanna see other things?";
+				next;
+				break;
+			}
+		}
+		close;
+	case 4:
+		emotion e_flash;
+		mes "[Pudding]";
+		mes "Ohhhhh Have you brought them?";
+		next;
+		break;
+	}
+	mes "[Pudding]";
+	mes "OKAY! In which equipment you want to dwell the power?";
+	next;
+	setarray .@parts[0], EQI_ARMOR, EQI_HAND_L, EQI_HAND_R, EQI_GARMENT, EQI_ACC_L, EQI_ACC_R, EQI_HEAD_LOW;
+	for(.@i = 0; .@i < 7; .@i++) {
+		if (!getequipisequiped(.@parts[.@i])) {
+			switch(.@i) {
+				case 0:
+					.@equipped$[.@i] = "^999999Armor-[Not equipped]^000000";
+					break;
+				case 1:
+					.@equipped$[.@i] = "^999999Left Hand-[Not equipped]^000000";
+					break;
+				case 2:
+					.@equipped$[.@i] = "^999999Right Hand-[Not equipped]^000000";
+					break;
+				case 3:
+					.@equipped$[.@i] = "^999999Garment-[Not equipped]^000000";
+					break;
+				case 4:
+					.@equipped$[.@i] = "^999999Accessory-[Not equipped]^000000";
+					break;
+				case 5:
+					.@equipped$[.@i] = "^999999Accessory-[Not equipped]^000000";
+					break;
+				case 6:
+					.@equipped$[.@i] = "^999999Helm-[Not equipped]^000000";
+					break;
+			}
+		} else {
+			.@equipped$[.@i] = getequipname(.@parts[.@i]);
+		}
+	}
+	switch(select("I changed my mind.", .@equipped$[0], .@equipped$[1], .@equipped$[2], .@equipped$[3], .@equipped$[4], 
+	.@equipped$[5], .@equipped$[6])) {
+	case 1:
+		mes "[Pudding]";
+		mes "Well, I was looking forward to doing it, but I cannot help then.";
+		close;
+	case 2:
+		if (!getequipisequiped(EQI_ARMOR)) {
+			mes "[Pudding]";
+			mes "Hey..Where is the armor?";
+			close;
+		}
+		.@part = EQI_ARMOR;
+		break;
+	case 3:
+		if (!getequipisequiped(EQI_HAND_L)) {
+			mes "[Pudding]";
+			mes "Well.. You are not equipping anything on the left hand.";
+			close;
+		}
+		.@part = EQI_HAND_L;
+		break;
+	case 4:
+		if (!getequipisequiped(EQI_HAND_R)) {
+			mes "[Pudding]";
+			mes "Well.. You are not equipping anything on the right hand.";
+			close;
+		}
+		.@part = EQI_HAND_R;
+		break;
+	case 5:
+		if (!getequipisequiped(EQI_GARMENT)) {
+			mes "[Pudding]";
+			mes "Um.... Where's your robe?";
+			close;
+		}
+		.@part = EQI_GARMENT;
+		break;
+	case 6:
+		if (!getequipisequiped(EQI_ACC_L)) {
+			mes "[Pudding]";
+			mes ".....Where's the accessory?";
+			close;
+		}
+		.@part = EQI_ACC_L;
+		break;
+	case 7:
+		if (!getequipisequiped(EQI_ACC_R)) {
+			mes "[Pudding]";
+			mes ".....Where's the accessory?";
+			close;
+		}
+		.@part = EQI_ACC_R;
+		break;
+	case 8:
+		if (!getequipisequiped(EQI_HEAD_LOW)) {
+			mes "[Pudding]";
+			mes "Hey.. Are you not wearing any Helm?";
+			close;
+		}
+		.@part = EQI_HEAD_LOW;
+		break;
+	}
+	.@refine_count = getequiprefinerycnt(.@part);
+	.@equip_item = getequipid(.@part);
+	.@lhz_max_num = 4000;
+	if (.@equip_item == Agent_Katar || .@equip_item == Guillotine_Katar || .@equip_item == Ygnus_Stale || 
+	    .@equip_item == End_Sektura || .@equip_item = Cannon_Spear || .@equip_item == Giant_Lance || 
+	    .@equip_item == Aztoe_Nail || .@equip_item == Scarletto_Nail || .@equip_item == Bloody_Cross) {
+		.@type = 1;
+		if (.@equip_item == Giant_Lance)
+			.@lhz_max_num = 4200;
+	} else if (.@equip_item == Catapult || .@equip_item == Big_CrossBow || .@equip_item == Creeper_Bow) {
+		.@type = 2;
+	} else if (.@equip_item == Chilly_Spell_Book || .@equip_item == Recovery_Light) {
+		.@type = 3;
+	} else if (.@equip_item== Giant_Shield || .@equip_item == Geffenia_Book_Water || .@equip_item == Bible_Of_Promise2 ||
+	           .@equip_item == Salvage_Cape || .@equip_item == Assassin_Handcuffs || .@equip_item == Green_Operation_Coat || 
+	           .@equip_item == Ancient_Gold_Deco) {
+		if (.@equip_item == Salvage_Cape || .@equip_item == Ancient_Gold_Deco)
+			.@lhz_max_num = 4200;
+	} else {
+		mes "[Pudding]";
+		mes "Before! I need to check if this equipment can accept the power.";
+		next;
+		specialeffect2 EF_SPHERE;
+		progressbar "ffff00", 2;
+		specialeffect2 EF_SUI_EXPLOSION;
+		emotion e_sob;
+		mes "[Pudding]";
+		mes "Hm.... This equipment cannot accept the power of '^F2766EWill of Warrior^000000' or '^952420Thirst for Blood^000000'.";
+		close;
+	}
+	emotion e_ho;
+	mes "[Pudding]";
+	mes "OHHH.. This equipment could accept the power of '^F2766EWill of Warrior^000000' or '^952420Thirst for Blood^000000'.";
+	next;
+	if (countitem(6469) >= 10)
+		.@menu_in$[1] = "Dwell the power of '^F2766EWill of Warrior^000000'";
+	else
+		.@menu_in$[1] = "Not enough ^999999'Will of Warrior'^000000";
+
+	if (countitem(6470) >= 10)
+		.@menu_in$[2] = "Dwell the power of '^952420Thirst for Blood^000000'";
+	else
+		.@menu_in$[2] = "Not enough ^999999'Thirst for Blood'^000000";
+
+	if (countitem(6471) >= 10)
+		.@menu_in$[3] = "Consume the '^88C6F7Chill of the Dead^000000'";
+	else
+		.@menu_in$[3] = "Not enough ^999999'Chill of the Dead'^000000";
+	mes "[Pudding]";
+	mes "OK! Which power do you want to dwell in your equipment?";
+	next;
+	switch(select("I say no! I don't need that!!", .@menu_in$[1], .@menu_in$[2], .@menu_in$[3])) {
+		case 1:
+			mes "[Pudding]";
+			mes "Ohhh.. I was looking forward to doing it, but it's all up to you......";
+			close;
+		case 2:
+			if (countitem(6469) < 10) {
+				mes "[Pudding]";
+				mes "Not enough '^F2766EWill of Warrior^000000', You need to bring 10 '^F2766EWill of Warrior^000000'";
+				close;
+			}
+			else if (getequipcardid(.@part, 3) > 0) {
+				mes "[Pudding]";
+				mes "This equipment already got the power of '^F2766EWill of Warrior^000000'.";
+				close;
+			} else {
+				.@socket_type = 4;
+			}
+			break;
+		case 3:
+			if (countitem(6470) < 10) {
+				mes "[Pudding]";
+				mes "Not enough '^952420Thirst for Blood^000000', You need to bring 10 '^952420Thirst for Blood^000000'";
+				close;
+			}
+			else if (getequipcardid(.@part, 2) > 0) {
+				mes "[Pudding]";
+				mes "This equipment already got the power of '^952420Thirst for Blood^000000'.";
+				close;
+			} else {
+				.@socket_type = 3;
+			}
+			break;
+		case 4:
+			// Enchant Removal
+			if (countitem(6471) < 10) {
+				.@menu_clear$[1] = "^999999Not enough 'Chill of the Dead'^000000";
+				.@menu_clear$[2] = "^999999Not enough 'Chill of the Dead'^000000";
+				.@4thzptsodyd = 1;
+				.@3thzptsodyd = 1;
+			} else {
+				if (getequipcardid(.@part, 3) > 0) {
+					.@menu_clear$[1] = "Remove the power of '^F2766EWill of Warrior^000000'";
+				} else {
+					.@menu_clear$[1] = "^999999There's no power to remove^000000";
+					.@4thzptsodyd = 1;
+				}
+				if (getequipcardid(.@part, 2) > 0) {
+					.@menu_clear$[2] = "Remove the power of '^952420Thirst for Blood^000000'";
+				} else {
+					.@menu_clear$[2] = "^999999There's no power to remove^000000";
+					.@3thzptsodyd = 1;
+				}
+			}
+			mes "[Pudding]";
+			mes "Alright, which power do you want to remove?";
+			next;
+			.@menu = select("No, I don't wannna remove any.", .@menu_clear$[1], .@menu_clear$[2]);
+			switch(.@menu){
+				case 1:
+					mes "[Pudding]";
+					mes "Really? Ok. I got it..";
+					close;
+				case 2:
+				case 3:
+					if (countitem(6471) < 10) {
+						mes "[Pudding]";
+						mes "Not enough '^88C6F7Chill of the Dead^000000', You need to bring 10 '^88C6F7Chill of the Dead^000000'";
+						close;
+					}
+					if ( (.@menu==3 && .@3thzptsodyd == 1) || (.@menu==2 && .@4thzptsodyd == 1) ) {
+						mes "[Pudding]";
+						mes "This equipment didn't get any special power.";
+						close;
+					}
+					setarray .@equip_card[0], getequipcardid(.@part,0), getequipcardid(.@part,1), getequipcardid(.@part,2), getequipcardid(.@part,3);
+					if (.@menu == 2)
+						.@equip_card[3] = 0;
+					else
+						.@equip_card[2] = 0;
+					.@equip_item = getequipid(.@part);
+					specialeffect EF_BEGINSPELL2, AREA, "Sorcerer#Bio4Reward";
+					progressbar "ffff00", 2;
+					specialeffect2 EF_FROSTWEAPON;
+					delitem 6471, 10; //Goast_Chill
+					delequip .@part;
+					getitem2 .@equip_item, 1, 1, .@refine_count, 0, .@equip_card[0], .@equip_card[1], .@equip_card[2], .@equip_card[3];
+					mes "[Pudding]";
+					if (.@menu==3)
+						mes "The power of '^952420Thirst for Blood^000000' has been perfectly removed.";
+					else
+						mes "The power of '^F2766EWill of Warrior^000000' has been perfectly removed.";
+					close;
+			}
+	}
+	mes "[Pudding]";
+	mes "Before I dwell the power, let me explain to you cautions.";
+	next;
+	mes "[Pudding]";
+	mes "While dwelling the power of '^F2766EWill of Warrior^000000' or '^952420Thirst for Blood^000000', the equipment would be not capable to accept that and will be destryed..";
+	next;
+	mes "[Pudding]";
+	mes "^9D2628If the equipment is destroyed, you will also lose the cards you inserted in it, and the refine Lv will be removed too.^000000";
+	next;
+	mes "[Pudding]";
+	mes "Alright. will you really wish to dwell the power into the equipment?";
+	next;
+	if (select("Wait, I will think again.", "Sure, carry on.") == 1) {
+		mes "[Pudding]";
+		mes "OK. I will be hoping to see you again.";
+		close;
+	}
+	mes "[Pudding]";
+	mes "I wish you made a correct decision...";
+	next;
+	if (.@socket_type >= 3) {
+		switch(.@type){
+			case 1:	// Short Distance
+				.@r = rand(1, .@lhz_max_num);
+				if      (.@r < 401)  .@enchant = 4700; //Strength1
+				else if (.@r < 441)  .@enchant = 4701; //Strength2
+				else if (.@r < 445)  .@enchant = 4702; //Strength3
+				else if (.@r < 845)  .@enchant = 4730; //Agility1
+				else if (.@r < 885)  .@enchant = 4731; //Agility2
+				else if (.@r < 889)  .@enchant = 4732; //Agility3
+				else if (.@r < 1289) .@enchant = 4740; //Vitality1
+				else if (.@r < 1329) .@enchant = 4741; //Vitality2
+				else if (.@r < 1333) .@enchant = 4742; //Vitality3
+				else if (.@r < 1523) .@enchant = 4710; //Inteligence1
+				else if (.@r < 1542) .@enchant = 4711; //Inteligence2
+				else if (.@r < 1544) .@enchant = 4712; //Inteligence3
+				else if (.@r < 1844) .@enchant = 4720; //Dexterity1
+				else if (.@r < 1874) .@enchant = 4721; //Dexterity2
+				else if (.@r < 1877) .@enchant = 4722; //Dexterity3
+				else if (.@r < 2067) .@enchant = 4750; //Luck1
+				else if (.@r < 2086) .@enchant = 4751; //Luck2
+				else if (.@r < 2088) .@enchant = 4752; //Luck3
+				else if (.@r < 2491) .@enchant = 0;
+				else if (.@r < 2891) .@enchant = 4811; //Fighting_Spirit1
+				else if (.@r < 2931) .@enchant = 4810; //Fighting_Spirit2
+				else if (.@r < 2935) .@enchant = 4809; //Fighting_Spirit3
+				else if (.@r < 3125) .@enchant = 4815; //Spell1
+				else if (.@r < 3144) .@enchant = 4814; //Spell2
+				else if (.@r < 3146) .@enchant = 4813; //Spell3
+				else if (.@r < 3148) .@enchant = 4807; //Atk_Speed1
+				else if (.@r < 3348) .@enchant = 4818; //Sharp1
+				else if (.@r < 3368) .@enchant = 4817; //Sharp2
+				else if (.@r < 3370) .@enchant = 4816; //Sharp3
+				else if (.@r < 3560) .@enchant = 4832; //Expert_Archer1
+				else if (.@r < 3579) .@enchant = 4833; //Expert_Archer2
+				else if (.@r < 3581) .@enchant = 4834; //Expert_Archer3
+				else                 .@enchant = 0;
+				break;
+			case 2:	// Long Distance
+				.@r = rand(1, .@lhz_max_num);
+				if      (.@r < 191)  .@enchant = 4700; //Strength1
+				else if (.@r < 210)  .@enchant = 4701; //Strength2
+				else if (.@r < 212)  .@enchant = 4702; //Strength3
+				else if (.@r < 612)  .@enchant = 4730; //Agility1
+				else if (.@r < 652)  .@enchant = 4731; //Agility2
+				else if (.@r < 656)  .@enchant = 4732; //Agility3
+				else if (.@r < 846)  .@enchant = 4740; //Vitality1
+				else if (.@r < 865)  .@enchant = 4741; //Vitality2
+				else if (.@r < 867)  .@enchant = 4742; //Vitality3
+				else if (.@r < 1167) .@enchant = 4710; //Inteligence1
+				else if (.@r < 1197) .@enchant = 4711; //Inteligence2
+				else if (.@r < 1200) .@enchant = 4712; //Inteligence3
+				else if (.@r < 1600) .@enchant = 4720; //Dexterity1
+				else if (.@r < 1640) .@enchant = 4721; //Dexterity2
+				else if (.@r < 1644) .@enchant = 4722; //Dexterity3
+				else if (.@r < 1834) .@enchant = 4750; //Luck1
+				else if (.@r < 1853) .@enchant = 4751; //Luck2
+				else if (.@r < 1855) .@enchant = 4752; //Luck3
+				else if (.@r < 2258) .@enchant = 0;
+				else if (.@r < 2448) .@enchant = 4811; //Fighting_Spirit1
+				else if (.@r < 2467) .@enchant = 4810; //Fighting_Spirit2
+				else if (.@r < 2469) .@enchant = 4809; //Fighting_Spirit3
+				else if (.@r < 2669) .@enchant = 4815; //Spell1
+				else if (.@r < 2689) .@enchant = 4814; //Spell2
+				else if (.@r < 2691) .@enchant = 4813; //Spell3
+				else if (.@r < 2693) .@enchant = 4807; //Atk_Speed1
+				else if (.@r < 3093) .@enchant = 4818; //Sharp1
+				else if (.@r < 3133) .@enchant = 4817; //Sharp2
+				else if (.@r < 3137) .@enchant = 4816; //Sharp3
+				else if (.@r < 3537) .@enchant = 4832; //Expert_Archer1
+				else if (.@r < 3577) .@enchant = 4833; //Expert_Archer2
+				else if (.@r < 3581) .@enchant = 4834; //Expert_Archer3
+				else                 .@enchant = 0;
+				break;
+			case 3:
+				.@r = rand(1, .@lhz_max_num);
+				if      (.@r < 301)  .@enchant = 4700; //Strength1
+				else if (.@r < 331)  .@enchant = 4701; //Strength2
+				else if (.@r < 334)  .@enchant = 4702; //Strength3
+				else if (.@r < 534)  .@enchant = 4730; //Agility1
+				else if (.@r < 554)  .@enchant = 4731; //Agility2
+				else if (.@r < 556)  .@enchant = 4732; //Agility3
+				else if (.@r < 956)  .@enchant = 4740; //Vitality1
+				else if (.@r < 996)  .@enchant = 4741; //Vitality2
+				else if (.@r < 1000) .@enchant = 4742; //Vitality3
+				else if (.@r < 1400) .@enchant = 4710; //Inteligence1
+				else if (.@r < 1440) .@enchant = 4711; //Inteligence2
+				else if (.@r < 1444) .@enchant = 4712; //Inteligence3
+				else if (.@r < 1844) .@enchant = 4720; //Dexterity1
+				else if (.@r < 1884) .@enchant = 4721; //Dexterity2
+				else if (.@r < 1888) .@enchant = 4722; //Dexterity3
+				else if (.@r < 2078) .@enchant = 4750; //Luck1
+				else if (.@r < 2097) .@enchant = 4751; //Luck2
+				else if (.@r < 2099) .@enchant = 4752; //Luck3
+				else if (.@r < 2502) .@enchant = 0;
+				else if (.@r < 2692) .@enchant = 4811; //Fighting_Spirit1
+				else if (.@r < 2711) .@enchant = 4810; //Fighting_Spirit2
+				else if (.@r < 2713) .@enchant = 4809; //Fighting_Spirit3
+				else if (.@r < 3113) .@enchant = 4815; //Spell1
+				else if (.@r < 3153) .@enchant = 4814; //Spell2
+				else if (.@r < 3157) .@enchant = 4813; //Spell3
+				else if (.@r < 3159) .@enchant = 4807; //Atk_Speed1
+				else if (.@r < 3349) .@enchant = 4818; //Sharp1
+				else if (.@r < 3368) .@enchant = 4817; //Sharp2
+				else if (.@r < 3370) .@enchant = 4816; //Sharp3
+				else if (.@r < 3560) .@enchant = 4832; //Expert_Archer1
+				else if (.@r < 3579) .@enchant = 4833; //Expert_Archer2
+				else if (.@r < 3581) .@enchant = 4834; //Expert_Archer3
+				else                 .@enchant = 0;
+				break;
+			case 4:	// Armor
+				.@r = rand(1, .@lhz_max_num);
+				if      (.@r < 301)  .@enchant = 4700; //Strength1
+				else if (.@r < 331)  .@enchant = 4701; //Strength2
+				else if (.@r < 334)  .@enchant = 4702; //Strength3
+				else if (.@r < 634)  .@enchant = 4730; //Agility1
+				else if (.@r < 664)  .@enchant = 4731; //Agility2
+				else if (.@r < 667)  .@enchant = 4732; //Agility3
+				else if (.@r < 967)  .@enchant = 4740; //Vitality1
+				else if (.@r < 997)  .@enchant = 4741; //Vitality2
+				else if (.@r < 1000) .@enchant = 4742; //Vitality3
+				else if (.@r < 1300) .@enchant = 4710; //Inteligence1
+				else if (.@r < 1330) .@enchant = 4711; //Inteligence2
+				else if (.@r < 1333) .@enchant = 4712; //Inteligence3
+				else if (.@r < 1633) .@enchant = 4720; //Dexterity1
+				else if (.@r < 1663) .@enchant = 4721; //Dexterity2
+				else if (.@r < 1666) .@enchant = 4722; //Dexterity3
+				else if (.@r < 1966) .@enchant = 4750; //Luck1
+				else if (.@r < 1996) .@enchant = 4751; //Luck2
+				else if (.@r < 1999) .@enchant = 4752; //Luck3
+				else if (.@r < 2399) .@enchant = 0;
+				else if (.@r < 2549) .@enchant = 4786; //Mdef2
+				else if (.@r < 2599) .@enchant = 4787; //Mdef4
+				else if (.@r < 2609) .@enchant = 4788; //Mdef6
+				else if (.@r < 2614) .@enchant = 4789; //Mdef8
+				else if (.@r < 2616) .@enchant = 4790; //Mdef10
+				else if (.@r < 2766) .@enchant = 4791; //Def3
+				else if (.@r < 2866) .@enchant = 4792; //Def6
+				else if (.@r < 2876) .@enchant = 4793; //Def9
+				else if (.@r < 2878) .@enchant = 4794; //Def12
+				else if (.@r < 3278) .@enchant = 0;
+				else if (.@r < 3428) .@enchant = 4859; //Evasion1
+				else if (.@r < 3478) .@enchant = 4860; //Evasion3
+				else if (.@r < 3488) .@enchant = 4762; //Evasion6
+				else if (.@r < 3498) .@enchant = 4800; //SP50
+				else if (.@r < 3734) .@enchant = 4795; //HP100
+				else if (.@r < 3834) .@enchant = 4796; //HP200
+				else if (.@r < 3884) .@enchant = 4797; //HP300
+				else                 .@enchant = 0;
+			break;
+		}
+		setarray .@equip_card[0], getequipcardid(.@part,0),getequipcardid(.@part,1),getequipcardid(.@part,2),getequipcardid(.@part,3);
+		.@equip_card[(.@socket_type-1)] = .@enchant;
+		.@equip_item = getequipid(.@part);
+		specialeffect EF_BEGINSPELL3, AREA, "Sorcerer#Bio4Reward";
+		progressbar "ffff00", 2;
+		if (.@socket_type == 3)
+			delitem 6470, 10; //Blood_Thirst
+		else
+			delitem 6469, 10; //Will_Of_Warrior
+		delequip .@part;
+		
+		if (.@enchant == 0){
+			specialeffect2 EF_SUI_EXPLOSION;
+			emotion e_otl;
+			mes "[Pudding]";
+			mes "...Well....the equipment could not accept the power of "+((.@socket_type==3)?"'^952420Thirst for Blood^000000'":"'^F2766EWill of Warrior^000000'")+" and it got destroyed.";
+			close;
+		} else {
+			specialeffect2 EF_FIREHIT;
+			getitem2 .@equip_item, 1, 1, .@refine_count, 0, .@equip_card[0], .@equip_card[1], .@equip_card[2], .@equip_card[3];
+			//dispbottom "1:"+ .@equip_item;
+			//dispbottom "1:"+ .@refine_count;
+			//dispbottom "1:"+ .@equip_card[0];
+			//dispbottom "1:"+ .@equip_card[1];
+			//dispbottom "1:"+ .@equip_card[2];
+			//dispbottom "1:"+ .@equip_card[3];
+			emotion e_ho;
+			mes "[Pudding]";
+			mes "Fortunately the power of "+((.@socket_type==3)?"'^952420Thirst for Blood^000000'":"'^F2766EWill of Warrior^000000'")+" has been dwelt well in your equipment...";
+			close;
+		}
+	}
+	end;
+}
+
+// Warp portal to the 4th Fl.
+//============================================================
+lhz_dun03,239,78,1	script	lhz_dun03_lhz_dun04	WARPNPC,1,1,{
+	end;
+
+OnTouch:
+	if (lght_duk01 > 0 && lght_duk01 < 6) {
+		mes "In order to investigate human experimentation, I had to go down whilst I didn't want to because of gruesome sound.";
+		close2;
+		if (lght_duk01 < 3) {
+			warp "que_lhz", 245, 56;
+		} else if (lght_duk01 == 3) {
+			warp "que_lhz", 96, 136;
+		} else {
+			warp "que_lhz", 148, 215;
+		}
+	} else {
+		if (lhz_boss < 31) {
+			mes "- Whistling sound -";
+			mes "From below, there comes a gruesome sound mingling with the wind.";
+			close2;
+		}
+		warp "lhz_dun04", 245, 56;
+	}
+	end;
+}
+
+// Warp Portal to the 3rd Fl.
+//============================================================
+lhz_dun04,244,61,1	warp	lhz_dun04_lhz_dun03	1,1,lhz_dun03,240,75
+
+// Inside the Lab
+//============================================================
+que_lhz,242,50,0	script	#01Startpoint	-1,3,3,{
+	end;
+
+OnInit:
+	initnpctimer;
+	end;
+
+OnTimer60000:
+	mapannounce "que_lhz", "Man's whisper: Pl.. please.. save me.. I don't wanna die.. wouaaaa..", bc_map, "0x7DCBF0";
+	end;
+
+OnTimer120000:
+	mapannounce "que_lhz", "Woman's whisper: .. Save.. aaaah.. us...", bc_map, "0x7DCBF0";
+	end;
+
+OnTimer180000:
+	mapannounce "que_lhz", "Kid's whisper: Bawwww~ Where am I? Mama......aaaa....", bc_map, "0x7DCBF0";
+	end;
+
+OnTimer240000:
+	mapannounce "que_lhz", "Oldman's whisper: Kirk...hel...help......", bc_map, "0x7DCBF0";
+	end;
+
+OnTimer300000:
+	stopnpctimer;
+	initnpctimer;
+	end;
+
+OnTouch:
+	if (lght_duk01 == 1) {
+		mes "I arrived at a research facility which seems it has been used till these days.";
+		next;
+		mes "There are some destroyed part, but the basic facility seem fine.";
+		next;
+		lght_duk01 = 2;
+		mes "Get around a little more...";
+		close;
+	}
+	end;
+}
+
+que_lhz,206,74,4	script	Researcher#02	4_LGTSCIENCE,3,3,{
+	end;
+
+OnTouch:
+	if (lght_duk01 == 2) {
+		emotion e_omg, 1;
+		mes "["+ strcharinfo(0) +"]";
+		mes "You!!!! are Wolfchev?";
+		next;
+		emotion e_gg, "Researcher#02";
+		mes "[Wolfchev]";
+		mes "A Human! kaahaha. People tend to hate this place, why are you here?";
+		next;
+		mes "["+ strcharinfo(0) +"]";
+		mes "You!!! I heard that you were committing human experimentation. Wolfchev!!";
+		next;
+		mes "["+ strcharinfo(0) +"]";
+		mes "And I see that you are still committing that!!!";
+		next;
+		emotion e_gg, "Researcher#02";
+		mes "[Wolfchev]";
+		mes "Kihihihi. I can see that you know something about me. Is that you who accused me?";
+		mes "How dare you come back to me after you did that. Kihihih";
+		next;
+		mes "[Wolfchev]";
+		mes "I feel good to see a human";
+		mes "in a long time, but I gotta go. Kihihihi.";
+		next;
+		mes "- Wolfchev ran away giving a awkward laughing sound. -";
+		next;
+		erasequest 5109;
+		setquest 5110;
+		lght_duk01 = 3;
+		emotion e_omg, 1;
+		mes "["+ strcharinfo(0) +"]";
+		mes "Whoa! Wolfchev, stop!";
+		close2;
+		warp "que_lhz", 96, 136;
+	}
+	end;
+}
+
+que_lhz,94,119,4	script	Researcher#03	4_LGTSCIENCE,{
+	if ((MaxWeight - Weight) < 1000 || !checkweight(1201, 1)) {
+		mes "^FF0000 Check up your inventory. You got too many items to carry out the quest. ^000000";
+		close;
+	}
+	if (lght_duk01 == 3) {
+		emotion e_swt2, "Researcher#03";
+		mes "[Wolfchev]";
+		mes "(Gasping) Pshaw... you are still following me. Hey, why do you keep following me?";
+		next;
+		mes "["+ strcharinfo(0) +"]";
+		mes "Wolfchev.. You said before. that you are doing research for everybody.";
+		next;
+		mes "[Wolfchev]";
+		mes "I might have said that.... so what?";
+		next;
+		mes "["+ strcharinfo(0) +"]";
+		mes "But, your experiment seem really dangerous. How come this is what everybody wants?";
+		next;
+		emotion e_gg, "Researcher#03";
+		mes "[Wolfchev]";
+		mes "Everyone has a desire to be stronger and wants to dominate others so those other people obey and admire you. Do you not have that desire?";
+		next;
+		mes "["+ strcharinfo(0) +"]";
+		mes "... .... ...";
+		next;
+		mes "[Wolfchev]";
+		mes "If you want to save yourself, should stop following me. Bugger off.";
+		next;
+		mes "Wolfchev is again running away with a strange sound.";
+		next;
+		lght_duk01 = 4;
+		mes "["+ strcharinfo(0) +"]";
+		mes "Awwww!! You!! running away again..... Stop!";
+		close2;
+		warp "que_lhz", 148, 215;
+	}
+	end;
+}
+
+que_lhz,147,224,4	script	Researcher#04	4_LGTSCIENCE,{
+	if ((MaxWeight - Weight) < 1000 || !checkweight(1201, 1)) {
+		mes "^FF0000 Check up your inventory. You got too many items to carry out the quest. ^000000";
+		close;
+	}
+	if (lght_duk01 == 4) {
+		mes "[Wolfchev]";
+		mes "You are pretty persistent, aren't you? Or I think.......that you like me, huh? Kihihii.";
+		next;
+		emotion e_dots;
+		mes "["+ strcharinfo(0) +"]";
+		mes "... .... ...";
+		next;
+		specialeffect EF_SIGHTRASHER;
+		mes "Wolfchev mocked you at your silence and pressed a button in his hand. Then guinea pigs woken up around him.";
+		next;
+		for(.@i = 1; .@i < 9; .@i++)
+			donpcevent "Human Guinea pig#0"+.@i+"::OnEnable";
+		mes "[Wolfchev]";
+		mes "Again.. it's time to say goodbye.";
+		next;
+		emotion e_gasp, "Researcher#04";
+		mes "[Wolfchev]";
+		mes "Well! May be....";
+		next;
+		mes "[Wolfchev]";
+		mes "If you come to me for the experimentation, I can treat you better.";
+		next;
+		donpcevent "#Eventctrl::OnEnable";
+		progressbar "FF00FF", 5;
+		emotion e_omg, "Researcher#04";
+		mes "[Wolfchev]";
+		mes "Oh my,... What happened?";
+		next;
+		donpcevent "#Eventctrl::OnEnable2";
+		for(.@i = 1; .@i < 9; .@i++)
+			donpcevent "Human Guinea pig#0"+.@i+"::OnDisable";
+		mes "[Wolfchev]";
+		mes "No! Don't come to me! Don't!!";
+		next;
+		lght_duk01 = 5;
+		mes "First of all, I gotta handle those guinea pigs!";
+		close;
+	} else if (lght_duk01 == 5) {
+		.@i = rand(1,3);
+		if (.@i == 2) {
+			mes "Wolfchev is confused and has no idea now since those monsters are attacking him too.";
+			next;
+			specialeffect EF_STUNATTACK;
+			specialeffect EF_STUNATTACK;
+			mes "- Hit him to wake him up -";
+			next;
+			specialeffect EF_DARKBREATH;
+			emotion e_no;
+			mes "["+ strcharinfo(0) +"]";
+			mes "Hey Dude! Anyway let's get out of here first! Isn't there any place where they cannot reach?";
+			next;
+			mes "[Wolfchev]";
+			mes "Oooops.. then my....my lab....to my lab...";
+			next;
+			mes "["+ strcharinfo(0) +"]";
+			mes "Your lab?? Okay, where's that?";
+			next;
+			mes "[Wolfchev]";
+			mes "to the north....... . Not so far from here..";
+			next;
+			erasequest 5110;
+			setquest 5111;
+			lght_duk01 = 6;
+			mes "Go to '^0000FFWolfchev's Lab^000000' at the 12 o'clock direction...";
+			close;
+		} else {
+			emotion e_spin, "Researcher#04";
+			mes "Wolfchev is confused and has no idea now since those monsters are attacking him too.";
+			close;
+		}
+	} else if (lght_duk01 == 6) {
+		mes "Go to '^0000FFWolfchev's Lab^000000' at the 12 o'clock direction...";
+		close;
+	}
+	end;
+}
+
+// Warp to lhz_dun04 from Wolfchev's Lab
+//============================================================
+que_lhz,148,251,0	script	#Move2lab	-1,12,0,{
+	end;
+
+OnTouch:
+	if (lght_duk01 == 6) {
+		mes "I arrived at '^0000FFWolfchev's Lab^000000'.";
+		close2;
+		warp "lhz_dun04", 148, 269;
+		end;
+	} else {
+		mes "I still have something to do with Wolfchev.";
+		close;
+	}
+}
+
+// Event Controller
+//============================================================
+que_lhz,1,1,0	script	#Eventctrl	-1,{
+	end;
+
+OnEnable:
+	initnpctimer;
+	end;
+
+OnEnable2:
+	monster "que_lhz", 139, 232, "Human Guinea pig", 2244, 1, "#Eventctrl::OnMyMobDead";
+	monster "que_lhz", 147, 232, "Human Guinea pig", 2244, 1, "#Eventctrl::OnMyMobDead";
+	monster "que_lhz", 156, 232, "Human Guinea pig", 2244, 1, "#Eventctrl::OnMyMobDead";
+	monster "que_lhz", 156, 224, "Human Guinea pig", 2244, 1, "#Eventctrl::OnMyMobDead";
+	monster "que_lhz", 156, 215, "Human Guinea pig", 2244, 1, "#Eventctrl::OnMyMobDead";
+	monster "que_lhz", 147, 215, "Human Guinea pig", 2244, 1, "#Eventctrl::OnMyMobDead";
+	monster "que_lhz", 139, 215, "Human Guinea pig", 2244, 1, "#Eventctrl::OnMyMobDead";
+	monster "que_lhz", 139, 224, "Human Guinea pig", 2244, 1, "#Eventctrl::OnMyMobDead";
+	end;
+
+OnTimer1000:
+	specialeffect EF_SUI_EXPLOSION,AREA, "#01";
+	specialeffect EF_BEGINASURA, "Human Guinea pig#01";
+	end;
+
+OnTimer2000:
+	specialeffect EF_SUI_EXPLOSION,AREA, "#02";
+	specialeffect EF_BEGINASURA, "Human Guinea pig#02";
+	end;
+
+OnTimer3000:
+	specialeffect EF_SUI_EXPLOSION,AREA, "#03";
+	specialeffect EF_BEGINASURA, "Human Guinea pig#03";
+	end;
+
+OnTimer4000:
+	specialeffect EF_SUI_EXPLOSION,AREA, "#04";
+	specialeffect EF_BEGINASURA, "Human Guinea pig#04";
+	end;
+
+OnTimer5000:
+	specialeffect EF_SUI_EXPLOSION,AREA, "#05";
+	specialeffect EF_BEGINASURA, "Human Guinea pig#05";
+	end;
+
+OnTimer6000:
+	specialeffect EF_SUI_EXPLOSION,AREA, "#06";
+	specialeffect EF_BEGINASURA, "Human Guinea pig#06";
+	end;
+
+OnTimer7000:
+	specialeffect EF_SUI_EXPLOSION,AREA, "#07";
+	specialeffect EF_BEGINASURA, "Human Guinea pig#07";
+	end;
+
+OnTimer8000:
+	specialeffect EF_SUI_EXPLOSION,AREA, "#08";
+	specialeffect EF_BEGINASURA, "Human Guinea pig#08";
+	stopnpctimer;
+	end;
+
+OnMyMobDead:
+	if (mobcount("que_lhz", "#Eventctrl::OnMyMobDead") < 4)
+		killmonster "que_lhz", "#Eventctrl::OnMyMobDead";
+}
+que_lhz,139,232,0	script	#01	-1,{ end; }
+que_lhz,147,232,0	script	#02	-1,{ end; }
+que_lhz,156,232,0	script	#03	-1,{ end; }
+que_lhz,156,224,0	script	#04	-1,{ end; }
+que_lhz,156,215,0	script	#05	-1,{ end; }
+que_lhz,147,215,0	script	#06	-1,{ end; }
+que_lhz,139,215,0	script	#07	-1,{ end; }
+que_lhz,139,224,0	script	#08	-1,{ end; }
+
+// Human Guinea pigs
+//============================================================
+que_lhz,140,231,1	script	Human Guinea pig#01	2224,{
+	end;
+
+OnInit:
+	disablenpc strnpcinfo(0);
+	end;
+
+OnEnable:
+	enablenpc strnpcinfo(0);
+	end;
+
+OnDisable:
+	specialeffect EF_FLASHER;
+	disablenpc strnpcinfo(0);
+	end;
+}
+que_lhz,147,231,0	duplicate(Human Guinea pig#01)	Human Guinea pig#02	2224
+que_lhz,155,231,7	duplicate(Human Guinea pig#01)	Human Guinea pig#03	2224
+que_lhz,155,224,6	duplicate(Human Guinea pig#01)	Human Guinea pig#04	2224
+que_lhz,155,216,5	duplicate(Human Guinea pig#01)	Human Guinea pig#05	2224
+que_lhz,147,216,4	duplicate(Human Guinea pig#01)	Human Guinea pig#06	2224
+que_lhz,140,216,3	duplicate(Human Guinea pig#01)	Human Guinea pig#07	2224
+que_lhz,140,224,2	duplicate(Human Guinea pig#01)	Human Guinea pig#08	2224
+
+// Instance Creation
+//============================================================
+lhz_dun04,151,276,3	script	Researcher#memo	4_LGTSCIENCE,{
+	if ((MaxWeight - Weight) < 1000 || !checkweight(1201, 1)) {
+		mes "^FF0000You cannot continue the process due to possessing too many belongings.^000000";
+		close;
+	}
+	.@quest_time = checkquest(5112, PLAYTIME);
+	.@killed_bosses = true;
+	for(.@quest_id = 5113; .@quest_id <= 5125; .@quest_id++) {
+		if (checkquest(.@quest_id, HUNTING) <= 1)
+			.@killed_bosses = false;
+	}
+	if (lght_duk01 < 6) {
+		mes "[Researcher]";
+		mes "What! Do you have any business here?";
+		next;
+		if (select("Yes I do!!", "Umm.. No..") == 1) {
+			mes "[Researcher]";
+			mes "Why don't stop staring at other's laboratory, and be on your way?";
+			close;
+		}
+		mes "[Researcher]";
+		mes "Stop wondering here, and be on your way. Will you? Khh Khh.";
+		close;
+	} else if (lght_duk01 == 6) {
+		mes "It seems experimental creatures cannot come near the laboratory, just like Wolfchev said.";
+		next;
+		mes "["+ strcharinfo(0) +"]";
+		mes "Hey, is there any way to stop those creatures? You should know something, you made those things!";
+		next;
+		mes "[Wolfchev]";
+		mes "Urrgg.. I didn't expect them to loose control like that...";
+		next;
+		mes "[Wolfchev]";
+		mes "What is wrong with this whole thing?";
+		next;
+		mes "[Wolfchev]";
+		mes "Urr.. I think they will ruin my whole laboratory!";
+		next;
+		emotion e_loud, 1;
+		mes "["+ strcharinfo(0) +"]";
+		mes "Hey! Wolfchev!!";
+		next;
+		mes "[Wolfchev]";
+		mes "You!? Hey, please stop them!";
+		mes "Creatures are ^9f6077organically connected with same job field^000000.";
+		next;
+		mes "[Wolfchev]";
+		mes "There is one special creature being their ^46B951boss position^000000...";
+		mes "If you could deactivate that creature, all ^A1BB44slave creatures^000000 walking around here will stop moving right away.";
+		next;
+		mes "["+ strcharinfo(0) +"]";
+		mes "Boss creature?";
+		mes "Hey! Wolfchev! Where is that ^46B951Boss creature^000000?";
+		next;
+		mes "[Wolfchev]";
+		mes "Inside.. of laboratory.. It should be waken up now. It's sad to destroy my life of work, but I can't take this any more.. ...";
+		next;
+		mes "["+ strcharinfo(0) +"]";
+		mes "How can I get into the Wolfchev's laboratory?";
+		next;
+		mes "[Wolfchev]";
+		mes "Oh.. Wait!";
+		mes "I will help you get in there.";
+		next;
+		mes "[Wolfchev]";
+		mes "Good news is that boss creatures are not set up to wake up all at once, even though slaves are.";
+		next;
+		erasequest 5111;
+		lght_duk01 = 7;
+		for(.@i = 5113; .@i <= 5125; .@i++)
+			setquest .@i;
+		mes "[Wolfchev]";
+		mes "But still, it is really dangerous since we don't know when they will escape from there.";
+		mes "So, please prepare your party members, and take care of those boss creatures. I'm not sure how long this place can hold.";
+		close;
+	} else if (lght_duk01 > 6) {
+		if (getcharid(1) > 0) {
+			mes "[Wolfchev]";
+			mes "Are you all set there? I will prepare the entrance if you are the leader of that party.";
+			next;
+			switch(select("Any warnings?", "Going into the laboratory", "Do not enter")) {
+			case 1:
+				mes "[Wolfchev]";
+				mes "I didn't know pressing the emergency alarm would cause such problem. The management system seems to be changed to emergency mode.";
+				next;
+				mes "[Wolfchev]";
+				mes "There are so many systems set up inside of the laboratory, so eve I cannot be sure how systems are twisted by now.";
+				next;
+				mes "[Wolfchev]";
+				mes "Ah! If the emergency system is activating, only the leader of party should control everything. It is a lot of pressure I understand.";
+				next;
+				mes "[Wolfchev]";
+				mes "And just so you know, please do not touch random things out of curiosity. I don't want you to get hurt.";
+				close;
+			case 2:
+				if (.@quest_time == 0) {
+					mes "[Wolfchev]";
+					mes "I'm sorry, but it seems you still cannot enter to the laboratory yet. Will you come back later? The system is kind of tricky you know.";
+					close;
+				} else {
+					//if (.@quest_time == 2)
+						//recall_completequest 5112;
+					if (isbegin_quest(5112))
+						erasequest 5112;
+					if (!.@killed_bosses) {
+						if (lght_duk01 == 9) {
+							mes "[Wolfchev]";
+							mes "You came back, Ka Ha Ha.";
+							next;
+							mes "[Wolfchev]";
+							mes "After you left, I was fixing some system parts. And then suddenly strange thing happened.";
+							next;
+							mes "["+ strcharinfo(0) +"]";
+							mes "What was that?";
+							next;
+							mes "[Wolfchev]";
+							mes "All those boss creatures you took care of started to regenerate themselves..";
+							next;
+							mes "["+ strcharinfo(0) +"]";
+							mes "What.. How is that possible...?!";
+							next;
+							mes "[Wolfchev]";
+							mes "I am also completely lost here.. But, this should not be happening..";
+							next;
+							mes "["+ strcharinfo(0) +"]";
+							mes "... .... ...";
+							next;
+							mes "[Wolfchev]";
+							mes "As you can see, you are the only one I can trust. Would you and your party help me once again deactivating those creatures?";
+							next;
+							if (select("I am not sure", "Why not") == 1) {
+								mes "[Wolfchev]";
+								mes "I see. I understand why you are hesitating, and don't want to press you any more. But, still I'm not sure why you want go there anyways,";
+								next;
+							} else {
+								for(.@i = 5113; .@i <= 5125; .@i++) {
+									setquest .@i;
+								}
+								lght_duk01 = 10;
+								mes "[Wolfchev]";
+								mes "Thank you very much. "+strcharinfo(0)+"";
+								mes "I will help you get in the laboratory right away.";
+								next;
+							}
+						} else {
+							mes "[Wolfchev]";
+							mes "Hmm.. Those boss creatures regenerating once again..";
+							next;
+							mes "[Wolfchev]";
+							mes "Can you help me just one more time?";
+							next;
+							if (select("I am not sure", "Why not") == 1) {
+								mes "[Wolfchev]";
+								mes "I see. I understand why you are hesitating, and don't want to press you any more. But, still I'm not sure why you want go there anyways,";
+								next;
+							} else {
+								for(.@i = 5113; .@i <= 5125; .@i++) {
+									setquest .@i;
+								}
+								lght_duk01 = 10;
+								mes "[Wolfchev]";
+								mes "Thank you. "+strcharinfo(0)+"";
+								mes "You want to get in there fast, right?";
+								next;
+							}
+						}
+					}
+				}
+				if (getpartyleader(getcharid(1),2) == getcharid(0)) {
+					if (instance_create("Wolfchev's Laboratory") < 0) {
+						mes "[Wolfchev]";
+						mes "Hmm.. Lab entering system is a bit weird. Would wait for me to check the system?";
+						close;
+					}
+					mes "[Wolfchev]";
+					mes "Please hold on...";
+					next;
+					mes "Wolfchev starts to control certain gear.";
+					next;
+					progressbar "FF00FF", 2;
+					mes "[Wolfchev]";
+					mes "Alright! I have marked lan entering system code as";
+					mes "^0000ff"+ strcharinfo(1) +"^000000 party leader's name ^0000ff"+ strcharinfo(0) +"^000000!!.";
+					next;
+					mes "[Wolfchev]";
+					mes "Now, your party is free to pass the entrance.";
+					close;
+				} else {
+					mes "[Wolfchev]";
+					mes "You are not the ^0000ffLeader of the party^000000, are you? Please go get the leader.";
+					close;
+				}
+			case 3:
+				mes "[Wolfchev]";
+				mes "Need more preparation? Please, we don't have all day.";
+				close;
+			}
+		} else {
+			mes "[Wolfchev]";
+			mes "Are you trying to go there along? That is a suicide! Our lab entering system is not as easy as you thinkz`.";
+			close;
+		}
+	} else {
+		mes "[Wolfchev]";
+		mes "Woot! Something weird just happen. If this keep happening, maybe we should try other way..";
+		close;
+	}
+}
+
+lhz_dun04,147,279,0	script	Laboratory Entrance#memo	CLEAR_NPC,{
+	if ((MaxWeight - Weight) < 1000 || !checkweight(1201, 1)) {
+		mes "^FF0000You cannot continue the process due to possessing too many belongings.^000000";
+		close;
+	}
+	.@lhz_time = checkquest(5112, PLAYTIME);
+	if (lght_duk01 < 7) {
+		mes "It says,";
+		mes "'^0000FF****'s laboratory member only^000000'";
+		close;
+	}
+	if (.@lhz_time == -1) {
+		mes "This is an entrance towards Wolfchev's laboratory. Something is howling over the entrance.";
+		next;
+		if (select("Go inside", "Think one more time") == 2) {
+			mes "You have stopped entering to Wolfchev's laboratory.";
+			close;
+		}
+		if (instance_enter("Wolfchev's Laboratory") != 0) {  // probably missing failure cases
+			mes "^FF0000Warning^000000";
+			mes ""+ strcharinfo(0) +". . .";
+			mes "^FF0000Unregistered personnel^000000";
+			next;
+			pushpc 0, 10;
+			percentheal -5,0;
+			specialeffect EF_AUTOCOUNTER;
+			specialeffect2 EF_BASH;
+			mes "You have been wounded by laboratory entrance system attack.";
+			close;
+		}
+		mapannounce "lhz_dun04","Laboratory entrance system ["+ strcharinfo(1) +"] member ["+ strcharinfo(0) +"] access granted..",bc_map,"0x0DF297";
+		setquest 5112;
+		//warp "1@lhz", 45, 148;
+		close;
+	} else if (.@lhz_time == 0) {
+		mes "Di Rit- Di- Di- Dit-";
+		next;
+		mes ""+ strcharinfo(0) +". . .";
+		mes "^FF0000Forbidden personnel^000000";
+		next;
+		mes "The system denied your entrance.";
+		close;
+	} else if (.@lhz_time >= 1) {
+		mes "Di Rit- Di- Di- Dit-";
+		next;
+		//if (.@lhz_time == 2)
+			//recall_completequest 5112;
+		erasequest 5112;
+		mes ""+ strcharinfo(0) +". . .";
+		mes "^FF0000Access denial has been deactivated.^000000";
+		close;
+	} else {
+		mes "^FF0000Error! Error!^000000";
+		mes "^FF0000Please try again.^000000";
+		close;
+	}
+}
+
+// The Lab No.1 : System 1_1
+//============================================================
+1@lhz,35,108,4	script	Lab1#1_1	CLEAR_NPC,{
+	end;
+
+OnInstanceInit:
+	initnpctimer;
+	end;
+
+OnDisable:
+	stopnpctimer;
+	end;
+
+OnType_02:
+	donpcevent instance_npcname("Manual Sheet#1_1")+"::OnEnable";
+	donpcevent instance_npcname("Valve#1_2")+"::OnEnable";
+	donpcevent instance_npcname("Valve#1_3")+"::OnEnable";
+	mapannounce instance_mapname("1@lhz"),"[Security System] the persons concerned, access with the emergency access method.",bc_map,"0xff9977";
+	end;
+
+OnTimer1000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] This is a warning notice! Warning notice! Intruder Detected.",bc_map,"0xff9977";
+	end;
+
+OnTimer2000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] In 5 seconds, The Lab No.1's security system will be activated.",bc_map,"0xff9977";
+	end;
+
+OnTimer7000:
+	donpcevent instance_npcname("MobCtrl1#mob01")+"::OnEnable";
+	end;
+}
+
+// The Lab No.1 Monster Control
+//============================================================
+1@lhz,37,108,4	script	MobCtrl1#mob01	CLEAR_NPC,{
+	end;
+
+OnEnable:
+	.@map$ = instance_mapname("1@lhz");
+	mapannounce .@map$,"[Security System] Security system Activated !! Experimental animals are released. The persons concerned have to evacuate.",bc_map,"0xff9977";
+	areamonster .@map$,35,159,50,169,"Starving Lab animal",2242,rand(10,15),instance_npcname(strnpcinfo(0))+"::OnMyMobDead";
+	initnpctimer;
+	end;
+
+OnDisable:
+	killmonster instance_mapname("1@lhz"),instance_npcname(strnpcinfo(0))+"::OnMyMobDead";
+	end;
+
+OnTimer180000:
+	stopnpctimer;
+	if (mobcount(instance_mapname("1@lhz"), instance_npcname(strnpcinfo(0))+"::OnMyMobDead") < 1) {
+		donpcevent instance_npcname("Lab1#1_1")+"::OnType_02";
+		mapannounce instance_mapname("1@lhz"),"[Security System] The Lab No.1's security system has been stopped.",bc_map,"0xff9977";
+	} else {
+		initnpctimer;
+	}
+	end;
+
+OnMyMobDead:
+	if (mobcount(instance_mapname("1@lhz"), instance_npcname(strnpcinfo(0))+"::OnMyMobDead") < 1) {
+		donpcevent instance_npcname("Lab1#1_1")+"::OnType_02";
+		mapannounce instance_mapname("1@lhz"),"[Security System] The Lab No.1's security system has been stopped.",bc_map,"0xff9977";
+		stopnpctimer;
+	}
+	end;
+}
+
+// Emergency Access Valve Manual
+//============================================================
+1@lhz,39,168,0	script	Manual Sheet#1_1	CLEAR_NPC,{
+	mes "There are valve manual sheets littered on the floor.";
+	next;
+	if (getpartyleader(getcharid(1),2) == getcharid(0)) {
+		mes "You the party leader, started to read the manual.";
+		next;
+		mes "[Emergency Access Valve Manual]";
+		switch(lght_duk02) {
+		case 0:
+			switch(rand(1,6)) {
+			case 1:
+				lght_duk02 = 1;
+				mes "Turn the left valve Clockwise twice, Counterclockwise once, Clockwise once";
+				break;
+			case 2:
+				lght_duk02 = 2;
+				mes "Turn the left valve Clockwise once, Counterclockwise twice, Clockwise once";
+				break;
+			case 3:
+				lght_duk02 = 3;
+				mes "Turn the left valve Clockwise once, Counterclockwise once, Clockwise twice";
+				break;
+			case 4:
+				lght_duk02 = 4;
+				mes "Turn the right valve Counterclockwise twice, Clockwise once, Counterclockwise once";
+				break;
+			case 5:
+				lght_duk02 = 5;
+				mes "Turn the right valve Counterclockwise once, Clockwise twice, Counterclockwise once";
+				break;
+			case 6:
+				lght_duk02 = 6;
+				mes "Turn the right valve Counterclockwise once, Clockwise once, Counterclockwise twice";
+				break;
+			default:
+				mes "This is a unknown Error. If you get the same problem after trying one more time, contact GM.";
+				break;
+			}
+			break;
+		case 1:
+			mes "Turn the left valve Clockwise twice, Counterclockwise once, Clockwise once";
+			break;
+		case 2:
+			mes "Turn the left valve Clockwise once, Counterclockwise twice, Clockwise once";
+			break;
+		case 3:
+			mes "Turn the left valve Clockwise once, Counterclockwise once, Clockwise twice";
+			break;
+		case 4:
+			mes "Turn the right valve Counterclockwise twice, Clockwise once, Counterclockwise once";
+			break;
+		case 5:
+			mes "Turn the right valve Counterclockwise once, Clockwise twice, Counterclockwise once";
+			break;
+		case 6:
+			mes "Turn the right valve Counterclockwise once, Clockwise once, Counterclockwise twice";
+			break;
+		default:
+			mes "This is an unknown error. If you get the same problem after trying one more time, contact a GM.";
+			break;
+		}
+	} else {
+		mes "Let your party leader handle the valve.";
+	}
+	close;
+
+OnInstanceInit:
+	disablenpc instance_npcname("Manual Sheet#1_1");
+	end;
+
+OnEnable:
+	specialeffect EF_LIGHTSPHERE;
+	enablenpc instance_npcname("Manual Sheet#1_1");
+	end; 
+}
+
+// Left Valve
+//============================================================
+1@lhz,41,172,0	script	Valve#1_2	CLEAR_NPC,{
+	.@open_portal = 0;
+	mes "This is the left valve for the emergency access.";
+	if (getpartyleader(getcharid(1),2) == getcharid(0)) {
+		next;
+		mes "To which direction do you wish to turn?";
+		next;
+		if (lght_duk02 < 1 || lght_duk02 > 3) {
+			for(.@i = 1; .@i <= 4; .@i++) {
+				select("Clockwise", "Counterclockwise");
+				mes "-A metal sound-";
+				if (.@i != 4)
+					mes "and, to which direction then?";
+				next;
+			}
+		} else {
+			// lght_duk02 == 1 : Clockwise, Clockwise, Counterclockwise, Clockwise
+			// lght_duk02 == 2 : Clockwise, Counterclockwise, Counterclockwise, Clockwise
+			// lght_duk02 == 3 : Clockwise, Counterclockwise, Clockwise, Clockwise
+			for(.@i = 1; .@i <= 4; .@i++) {
+				switch(select("Clockwise", "Counterclockwise")) {
+				case 1:
+					if ((.@i == 1 || .@i == 4) || (.@i == 2 && lght_duk02 == 1) || (.@i == 3 && lght_duk02 == 3)) {
+						.@open_portal += 1;
+					}
+				case 2:
+					if ((.@i == 2 && lght_duk02 != 1) || (.@i == 3 && lght_duk02 != 3)) {
+						.@open_portal += 1;
+					}
+				}
+				mes "-A metal sound-";
+				if (.@i != 4)
+					mes "and, to which direction then?";
+				next;
+			}
+		}
+		if (.@open_portal == 4) {
+			donpcevent instance_npcname("#potal_01")+"::OnEnable";
+			lght_duk02 = 0;
+			mes "-Door opened-";
+			next;
+			mes "The door which connects to the Lab No.2 is now open.";
+		} else {
+			lght_duk02 = 0;
+			mes "Nothing happened.";
+			next;
+			mes "You need to review the manual.";
+		}
+	}
+	close;
+
+OnInstanceInit:
+	disablenpc instance_npcname("Valve#1_2");
+	end;
+
+OnEnable:
+	specialeffect EF_LIGHTSPHERE;
+	enablenpc instance_npcname("Valve#1_2");
+	end;
+}
+
+// Right Valve
+//============================================================
+1@lhz,52,172,0	script	Valve#1_3	CLEAR_NPC,{
+	.@open_portal = 0;
+	mes "This is the left valve for the emergency access.";
+	if (getpartyleader(getcharid(1),2) == getcharid(0)) {
+		next;
+		mes "To which direction do you wish to turn?";
+		next;
+		if (lght_duk02 < 4 || lght_duk02 > 6) {
+			for(.@i = 1; .@i <= 4; .@i++) {
+				select("Clockwise", "Counterclockwise");
+				mes "-A metal sound-";
+				if (.@i != 4)
+					mes "and, to which direction then?";
+				next;
+			}
+		} else {
+			// lght_duk02 == 4 : Counterclockwise, Counterclockwise, Clockwise, Counterclockwise
+			// lght_duk02 == 5 : Counterclockwise, Clockwise, Clockwise, Counterclockwise
+			// lght_duk02 == 6 : Counterclockwise, Clockwise, Counterclockwise, Counterclockwise
+			for(.@i = 1; .@i <= 4; .@i++) {
+				switch(select("Clockwise", "Counterclockwise")) {
+				case 1:
+					if ((.@i == 2 && lght_duk02 != 4) || (.@i == 3 && lght_duk02 != 6))
+						.@open_portal += 1;
+					break;
+				case 2:
+					if ((.@i == 1 || .@i == 4) || (.@i == 2 && lght_duk02 == 4) || (.@i == 3 && lght_duk02 == 6))
+						.@open_portal += 1;
+					break;
+				}
+				mes "-A metal sound-";
+				if (.@i != 4)
+					mes "and, to which direction then?";
+				next;
+			}
+		}
+		if (.@open_portal == 4) {
+			donpcevent instance_npcname("#potal_01")+"::OnEnable";
+			lght_duk02 = 0;
+			mes "-Door opened-";
+			next;
+			mes "The door which connects to the Lab No.2 is now open.";
+		} else {
+			lght_duk02 = 0;
+			mes "Nothing happened.";
+			next;
+			mes "You need to review the manual.";
+		}
+	}
+	close;
+
+OnInstanceInit:
+	disablenpc instance_npcname("Valve#1_3");
+	end;
+
+OnEnable:
+	specialeffect EF_LIGHTSPHERE;
+	enablenpc instance_npcname("Valve#1_3");
+	end;
+}
+
+
+// The Lab No.1 >> The Lab No.2 Warp portal
+//============================================================
+1@lhz,45,173,0	script	#potal_01	WARPNPC,2,2,{
+	end;
+
+OnInstanceInit:
+OnDisable:
+	disablenpc instance_npcname("#potal_01");
+	end;
+
+OnEnable:
+	mapannounce instance_mapname("1@lhz"),"[Management System] The door which connects to the Lab No.2 is now open.",bc_map,"0xff9977";
+	enablenpc instance_npcname("#potal_01");
+	end;
+
+OnTouch:
+	warp instance_mapname("1@lhz"), 151, 29;
+	end;
+}
+
+// The Lab No.2
+//============================================================
+1@lhz,151,29,0	script	#2_0	-1,1,1,{
+	end;
+
+OnEnable:
+	enablenpc instance_npcname("#2_0");
+	end;
+
+OnDisable:
+	disablenpc instance_npcname("#2_0");
+	end;
+
+OnTouch:
+	donpcevent instance_npcname("Lab2#2_1")+"::OnEnable";
+	donpcevent instance_npcname("#2_0")+"::OnDisable";
+	end;
+}
+
+// The Lab No.2 2_1 System - Control of Monster Wave and Pipe right before exploding
+//============================================================
+1@lhz,35,106,4	script	Lab2#2_1	CLEAR_NPC,{
+	end;
+
+OnInstanceInit:
+OnDisable:
+	stopnpctimer;
+	end;
+
+OnEnable:
+	initnpctimer;
+	end;
+
+OnTimer1000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] This is a warning notice! Warning notice! Intruder Detected in The Lab No.2!!",bc_map,"0xff9977";
+	end;
+
+OnTimer3000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] In 5 seconds, The Lab No.2 Security system will start working.",bc_map,"0xff9977";
+	end;
+
+OnTimer5000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] Warning! The pipe pressure in the Lab No.2 is too high.",bc_map,"0xff99ff";
+	end;
+
+OnTimer8000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] First security system activated !! The persons concerned have to evacuate.",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl2#mob02")+"::On01";
+	end;
+
+OnTimer10000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] Warning! The pipe pressure is too high. Open the valve.",bc_map,"0xff99ff";
+	donpcevent instance_npcname("Lab2#2_2")+"::OnPipePressure";
+	end;
+
+OnTimer190000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] Warning! The pipe pressure is too high. Open the valve.",bc_map,"0xff99ff";
+	donpcevent instance_npcname("Lab2#2_2")+"::OnPipePressure";
+	end;
+
+OnTimer303000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] In 5 seconds, Second Security system will start working.",bc_map,"0xff9977";
+	end;
+
+OnTimer308000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] Second security system activated !! The persons concerned have to evacuate.",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl2#mob02")+"::On02";
+	end;
+
+OnTimer370000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] Warning! The pipe pressure is too high. Open the valve.",bc_map,"0xff99ff";
+	donpcevent instance_npcname("Lab2#2_2")+"::OnPipePressure";
+	end;
+
+OnTimer550000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] Warning! The pipe pressure is too high. Open the valve.",bc_map,"0xff99ff";
+	donpcevent instance_npcname("Lab2#2_2")+"::OnPipePressure";
+	end;
+
+OnTimer603000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] In 5 seconds, Third Security system will start working.",bc_map,"0xff9977";
+	end;
+
+OnTimer608000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] Third security system activated !! The persons concerned have to evacuate.",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl2#mob02")+"::On03";
+	end;
+
+OnTimer730000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] Warning! The pipe pressure is too high. Open the valve.",bc_map,"0xff99ff";
+	donpcevent instance_npcname("Lab2#2_2")+"::OnPipePressure";
+	end;
+
+OnTimer903000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] In 5 seconds, Fourth Security system will start working.",bc_map,"0xff9977";
+	end;
+
+OnTimer908000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] Fourth security system activated !! The persons concerned have to evacuate.",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl2#mob02")+"::On04";
+	end;
+
+OnTimer910000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] Warning! The pipe pressure is too high. Open the valve.",bc_map,"0xff99ff";
+	donpcevent instance_npcname("Lab2#2_2")+"::OnPipePressure";
+	end;
+
+OnTimer1090000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] Warning! The pipe pressure is too high. Open the valve.",bc_map,"0xff99ff";
+	donpcevent instance_npcname("Lab2#2_2")+"::OnPipePressure";
+	end;
+
+OnTimer1203000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] In 5 seconds, Fifth Security system will start working.",bc_map,"0xff9977";
+	end;
+
+OnTimer1208000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] Fifth security system activated !! The persons concerned have to evacuate.",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl2#mob02")+"::On05";
+	end;
+
+OnTimer1270000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] Warning! The pipe pressure is too high. Open the valve.",bc_map,"0xff99ff";
+	donpcevent instance_npcname("Lab2#2_2")+"::OnPipePressure";
+	stopnpctimer;
+	end;
+}
+
+// The Lab No.2 2_2 System - Pipe Operation Control
+// When 3 pipes explode, system will shut down.
+//============================================================
+1@lhz,37,106,4	script	Lab2#2_2	CLEAR_NPC,{
+	end;
+
+OnInstanceInit:
+	'broken_pipes = 0;
+	stopnpctimer;
+	end;
+
+OnPipePressure:
+	switch(rand(1,6)) {
+	case 1:
+		donpcevent instance_npcname("Valve#2_1")+"::OnEnable";
+		donpcevent instance_npcname("MobCtrl2#mob02")+"::On2_01";
+	case 2:
+		donpcevent instance_npcname("Valve#2_2")+"::OnEnable";
+		donpcevent instance_npcname("MobCtrl2#mob02")+"::On2_02";
+	case 3:
+		donpcevent instance_npcname("Valve#2_3")+"::OnEnable";
+		donpcevent instance_npcname("MobCtrl2#mob02")+"::On2_03";
+	case 4:
+		donpcevent instance_npcname("Valve#2_4")+"::OnEnable";
+		donpcevent instance_npcname("MobCtrl2#mob02")+"::On2_04";
+	case 5:
+		donpcevent instance_npcname("Valve#2_5")+"::OnEnable";
+		donpcevent instance_npcname("MobCtrl2#mob02")+"::On2_05";
+	case 6:
+		donpcevent instance_npcname("Valve#2_6")+"::OnEnable";
+		donpcevent instance_npcname("MobCtrl2#mob02")+"::On2_06";
+	}
+	initnpctimer;
+	end;
+
+OnDisableValve1:
+	disablenpc instance_npcname("Valve#2_1");
+	stopnpctimer;
+	end;
+
+OnDisableValve2:
+	disablenpc instance_npcname("Valve#2_2");
+	stopnpctimer;
+	end;
+
+OnDisableValve3:
+	disablenpc instance_npcname("Valve#2_3");
+	stopnpctimer;
+	end;
+
+OnDisableValve4:
+	disablenpc instance_npcname("Valve#2_4");
+	stopnpctimer;
+	end;
+
+OnDisableValve5:
+	disablenpc instance_npcname("Valve#2_5");
+	stopnpctimer;
+	end;
+
+OnDisableValve6:
+	disablenpc instance_npcname("Valve#2_6");
+	stopnpctimer;
+	end;
+
+OnTimer63000:
+	for(.@i = 1; .@i < 7; .@i++) {
+		specialeffect EF_SUI_EXPLOSION, AREA, instance_npcname("Valve#2_"+.@i+"");
+		disablenpc instance_npcname("Valve#2_"+.@i+"");
+	}
+	'broken_pipes += 1;
+	if ('broken_pipes == 3) {
+		donpcevent instance_npcname("#2_3")+"::OnEnable";
+		stopnpctimer;
+	} else {
+		mapannounce instance_mapname("1@lhz"),"[Management System] Pipe explosion detected! When "+ (3 - 'broken_pipes) +" more break, the system will stop.",bc_map,"0xff99ff";
+	}
+	end;
+}
+
+// The Lab No.2 2_3 System
+//============================================================
+1@lhz,151,48,0	script	#2_3	-1,20,20,{
+	end;
+
+OnInstanceInit:
+	disablenpc instance_npcname("#2_3");
+	end;
+
+OnEnable:
+	initnpctimer;
+	end;
+
+OnTimer1000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] System Freezes! System Freezes! Evacuate from the Lab in 10 seconds.",bc_map,"0xff99ff";
+	end;
+
+OnTimer11000:
+	mapannounce instance_mapname("1@lhz"),"[Management System] Evacuate!!",bc_map,"0xff99ff";
+	enablenpc instance_npcname("#2_3");
+	end;
+
+OnTouch:
+	warp "lhz_dun04", 147, 273;
+	end;
+}
+
+// The Lab No.2 Monster Control
+//============================================================
+1@lhz,39,106,4	script	MobCtrl2#mob02	CLEAR_NPC,{
+	end;
+
+On01:
+	.@map$ = instance_mapname("1@lhz");
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster .@map$,139,37,164,58,"Starving Lab animal",2242,10,.@label$;
+	end;
+
+On02:
+	.@map$ = instance_mapname("1@lhz");
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster .@map$,139,37,164,58,"Starving Lab animal",2242,20,.@label$;
+	end;
+
+On03:
+	.@map$ = instance_mapname("1@lhz");
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster .@map$,139,37,164,58,"Starving Lab animal",2242,16,.@label$;
+	end;
+
+On04:
+	.@map$ = instance_mapname("1@lhz");
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster .@map$,139,37,164,58,"Starving Lab animal",2242,19,.@label$;
+	end;
+
+On05:
+	.@map$ = instance_mapname("1@lhz");
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster .@map$,139,37,164,58,"Starving Lab animal",2242,20,.@label$;
+	end;
+
+On2_01:
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster instance_mapname("1@lhz"),155,43,161,49,"Starving Lab animal",2243,5,.@label$;
+	end;
+
+On2_02:
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster instance_mapname("1@lhz"),137,40,143,46,"Starving Lab animal",2243,5,.@label$;
+	end;
+
+On2_03:
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster instance_mapname("1@lhz"),137,51,143,57,"Starving Lab animal",2243,5,.@label$;
+	end;
+
+On2_04:
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster instance_mapname("1@lhz"),143,56,149,62,"Starving Lab animal",2243,5,.@label$;
+	end;
+
+On2_05:
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster instance_mapname("1@lhz"),160,48,166,54,"Starving Lab animal",2243,5,.@label$;
+	end;
+
+On2_06:
+	.@label$ = instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	areamonster instance_mapname("1@lhz"),135,44,141,50,"Starving Lab animal",2243,5,.@label$;
+	end;
+
+OnDisable:
+	killmonster instance_mapname("1@lhz"),instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead";
+	end;
+
+OnMyMobDead:
+	if (mobcount(instance_mapname("1@lhz"),instance_npcname("MobCtrl2#mob02")+"::OnMyMobDead") < 1) {
+		donpcevent instance_npcname("#potal_02")+"::OnEnable";
+		donpcevent instance_npcname("Lab2#2_1")+"::OnDisable";
+		mapannounce instance_mapname("1@lhz"),"[Security System] The Security system of The Lab No.2 has been stopped.",bc_map,"0xff9977";
+	}
+	end;
+}
+
+// The Lab No.2 Valves
+//============================================================
+-	script	bio4FLab2Valve	-1,{
+	if (getpartyleader(getcharid(1),2) == getcharid(0)) {
+		progressbar "0xffff00", 20;
+		stopnpctimer;
+		donpcevent instance_npcname("Lab2#2_2")+"::OnDisableValve1";
+		disablenpc instance_npcname(strnpcinfo(0));
+		end;
+	} else {
+		mes "Let your party leader handle the valve.";
+		close;
+	}
+
+OnInstanceInit:
+	disablenpc instance_npcname(strnpcinfo(0));
+	end;
+
+OnEnable:
+	enablenpc instance_npcname(strnpcinfo(0));
+	initnpctimer;
+	end;
+
+OnTimer3000:
+	specialeffect EF_DRAGONSMOKE,AREA,instance_npcname(strnpcinfo(0));
+	stopnpctimer;
+	initnpctimer;
+	end;
+}
+1@lhz,158,46,0	duplicate(bio4FLab2Valve)	Valve#2_1	CLEAR_NPC
+1@lhz,138,43,0	duplicate(bio4FLab2Valve)	Valve#2_2	CLEAR_NPC
+1@lhz,139,54,0	duplicate(bio4FLab2Valve)	Valve#2_3	CLEAR_NPC
+1@lhz,145,60,0	duplicate(bio4FLab2Valve)	Valve#2_4	CLEAR_NPC
+1@lhz,165,51,0	duplicate(bio4FLab2Valve)	Valve#2_5	CLEAR_NPC
+1@lhz,137,47,0	duplicate(bio4FLab2Valve)	Valve#2_6	CLEAR_NPC
+
+// The Lab No.2 >> The Lab No.3 Warp portal(General)
+//============================================================
+1@lhz,151,64,0	script	#potal_02	WARPNPC,2,2,{
+	end;
+
+OnInstanceInit:
+OnDisable:
+	disablenpc instance_npcname("#potal_02");
+	end;
+
+OnEnable:
+	mapannounce instance_mapname("1@lhz"),"[Management System] The door which connects to the Lab No.3 is now open.",bc_map,"0xff99ff";
+	enablenpc instance_npcname("#potal_02");
+	end;
+
+OnTouch:
+	warp instance_mapname("1@lhz"), 84, 28;
+	end;
+}
+
+// The Lab No.3
+//============================================================
+1@lhz,84,28,0	script	#3_0	-1,1,1,{
+	end;
+
+OnEnable:
+	enablenpc instance_npcname("#3_0");
+	end;
+
+OnDisable:
+	disablenpc instance_npcname("#3_0");
+	end;
+
+OnTouch:
+	donpcevent instance_npcname("Lab3#3_1")+"::OnEnable";
+	donpcevent instance_npcname("#3_0")+"::OnDisable";
+	end;
+}
+
+// The Lab No.3 3_1 System - Monster wave control
+//============================================================
+1@lhz,35,104,4	script	Lab3#3_1	CLEAR_NPC,{
+	end;
+
+OnEnable:
+	initnpctimer;
+	end;
+
+OnDisable:
+	stopnpctimer;
+	end;
+
+OnTimer1000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] This is a warning notice! Warning notice!",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl3#mob03")+"::OnDisable";
+	end;
+
+OnTimer5000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] Intruder Detected in The Lab No.3!!",bc_map,"0xff9977";
+	end;
+
+OnTimer7000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] In 5 seconds, The Security system of The Lab No.3 will start working.",bc_map,"0xff9977";
+	end;
+
+OnTimer12000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] First security system of The Lab No.3 activated !! The persons concerned have to evacuate.",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl3#mob03")+"::On01";
+	end;
+
+OnTimer192000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] Second security system of The Lab No.3 activated !! The persons concerned have to evacuate.",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl3#mob03")+"::On02";
+	end;
+
+OnTimer372000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] Third security system of The Lab No.3 activated !! The persons concerned have to evacuate.",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl3#mob03")+"::On03";
+	end;
+
+OnTimer552000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] Fourth security system of The Lab No.3activated !! The persons concerned have to evacuate.",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl3#mob03")+"::On04";
+	end;
+
+OnTimer732000:
+	mapannounce instance_mapname("1@lhz"),"[Security System] Fifth security system of The Lab No.3 activated !! The persons concerned have to evacuate.",bc_map,"0xff9977";
+	donpcevent instance_npcname("MobCtrl3#mob03")+"::On05";
+	stopnpctimer;
+	end;
+}
+
+// The Lab No.3 Monster Control
+//============================================================
+1@lhz,37,104,4	script	MobCtrl3#mob03	CLEAR_NPC,{
+	end;
+
+On01:
+	.@map$ = instance_mapname("1@lhz");
+	.@label$ = instance_npcname("MobCtrl3#mob03")+"::OnMyMobDead";
+	monster .@map$,80,60,"Starving Lab animal",2242,1,.@label$;
+	monster .@map$,81,58,"Starving Lab animal",2242,1,.@label$;
+	monster .@map$,82,56,"Starving Lab animal",2242,1,.@label$;
+	monster .@map$,84,60,"Starving Lab animal",2242,1,.@label$;
+	monster .@map$,85,58,"Starving Lab animal",2242,1,.@label$;
+	monster .@map$,82,60,"Starving Lab animal",2243,1,.@label$;
+	monster .@map$,83,58,"Starving Lab animal",2243,1,.@label$;
+	monster .@map$,85,56,"Starving Lab animal",2243,1,.@label$;		
+	monster .@map$,86,60,"Starving Lab animal",2243,1,.@label$;
+	monster .@map$,87,58,"Starving Lab animal",2243,1,.@label$;
+	end;
+
+On02:
+	.@map$ = instance_mapname("1@lhz");
+	.@amount1 = rand(1,5);
+	.@amount2 = rand(1,5);
+	.@label$ = instance_npcname("MobCtrl3#mob03")+"::OnMyMobDead";
+	monster .@map$,80,60,"Starving Lab animal",2242,.@amount1,.@label$;
+	monster .@map$,82,60,"Starving Lab animal",2242,.@amount2,.@label$;
+	monster .@map$,84,60,"Starving Lab animal",2243,.@amount1,.@label$;
+	monster .@map$,86,60,"Starving Lab animal",2242,.@amount2,.@label$;
+	monster .@map$,81,58,"Starving Lab animal",2242,.@amount1,.@label$;
+	monster .@map$,83,58,"Starving Lab animal",2243,.@amount2,.@label$;
+	monster .@map$,85,58,"Starving Lab animal",2242,.@amount1,.@label$;
+	monster .@map$,87,58,"Starving Lab animal",2242,.@amount2,.@label$;
+	monster .@map$,82,56,"Starving Lab animal",2243,.@amount1,.@label$;
+	monster .@map$,85,56,"Starving Lab animal",2242,.@amount2,.@label$;
+	end;
+
+On03:
+	.@map$ = instance_mapname("1@lhz");
+	.@amount1 = rand(1,5);
+	.@amount2 = rand(1,5);
+	.@amount3 = rand(1,5);
+	.@label$ = instance_npcname("MobCtrl3#mob03")+"::OnMyMobDead";
+	monster .@map$,80,60,"Starving Lab animal",2242,.@amount1,.@label$;
+	monster .@map$,82,60,"Starving Lab animal",2242,.@amount2,.@label$;
+	monster .@map$,84,60,"Starving Lab animal",2242,.@amount3,.@label$;
+	monster .@map$,86,60,"Starving Lab animal",2243,.@amount1,.@label$;
+	monster .@map$,81,58,"Starving Lab animal",2242,.@amount2,.@label$;
+	monster .@map$,83,58,"Starving Lab animal",2242,.@amount3,.@label$;
+	monster .@map$,85,58,"Starving Lab animal",2242,.@amount1,.@label$;
+	monster .@map$,87,58,"Starving Lab animal",2243,.@amount2,.@label$;
+	monster .@map$,82,56,"Starving Lab animal",2242,.@amount3,.@label$;
+	monster .@map$,85,56,"Starving Lab animal",2242,.@amount1,.@label$;
+	end;
+
+On04:
+	.@map$ = instance_mapname("1@lhz");
+	.@amount1 = rand(1,5);
+	.@amount2 = rand(1,5);
+	.@amount3 = rand(1,5);
+	.@amount4 = rand(1,5);
+	.@label$ = instance_npcname("MobCtrl3#mob03")+"::OnMyMobDead";
+	monster .@map$,80,60,"Starving Lab animal",2242,.@amount1,.@label$;
+	monster .@map$,82,60,"Starving Lab animal",2242,.@amount2,.@label$;
+	monster .@map$,84,60,"Starving Lab animal",2242,.@amount3,.@label$;
+	monster .@map$,86,60,"Starving Lab animal",2242,.@amount4,.@label$;
+	monster .@map$,81,58,"Starving Lab animal",2243,.@amount1,.@label$;
+	monster .@map$,83,58,"Starving Lab animal",2242,.@amount2,.@label$;
+	monster .@map$,85,58,"Starving Lab animal",2242,.@amount3,.@label$;
+	monster .@map$,87,58,"Starving Lab animal",2242,.@amount4,.@label$;
+	monster .@map$,82,56,"Starving Lab animal",2243,.@amount1,.@label$;
+	monster .@map$,85,56,"Starving Lab animal",2242,.@amount2,.@label$;
+	end;
+
+On05:
+	.@map$ = instance_mapname("1@lhz");
+	.@amount1 = rand(1,5);
+	.@amount2 = rand(1,5);
+	.@amount3 = rand(1,5);
+	.@amount4 = rand(1,5);
+	.@amount5 = rand(1,5);
+	.@label$ = instance_npcname("MobCtrl3#mob03")+"::OnMyMobDead";
+	monster .@map$,80,60,"Starving Lab animal",2243,.@amount1,.@label$;
+	monster .@map$,82,60,"Starving Lab animal",2242,.@amount2,.@label$;
+	monster .@map$,84,60,"Starving Lab animal",2242,.@amount3,.@label$;
+	monster .@map$,86,60,"Starving Lab animal",2243,.@amount4,.@label$;
+	monster .@map$,81,58,"Starving Lab animal",2242,.@amount5,.@label$;
+	monster .@map$,83,58,"Starving Lab animal",2242,.@amount1,.@label$;
+	monster .@map$,85,58,"Starving Lab animal",2243,.@amount2,.@label$;
+	monster .@map$,87,58,"Starving Lab animal",2242,.@amount3,.@label$;
+	monster .@map$,82,56,"Starving Lab animal",2242,.@amount4,.@label$;
+	monster .@map$,85,56,"Starving Lab animal",2243,.@amount5,.@label$;
+	end;
+
+OnDisable:
+	killmonster instance_mapname("1@lhz"),instance_npcname("MobCtrl3#mob03")+"::OnMyMobDead";
+	end;
+
+OnMyMobDead:
+	if (mobcount(instance_mapname("1@lhz"),instance_npcname("MobCtrl3#mob03")+"::OnMyMobDead") < 1) {
+		donpcevent instance_npcname("#potal_03")+"::OnEnable";
+		donpcevent instance_npcname("Lab3#3_1")+"::OnDisable";
+		mapannounce instance_mapname("1@lhz"),"[Security System] The Security system of The Lab No.3 has been stopped.",bc_map,"0xff9977";
+	}
+	end;
+}
+
+// The Lab No.3 >> Boss's Room Warp portal
+//============================================================
+1@lhz,83,62,0	script	#potal_03	WARPNPC,2,2,{
+	end;
+
+OnInstanceInit:
+	disablenpc instance_npcname("#potal_03");
+	end;
+
+OnEnable:
+	mapannounce instance_mapname("1@lhz"),"[Management System] The door which connects to the Lab No.4 is now open.",bc_map,"0x7799ff";
+	enablenpc instance_npcname("#potal_03");
+	end;
+
+OnDisable:
+	disablenpc instance_npcname("#potal_03");
+	end;
+
+OnTouch:
+	warp instance_mapname("1@lhz"), 137, 100;
+	end;
+}
+
+// The Lab No.4
+//============================================================
+1@lhz,137,100,0	script	#4_0	-1,1,1,{
+	end;
+
+OnEnable:
+	enablenpc instance_npcname("#4_0");
+	end;
+
+OnDisable:
+	disablenpc instance_npcname("#4_0");
+	end;
+
+OnTouch:
+	donpcevent instance_npcname("Lab4#4_1")+"::OnEnable";
+	donpcevent instance_npcname("#4_0")+"::OnDisable";
+	end;
+}
+
+// The Lab No.4 4_1 System - Summon of Boss Monster
+//============================================================
+1@lhz,35,102,4	script	Lab4#4_1	CLEAR_NPC,{
+	end;
+
+OnEnable:
+	initnpctimer;
+	end;
+
+OnDisable:
+	stopnpctimer;
+	end;
+
+OnTimer1000:
+	mapannounce instance_mapname("1@lhz"),"Whisper: Who are you....",bc_map,"0x7DCBF0";
+	specialeffect EF_SPHERE,AREA,instance_npcname("Seyren Windsor#boss01");
+	end;
+
+OnTimer2000:
+	specialeffect EF_SPHERE,AREA,instance_npcname("Cecile Damon#boss02");
+	end;
+
+OnTimer3000:
+	mapannounce instance_mapname("1@lhz"),"Whisper: Do not approach more...",bc_map,"0x7DCBF0";
+	specialeffect EF_SPHERE,AREA,instance_npcname("Gertie Wie#boss03");
+	end;
+
+OnTimer4000:
+	specialeffect EF_SPHERE,AREA,instance_npcname("Eremes Guile#boss04");
+	end;
+
+OnTimer5000:
+	mapannounce instance_mapname("1@lhz"),"Whisper: This is a very dangerous place..",bc_map,"0x7DCBF0";
+	specialeffect EF_SPHERE,AREA,instance_npcname("Trentini#boss05");
+	end;
+
+OnTimer6000:
+	specialeffect EF_SPHERE,AREA,instance_npcname("Chen Liu#boss06");
+	end;
+
+OnTimer7000:
+	mapannounce instance_mapname("1@lhz"),"Whisper: You won't go out alive....",bc_map,"0x7DCBF0";
+	specialeffect EF_SPHERE,AREA,instance_npcname("Alphochio Basil#boss07");
+	end;
+
+OnTimer8000:
+	specialeffect EF_SPHERE,AREA,instance_npcname("Flamel Emul#boss08");
+	end;
+
+OnTimer9000:
+	mapannounce instance_mapname("1@lhz"),"Whisper: If you don't want to be a part of us....",bc_map,"0x7DCBF0";
+	specialeffect EF_SPHERE,AREA,instance_npcname("Randel Lawrence#boss09");
+	end;
+
+OnTimer10000:
+	specialeffect EF_SPHERE,AREA,instance_npcname("Celia Alde#boss10");
+	end;
+
+OnTimer11000:
+	mapannounce instance_mapname("1@lhz"),"Whisper: Leave now....",bc_map,"0x7DCBF0";
+	specialeffect EF_SPHERE,AREA,instance_npcname("Kathryne Keyron#boss11");
+	end;
+
+OnTimer12000:
+	specialeffect EF_SPHERE,AREA,instance_npcname("Margaretha Sorin#boss12");
+	end;
+
+OnTimer13000:
+	mapannounce instance_mapname("1@lhz"),"Whisper: Before this place is thoroughly filled with sorrow and pain....",bc_map,"0x7DCBF0";
+	specialeffect EF_SPHERE,AREA,instance_npcname("Howard Alt-Eisen#boss13");
+	end;
+
+OnTimer14000:
+	specialeffect EF_SPHERE,AREA,instance_npcname("Type_**Gren#boss14");
+	end;
+
+OnTimer15000:
+	specialeffect EF_SPHERE,AREA,instance_npcname("Type_**Roke#boss15");
+	end;
+
+OnTimer16000:
+	specialeffect EF_SPHERE,AREA,instance_npcname("Type_**Dree#boss16");
+	end;
+
+OnTimer17000:
+	mapannounce instance_mapname("1@lhz"),"Whisper: Ah....it....it's too late......",bc_map,"0x7DCBF0";
+	donpcevent instance_npcname("MobCtrl4#mob04")+"::OnEnable";
+	stopnpctimer;
+	end;
+}
+
+// Area No. 4 - Boss Summon Control
+//============================================================
+1@lhz,37,102,4	script	MobCtrl4#mob04	CLEAR_NPC,{
+	end;
+
+OnEnable:
+	switch(rand(1,13)) {
+	case 1:
+		donpcevent instance_npcname("Seyren Windsor#boss01")+"::OnEnable";
+		end;
+	case 2:
+		donpcevent instance_npcname("Cecile Damon#boss02")+"::OnEnable";
+		end;
+	case 3:
+		donpcevent instance_npcname("Gertie Wie#boss03")+"::OnEnable";
+		end;
+	case 4:
+		donpcevent instance_npcname("Eremes Guile#boss04")+"::OnEnable";
+		end;
+	case 5:
+		donpcevent instance_npcname("Trentini#boss05")+"::OnEnable";
+		end;
+	case 6:
+		donpcevent instance_npcname("Chen Liu#boss06")+"::OnEnable";
+		end;
+	case 7:
+		donpcevent instance_npcname("Alphochio Basil#boss07")+"::OnEnable";
+		end;
+	case 8:
+		donpcevent instance_npcname("Flamel Emul#boss08")+"::OnEnable";
+		end;
+	case 9:
+		donpcevent instance_npcname("Randel Lawrence#boss09")+"::OnEnable";
+		end;
+	case 10:
+		donpcevent instance_npcname("Celia Alde#boss10")+"::OnEnable";
+		end;
+	case 11:
+		donpcevent instance_npcname("Kathryne Keyron#boss11")+"::OnEnable";
+		end;
+	case 12:
+		donpcevent instance_npcname("Margaretha Sorin#boss12")+"::OnEnable";
+		end;
+	case 13:
+		donpcevent instance_npcname("Howard Alt-Eisen#boss13")+"::OnEnable";
+		end; 
+	}
+
+OnDisable:
+	//stopnpctimer;
+	end;
+}
+
+// Random Experiments in Tubes
+//============================================================
+1@lhz,156,148,3	script	Type_**Gren#boss14	4_M_03,{ end; }
+1@lhz,152,152,3	script	Type_**Roke#boss15	4_M_HUMAN_01,{ end; }
+1@lhz,148,156,3	script	Type_**Dree#boss16	4_M_DWARF,{ end; }
+
+// Bosses
+//============================================================
+-	script	bio4FBoss	-1,{
+	end;
+
+OnEnable:
+	.@map$ = instance_mapname("1@lhz");
+	.@label$ = instance_npcname(strnpcinfo(0))+"::OnMyMobDead";
+	specialeffect EF_SUI_EXPLOSION;
+
+	if (strnpcinfo(0) == "Seyren Windsor#boss01")
+		monster .@map$,129,154,"Load Knight Seyren",1646,1,.@label$;
+	else if (strnpcinfo(0) == "Cecile Damon#boss02")
+		monster .@map$,125,150,"Sniper Cecile",1650,1,.@label$;
+	else if (strnpcinfo(0) == "Gertie Wie#boss03")
+		monster .@map$,121,146,"Stalker Gertie",2239,1,.@label$;
+	else if (strnpcinfo(0) == "Eremes Guile#boss04")
+		monster .@map$,117,142,"Assassin Cross Eremes",1647,1,.@label$;
+	else if (strnpcinfo(0) == "Trentini#boss05")
+		monster .@map$,117,125,"Gypsy Trentini",2241,1,.@label$;
+	else if (strnpcinfo(0) == "Chen Liu#boss06")
+		monster .@map$,121,121,"Champion Chen",2238,1,.@label$;
+	else if (strnpcinfo(0) == "Alphochio Basil#boss07")
+		monster .@map$,125,117,"Crown Alphochio",2240,1,.@label$;
+	else if (strnpcinfo(0) == "Flamel Emul#boss08")
+		monster .@map$,129,113,"Creator Flamel",2236,1,.@label$;
+	else if (strnpcinfo(0) == "Randel Lawrence#boss09")
+		monster .@map$,146,113,"Paladin Randel",2235,1,.@label$;
+	else if (strnpcinfo(0) == "Celia Alde#boss10")
+		monster .@map$,150,117,"Professor Celia",2237,1,.@label$;
+	else if (strnpcinfo(0) == "Kathryne Keyron#boss11")
+		monster .@map$,154,121,"High Wizard Kathryne",1651,1,.@label$;
+	else if (strnpcinfo(0) == "Margaretha Sorin#boss12")
+		monster .@map$,158,125,"High Priest Margaretha",1649,1,.@label$;
+	else if (strnpcinfo(0) == "Howard Alt-Eisen#boss13")
+		monster .@map$,158,142,"White Smith Howard",1648,1,.@label$;
+
+	end;
+
+OnDisable:
+	killmonster instance_mapname("1@lhz"),instance_npcname(strnpcinfo(0))+"::OnMyMobDead";
+	disablenpc instance_npcname(strnpcinfo(0));
+	end;
+
+OnMyMobDead:
+	if (mobcount(instance_mapname("1@lhz"), instance_npcname(strnpcinfo(0))+"::OnMyMobDead") < 1) {
+		.@map$ = instance_mapname("1@lhz");
+
+		if (strnpcinfo(0) == "Seyren Windsor#boss01")
+			mapannounce .@map$,"Awww... Where are all my fellows....",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Cecile Damon#boss02")
+			mapannounce .@map$,"Any..one, please help.. please.....",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Gertie Wie#boss03")
+			mapannounce .@map$,".. did I act too.. rashly...?",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Eremes Guile#boss04")
+			mapannounce .@map$,"Ah..... I am absolutely defeated....",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Trentini#boss05")
+			mapannounce .@map$,"ah.. If I.. ever can ... dance and.... sing...happily....",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Chen Liu#boss06")
+			mapannounce .@map$,"I.... am so .. sorry....",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Alphochio Basil#boss07")
+			mapannounce .@map$,"...the new song......was ....for.....her....",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Flamel Emul#boss08")
+			mapannounce .@map$,"Ha...I wanted to show.... the new potion....",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Randel Lawrence#boss09")
+			mapannounce .@map$,"Wooooo.. everyone got defeated.....??",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Celia Alde#boss10")
+			mapannounce .@map$,"No..... this experiment is.....dang...",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Kathryne Keyron#boss11")
+			mapannounce .@map$,"awww.. is everyone Ok....?",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Margaretha Sorin#boss12")
+			mapannounce .@map$,"My good boy.. Don't cry... ah.... our Great Odin.. please save us...",bc_map,"0xFD3B02";
+		else if (strnpcinfo(0) == "Howard Alt-Eisen#boss13")
+			mapannounce .@map$,"oh...no.... can't breath.... and my sister...?? sister!!",bc_map,"0xFD3B02";
+
+		donpcevent instance_npcname("Wolfchev#last")+"::OnEnable";
+		donpcevent instance_npcname(strnpcinfo(0))+"::OnDisable";
+	}
+	end;
+}
+1@lhz,127,156,5	duplicate(bio4FBoss)	Seyren Windsor#boss01	1646
+1@lhz,123,152,5	duplicate(bio4FBoss)	Cecile Damon#boss02	1650
+1@lhz,119,148,5	duplicate(bio4FBoss)	Gertie Wie#boss03	2239
+1@lhz,115,144,5	duplicate(bio4FBoss)	Eremes Guile#boss04	1647
+1@lhz,115,123,7	duplicate(bio4FBoss)	Trentini#boss05	2241
+1@lhz,119,119,7	duplicate(bio4FBoss)	Chen Liu#boss06	2238
+1@lhz,123,115,7	duplicate(bio4FBoss)	Alphochio Basil#boss07	2240
+1@lhz,127,111,7	duplicate(bio4FBoss)	Flamel Emul#boss08	2236
+1@lhz,148,111,1	duplicate(bio4FBoss)	Randel Lawrence#boss09	2235
+1@lhz,152,115,1	duplicate(bio4FBoss)	Celia Alde#boss10	2237
+1@lhz,156,119,1	duplicate(bio4FBoss)	Kathryne Keyron#boss11	1651
+1@lhz,160,123,1	duplicate(bio4FBoss)	Margaretha Sorin#boss12	1649
+1@lhz,160,144,3	duplicate(bio4FBoss)	Howard Alt-Eisen#boss13	1648
+
+// Wolfchev - Final encounter
+//============================================================
+1@lhz,137,156,7	script	Wolfchev#last	4_LGTSCIENCE,{
+	if ((MaxWeight - Weight) < 1000 || !checkweight(1201, 1)) {
+		mes "^FF0000 Check up your inventory. You got too many items to carry out the quest. ^000000";
+		close;
+	}
+	.@all_quests_complete = true;
+	for(.@i = 5113; .@i <= 5125; .@i++) {
+		if (checkquest(.@i, HUNTING) != 2)
+			.@all_quests_complete = false;
+	}
+	if (.@all_quests_complete) {
+		// Quests Complete. Get Rewards.
+		if (lght_duk01 == 8) {
+			// First time beating the instance.
+			mes "[Wolfchev]";
+			mes "You finally defeated my Boss creature.";
+			next;
+			mes "[Wolfchev]";
+			mes "Finally. is this the result?? For whom did I experiment? Did they cheat me?";
+			next;
+			mes "[Wolfchev]";
+			mes "The button was supposed to be pressed for an emergency case...but..";
+			next;
+			mes "[Wolfchev]";
+			mes "Hey... You and I met by a bad connection....";
+			next;
+			mes "[Wolfchev]";
+			mes "But...., you helped me... How could you do that?";
+			next;
+			mes "["+ strcharinfo(0) +"]";
+			mes "When I met you for the first time, you seemed mad but sad, even if you could commit those cruel and horrific experiments.";
+			next;
+			mes "["+ strcharinfo(0) +"]";
+			mes "But actually, you did that because you was lonely,.. you just concentrated on that for this reason, huh?";
+			next;
+			mes "[Wolfchev]";
+			mes "HAHAHAHA. Loneliness... you say?";
+			next;
+			mes "[Wolfchev]";
+			mes "It might be seen like that to you. But, it isn't. Loneliness is just a good and easy excuse of the losers.";
+			next;
+			mes "[Wolfchev]";
+			mes "I'm so happy doing experiments pursuing for a perfection, I never feel lonely.";
+			next;
+			mes "[Wolfchev]";
+			mes "Anyway, since I realized that Rekenber betrayed me, I cannot just let them do what they want.";
+			next;
+			mes "[Wolfchev]";
+			mes "For now, I will leave them alone, but I will make them cry and regret for trying to remove Wolfchev.";
+			next;
+			mes "["+ strcharinfo(0) +"]";
+			mes "... .... ... ....";
+			next;
+			lght_duk01 = 9;
+			callsub L_Reward;
+			mes "[Wolfchev]";
+			mes "aaaaaah, "+ strcharinfo(0) +" Thank you so much to remove my boys who had gone mad. Not a big gift but I wish you don't deny, I don't need this anymore.";
+			next;
+			mes "[Wolfchev]";
+			mes "And, if you can...hope you to come back often, especially with your friends. I want the place to be with human heart again so the sadness in here gets disappear.";
+			next;
+			mes "I looked at Wolfchev again before leaving his lab. and I could feel that he was not obsessed anymore..";
+			close2;
+			warp "lhz_dun04", 147, 273;
+			end;
+		} else {
+			mes "[Wolfchev]";
+			mes "You did defeat all of the Boss creatures. Thank you again.";
+			next;
+			callsub L_Reward;
+			mes "[Wolfchev]";
+			mes "I say again, "+ strcharinfo(0) +" Thank you so much to remove my boys who had gone mad. Not a big gift but I wish you don't deny, I don't need this anymore.";
+			next;
+			mes "[Wolfchev]";
+			mes "Khahaha, See you again. Do you want to get out of here now?";
+			next;
+			if (select("Not yet", "Yes") == 1) {
+				mes "[Wolfchev]";
+				mes "Then tell me when you want to.";
+				close;
+			}
+			mes "[Wolfchev]";
+			mes "Then I will send you out.";
+			close2;
+			warp "lhz_dun04", 147, 273;
+			end;
+		}
+	} else {
+		if (!.@all_quests_complete) {
+			mes "[Wolfchev]";
+			mes "I was looking at the system.... don't know who made this..... but it's so complicated to get..no idea...";
+			next;
+		} else {
+			mes "[Wolfchev]";
+			mes "kakakaah.. Thank you. You handled those Boss creatures well...";
+			next;
+		}
+		if (lght_duk01 == 7) {
+			lght_duk01 = 8;
+			mes "[Wolfchev]";
+			mes "While you were struggling...";
+			next;
+			mes "[Wolfchev]";
+			mes "I figured something out... and there's a system error which doesn't let us come and go freely, so you could help me in 72 hours... Go somewhere to rest before you come back.";
+			next;
+			mes "[Wolfchev]";
+			mes "Ah... and I can send you out of my laboratory. Do you want?";
+			next;
+		} else {
+			mes "[Wolfchev]";
+			mes "Do you want to get out of here now?";
+			next;
+		}
+		if (select("Not yet", "Yes") == 1) {
+			mes "[Wolfchev]";
+			mes "Then tell me when you want to.";
+			close;
+		}
+		mes "[Wolfchev]";
+		mes "Then I will send you out.";
+		close2;
+		warp "lhz_dun04", 147, 273;
+		end;
+	}
+
+L_Reward:
+	for(.@i = 5113; .@i <= 5125; .@i++) {
+		erasequest .@i;
+	}
+	.@r = rand(1, 1000);
+	if      (.@r < 84)  getitem 2582,  1; //Salvage_Cape
+	else if (.@r < 167) getitem 18570, 1; //Ancient_Gold_Deco
+	else if (.@r < 250) getitem 1490,  1; //Giant_Lance
+	else if (.@r < 333) getitem 16017, 1; //Bloody_Cross
+	else if (.@r < 416) getitem 1291,  1; //Guillotine_Katar
+	else if (.@r < 499) getitem 1584,  1; //Chilly_Spell_Book
+	else if (.@r < 582) getitem 6471, 10; //Goast_Chill
+	else if (.@r < 665) getitem 6470, 10; //Blood_Thirst
+	else if (.@r < 748) getitem 6469, 10; //Will_Of_Warrior
+	else if (.@r < 831) getitem 6471, 20; //Goast_Chill
+	else if (.@r < 914) getitem 6470, 20; //Blood_Thirst
+	else                getitem 6469, 20; //Will_Of_Warrior
+	return;
+
+OnInstanceInit:
+OnDisable:
+	disablenpc instance_npcname("Wolfchev#last");
+	end;
+
+OnEnable:
+	enablenpc instance_npcname("Wolfchev#last");
+	end;
+}

+ 2 - 574
npc/re/quests/quests_lighthalzen.txt

@@ -3,7 +3,7 @@
 //===== By: ================================================== 
 //= Ziu, Heris (translation)
 //===== Current Version: ===================================== 
-//= 1.2
+//= 1.3
 //===== Compatible With: ===================================== 
 //= rAthena Project
 //===== Description: ========================================= 
@@ -12,6 +12,7 @@
 //= 1.0 Updated to match the new Izlude Map. [Masao]
 //= 1.1 Added Somatology Laboratory F4 quest. [Euphy]
 //= 1.2 Added Izlude duplicates. [Euphy]
+//= 1.3 Removed Somatology Laboratory F4 quest. [Euphy]
 //============================================================ 
 
 // Renewal split [Daegaladh]
@@ -21,576 +22,3 @@ izlude_a,172,73,6	duplicate(Scamp)	Scamp#iz_a	853
 izlude_b,172,73,6	duplicate(Scamp)	Scamp#iz_b	853
 izlude_c,172,73,6	duplicate(Scamp)	Scamp#iz_c	853
 izlude_d,172,73,6	duplicate(Scamp)	Scamp#iz_d	853
-
-// Somatology Laboratory F4
-//============================================================
-lighthalzen,303,304,5	script	Jerome Jameson#start	904,{
-	if (lhz_dun04 == 0) {
-		mes "[Jerome Jameson]";
-		mes "Wow, what a "+((Sex)?"strong man!":"beautiful dame!");
-		next;
-		mes "[Jerome Jameson]";
-		mes ((Sex)?"Sir":"Ma'am")+", please take heed -- as soon";
-		mes "as a dangerous rumor aroused about";
-		mes "the endangerment of everyone in";
-		mes "town, the best thing to do is lock";
-		mes "your doors.";
-		
-		// To do: check BaseLevel requirement.
-		if (BaseLevel < 90 || hg_tre < 54) close;
-
-		next;
-		select("Dangerous rumor?");
-		mes "[Jerome Jameson]";
-		mes "Strong rumors have been heard from";
-		mes "Rekenber Investigation Institute";
-		mes "about terrible, secret experiments";
-		mes "with human beings!";
-		next;
-		select("What? Experiments?");
-		mes "[Jerome Jameson]";
-		mes "Yes. Biological experiments!!";
-		mes "Experiments with human beings";
-		mes "conducted in the undergrounds of";
-		mes "these very slums. Apparently, they";
-		mes "have spread the rumors upon being";
-		mes "denied of social benefits.";
-		next;
-		mes "[Jerome Jameson]";
-		mes "This rumor cannot go about";
-		mes "unhandled. The biological";
-		mes "experiments that have been carried";
-		mes "out in this place can be real.";
-		mes "This really needs to be";
-		mes "investigated, and soon!";
-		setquest 5109;
-		set lhz_dun04,1;
-		close;
-	}
-	mes "[Jerome Jameson]";
-	mes "Please investigate the deeper";
-	mes "parts of the laboratory. I hope";
-	mes "to hear from you soon.";
-	close;
-}
-
-// Is this the correct behavior? (limited and conflicting sources)
-// - NPC in lhz_dun04 warps into que_lhz. (?)
-// - lhz_dun03 warps directly to que_lhz. (?)
-function	script	lhz4enter	{
-	if (getmapusers("que_lhz") == 0 && mobcount("que_lhz","#controllhz4::OnMyMobDead") < 1) {
-		if (getarg(0) == 0) {
-			mes "- Having Jerome Jameson's orders";
-			mes "in mind, you hold your breath and";
-			mes "descend the flooded flight of";
-			mes "stairs. -";
-		} else {
-			mes "[Researcher]";
-			mes "Who are you?";
-			mes "................";
-			emotion e_omg;
-			next;
-			mes "The man runs away and you go after him.";
-		}
-		if (lhz_dun04 > 1) {
-			changequest 5110,5109;
-			set lhz_dun04,1;
-		}
-		close2;
-		// Check twice because of 'next'.
-		if (getmapusers("que_lhz") == 0 && mobcount("que_lhz","#controllhz4::OnMyMobDead") < 1) {
-			donpcevent "#lhz4mes1::OnEnable";
-			warp "que_lhz",244,52;
-		}
-		end;
-	}
-	mes "Right now there are other people inside. Wait for your turn.";
-	close;
-}
-
-lhz_dun03,239,77,0	script	#warplhz3lhz4	45,1,1,{
-OnTouch:
-	if (lhz_dun04 == 0) {
-		mes "It doesn't make sense to go down these flooded stairs.";
-		close;
-	} else if (lhz_dun04 < 6) {
-		callfunc "lhz4enter",0;
-		end;
-	}
-	warp "lhz_dun04",244,52;
-	end;
-}
-lhz_dun04,245,61,0	warp	#warplhz4lhz3	1,1,lhz_dun03,240,74
-
-// Does this portal exist?
-que_lhz,245,61,0	warp	#warplhzqlhz3	1,1,lhz_dun03,240,74
-
-que_lhz,244,52,0	script	#lhz4mes1	-1,2,2,{
-OnTouch:
-	mes "- You find another flight of";
-	mes "stairs that is raised and deviates";
-	mes "from the flooded path. -";
-	// Missing dialogue.
-	close2;
-	donpcevent "#lhz4mes1::OnDisable";
-	end;
-OnInit:
-OnDisable:
-	disablenpc "#lhz4mes1";
-	end;
-OnEnable:
-	enablenpc "#lhz4mes1";
-	end;
-}
-
-lhz_dun04,151,276,3	script	Researcher#lhz4	865,{
-	if (lhz_dun04 == 0) {
-		mes "[Researcher]";
-		mes "................";
-		close;
-	} else if (lhz_dun04 < 6) {
-		callfunc "lhz4enter",1;
-		end;
-	} else if (lhz_dun04 == 6) {
-		mes "Think twice before saying that these samples are a reason to shut this place down.";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "You're stopping me for doing nothing good? What about the last four men I've created?";
-		next;
-		mes "[Wolfchev]";
-		mes "Hmm. This place will be completely flooded...";
-		next;
-		mes "[Wolfchev]";
-		mes "What is the problem?";
-		next;
-		mes "[Wolfchev]";
-		mes "Hmm... All this burocracy is ruining my laboratory. For God's sake!";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "Hey! Wolfchev!!";
-		next;
-		mes "[Wolfchev]";
-		mes "Oh yes? To please them all! ^FF0080The different specimen^000000 are organically connected to each other.";
-		next;
-		mes "[Wolfchev]";
-		mes "Perhaps the boss of these ^00FF00things^000000...";
-		mes "My inability to control my own experiment... Here, are all the ^808000slaves used as decoys^000000 and the laboratory will be shut down.";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "Hey, Wolfchev!! This ^00FF00boss^000000 you're talking about. Where is it?";
-		next;
-		mes "[Wolfchev]";
-		mes "...in my laboratory. I awakened it. I tried to use it to destroy them all, but it didn't work... you'll have to do it...";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "How can I get access to your laboratory?";
-		next;
-		mes "[Wolfchev]";
-		mes "Now... One moment!";
-		mes "I will help you.";
-		next;
-		mes "[Wolfchev]";
-		mes "Luckily, the boss hasn't awaken sober, though he's still strong and destructive.";
-		next;
-		mes "[Wolfchev]";
-		mes "But it's still dangerous. He wil release his colleagues and this means we don't have much time here.";
-		set lhz_dun04,7;
-		completequest 5111;
-		setquest 5113;
-		setquest 5114;
-		setquest 5115;
-		setquest 5116;
-		setquest 5117;
-		setquest 5118;
-		setquest 5119;
-		setquest 5120;
-		setquest 5121;
-		setquest 5122;
-		setquest 5123;
-		setquest 5124;
-		setquest 5125;
-		close;
-	} else if (lhz_dun04 == 7) {
-		mes "[Wolfchev]";
-		mes "Are you going alone?";
-		mes "You will need a really good group to bypass the system and defeat the boss.";
-		close;
-	}
-	end;
-}
-
-que_lhz,207,75,3	script	Researcher#ins	865,3,3,{
-OnTouch:
-	if (lhz_dun04 == 1) {
-		mes "[Researcher]";
-		mes "..........";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "You! Are you professor Wolfchev?";
-		emotion e_omg,1;
-		next;
-		mes "[Wolfchev]";
-		mes "Many people come here looking for me. But most of them are reluctant to.";
-		mes "What do you want?";
-		emotion e_gg;
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "I've heard rumors about biological experiments.";
-		mes "Wolfchev!!";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "These experiments...";
-		next;
-		mes "[Wolfchev]";
-		mes "I think I know what you're gonna say. Are you accusing me of something?";
-		mes "I don't want to hear more of that.";
-		mes "You better leave.";
-		emotion e_gg;
-		next;
-		mes "[Wolfchev]";
-		mes "They seem to have cried for a long time... I'm busy, excuse me!";
-		next;
-		mes "From Wolfchev's eyes tears welled and he started laughing before running away.";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "Hey! Wolfchev there...";
-		emotion e_omg,1;
-		changequest 5109,5110;
-		set lhz_dun04,2;
-		close2;
-		warp "que_lhz",96,136;
-		end;
-	}
-	mes "[Researcher]";
-	mes "..........";
-	close;
-}
-
-que_lhz,94,119,3	script	Researcher#ins2	865,{
-	if (lhz_dun04 == 2) {
-		mes "[Wolfchev]";
-		mes "Hehehe. You are really persistent. What do you want from someone like me?";
-		emotion e_swt2;
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "Wolfchev... You've admitted it's dangerous already. And all these investigations...";
-		next;
-		mes "[Wolfchev]";
-		mes "You're right...hehe.";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "Your research is too dangerous. Do you think everybody wants it to keep going?";
-		next;
-		mes "[Wolfchev]";
-		mes "Everyone wants to be strong and dominate the others. Have their obedience, respect and attention. Don't you want that? Hehe.";
-		emotion e_gg;
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "... ... ...";
-		next;
-		mes "[Wolfchev]";
-		mes "With such a dangerous life, avoiding being damaged... Don't you see it?. Hehe.";
-		next;
-		mes "Again, Wolfchev hastily escapes.";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "Oh! He's far... and...";
-		set lhz_dun04,3;
-		close2;
-		warp "que_lhz",148,215;
-		end;
-	}
-	mes "[Researcher]";
-	mes "..........";
-	close;
-}
-que_lhz,147,224,3	script	Researcher#ins3	865,{
-	if (lhz_dun04 == 4 || mobcount("que_lhz","#controllhz4::OnMyMobDead") > 0) {
-		mes "[Wolfchev]";
-		mes "Wolfchev is freaking out. He is out of his mind.";
-		emotion e_turn;
-		close;
-	} else if (lhz_dun04 == 3) {
-		mes "[Wolfchev]";
-		mes "You really are a bothersome little";
-		mes "tick, aren't you? Isn't that";
-		mes "apparent to you at all?";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "... ... ...";
-		emotion e_dots,1;
-		next;
-		mes "Wolfchev didn't want to talk to you anymore, so while laughing he pressed a button on his hand. Then he went mad.";
-		specialeffect EF_SIGHTRASHER;
-		next;
-		mes "[Wolfchev]";
-		mes "Unfortunately to you, I will beat you here.";
-		donpcevent "#controllhz4::OnEnable";
-		next;
-		mes "[Wolfchev]";
-		mes "You're such a fool.";
-		emotion e_gasp;
-		next;
-		mes "[Wolfchev]";
-		mes "Look at all these experimental bodies you'll have to deal and see how good they are.";
-		next;
-		donpcevent "#controllhz4::OnEnable2";
-		progressbar "ffff00",6;
-		set lhz_dun04,4;
-		next;
-		mes "[Wolfchev]";
-		mes "NO!! ...Look what you did!! You";
-		mes "wreckless madman!!!";
-		emotion e_omg;
-		next;
-		mes "[Wolfchev]";
-		mes "Go back!";
-		next;
-		mes "First, let's destroy all these experiments!";
-		close;
-	} else if (lhz_dun04 == 5) {
-		mes "Wolfchev is freaking out. He is out of his mind.";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "*Slaps Face* Hey, snap out of it!";
-		mes "We've destroyed them!";
-		specialeffect EF_STUNATTACK;
-		sleep2 1000;
-		specialeffect EF_STUNATTACK;
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "Let's get out of here first! Is there a place we can go?";
-		specialeffect EF_DARKBREATH;
-		emotion e_no,1;
-		next;
-		mes "[Wolfchev]";
-		mes "This. My laboratory... My laboratory...";
-		next;
-		mes "["+strcharinfo(0)+"]";
-		mes "The laboratory? Where am I indeed?";
-		next;
-		mes "[Wolfchev]";
-		mes "Back to the beggining... here's when...";
-		next;
-		mes "- Wolfchev weakly points to the 12 o' clock direction. -";
-		next;
-		mes "I have to go to ^0000FF Wolfchev's Laboratory^000000...";
-		changequest 5110,5111;
-		set lhz_dun04,6;
-		donpcevent "#controllhz4d::OnEnable";
-		close;
-	} else if (lhz_dun04 == 6) {
-		mes "I have to go to ^0000FF Wolfchev's Laboratory^000000...";
-		close;
-	}
-	end;
-}
-
--	script	Awake Specimen#lhz	-1,{
-	end;
-OnInit:
-OnDisable:
-	hideonnpc strnpcinfo(0);
-	end;
-OnEnable:
-	hideoffnpc strnpcinfo(0);
-	end;
-OnEffect1:
-	specialeffect EF_SUI_EXPLOSION;
-	end;
-OnEffect2:
-	specialeffect EF_BEGINASURA;
-	end;
-OnEffect3:
-	specialeffect EF_FLASHER;
-	end;
-}
-que_lhz,148,231,0	duplicate(Awake Specimen#lhz)	Awake Specimen#0	2244
-que_lhz,140,231,1	duplicate(Awake Specimen#lhz)	Awake Specimen#1	2244
-que_lhz,140,224,2	duplicate(Awake Specimen#lhz)	Awake Specimen#2	2244
-que_lhz,140,216,3	duplicate(Awake Specimen#lhz)	Awake Specimen#3	2244
-que_lhz,147,216,4	duplicate(Awake Specimen#lhz)	Awake Specimen#4	2244
-que_lhz,155,216,5	duplicate(Awake Specimen#lhz)	Awake Specimen#5	2244
-que_lhz,155,224,6	duplicate(Awake Specimen#lhz)	Awake Specimen#6	2244
-que_lhz,155,231,7	duplicate(Awake Specimen#lhz)	Awake Specimen#7	2244
-
--	script	#controllhz4	-1,{
-OnInit:
-	disablenpc "#controllhz4";
-	end;
-OnEnable:
-	enablenpc "#controllhz4";
-	donpcevent "Awake Specimen#0::OnEnable";
-	donpcevent "Awake Specimen#1::OnEnable";
-	donpcevent "Awake Specimen#2::OnEnable";
-	donpcevent "Awake Specimen#3::OnEnable";
-	donpcevent "Awake Specimen#4::OnEnable";
-	donpcevent "Awake Specimen#5::OnEnable";
-	donpcevent "Awake Specimen#6::OnEnable";
-	donpcevent "Awake Specimen#7::OnEnable";
-	end;
-OnEnable2:
-	initnpctimer;
-	end;
-OnTimer1000:
-	donpcevent "Awake Specimen#0::OnEffect1";
-	end;
-OnTimer2000:
-	donpcevent "Awake Specimen#0::OnEffect2";
-	donpcevent "Awake Specimen#7::OnEffect1";
-	end;
-OnTimer3000:
-	donpcevent "Awake Specimen#7::OnEffect2";
-	donpcevent "Awake Specimen#6::OnEffect1";
-	end;
-OnTimer4000:
-	donpcevent "Awake Specimen#6::OnEffect2";
-	donpcevent "Awake Specimen#5::OnEffect1";
-	end;
-OnTimer5000:
-	donpcevent "Awake Specimen#5::OnEffect2";
-	donpcevent "Awake Specimen#4::OnEffect1";
-	end;
-OnTimer6000:
-	donpcevent "Awake Specimen#4::OnEffect2";
-	donpcevent "Awake Specimen#3::OnEffect1";
-	end;
-OnTimer7000:
-	donpcevent "Awake Specimen#3::OnEffect2";
-	donpcevent "Awake Specimen#2::OnEffect1";
-	end;
-OnTimer8000:
-	donpcevent "Awake Specimen#2::OnEffect2";
-	donpcevent "Awake Specimen#1::OnEffect1";
-	end;
-OnTimer9000:
-	donpcevent "Awake Specimen#1::OnEffect2";
-	end;
-OnTimer11000:
-	donpcevent "Awake Specimen#0::OnEffect3";
-	donpcevent "Awake Specimen#1::OnEffect3";
-	donpcevent "Awake Specimen#2::OnEffect3";
-	donpcevent "Awake Specimen#3::OnEffect3";
-	donpcevent "Awake Specimen#4::OnEffect3";
-	donpcevent "Awake Specimen#5::OnEffect3";
-	donpcevent "Awake Specimen#6::OnEffect3";
-	donpcevent "Awake Specimen#7::OnEffect3";
-	end;
-OnTimer14000:
-	donpcevent "Awake Specimen#0::OnDisable";
-	donpcevent "Awake Specimen#1::OnDisable";
-	donpcevent "Awake Specimen#2::OnDisable";
-	donpcevent "Awake Specimen#3::OnDisable";
-	donpcevent "Awake Specimen#4::OnDisable";
-	donpcevent "Awake Specimen#5::OnDisable";
-	donpcevent "Awake Specimen#6::OnDisable";
-	donpcevent "Awake Specimen#7::OnDisable";
-	end;
-OnTimer16000:
-	monster "que_lhz",148,231,"Awake Specimen",2244,1,"#controllhz4::OnMyMobDead";
-	monster "que_lhz",140,231,"Awake Specimen",2244,1,"#controllhz4::OnMyMobDead";
-	monster "que_lhz",140,224,"Awake Specimen",2244,1,"#controllhz4::OnMyMobDead";
-	monster "que_lhz",140,216,"Awake Specimen",2244,1,"#controllhz4::OnMyMobDead";
-	monster "que_lhz",147,216,"Awake Specimen",2244,1,"#controllhz4::OnMyMobDead";
-	monster "que_lhz",155,216,"Awake Specimen",2244,1,"#controllhz4::OnMyMobDead";
-	monster "que_lhz",155,224,"Awake Specimen",2244,1,"#controllhz4::OnMyMobDead";
-	monster "que_lhz",155,231,"Awake Specimen",2244,1,"#controllhz4::OnMyMobDead";
-	donpcevent "#controllhz4b::OnEnable";
-	stopnpctimer;
-	end;
-OnMyMobDead:
-	if (mobcount("que_lhz","#controllhz4::OnMyMobDead") < 1) {
-		donpcevent "#controllhz4b::OnStop";
-		donpcevent "#controllhz4c::OnEnable";
-		disablenpc "#controllhz4";
-		end;
-	}
-	end;
-}
-
--	script	#controllhz4b	-1,{
-OnInit:
-OnDisable:
-	disablenpc "#controllhz4b";
-	end;
-OnEnable:
-	enablenpc "#controllhz4b";
-	initnpctimer;
-	end;
-OnStop:
-	stopnpctimer;
-	donpcevent "#controllhz4b::OnDisable";
-	end;
-OnTimer400000:
-	killmonster "que_lhz","#controllhz4::OnMyMobDead";
-	mapwarp "que_lhz","lighthalzen",263,200;
-	disablenpc "#controllhz4";
-	disablenpc "#controllhz4b";
-	stopnpctimer;
-	end;
-}
-
--	script	#controllhz4c	-1,{
-OnInit:
-	disablenpc "#controllhz4c";
-	end;
-OnEnable:
-	enablenpc "#controllhz4c";
-	initnpctimer;
-	end;
-OnTimer10000:
-	mapannounce "que_lhz","Whisper of a man: Help me... Please... Aaah... I don't want to... Die....",bc_map,0x0080C0;
-	donpcevent "#controllhz4d::OnEnable";
-	stopnpctimer;
-	disablenpc "#controllhz4c";
-	end;
-}
-
-que_lhz,147,248,0	script	#controllhz4d	-1,6,4,{
-OnTouch:
-	if (lhz_dun04 == 4) {
-		mes "Looks like it's all done.";
-		set lhz_dun04,5;
-		donpcevent "#controllhz4d::OnDisable";
-		close;
-	} else if (lhz_dun04 == 6) {
-		mes "- Concrete falls from the ceiling";
-		mes "due to the weakened structure of";
-		mes "the lab and you tumble down the";
-		mes "flight of stairs avoiding it. -";
-		close2;
-		warp "lhz_dun04",148,269;
-		donpcevent "#lhz4mes2::OnEnable";
-		donpcevent "#controllhz4d::OnDisable";
-		end;
-	}
-	end;
-OnInit:
-OnDisable:
-	disablenpc "#controllhz4d";
-	end;
-OnEnable:
-	enablenpc "#controllhz4d";
-	end;
-}
-
-lhz_dun04,148,269,0	script	#lhz4mes2	-1,2,2,{
-OnTouch:
-	if (lhz_dun04 == 6) {
-		heal -Hp/2,0; // To do: check HP value.
-		mes "- You awaken injured, hearing the";
-		mes "sounds of footsteps all around";
-		mes "you... -";
-		close2;
-		donpcevent "#lhz4mes2::OnDisable";
-		end;
-	}
-	end;
-OnInit:
-OnDisable:
-	disablenpc "#lhz4mes2";
-	end;
-OnEnable:
-	enablenpc "#lhz4mes2";
-	end;
-}

+ 1 - 0
npc/re/scripts_athena.conf

@@ -57,6 +57,7 @@ npc: npc/re/instances/HazyForest.txt
 npc: npc/re/instances/MalangdoCulvert.txt
 npc: npc/re/instances/OctopusCave.txt
 npc: npc/re/instances/OldGlastHeim.txt
+npc: npc/re/instances/WolfchevLaboratory.txt
 
 // ---------------- Kafras & Cool Event Corp. -------------------
 npc: npc/re/kafras/kafras.txt

Datei-Diff unterdrückt, da er zu groß ist
+ 354 - 138
sql-files/item_db_re.sql


+ 1 - 0
sql-files/main.sql

@@ -123,6 +123,7 @@ CREATE TABLE IF NOT EXISTS `char` (
   `delete_date` INT(11) UNSIGNED NOT NULL DEFAULT '0',
   `moves` int(11) unsigned NOT NULL DEFAULT '0',
   `unban_time` int(11) unsigned NOT NULL default '0',
+  `font` tinyint(3) unsigned NOT NULL default '0',
   PRIMARY KEY  (`char_id`),
   UNIQUE KEY `name_key` (`name`),
   KEY `account_id` (`account_id`),

+ 1 - 2
sql-files/mob_db_re.sql

@@ -1442,8 +1442,7 @@ REPLACE INTO `mob_db_re` VALUES (2240,'B_ALPHOCCIO','Clown Alphoccio','Clown Alp
 REPLACE INTO `mob_db_re` VALUES (2241,'B_TRENTINI','Gypsy Trentini','Gypsy Trentini',160,3894278,0,4463758,2563096,1,1070,1498,181,112,176,258,155,132,309,95,10,12,1,7,84,0x37B5,100,76,384,288,2231879,0,0,0,0,0,0,12623,9000,12616,9000,616,9000,6224,9000,18103,5000,18110,5000,1963,5000,0,0,0,0,0,0);
 REPLACE INTO `mob_db_re` VALUES (2242,'MD_DESERT_WOLF','Desert Wolf','Desert Wolf',135,551578,0,0,0,1,1040,1158,151,39,93,69,63,61,82,42,10,12,1,6,20,0x37B5,200,1120,420,288,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
 REPLACE INTO `mob_db_re` VALUES (2243,'MD_DESERT_WOLF_B','Desert Wolf','Desert Wolf',130,274531,0,0,0,1,66,82,13,0,10,12,8,5,17,7,10,12,0,6,20,0x37B5,300,1600,900,240,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
-# Fix me! 2244 needs new info.
-REPLACE INTO `mob_db_re` VALUES (2244,'QUEST_CHEN','Champion Chen','Champion Chen',99,15000,2000,0,0,1,1700,3000,216,134,126,74,71,123,99,65,10,12,1,7,68,0x37B5,180,1152,384,288,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
+REPLACE INTO `mob_db_re` VALUES (2244,'QUEST_CHEN','Champion Chen','Champion Chen',130,300,1,0,0,1,103,126,25,56,122,81,83,130,201,61,10,12,1,7,81,0x37B5,300,200,768,288,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
 REPLACE INTO `mob_db_re` VALUES (2245,'EXP_TEST','Exp Test','Exp Test',1,100,1,100,100,1,8,9,2,5,6,1,1,0,6,5,10,12,1,7,21,0x83,400,1000,480,288,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
 REPLACE INTO `mob_db_re` VALUES (2246,'Q_WOOTAN_FIGHTER','Wootan Fighter','Wootan Fighter',95,9000,1,1400,2000,1,255,291,103,8,63,14,36,5,62,15,10,12,1,7,43,0x83,200,912,1344,480,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
 REPLACE INTO `mob_db_re` VALUES (2247,'Q_INCREASE_SOIL','Increase Soil','Mi Gao',95,20000,1,1400,2000,1,365,395,112,39,67,23,41,49,94,30,10,12,1,0,62,0x83,445,106,1056,576,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);

+ 1 - 0
sql-files/upgrades/upgrade_20140523.sql

@@ -0,0 +1 @@
+ALTER TABLE `char` ADD `font` tinyint(3) unsigned NOT NULL default '0';

+ 11 - 8
src/char/char.c

@@ -334,7 +334,8 @@ int char_mmo_char_tosql(int char_id, struct mmo_charstatus* p){
 		(p->pet_id != cp->pet_id) || (p->weapon != cp->weapon) || (p->hom_id != cp->hom_id) ||
 		(p->ele_id != cp->ele_id) || (p->shield != cp->shield) || (p->head_top != cp->head_top) ||
 		(p->head_mid != cp->head_mid) || (p->head_bottom != cp->head_bottom) || (p->delete_date != cp->delete_date) ||
-		(p->rename != cp->rename) || (p->robe != cp->robe) || (p->character_moves != cp->character_moves) || (p->unban_time != cp->unban_time)
+		(p->rename != cp->rename) || (p->robe != cp->robe) || (p->character_moves != cp->character_moves) ||
+		(p->unban_time != cp->unban_time) || (p->font != cp->font)
 	)
 	{	//Save status
 		if( SQL_ERROR == Sql_Query(sql_handle, "UPDATE `%s` SET `base_level`='%d', `job_level`='%d',"
@@ -344,9 +345,9 @@ int char_mmo_char_tosql(int char_id, struct mmo_charstatus* p){
 			"`option`='%d',`party_id`='%d',`guild_id`='%d',`pet_id`='%d',`homun_id`='%d',`elemental_id`='%d',"
 			"`weapon`='%d',`shield`='%d',`head_top`='%d',`head_mid`='%d',`head_bottom`='%d',"
 			"`last_map`='%s',`last_x`='%d',`last_y`='%d',`save_map`='%s',`save_x`='%d',`save_y`='%d', `rename`='%d',"
-			"`delete_date`='%lu',`robe`='%d',`moves`='%d'"
-			" WHERE  `account_id`='%d' AND `char_id` = '%d'",
-			schema_config.char_db, p->base_level, p->job_level,
+			"`delete_date`='%lu',`robe`='%d',`moves`='%d',`font`='%u'"
+			" WHERE `account_id`='%d' AND `char_id` = '%d'",
+			char_db, p->base_level, p->job_level,
 			p->base_exp, p->job_exp, p->zeny,
 			p->max_hp, p->hp, p->max_sp, p->sp, p->status_point, p->skill_point,
 			p->str, p->agi, p->vit, p->int_, p->dex, p->luk,
@@ -354,8 +355,8 @@ int char_mmo_char_tosql(int char_id, struct mmo_charstatus* p){
 			p->weapon, p->shield, p->head_top, p->head_mid, p->head_bottom,
 			mapindex_id2name(p->last_point.map), p->last_point.x, p->last_point.y,
 			mapindex_id2name(p->save_point.map), p->save_point.x, p->save_point.y, p->rename,
-			(unsigned long)p->delete_date,  // FIXME: platform-dependent size
-			p->robe,p->character_moves,
+			(unsigned long)p->delete_date, // FIXME: platform-dependent size
+			p->robe,p->character_moves,p->font,
 			p->account_id, p->char_id) )
 		{
 			Sql_ShowDebug(sql_handle);
@@ -987,8 +988,9 @@ int char_mmo_char_fromsql(int char_id, struct mmo_charstatus* p, bool load_every
 		"`str`,`agi`,`vit`,`int`,`dex`,`luk`,`max_hp`,`hp`,`max_sp`,`sp`,"
 		"`status_point`,`skill_point`,`option`,`karma`,`manner`,`party_id`,`guild_id`,`pet_id`,`homun_id`,`elemental_id`,`hair`,"
 		"`hair_color`,`clothes_color`,`weapon`,`shield`,`head_top`,`head_mid`,`head_bottom`,`last_map`,`last_x`,`last_y`,"
-		"`save_map`,`save_x`,`save_y`,`partner_id`,`father`,`mother`,`child`,`fame`,`rename`,`delete_date`,`robe`, `moves`, `unban_time`"
-		" FROM `%s` WHERE `char_id`=? LIMIT 1", schema_config.char_db)
+		"`save_map`,`save_x`,`save_y`,`partner_id`,`father`,`mother`,`child`,`fame`,`rename`,`delete_date`,`robe`, `moves`,"
+		"`unban_time`,`font`"
+		" FROM `%s` WHERE `char_id`=? LIMIT 1", char_db)
 	||	SQL_ERROR == SqlStmt_BindParam(stmt, 0, SQLDT_INT, &char_id, 0)
 	||	SQL_ERROR == SqlStmt_Execute(stmt)
 	||	SQL_ERROR == SqlStmt_BindColumn(stmt, 0,  SQLDT_INT,    &p->char_id, 0, NULL, NULL)
@@ -1045,6 +1047,7 @@ int char_mmo_char_fromsql(int char_id, struct mmo_charstatus* p, bool load_every
 	||	SQL_ERROR == SqlStmt_BindColumn(stmt, 51, SQLDT_SHORT,  &p->robe, 0, NULL, NULL)
 	||	SQL_ERROR == SqlStmt_BindColumn(stmt, 52, SQLDT_UINT32, &p->character_moves, 0, NULL, NULL)
 	||	SQL_ERROR == SqlStmt_BindColumn(stmt, 53, SQLDT_LONG,   &p->unban_time, 0, NULL, NULL)
+	||	SQL_ERROR == SqlStmt_BindColumn(stmt, 54, SQLDT_UCHAR,  &p->font, 0, NULL, NULL)
 	)
 	{
 		SqlStmt_ShowDebug(stmt);

+ 2 - 0
src/char/char.h

@@ -237,6 +237,8 @@ int char_rename_char_sql(struct char_session_data *sd, int char_id);
 int char_divorce_char_sql(int partner_id1, int partner_id2);
 int char_memitemdata_to_sql(const struct item items[], int max, int id, int tableswitch);
 
+void disconnect_player(int account_id);
+
 int char_married(int pl1,int pl2);
 int char_child(int parent_id, int child_id);
 int char_family(int pl1,int pl2,int pl3);

+ 1 - 1
src/char/int_mail.c

@@ -185,7 +185,7 @@ static bool mail_loadmessage(int mail_id, struct mail_message* msg)
 		Sql_GetData(sql_handle,14, &data, NULL); msg->item.identify = atoi(data);
 		Sql_GetData(sql_handle,15, &data, NULL); msg->item.unique_id = strtoull(data, NULL, 10);
 		msg->item.expire_time = 0;
-		msg->item.bound = 0;
+		msg->item.bound = BOUND_NONE;
 
 		for( j = 0; j < MAX_SLOTS; j++ )
 		{

+ 75 - 8
src/char/int_storage.c

@@ -251,9 +251,10 @@ int mapif_parse_itembound_retrieve(int fd)
 	StringBuf buf;
 	SqlStmt* stmt;
 	struct item item;
-	int j, i=0, s;
-	bool found=false;
+	int j, i = 0, s = 0, bound_qt = 0;
+	bool found = false;
 	struct item items[MAX_INVENTORY];
+	unsigned int bound_item[MAX_INVENTORY] = { 0 };
 	int char_id = RFIFOL(fd,2);
 	int aid = RFIFOL(fd,6);
 	int guild_id = RFIFOW(fd,10);
@@ -288,7 +289,7 @@ int mapif_parse_itembound_retrieve(int fd)
 		SqlStmt_BindColumn(stmt, 9+j, SQLDT_SHORT, &item.card[j], 0, NULL, NULL);
 
 	while( SQL_SUCCESS == SqlStmt_NextRow(stmt) ) {
-		if(item.bound == 2) {
+		if(item.bound == BOUND_GUILD) {
 			memcpy(&items[i],&item,sizeof(struct item));
 			i++;
 		}
@@ -311,6 +312,24 @@ int mapif_parse_itembound_retrieve(int fd)
 		else
 			found = true;
 		StringBuf_Printf(&buf, " `id`=%d",items[j].id);
+
+		if( items[j].bound && items[j].equip ) {
+			//Only the items that are also stored in `char` `equip`
+			if( (items[j].equip&EQP_HAND_R) ||
+				(items[j].equip&EQP_HAND_L) ||
+				(items[j].equip&EQP_HEAD_TOP) ||
+				(items[j].equip&EQP_HEAD_MID) ||
+				(items[j].equip&EQP_HEAD_LOW) ||
+				(items[j].equip&EQP_GARMENT) ||
+				(items[j].equip&EQP_COSTUME_HEAD_TOP) ||
+				(items[j].equip&EQP_COSTUME_HEAD_MID) ||
+				(items[j].equip&EQP_COSTUME_HEAD_LOW) ||
+				(items[j].equip&EQP_COSTUME_GARMENT) )
+			{
+				bound_item[bound_qt] = items[j].equip;
+				bound_qt++;
+			}
+		}
 	}
 
 	if( SQL_ERROR == SqlStmt_PrepareStr(stmt, StringBuf_Value(&buf))
@@ -323,12 +342,54 @@ int mapif_parse_itembound_retrieve(int fd)
 		return 1;
 	}
 
+	if( bound_qt ) { //Removes any view id that was set by an item that was removed
+/* Verifies equip bitmasks (see item.equip) and handles the sql statement */
+#define CHECK_REMOVE(var,mask,token) do { \
+	if( (var)&(mask) ) { \
+		if( (var) != (mask) && s ) StringBuf_AppendStr(&buf, ","); \
+		StringBuf_AppendStr(&buf, "`"#token"`='0'"); \
+		(var) &= ~(mask); \
+		s++; \
+	} \
+} while( 0 )
+
+		StringBuf_Clear(&buf);
+		StringBuf_Printf(&buf, "UPDATE `%s` SET ", schema_config.char_db);
+		for( j = 0; j < bound_qt; j++ ) {
+			//Equips can be at more than one slot at the same time
+			CHECK_REMOVE(bound_item[j],EQP_HAND_R,weapon);
+			CHECK_REMOVE(bound_item[j],EQP_HAND_L,shield);
+			CHECK_REMOVE(bound_item[j],EQP_HEAD_TOP|EQP_COSTUME_HEAD_TOP,head_top);
+			CHECK_REMOVE(bound_item[j],EQP_HEAD_MID|EQP_COSTUME_HEAD_MID,head_mid);
+			CHECK_REMOVE(bound_item[j],EQP_HEAD_LOW|EQP_COSTUME_HEAD_LOW,head_bottom);
+			CHECK_REMOVE(bound_item[j],EQP_GARMENT|EQP_COSTUME_GARMENT,robe);
+		}
+		StringBuf_Printf(&buf, " WHERE `char_id`='%d'", char_id);
+
+		if( SQL_ERROR == SqlStmt_PrepareStr(stmt, StringBuf_Value(&buf)) ||
+			SQL_ERROR == SqlStmt_Execute(stmt) )
+		{
+			SqlStmt_ShowDebug(stmt);
+			SqlStmt_Free(stmt);
+			StringBuf_Destroy(&buf);
+			mapif_itembound_ack(fd,aid,guild_id);
+			return 1;
+		}
+#undef CHECK_REMOVE
+	}
+
 	//Now let's update the guild storage with those deleted items
+	//@TODO/FIXME:
+	//This approach is basically the same as the one from memitemdata_to_sql, but
+	//the latter compares current database values and this is not needed in this case
+	//maybe sometime separate memitemdata_to_sql into different methods in order to use
+	//call that function here as well [Panikon]
 	found = false;
 	StringBuf_Clear(&buf);
-	StringBuf_Printf(&buf, "INSERT INTO `%s` (`guild_id`, `nameid`, `amount`, `identify`, `refine`, `attribute`, `expire_time`, `bound`", schema_config.guild_storage_db);
-	for( j = 0; j < MAX_SLOTS; ++j )
-		StringBuf_Printf(&buf, ", `card%d`", j);
+	StringBuf_Printf(&buf, "INSERT INTO `%s` (`guild_id`, `nameid`, `amount`, `equip`, `identify`, `refine`,"
+		"`attribute`, `expire_time`, `bound`", schema_config.guild_storage_db);
+	for( s = 0; s < MAX_SLOTS; ++s )
+		StringBuf_Printf(&buf, ", `card%d`", s);
 	StringBuf_AppendStr(&buf, ") VALUES ");
 
 	for( j = 0; j < i; ++j ) {
@@ -337,8 +398,9 @@ int mapif_parse_itembound_retrieve(int fd)
 		else
 			found = true;
 
-		StringBuf_Printf(&buf, "('%d', '%d', '%d', '%d', '%d', '%d', '%d', '%d'",
-			guild_id, items[j].nameid, items[j].amount, items[j].identify, items[j].refine, items[j].attribute, items[j].expire_time, items[j].bound);
+		StringBuf_Printf(&buf, "('%d', '%d', '%d', '%d', '%d', '%d', '%d', '%d', '%d'",
+			guild_id, items[j].nameid, items[j].amount, items[j].equip, items[j].identify, items[j].refine,
+			items[j].attribute, items[j].expire_time, items[j].bound);
 		for( s = 0; s < MAX_SLOTS; ++s )
 			StringBuf_Printf(&buf, ", '%d'", items[j].card[s]);
 		StringBuf_AppendStr(&buf, ")");
@@ -359,6 +421,11 @@ int mapif_parse_itembound_retrieve(int fd)
 
 	//Finally reload storage and tell map we're done
 	mapif_load_guild_storage(fd,aid,guild_id,0);
+
+	//If character is logged in char, disconnect
+	disconnect_player(aid);
+
+	//Tell map-server the operation is over and it can unlock the storage
 	mapif_itembound_ack(fd,aid,guild_id);
 	return 0;
 }

+ 38 - 0
src/common/mmo.h

@@ -186,6 +186,32 @@ struct item {
 	uint64 unique_id;
 };
 
+//Equip position constants
+enum equip_pos {
+	EQP_HEAD_LOW         = 0x000001,
+	EQP_HEAD_MID         = 0x000200, // 512
+	EQP_HEAD_TOP         = 0x000100, // 256
+	EQP_HAND_R           = 0x000002, // 2
+	EQP_HAND_L           = 0x000020, // 32
+	EQP_ARMOR            = 0x000010, // 16
+	EQP_SHOES            = 0x000040, // 64
+	EQP_GARMENT          = 0x000004, // 4
+	EQP_ACC_L            = 0x000008, // 8
+	EQP_ACC_R            = 0x000080, // 128
+	EQP_COSTUME_HEAD_TOP = 0x000400, // 1024
+	EQP_COSTUME_HEAD_MID = 0x000800, // 2048
+	EQP_COSTUME_HEAD_LOW = 0x001000, // 4096
+	EQP_COSTUME_GARMENT  = 0x002000, // 8192
+	//EQP_COSTUME_FLOOR  = 0x004000, // 16384
+	EQP_AMMO             = 0x008000, // 32768
+	EQP_SHADOW_ARMOR     = 0x010000, // 65536
+	EQP_SHADOW_WEAPON    = 0x020000, // 131072
+	EQP_SHADOW_SHIELD    = 0x040000, // 262144
+	EQP_SHADOW_SHOES     = 0x080000, // 524288
+	EQP_SHADOW_ACC_R     = 0x100000, // 1048576
+	EQP_SHADOW_ACC_L     = 0x200000, // 2097152
+};
+
 struct point {
 	unsigned short map;
 	short x,y;
@@ -390,6 +416,8 @@ struct mmo_charstatus {
 	// Char server addon system
 	unsigned int character_moves;
 
+	unsigned char font;
+
 	bool cashshop_sent; // Whether the player has received the CashShop list
 };
 
@@ -758,6 +786,16 @@ enum {
 	SEX_SERVER
 };
 
+/// Item Bound Type
+enum bound_type {
+	BOUND_NONE = 0, /// No bound
+	BOUND_ACCOUNT, /// 1- Account Bound
+	BOUND_GUILD, /// 2 - Guild Bound
+	BOUND_PARTY, /// 3 - Party Bound
+	BOUND_CHAR, /// 4 - Character Bound
+	BOUND_MAX
+};
+
 // sanity checks...
 #if MAX_ZENY > INT_MAX
 #error MAX_ZENY is too big

+ 1 - 6
src/config/core.h

@@ -62,12 +62,7 @@
 /// Uncomment to enable skills damage adjustments
 /// By enabling this, db/skill_damage.txt and the skill_damage mapflag will adjust the
 /// damage rate of specified skills.
-//#define ADJUST_SKILL_DAMAGE
-
-/// The skill damage adjustment rate is capped at 100000.
-#ifdef ADJUST_SKILL_DAMAGE
-#define MAX_SKILL_DAMAGE_RATE 100000
-#endif
+#define ADJUST_SKILL_DAMAGE
 
 /// Uncomment to enable the job base HP/SP table (job_basehpsp_db.txt)
 //#define HP_SP_TABLES

+ 1 - 1
src/login/loginlog_sql.c

@@ -13,7 +13,7 @@
 static char   global_db_hostname[32] = "127.0.0.1";
 static uint16 global_db_port = 3306;
 static char   global_db_username[32] = "ragnarok";
-static char   global_db_password[32] = "ragnarok";
+static char   global_db_password[32] = "";
 static char   global_db_database[32] = "ragnarok";
 static char   global_codepage[32] = "";
 // local sql settings

+ 126 - 109
src/map/atcommand.c

@@ -1198,7 +1198,7 @@ ACMD_FUNC(heal)
 ACMD_FUNC(item)
 {
 	char item_name[100];
-	int number = 0, flag = 0, bound = 0;
+	int number = 0, flag = 0, bound = BOUND_NONE;
 	struct item item_tmp;
 	struct item_data *item_data[10];
 	int get_count, i, j=0;
@@ -1207,12 +1207,19 @@ ACMD_FUNC(item)
 	nullpo_retr(-1, sd);
 	memset(item_name, '\0', sizeof(item_name));
 
-	if (!strcmpi(command+1,"itembound") && (!message || !*message || (
-		sscanf(message, "\"%99[^\"]\" %d %d", item_name, &number, &bound) < 2 &&
-		sscanf(message, "%99s %d %d", item_name, &number, &bound) < 2
-	))) {
-		clif_displaymessage(fd, msg_txt(sd,295)); // Please enter an item name or ID (usage: @item <item name/ID> <quantity> <bound_type>).
-		return -1;
+	if (!strcmpi(command+1,"itembound")) {
+		if (!message || !*message || (
+			sscanf(message, "\"%99[^\"]\" %d %d", item_name, &number, &bound) < 3 &&
+			sscanf(message, "%99s %d %d", item_name, &number, &bound) < 3))
+		{
+			clif_displaymessage(fd, msg_txt(sd,295)); // Please enter an item name or ID (usage: @item <item name/ID> <quantity> <bound_type>).
+			clif_displaymessage(fd, msg_txt(sd,298)); // Invalid bound type
+			return -1;
+		}
+		if( bound <= BOUND_NONE || bound >= BOUND_MAX ) {
+			clif_displaymessage(fd, msg_txt(sd,298)); // Invalid bound type
+			return -1;
+		}
 	} else if (!message || !*message || (
 		sscanf(message, "\"%99[^\"]\" %d", item_name, &number) < 1 &&
 		sscanf(message, "%99s %d", item_name, &number) < 1
@@ -1231,11 +1238,6 @@ ACMD_FUNC(item)
 		j++;
 	}
 
-	if( bound < 0 || bound > 4 ) {
-		clif_displaymessage(fd, msg_txt(sd,298)); // Invalid bound type
-		return -1;
-	}
-
 	if (number <= 0)
 		number = 1;
 	get_count = number;
@@ -1273,19 +1275,27 @@ ACMD_FUNC(item2)
 	struct item item_tmp;
 	struct item_data *item_data;
 	char item_name[100];
-	int item_id, number = 0, bound = 0;
+	int item_id, number = 0, bound = BOUND_NONE;
 	int identify = 0, refine = 0, attr = 0;
 	int c1 = 0, c2 = 0, c3 = 0, c4 = 0;
 	nullpo_retr(-1, sd);
 
 	memset(item_name, '\0', sizeof(item_name));
 
-	if (!strcmpi(command+1,"itembound2") && (!message || !*message || (
-		sscanf(message, "\"%99[^\"]\" %d %d %d %d %d %d %d %d %d", item_name, &number, &identify, &refine, &attr, &c1, &c2, &c3, &c4, &bound) < 10 &&
-		sscanf(message, "%99s %d %d %d %d %d %d %d %d %d", item_name, &number, &identify, &refine, &attr, &c1, &c2, &c3, &c4, &bound) < 10 ))) {
-		clif_displaymessage(fd, msg_txt(sd,296)); // Please enter all parameters (usage: @item2 <item name/ID> <quantity>
-		clif_displaymessage(fd, msg_txt(sd,297)); //   <identify_flag> <refine> <attribute> <card1> <card2> <card3> <card4> <bound_type>).
-		return -1;
+	if (!strcmpi(command+1,"itembound2")) {
+		if (!message || !*message || (
+			sscanf(message, "\"%99[^\"]\" %d %d %d %d %d %d %d %d %d", item_name, &number, &identify, &refine, &attr, &c1, &c2, &c3, &c4, &bound) < 10 &&
+			sscanf(message, "%99s %d %d %d %d %d %d %d %d %d", item_name, &number, &identify, &refine, &attr, &c1, &c2, &c3, &c4, &bound) < 10 ))
+		{
+			clif_displaymessage(fd, msg_txt(sd,296)); // Please enter all parameters (usage: @item2 <item name/ID> <quantity>
+			clif_displaymessage(fd, msg_txt(sd,297)); //   <identify_flag> <refine> <attribute> <card1> <card2> <card3> <card4> <bound_type>).
+			clif_displaymessage(fd, msg_txt(sd,298)); // Invalid bound type
+			return -1;
+		}
+		if( bound <= BOUND_NONE || bound >= BOUND_MAX ) {
+			clif_displaymessage(fd, msg_txt(sd,298)); // Invalid bound type
+			return -1;
+		}
 	} else if ( !message || !*message || (
 		sscanf(message, "\"%99[^\"]\" %d %d %d %d %d %d %d %d", item_name, &number, &identify, &refine, &attr, &c1, &c2, &c3, &c4) < 9 &&
 		sscanf(message, "%99s %d %d %d %d %d %d %d %d", item_name, &number, &identify, &refine, &attr, &c1, &c2, &c3, &c4) < 9
@@ -1298,11 +1308,6 @@ ACMD_FUNC(item2)
 	if (number <= 0)
 		number = 1;
 
-	if( bound < 0 || bound > 4 ) {
-		clif_displaymessage(fd, msg_txt(sd,298)); // Invalid bound type
-		return -1;
-	}
-
 	item_id = 0;
 	if ((item_data = itemdb_searchname(item_name)) != NULL ||
 	    (item_data = itemdb_exists(atoi(item_name))) != NULL)
@@ -1398,6 +1403,7 @@ ACMD_FUNC(baselevelup)
 
 		sd->status.status_point += status_point;
 		sd->status.base_level += (unsigned int)level;
+		status_calc_pc(sd, SCO_FORCE);
 		status_percent_heal(&sd->bl, 100, 100);
 		clif_misceffect(&sd->bl, 0);
 		clif_displaymessage(fd, msg_txt(sd,21)); // Base level raised.
@@ -1419,13 +1425,13 @@ ACMD_FUNC(baselevelup)
 			sd->status.status_point -= status_point;
 		sd->status.base_level -= (unsigned int)level;
 		clif_displaymessage(fd, msg_txt(sd,22)); // Base level lowered.
+		status_calc_pc(sd, SCO_FORCE);
 	}
 	sd->status.base_exp = 0;
 	clif_updatestatus(sd, SP_STATUSPOINT);
 	clif_updatestatus(sd, SP_BASELEVEL);
 	clif_updatestatus(sd, SP_BASEEXP);
 	clif_updatestatus(sd, SP_NEXTBASEEXP);
-	status_calc_pc(sd, 0);
 	pc_baselevelchanged(sd);
 	if(sd->status.party_id)
 		party_send_levelup(sd);
@@ -1479,7 +1485,7 @@ ACMD_FUNC(joblevelup)
 	clif_updatestatus(sd, SP_JOBEXP);
 	clif_updatestatus(sd, SP_NEXTJOBEXP);
 	clif_updatestatus(sd, SP_SKILLPOINT);
-	status_calc_pc(sd, 0);
+	status_calc_pc(sd, SCO_FORCE);
 
 	return 0;
 }
@@ -2539,7 +2545,7 @@ ACMD_FUNC(param)
 		*status[i] = new_value;
 		clif_updatestatus(sd, SP_STR + i);
 		clif_updatestatus(sd, SP_USTR + i);
-		status_calc_pc(sd, 0);
+		status_calc_pc(sd, SCO_FORCE);
 		clif_displaymessage(fd, msg_txt(sd,42)); // Stat changed.
 	} else {
 		if (value < 0)
@@ -2610,7 +2616,7 @@ ACMD_FUNC(stat_all)
 	}
 
 	if (count > 0) { // if at least 1 stat modified
-		status_calc_pc(sd, 0);
+		status_calc_pc(sd, SCO_FORCE);
 		clif_displaymessage(fd, msg_txt(sd,84)); // All stats changed!
 	} else {
 		if (value < 0)
@@ -3925,7 +3931,7 @@ ACMD_FUNC(mapinfo) {
 				if (map[m_id].skill_damage[j].skill_id) {
 					sprintf(atcmd_output,"     %d. %s : %d%%, %d%%, %d%%, %d%% | %d"
 						,j+1
-						,skill_db[skill_get_index(map[m_id].skill_damage[j].skill_id)].name
+						,skill_get_name(map[m_id].skill_damage[j].skill_id)
 						,map[m_id].skill_damage[j].pc
 						,map[m_id].skill_damage[j].mob
 						,map[m_id].skill_damage[j].boss
@@ -7146,13 +7152,14 @@ ACMD_FUNC(homlevel)
 
 	for (i = 1; i <= level && hd->exp_next; i++){
 		hd->homunculus.exp += hd->exp_next;
-		if( !hom_levelup(hd) ){
+		if( !hom_levelup(hd) )
 			break;
-		}
 	}
-	status_calc_homunculus(hd,0);
+
+	status_calc_homunculus(hd, SCO_NONE);
 	status_percent_heal(&hd->bl, 100, 100);
 	clif_specialeffect(&hd->bl,568,AREA);
+
 	return 0;
 }
 
@@ -8315,6 +8322,11 @@ ACMD_FUNC(auction)
 {
 	nullpo_ret(sd);
 
+	if (!battle_config.feature_auction) {
+		clif_colormes(sd, color_table[COLOR_RED], msg_txt(sd, 517));
+		return 0;
+	}
+
 	clif_Auction_openwindow(sd);
 
 	return 0;
@@ -8405,35 +8417,26 @@ ACMD_FUNC(itemlist)
 
 	nullpo_retr(-1, sd);
 
-	if( strcmp(command+1, "storagelist") == 0 )
-	{
+	if( strcmp(command+1, "storagelist") == 0 ) {
 		location = "storage";
 		items = sd->status.storage.items;
 		size = sd->storage_size;
-	}
-	else
-	if( strcmp(command+1, "cartlist") == 0 )
-	{
+	} else if( strcmp(command+1, "cartlist") == 0 ) {
 		location = "cart";
 		items = sd->status.cart;
 		size = MAX_CART;
-	}
-	else
-	if( strcmp(command+1, "itemlist") == 0 )
-	{
+	} else if( strcmp(command+1, "itemlist") == 0 ) {
 		location = "inventory";
 		items = sd->status.inventory;
 		size = MAX_INVENTORY;
-	}
-	else
+	} else
 		return 1;
 
 	StringBuf_Init(&buf);
 
 	count = 0; // total slots occupied
 	counter = 0; // total items found
-	for( i = 0; i < size; ++i )
-	{
+	for( i = 0; i < size; ++i ) {
 		const struct item* it = &items[i];
 		struct item_data* itd;
 
@@ -8443,8 +8446,7 @@ ACMD_FUNC(itemlist)
 		counter += it->amount;
 		count++;
 
-		if( count == 1 )
-		{
+		if( count == 1 ) {
 			StringBuf_Printf(&buf, msg_txt(sd,1332), location, sd->status.name); // ------ %s items list of '%s' ------
 			clif_displaymessage(fd, StringBuf_Value(&buf));
 			StringBuf_Clear(&buf);
@@ -8455,38 +8457,70 @@ ACMD_FUNC(itemlist)
 		else
 			StringBuf_Printf(&buf, "%d %s (%s, id: %d)", it->amount, itd->jname, itd->name, it->nameid);
 
-		if( it->equip )
-		{
+		if( it->equip ) {
 			char equipstr[CHAT_SIZE_MAX];
-			strcpy(equipstr, msg_txt(sd,1333)); //  | equipped:
-			if( it->equip & EQP_GARMENT )
-				strcat(equipstr, msg_txt(sd,1334)); // garment,
-			if( it->equip & EQP_ACC_L )
-				strcat(equipstr, msg_txt(sd,1335)); // left accessory,
-			if( it->equip & EQP_ARMOR )
-				strcat(equipstr, msg_txt(sd,1336)); // body/armor,
-			if( (it->equip & EQP_ARMS) == EQP_HAND_R )
-				strcat(equipstr, msg_txt(sd,1337)); // right hand,
-			if( (it->equip & EQP_ARMS) == EQP_HAND_L )
-				strcat(equipstr, msg_txt(sd,1338)); // left hand,
-			if( (it->equip & EQP_ARMS) == EQP_ARMS )
-				strcat(equipstr, msg_txt(sd,1339)); // both hands,
-			if( it->equip & EQP_SHOES )
-				strcat(equipstr, msg_txt(sd,1340)); // feet,
-			if( it->equip & EQP_ACC_R )
-				strcat(equipstr, msg_txt(sd,1341)); // right accessory,
-			if( (it->equip & EQP_HELM) == EQP_HEAD_LOW )
-				strcat(equipstr, msg_txt(sd,1342)); // lower head,
-			if( (it->equip & EQP_HELM) == EQP_HEAD_TOP )
-				strcat(equipstr, msg_txt(sd,1343)); // top head,
-			if( (it->equip & EQP_HELM) == (EQP_HEAD_LOW|EQP_HEAD_TOP) )
-				strcat(equipstr, msg_txt(sd,1344)); // lower/top head,
-			if( (it->equip & EQP_HELM) == EQP_HEAD_MID )
-				strcat(equipstr, msg_txt(sd,1345)); // mid head,
-			if( (it->equip & EQP_HELM) == (EQP_HEAD_LOW|EQP_HEAD_MID) )
-				strcat(equipstr, msg_txt(sd,1346)); // lower/mid head,
-			if( (it->equip & EQP_HELM) == EQP_HELM )
-				strcat(equipstr, msg_txt(sd,1347)); // lower/mid/top head,
+
+			strcpy(equipstr, msg_txt(sd,1333)); // | Equipped:
+			if( it->equip&EQP_GARMENT )
+				strcat(equipstr, msg_txt(sd,1334)); // Robe,
+			if( it->equip&EQP_ACC_L )
+				strcat(equipstr, msg_txt(sd,1335)); // Left Accessory,
+			if( it->equip&EQP_ARMOR )
+				strcat(equipstr, msg_txt(sd,1336)); // Body/Armor,
+			if( (it->equip&EQP_ARMS) == EQP_HAND_R )
+				strcat(equipstr, msg_txt(sd,1337)); // Right Hand,
+			if( (it->equip&EQP_ARMS) == EQP_HAND_L )
+				strcat(equipstr, msg_txt(sd,1338)); // Left Hand,
+			if( (it->equip&EQP_ARMS) == EQP_ARMS )
+				strcat(equipstr, msg_txt(sd,1339)); // Both Hands,
+			if( it->equip&EQP_SHOES )
+				strcat(equipstr, msg_txt(sd,1340)); // Shoes,
+			if( it->equip&EQP_ACC_R )
+				strcat(equipstr, msg_txt(sd,1341)); // Right Accessory,
+			if( (it->equip&EQP_HELM) == EQP_HEAD_LOW )
+				strcat(equipstr, msg_txt(sd,1342)); // Lower Head,
+			if( (it->equip&EQP_HELM) == EQP_HEAD_TOP )
+				strcat(equipstr, msg_txt(sd,1343)); // Top Head,
+			if( (it->equip&EQP_HELM) == (EQP_HEAD_LOW|EQP_HEAD_TOP) )
+				strcat(equipstr, msg_txt(sd,1344)); // Top/Lower Head,
+			if( (it->equip&EQP_HELM) == EQP_HEAD_MID )
+				strcat(equipstr, msg_txt(sd,1345)); // Mid Head,
+			if( (it->equip&EQP_HELM) == (EQP_HEAD_LOW|EQP_HEAD_MID) )
+				strcat(equipstr, msg_txt(sd,1346)); // Mid/Lower Head,
+			if( (it->equip&EQP_HELM) == EQP_HELM )
+				strcat(equipstr, msg_txt(sd,1347)); // Top/Mid/Lower Head,
+			if( (it->equip&EQP_COSTUME_HELM) == EQP_COSTUME_HEAD_LOW )
+				strcat(equipstr, msg_txt(sd,518));
+			if( (it->equip&EQP_COSTUME_HELM) == EQP_COSTUME_HEAD_TOP )
+				strcat(equipstr, msg_txt(sd,519));
+			if( (it->equip&EQP_COSTUME_HELM) == (EQP_COSTUME_HEAD_LOW|EQP_COSTUME_HEAD_TOP) )
+				strcat(equipstr, msg_txt(sd,520));
+			if( (it->equip&EQP_COSTUME_HELM) == EQP_COSTUME_HEAD_MID )
+				strcat(equipstr, msg_txt(sd,521));
+			if( (it->equip&EQP_COSTUME_HELM) == (EQP_COSTUME_HEAD_LOW|EQP_COSTUME_HEAD_MID) )
+				strcat(equipstr, msg_txt(sd,522));
+			if( (it->equip&EQP_COSTUME_HELM) == EQP_COSTUME_HELM )
+				strcat(equipstr, msg_txt(sd,523));
+			if( it->equip&EQP_COSTUME_GARMENT )
+				strcat(equipstr, msg_txt(sd,524));
+			//if( it->equip&EQP_COSTUME_FLOOR )
+				//strcat(equipstr, msg_txt(sd,525));
+			if( it->equip&EQP_AMMO )
+				strcat(equipstr, msg_txt(sd,526));
+			if( it->equip&EQP_SHADOW_ARMOR )
+				strcat(equipstr, msg_txt(sd,527));
+			if( (it->equip&EQP_SHADOW_ARMS) == EQP_SHADOW_WEAPON )
+				strcat(equipstr, msg_txt(sd,528));
+			if( (it->equip&EQP_SHADOW_ARMS) == EQP_SHADOW_SHIELD )
+				strcat(equipstr, msg_txt(sd,529));
+			if( (it->equip&EQP_SHADOW_ARMS) == EQP_SHADOW_ARMS )
+				strcat(equipstr, msg_txt(sd,530));
+			if( it->equip&EQP_SHADOW_SHOES )
+				strcat(equipstr, msg_txt(sd,531));
+			if( it->equip&EQP_SHADOW_ACC_R )
+				strcat(equipstr, msg_txt(sd,532));
+			if( it->equip&EQP_SHADOW_ACC_L )
+				strcat(equipstr, msg_txt(sd,533));
 			// remove final ', '
 			equipstr[strlen(equipstr) - 2] = '\0';
 			StringBuf_AppendStr(&buf, equipstr);
@@ -8495,29 +8529,19 @@ ACMD_FUNC(itemlist)
 		clif_displaymessage(fd, StringBuf_Value(&buf));
 		StringBuf_Clear(&buf);
 
-		if( it->card[0] == CARD0_PET )
-		{// pet egg
+		if( it->card[0] == CARD0_PET ) { // pet egg
 			if (it->card[3])
 				StringBuf_Printf(&buf, msg_txt(sd,1348), (unsigned int)MakeDWord(it->card[1], it->card[2])); //  -> (pet egg, pet id: %u, named)
 			else
 				StringBuf_Printf(&buf, msg_txt(sd,1349), (unsigned int)MakeDWord(it->card[1], it->card[2])); //  -> (pet egg, pet id: %u, unnamed)
-		}
-		else
-		if(it->card[0] == CARD0_FORGE)
-		{// forged item
+		} else if(it->card[0] == CARD0_FORGE) { // forged item
 			StringBuf_Printf(&buf, msg_txt(sd,1350), (unsigned int)MakeDWord(it->card[2], it->card[3]), it->card[1]>>8, it->card[1]&0x0f); //  -> (crafted item, creator id: %u, star crumbs %d, element %d)
-		}
-		else
-		if(it->card[0] == CARD0_CREATE)
-		{// created item
+		} else if(it->card[0] == CARD0_CREATE) { // created item
 			StringBuf_Printf(&buf, msg_txt(sd,1351), (unsigned int)MakeDWord(it->card[2], it->card[3])); //  -> (produced item, creator id: %u)
-		}
-		else
-		{// normal item
+		} else { // normal item
 			int counter2 = 0;
 
-			for( j = 0; j < itd->slot; ++j )
-			{
+			for( j = 0; j < itd->slot; ++j ) {
 				struct item_data* card;
 
 				if( it->card[j] == 0 || (card = itemdb_exists(it->card[j])) == NULL )
@@ -8691,29 +8715,22 @@ ACMD_FUNC(font)
 	nullpo_retr(-1,sd);
 
 	font_id = atoi(message);
-	if( font_id == 0 )
-	{
-		if( sd->user_font )
-		{
-			sd->user_font = 0;
+	if( font_id == 0 ) {
+		if( sd->status.font ) {
+			sd->status.font = 0;
 			clif_displaymessage(fd, msg_txt(sd,1356)); // Returning to normal font.
 			clif_font(sd);
-		}
-		else
-		{
+		} else {
 			clif_displaymessage(fd, msg_txt(sd,1357)); // Use @font <1-9> to change your message font.
 			clif_displaymessage(fd, msg_txt(sd,1358)); // Use 0 or no parameter to return to normal font.
 		}
-	}
-	else if( font_id < 0 || font_id > 9 )
+	} else if( font_id < 0 || font_id > 9 )
 		clif_displaymessage(fd, msg_txt(sd,1359)); // Invalid font. Use a value from 0 to 9.
-	else if( font_id != sd->user_font )
-	{
-		sd->user_font = font_id;
+	else if( font_id != sd->status.font ) {
+		sd->status.font = font_id;
 		clif_font(sd);
 		clif_displaymessage(fd, msg_txt(sd,1360)); // Font changed.
-	}
-	else
+	} else
 		clif_displaymessage(fd, msg_txt(sd,1361)); // Already using this font.
 
 	return 0;

Datei-Diff unterdrückt, da er zu groß ist
+ 307 - 238
src/map/battle.c


+ 1 - 0
src/map/battle.h

@@ -505,6 +505,7 @@ extern struct Battle_Config
 	int item_onfloor; // Whether to drop an undroppable item on the map or destroy it if inventory is full.
 	int bowling_bash_area;
 	int drop_rateincrease;
+	int feature_auction;
 	int feature_banking;
 	int vip_storage_increase;
 	int vip_base_exp_increase;

+ 3 - 2
src/map/cashshop.c

@@ -67,6 +67,7 @@ static int cashshop_parse_dbrow( char** str, const char* source, int line ){
 /*
  * Reads database from TXT format,
  * parses lines and sends them to parse_dbrow.
+ * TODO: Change to sv_readdb
  */
 static void cashshop_read_db_txt( void ){
 	const char* filename[] = { DBPATH"item_cash_db.txt", DBIMPORT"/item_cash_db.txt" };
@@ -130,7 +131,7 @@ static void cashshop_read_db_txt( void ){
 
 		fclose(fp);
 
-		ShowStatus( "Done reading '"CL_WHITE"%lu"CL_RESET"' entries in '"CL_WHITE"%s"CL_RESET"'.\n", count, filename[fi] );
+		ShowStatus( "Done reading '"CL_WHITE"%lu"CL_RESET"' entries in '"CL_WHITE"%s"CL_RESET"'.\n", count, path );
 	}
 }
 
@@ -185,7 +186,7 @@ static int cashshop_read_db_sql( void ){
 static void cashshop_read_db( void ){
 	if( db_use_sqldbs ){
 		cashshop_read_db_sql();
-	}else{
+	} else {
 		cashshop_read_db_txt();
 	}
 }

+ 5 - 2
src/map/chrif.c

@@ -1372,11 +1372,14 @@ int chrif_load_scdata(int fd) {
 
 	for (i = 0; i < count; i++) {
 		struct status_change_data *data = (struct status_change_data*)RFIFOP(fd,14 + i*sizeof(struct status_change_data));
+
 		status_change_start(NULL,&sd->bl, (sc_type)data->type, 10000, data->val1, data->val2, data->val3, data->val4, data->tick, 1|2|4|8);
 	}
+
+	pc_scdata_received(sd);
 #endif
 
-	if( sd->state.autotrade ){
+	if( sd->state.autotrade ) {
 		buyingstore_reopen( sd );
 		vending_reopen( sd );
 	}
@@ -1897,7 +1900,7 @@ int chrif_load_bsdata(int fd) {
 		calc = true;
 	}
 	if (calc)
-		status_calc_pc(sd,false);
+		status_calc_pc(sd,SCO_NONE);
 	return 0;
 }
 

+ 74 - 23
src/map/clif.c

@@ -649,7 +649,7 @@ void clif_authok(struct map_session_data *sd)
 	WFIFOB(fd, 9) = 5; // ignored
 	WFIFOB(fd,10) = 5; // ignored
 #if PACKETVER >= 20080102
-	WFIFOW(fd,11) = sd->user_font;  // FIXME: Font is currently not saved.
+	WFIFOW(fd,11) = sd->status.font;
 #endif
 	WFIFOSET(fd,packet_len(cmd));
 }
@@ -1076,7 +1076,7 @@ static int clif_set_unit_idle(struct block_list* bl, unsigned char* buffer, bool
 		return packet_len(WBUFW(buffer,0));
 #endif
 #if PACKETVER >= 20080102
-	WBUFW(buf,53) = sd?sd->user_font:0;
+	WBUFW(buf,53) = (sd ? sd->status.font : 0);
 #endif
 #if PACKETVER >= 20091103
 	memcpy((char*)WBUFP(buf,55), name, NAME_LENGTH);
@@ -1183,7 +1183,7 @@ static int clif_set_unit_walking(struct block_list* bl, struct unit_data* ud, un
 	WBUFB(buf,57) = (sd)? 5 : 0;
 	WBUFW(buf,58) = clif_setlevel(bl);
 #if PACKETVER >= 20080102
-	WBUFW(buf,60) = sd?sd->user_font:0;
+	WBUFW(buf,60) = (sd ? sd->status.font : 0);
 #endif
 #if PACKETVER >= 20091103
 	memcpy((char*)WBUFP(buf,62), name, NAME_LENGTH);
@@ -1729,11 +1729,10 @@ void clif_changemapserver(struct map_session_data* sd, unsigned short map_index,
 }
 
 
-void clif_blown(struct block_list *bl) //FIXME: This needs a better behaviour than just sending 2 position fixes
+void clif_blown(struct block_list *bl)
 {
-//Aegis packets says fixpos, but it's unsure whether slide works better or not.
-	clif_fixpos(bl);
 	clif_slide(bl, bl->x, bl->y);
+	//clif_fixpos(bl); //Aegis packets says fixpos, but it's unsure whether slide works better or not.
 }
 
 
@@ -2262,7 +2261,7 @@ void clif_additem(struct map_session_data *sd, int n, int amount, int fail)
 		WFIFOL(fd,offs+23)=sd->status.inventory[n].expire_time;
 #endif
 #if PACKETVER >= 20071002
-		WFIFOW(fd,offs+27)=sd->status.inventory[n].bound ? 2 : 0;
+		WFIFOW(fd,offs+27)=sd->status.inventory[n].bound ? BOUND_GUILD : 0;
 #endif
 	}
 
@@ -2368,7 +2367,7 @@ void clif_item_sub(unsigned char *buf, int n, int idx, struct item *i, struct it
 		clif_addcards(WBUFP(buf, n+12), i); //8B
 #if PACKETVER >= 20071002
 		WBUFL(buf,n+20)=i->expire_time;
-		WBUFW(buf,n+24)=i->bound ? 2 : 0;
+		WBUFW(buf,n+24)=i->bound ? BOUND_GUILD : 0;
 #endif
 #if PACKETVER >= 20100629
 		WBUFW(buf,n+26)= (id->equip&EQP_VISIBLE)?id->look:0;
@@ -8633,6 +8632,34 @@ void clif_messagecolor(struct block_list* bl, unsigned long color, const char* m
 	clif_send(buf, WBUFW(buf,2), bl, AREA_CHAT_WOC);
 }
 
+/**
+ * Notifies the client that the storage window is still open
+ *
+ * Should only be used in cases where the client closed the 
+ * storage window without server's consent
+ */
+void clif_refresh_storagewindow(struct map_session_data *sd) {
+	// Notify the client that the storage is open
+	if( sd->state.storage_flag == 1 ) {
+		storage_sortitem(sd->status.storage.items, ARRAYLENGTH(sd->status.storage.items));
+		clif_storagelist(sd, sd->status.storage.items, ARRAYLENGTH(sd->status.storage.items));
+		clif_updatestorageamount(sd, sd->status.storage.storage_amount, MAX_STORAGE);
+	}
+	// Notify the client that the gstorage is open otherwise it will
+	// remain locked forever and nobody will be able to access it
+	if( sd->state.storage_flag == 2 ) {
+		struct guild_storage *gstor = guild2storage2(sd->status.guild_id);
+
+		if( !gstor ) // Shouldn't happen. The information should already be at the map-server
+			intif_request_guild_storage(sd->status.account_id, sd->status.guild_id);
+		else {
+			storage_sortitem(gstor->items, ARRAYLENGTH(gstor->items));
+			clif_storagelist(sd, gstor->items, ARRAYLENGTH(gstor->items));
+			clif_updatestorageamount(sd, gstor->storage_amount, MAX_GUILD_STORAGE);
+		}
+	}
+}
+
 // refresh the client's screen, getting rid of any effects
 void clif_refresh(struct map_session_data *sd)
 {
@@ -8693,6 +8720,7 @@ void clif_refresh(struct map_session_data *sd)
 		pc_disguise(sd, 0);
 		pc_disguise(sd, disguise);
 	}
+	clif_refresh_storagewindow(sd);
 }
 
 
@@ -9759,7 +9787,7 @@ void clif_parse_LoadEndAck(int fd,struct map_session_data *sd)
 		}
 
 		map_iwall_get(sd); // Updates Walls Info on this Map to Client
-		status_calc_pc(sd, false); // Some conditions are map-dependent so we must recalculate
+		status_calc_pc(sd, SCO_NONE); // Some conditions are map-dependent so we must recalculate
 		sd->state.changemap = false;
 
 		// Instances do not need their own channels
@@ -10269,7 +10297,7 @@ void clif_parse_ActionRequest_sub(struct map_session_data *sd, int action_type,
 
 	if (sd->sc.count &&
 		(sd->sc.data[SC_TRICKDEAD] ||
-		sd->sc.data[SC_AUTOCOUNTER] ||
+		(sd->sc.data[SC_AUTOCOUNTER] && action_type != 0x07) ||
 		 sd->sc.data[SC_BLADESTOP] ||
 		 sd->sc.data[SC__MANHOLE] ||
 		 sd->sc.data[SC_CURSEDCIRCLE_ATKER] ||
@@ -11302,10 +11330,6 @@ void clif_parse_UseSkillToId(int fd, struct map_session_data *sd)
 		sd->state.storage_flag && !(tmp&INF_SELF_SKILL) ) //SELF skills can be used with the storage open, issue: 8027
 		return;
 
-	//Some self skills need to close the storage to work properly
-	if( skill_id == AL_TELEPORT && sd->state.storage_flag )
-		storage_storageclose(sd);
-
 	if( pc_issit(sd) )
 		return;
 
@@ -11499,7 +11523,8 @@ void clif_parse_UseSkillMap(int fd, struct map_session_data* sd)
 	if(skill_id != sd->menuskill_id)
 		return;
 
-	if( pc_cant_act(sd) ) {
+	//It is possible to use teleport with the storage window open bugreport:8027
+	if (pc_cant_act(sd) && !sd->state.storage_flag && skill_id != AL_TELEPORT) {
 		clif_menuskill_clear(sd);
 		return;
 	}
@@ -14069,18 +14094,27 @@ void clif_parse_HomMenu(int fd, struct map_session_data *sd)
 void clif_parse_AutoRevive(int fd, struct map_session_data *sd)
 {
 	int item_position = pc_search_inventory(sd, ITEMID_TOKEN_OF_SIEGFRIED);
+	int hpsp = 100;
 
-	if (item_position < 0)
-		return;
+	if (item_position < 0) {
+		if (sd->sc.data[SC_LIGHT_OF_REGENE])
+			hpsp = sd->sc.data[SC_LIGHT_OF_REGENE]->val2;
+		else
+			return;
+	}
 
 	if (sd->sc.data[SC_HELLPOWER]) //Cannot res while under the effect of SC_HELLPOWER.
 		return;
 
-	if (!status_revive(&sd->bl, 100, 100))
+	if (!status_revive(&sd->bl, hpsp, hpsp))
 		return;
 
-	clif_skill_nodamage(&sd->bl,&sd->bl,ALL_RESURRECTION,4,1);
-	pc_delitem(sd, item_position, 1, 0, 1, LOG_TYPE_CONSUME);
+	if (item_position < 0)
+		status_change_end(&sd->bl, SC_LIGHT_OF_REGENE, INVALID_TIMER);
+	else
+		pc_delitem(sd, item_position, 1, 0, 1, LOG_TYPE_CONSUME);
+
+	clif_skill_nodamage(&sd->bl, &sd->bl, ALL_RESURRECTION, 4, 1);
 }
 
 
@@ -14607,6 +14641,9 @@ void clif_Auction_openwindow(struct map_session_data *sd)
 	if( sd->state.storage_flag || sd->state.vending || sd->state.buyingstore || sd->state.trading )
 		return;
 
+	if( !battle_config.feature_auction )
+		return;
+
 	WFIFOHEAD(fd,packet_len(0x25f));
 	WFIFOW(fd,0) = 0x25f;
 	WFIFOL(fd,2) = 0;
@@ -14697,6 +14734,9 @@ void clif_parse_Auction_setitem(int fd, struct map_session_data *sd){
 	int amount = RFIFOL(fd,info->pos[1]); // Always 1
 	struct item_data *item;
 
+	if( !battle_config.feature_auction )
+		return;
+
 	if( sd->auction.amount > 0 )
 		sd->auction.amount = 0;
 
@@ -14774,6 +14814,9 @@ void clif_parse_Auction_register(int fd, struct map_session_data *sd)
 	struct item_data *item;
 	struct s_packet_db* info = &packet_db[sd->packet_ver][RFIFOW(fd,0)];
 
+	if( !battle_config.feature_auction )
+		return;
+
 	auction.price = RFIFOL(fd,info->pos[0]);
 	auction.buynow = RFIFOL(fd,info->pos[1]);
 	auction.hours = RFIFOW(fd,info->pos[2]);
@@ -14906,6 +14949,9 @@ void clif_parse_Auction_search(int fd, struct map_session_data* sd){
 	int price = RFIFOL(fd,info->pos[1]);  // FIXME: bug #5071
 	int page = RFIFOW(fd,info->pos[3]);
 
+	if( !battle_config.feature_auction )
+		return; 
+
 	clif_parse_Auction_cancelreg(fd, sd);
 
 	safestrncpy(search_text, (char*)RFIFOP(fd,info->pos[2]), sizeof(search_text));
@@ -14921,6 +14967,10 @@ void clif_parse_Auction_search(int fd, struct map_session_data* sd){
 void clif_parse_Auction_buysell(int fd, struct map_session_data* sd)
 {
 	short type = RFIFOW(fd,packet_db[sd->packet_ver][RFIFOW(fd,0)].pos[0]) + 6;
+
+	if( !battle_config.feature_auction )
+		return;
+
 	clif_parse_Auction_cancelreg(fd, sd);
 
 	intif_Auction_requestlist(sd->status.char_id, type, 0, "", 1);
@@ -15855,7 +15905,7 @@ void clif_font(struct map_session_data *sd)
 	nullpo_retv(sd);
 	WBUFW(buf,0) = 0x2ef;
 	WBUFL(buf,2) = sd->bl.id;
-	WBUFW(buf,6) = sd->user_font;
+	WBUFW(buf,6) = sd->status.font;
 	clif_send(buf, packet_len(0x2ef), &sd->bl, AREA);
 #endif
 }
@@ -16703,7 +16753,7 @@ int clif_spellbook_list(struct map_session_data *sd)
 		if( itemdb_is_spellbook(sd->status.inventory[i].nameid) )
 		{
 			WFIFOW(fd, c * 2 + 4) = sd->status.inventory[i].nameid;
-			c ++;
+			c++;
 		}
 	}
 
@@ -17001,7 +17051,7 @@ void clif_ackworldinfo(struct map_session_data* sd) {
 	WFIFOHEAD(fd,packet_len(0x979));
 	WFIFOW(fd,0)=0x979;
 	//AID -> world name ?
-	safestrncpy((char*)WFIFOP(fd,2), '\0' /* World name */, 24);
+	safestrncpy((char*)WFIFOP(fd,2), "" /* World name */, 24);
 	safestrncpy((char*)WFIFOP(fd,26), sd->status.name, NAME_LENGTH);
 	WFIFOSET(fd,packet_len(0x979));
 }
@@ -18152,6 +18202,7 @@ void do_init_clif(void) {
 	const char* colors[COLOR_MAX] = {
 		"0xFF0000",
 		"0xFFFFFF",
+		"0xFFFF00",
 	};
 	int i;
 	/**

+ 2 - 1
src/map/clif.h

@@ -460,6 +460,7 @@ void clif_changechatowner(struct chat_data* cd, struct map_session_data* sd);	//
 void clif_clearchat(struct chat_data *cd,int fd);	// area or fd
 void clif_leavechat(struct chat_data* cd, struct map_session_data* sd, bool flag);	// chat
 void clif_changechatstatus(struct chat_data* cd);	// chat
+void clif_refresh_storagewindow(struct map_session_data *sd);
 void clif_refresh(struct map_session_data *sd);	// self
 
 void clif_fame_blacksmith(struct map_session_data *sd, int points);
@@ -852,7 +853,7 @@ void clif_monster_hp_bar( struct mob_data* md, int fd );
 enum clif_colors {
 	COLOR_RED,
 	COLOR_WHITE,
-
+	COLOR_YELLOW,
 	COLOR_MAX
 };
 unsigned long color_table[COLOR_MAX];

+ 5 - 5
src/map/elemental.c

@@ -263,7 +263,7 @@ int elemental_data_received(struct s_elemental *ele, bool flag) {
 		ed->bl.y = ed->ud.to_y;
 
 		map_addiddb(&ed->bl);
-		status_calc_elemental(ed,1);
+		status_calc_elemental(ed,SCO_FIRST);
 		ed->last_spdrain_time = ed->last_thinktime = gettick();
 		ed->summon_timer = INVALID_TIMER;
 		ed->masterteleport_timer = INVALID_TIMER;
@@ -561,19 +561,19 @@ int elemental_unlocktarget(struct elemental_data *ed) {
 	return 0;
 }
 
-int elemental_skillnotok(uint16 skill_id, struct elemental_data *ed) {
-	int idx = skill_get_index(skill_id);
+bool elemental_skillnotok(uint16 skill_id, struct elemental_data *ed) {
+	uint16 idx = skill_get_index(skill_id);
 	nullpo_retr(1,ed);
 
 	if (idx == 0)
-		return 1; // invalid skill id
+		return false; // invalid skill id
 
 	return skill_isNotOk(skill_id,ed->master);
 }
 
 struct skill_condition elemental_skill_get_requirements(uint16 skill_id, uint16 skill_lv){
 	struct skill_condition req;
-	int idx = skill_get_index(skill_id);
+	uint16 idx = skill_get_index(skill_id);
 
 	memset(&req,0,sizeof(req));
 

+ 1 - 1
src/map/elemental.h

@@ -92,7 +92,7 @@ void elemental_summon_stop(struct elemental_data *ed);
 int elemental_get_lifetime(struct elemental_data *ed);
 
 int elemental_unlocktarget(struct elemental_data *ed);
-int elemental_skillnotok(uint16 skill_id, struct elemental_data *ed);
+bool elemental_skillnotok(uint16 skill_id, struct elemental_data *ed);
 int elemental_set_target( struct map_session_data *sd, struct block_list *bl );
 int elemental_clean_single_effect(struct elemental_data *ed, uint16 skill_id);
 int elemental_clean_effect(struct elemental_data *ed);

+ 2 - 2
src/map/guild.c

@@ -1807,7 +1807,7 @@ int guild_break(struct map_session_data *sd,char *name) {
 	//Guild bound item check - Removes the bound flag
 	j = pc_bound_chk(sd,2,idxlist);
 	for(i=0;i<j;i++)
-		sd->status.inventory[idxlist[i]].bound = 0;
+		sd->status.inventory[idxlist[i]].bound = BOUND_NONE;
 #endif
 
 	intif_guild_break(g->guild_id);
@@ -1876,7 +1876,7 @@ int guild_castledatasave(int castle_id, int index, int value) {
 		for (i = 0; i < MAX_GUARDIANS; i++){
 			struct mob_data *gd;
 			if (gc->guardian[i].visible && (gd = map_id2md(gc->guardian[i].id)) != NULL)
-				status_calc_mob(gd, 0);
+				status_calc_mob(gd, SCO_NONE);
 		}
 		break;
 	}

+ 30 - 9
src/map/homunculus.c

@@ -300,7 +300,7 @@ void hom_skillup(struct homun_data *hd,uint16 skill_id)
 	{
 		hd->homunculus.hskill[i].lv++;
 		hd->homunculus.skillpts-- ;
-		status_calc_homunculus(hd,0);
+		status_calc_homunculus(hd, SCO_NONE);
 		if (hd->master) {
 			clif_homskillup(hd->master, skill_id);
 			clif_hominfo(hd->master,hd,0);
@@ -417,8 +417,7 @@ int hom_evolution(struct homun_data *hd)
 	struct map_session_data *sd;
 	nullpo_ret(hd);
 
-	if(!hd->homunculusDB->evo_class || hd->homunculus.class_ == hd->homunculusDB->evo_class)
-	{
+	if(!hd->homunculusDB->evo_class || hd->homunculus.class_ == hd->homunculusDB->evo_class) {
 		clif_emotion(&hd->bl, E_SWT);
 		return 0 ;
 	}
@@ -456,7 +455,7 @@ int hom_evolution(struct homun_data *hd)
 	//status_Calc flag&1 will make current HP/SP be reloaded from hom structure
 	hom->hp = hd->battle_status.hp;
 	hom->sp = hd->battle_status.sp;
-	status_calc_homunculus(hd,1);
+	status_calc_homunculus(hd, SCO_FIRST);
 
 	if (!(battle_config.hom_setting&0x2))
 		skill_unit_move(&sd->hd->bl,gettick(),1); // apply land skills immediately
@@ -510,7 +509,7 @@ int hom_mutate(struct homun_data *hd, int homun_id)
 	hom->hp = hd->battle_status.hp;
 	hom->sp = hd->battle_status.sp;
 	hom->prev_class = prev_class;
-	status_calc_homunculus(hd,1);
+	status_calc_homunculus(hd, SCO_FIRST);
 
 	if (!(battle_config.hom_setting&0x2))
 		skill_unit_move(&sd->hd->bl,gettick(),1); // apply land skills immediately
@@ -556,7 +555,7 @@ int hom_gainexp(struct homun_data *hd,int exp)
 		hd->homunculus.exp = 0 ;
 
 	clif_specialeffect(&hd->bl,568,AREA);
-	status_calc_homunculus(hd,0);
+	status_calc_homunculus(hd, SCO_NONE);
 	status_percent_heal(&hd->bl, 100, 100);
 	return 0;
 }
@@ -785,7 +784,8 @@ int hom_search(int key,int type)
 }
 
 // Create homunc structure
-void hom_alloc(struct map_session_data *sd, struct s_homunculus *hom) {
+void hom_alloc(struct map_session_data *sd, struct s_homunculus *hom)
+{
 	struct homun_data *hd;
 	int i = 0;
 
@@ -823,7 +823,8 @@ void hom_alloc(struct map_session_data *sd, struct s_homunculus *hom) {
 	hd->bl.y = hd->ud.to_y;
 
 	map_addiddb(&hd->bl);
-	status_calc_homunculus(hd,1);
+	status_calc_homunculus(hd, SCO_FIRST);
+	status_percent_heal(&hd->bl, 100, 100);
 
 	hd->hungry_timer = INVALID_TIMER;
 	hd->masterteleport_timer = INVALID_TIMER;
@@ -1093,13 +1094,33 @@ int hom_shuffle(struct homun_data *hd)
 	memcpy(&hd->homunculus.hskill, &b_skill, sizeof(b_skill));
 	hd->homunculus.skillpts = skillpts;
 	clif_homskillinfoblock(sd);
-	status_calc_homunculus(hd,0);
+	status_calc_homunculus(hd, SCO_NONE);
 	status_percent_heal(&hd->bl, 100, 100);
 	clif_specialeffect(&hd->bl,568,AREA);
 
 	return 1;
 }
 
+uint8 hom_get_intimacy_grade(struct homun_data *hd)
+{
+	unsigned int val = hd->homunculus.intimacy / 100;
+
+	if( val > 100 ) {
+		if( val > 250 ) {
+			if( val > 750 ) {
+				if ( val > 900 )
+					return 4;
+				else
+					return 3;
+			} else
+				return 2;
+		} else
+			return 1;
+	}
+
+	return 0;
+}
+
 static bool read_homunculusdb_sub(char* str[], int columns, int current)
 {
 	int classid;

+ 2 - 0
src/map/homunculus.h

@@ -141,6 +141,8 @@ void hom_reload(void);
 int hom_addspiritball(TBL_HOM *hd, int max);
 int hom_delspiritball(TBL_HOM *hd, int count, int type);
 
+uint8 hom_get_intimacy_grade(struct homun_data *hd);
+
 void do_final_homunculus(void);
 void do_init_homunculus(void);
 

+ 155 - 184
src/map/itemdb.c

@@ -19,18 +19,20 @@
 #include <string.h>
 
 static struct item_data* itemdb_array[MAX_ITEMDB];
-static DBMap*            itemdb_other;// int nameid -> struct item_data*
-
-static struct s_item_group_db itemgroup_db[MAX_ITEMGROUP];
-
 struct item_data dummy_item; //This is the default dummy item used for non-existant items. [Skotlex]
 
+static DBMap* itemdb_other;// int nameid -> struct item_data*
 static DBMap *itemdb_combo;
+static DBMap *itemdb_group;
 
 DBMap * itemdb_get_combodb(){
 	return itemdb_combo;
 }
 
+DBMap * itemdb_get_groupdb() {
+	return itemdb_group;
+}
+
 /**
  * Search for item name
  * name = item alias, so we should find items aliases first. if not found then look for "jname" (full name)
@@ -150,9 +152,10 @@ int itemdb_searchname_array(struct item_data** data, int size, const char *str)
 */
 unsigned short itemdb_searchrandomid(uint16 group_id, uint8 sub_group)
 {
+	struct s_item_group_db *group = (struct s_item_group_db *) idb_get(itemdb_group, group_id);
 	if (sub_group)
 		sub_group -= 1;
-	if (!group_id || group_id >= MAX_ITEMGROUP || !&itemgroup_db[group_id]) {
+	if (!group) {
 		ShowError("itemdb_searchrandomid: Invalid group id %d\n", group_id);
 		return UNKNOWN_ITEM_ID;
 	}
@@ -160,8 +163,8 @@ unsigned short itemdb_searchrandomid(uint16 group_id, uint8 sub_group)
 		ShowError("itemdb_searchrandomid: Invalid sub_group %d\n", sub_group+1);
 		return UNKNOWN_ITEM_ID;
 	}
-	if (&itemgroup_db[group_id].random[sub_group] && itemgroup_db[group_id].random[sub_group].data_qty)
-		return itemgroup_db[group_id].random[sub_group].data[rand()%itemgroup_db[group_id].random[sub_group].data_qty].nameid;
+	if (&group->random[sub_group] && group->random[sub_group].data_qty)
+		return group->random[sub_group].data[rand()%group->random[sub_group].data_qty].nameid;
 
 	ShowError("itemdb_searchrandomid: No item entries for group id %d and sub group %d\n", group_id, sub_group+1);
 	return UNKNOWN_ITEM_ID;
@@ -177,9 +180,11 @@ unsigned short itemdb_searchrandomid(uint16 group_id, uint8 sub_group)
 */
 uint16 itemdb_get_randgroupitem_count(uint16 group_id, uint8 sub_group, uint16 nameid) {
 	uint16 i, amt = 1;
+	struct s_item_group_db *group = (struct s_item_group_db *) idb_get(itemdb_group, group_id);
+	
 	if (sub_group)
 		sub_group -= 1;
-	if (!group_id || group_id >= MAX_ITEMGROUP || !&itemgroup_db[group_id]) {
+	if (!group) {
 		ShowError("itemdb_get_randgroupitem_count: Invalid group id %d\n", group_id);
 		return amt;
 	}
@@ -187,11 +192,12 @@ uint16 itemdb_get_randgroupitem_count(uint16 group_id, uint8 sub_group, uint16 n
 		ShowError("itemdb_get_randgroupitem_count: Invalid sub_group id %d\n", group_id+1);
 		return amt;
 	}
-	if (!(&itemgroup_db[group_id].random[sub_group]) || !itemgroup_db[group_id].random[sub_group].data_qty)
+	if (!(&group->random[sub_group]) || !group->random[sub_group].data_qty)
 		return amt;
-	ARR_FIND(0,itemgroup_db[group_id].random[sub_group].data_qty,i,itemgroup_db[group_id].random[sub_group].data[i].nameid == nameid);
-	if (i < itemgroup_db[group_id].random[sub_group].data_qty)
-		amt = itemgroup_db[group_id].random[sub_group].data[i].amount;
+	for (i = 0; i < group->random[sub_group].data_qty; i++) {
+		if (group->random[sub_group].data[i].nameid == nameid)
+			return group->random[sub_group].data[i].amount;
+	}
 	return amt;
 }
 
@@ -201,37 +207,37 @@ uint16 itemdb_get_randgroupitem_count(uint16 group_id, uint8 sub_group, uint16 n
 * @param group_id: The group ID of item that obtained by player
 * @param *group: struct s_item_group from itemgroup_db[group_id].random[idx] or itemgroup_db[group_id].must[sub_group][idx]
 */
-static void itemdb_pc_get_itemgroup_sub(struct map_session_data *sd, uint16 group_id, struct s_item_group *group) {
+static void itemdb_pc_get_itemgroup_sub(struct map_session_data *sd, struct s_item_group_entry *data) {
 	uint16 i;
 	struct item tmp;
 
-	nullpo_retv(group);
+	nullpo_retv(data);
 
-	memset(&tmp,0,sizeof(tmp));
+	memset(&tmp, 0, sizeof(tmp));
 
-	tmp.nameid = group->nameid;
-	tmp.amount = (itemdb_isstackable(group->nameid)) ? group->amount : 1;
-	tmp.bound = group->bound;
+	tmp.nameid = data->nameid;
+	tmp.amount = (itemdb_isstackable(data->nameid)) ? data->amount : 1;
+	tmp.bound = data->bound;
 	tmp.identify = 1;
-	tmp.expire_time = (group->duration) ? (unsigned int)(time(NULL) + group->duration*60) : 0;
-	if (group->isNamed) {
-		tmp.card[0] = itemdb_isequip(group->nameid) ? CARD0_FORGE : CARD0_CREATE;
+	tmp.expire_time = (data->duration) ? (unsigned int)(time(NULL) + data->duration*60) : 0;
+	if (data->isNamed) {
+		tmp.card[0] = itemdb_isequip(data->nameid) ? CARD0_FORGE : CARD0_CREATE;
 		tmp.card[1] = 0;
 		tmp.card[2] = GetWord(sd->status.char_id, 0);
 		tmp.card[3] = GetWord(sd->status.char_id, 1);
 	}
-	//Do loop for non-stackable item
-	for (i = 0; i < group->amount; i++) {
-		int flag;
-		if ((flag = pc_additem(sd,&tmp,tmp.amount,LOG_TYPE_SCRIPT)))
-			clif_additem(sd,0,0,flag);
-		else if (!flag && group->isAnnounced) { ///TODO: Move this broadcast to proper behavior (it should on at different packet)
+	// Do loop for non-stackable item
+	for (i = 0; i < data->amount; i++) {
+		char flag;
+		if ((flag = pc_additem(sd, &tmp, tmp.amount, LOG_TYPE_SCRIPT)))
+			clif_additem(sd, 0, 0, flag);
+		else if (!flag && data->isAnnounced) { ///TODO: Move this broadcast to proper behavior (it should on at different packet)
 			char output[CHAT_SIZE_MAX];
-			sprintf(output,msg_txt(NULL,717),sd->status.name,itemdb_jname(group->nameid),itemdb_jname(sd->itemid));
-			clif_broadcast(&sd->bl,output,strlen(output),BC_DEFAULT,ALL_CLIENT);
+			sprintf(output, msg_txt(NULL, 717), sd->status.name, itemdb_jname(data->nameid), itemdb_jname(sd->itemid));
+			clif_broadcast(&sd->bl, output, strlen(output), BC_DEFAULT, ALL_CLIENT);
 			//clif_broadcast_obtain_special_item();
 		}
-		if (itemdb_isstackable(group->nameid))
+		if (itemdb_isstackable(data->nameid))
 			break;
 	}
 }
@@ -244,53 +250,36 @@ static void itemdb_pc_get_itemgroup_sub(struct map_session_data *sd, uint16 grou
 */
 char itemdb_pc_get_itemgroup(uint16 group_id, struct map_session_data *sd) {
 	uint16 i = 0;
+	struct s_item_group_db *group;
 
 	nullpo_retr(1,sd);
 	
-	if (!group_id || group_id >= MAX_ITEMGROUP) {
+	if (!(group = (struct s_item_group_db *) idb_get(itemdb_group, group_id))) {
 		ShowError("itemdb_pc_get_itemgroup: Invalid group id '%d' specified.",group_id);
 		return 2;
 	}
 	
-	//Get the 'must' item(s)
-	if (itemgroup_db[group_id].must_qty)
-		for (i = 0; i < itemgroup_db[group_id].must_qty; i++)
-			if (&itemgroup_db[group_id].must[i] && itemdb_exists(itemgroup_db[group_id].must[i].nameid))
-				itemdb_pc_get_itemgroup_sub(sd,group_id,&itemgroup_db[group_id].must[i]);
+	// Get the 'must' item(s)
+	if (group->must_qty) {
+		for (i = 0; i < group->must_qty; i++)
+			if (&group->must[i])
+				itemdb_pc_get_itemgroup_sub(sd,&group->must[i]);
+	}
 
-	//Get the 'random' item each random group
+	// Get the 'random' item each random group
 	for (i = 0; i < MAX_ITEMGROUP_RANDGROUP; i++) {
 		uint16 rand;
-		if (!(&itemgroup_db[group_id].random[i]) || !itemgroup_db[group_id].random[i].data_qty) //Skip empty random group
+		if (!(&group->random[i]) || !group->random[i].data_qty) //Skip empty random group
 			continue;
-		rand = rnd()%itemgroup_db[group_id].random[i].data_qty;
-		//Woops, why is the data empty? Every check should be done when load the item group! So this is bad day for the player :P
-		if (!&itemgroup_db[group_id].random[i].data[rand] || !itemgroup_db[group_id].random[i].data[rand].nameid) {
+		rand = rnd()%group->random[i].data_qty;
+		if (!(&group->random[i].data[rand]) || !group->random[i].data[rand].nameid)
 			continue;
-		}
-		if (itemdb_exists(itemgroup_db[group_id].random[i].data[rand].nameid))
-			itemdb_pc_get_itemgroup_sub(sd,group_id,&itemgroup_db[group_id].random[i].data[rand]);
+		itemdb_pc_get_itemgroup_sub(sd,&group->random[i].data[rand]);
 	}
 
 	return 0;
 }
 
-/*==========================================
- * Calculates total item-group related bonuses for the given item
- *------------------------------------------*/
-int itemdb_group_bonus(struct map_session_data* sd, int itemid)
-{
-	int bonus = 0, i, j;
-	for (i=0; i < MAX_ITEMGROUP; i++) {
-		if (!sd->itemgrouphealrate[i])
-			continue;
-		ARR_FIND(0,itemgroup_db[i].random[0].data_qty,j,itemgroup_db[i].random[0].data[j].nameid == itemid );
-		if( j < itemgroup_db[i].random[0].data_qty )
-			bonus += sd->itemgrouphealrate[i];
-	}
-	return bonus;
-}
-
 /// Searches for the item_data.
 /// Returns the item_data or NULL if it does not exist.
 struct item_data* itemdb_exists(int nameid)
@@ -482,30 +471,14 @@ struct item_data* itemdb_search(int nameid)
 	return id;
 }
 
-/*==========================================
- * Returns if given item is a player-equippable piece.
- *------------------------------------------*/
-bool itemdb_isequip(int nameid)
-{
-	int type=itemdb_type(nameid);
-	switch (type) {
-		case IT_WEAPON:
-		case IT_ARMOR:
-		case IT_AMMO:
-		case IT_SHADOWGEAR:
-			return true;
-		default:
-			return false;
-	}
-}
-
-/*==========================================
- * Alternate version of itemdb_isequip
- *------------------------------------------*/
-bool itemdb_isequip2(struct item_data *data)
+/** Checks if item is equip type or not
+* @param id Item data
+* @return True if item is equip, false otherwise
+*/
+bool itemdb_isequip2(struct item_data *id)
 {
-	nullpo_ret(data);
-	switch(data->type) {
+	nullpo_ret(id);
+	switch(id->type) {
 		case IT_WEAPON:
 		case IT_ARMOR:
 		case IT_AMMO:
@@ -516,31 +489,14 @@ bool itemdb_isequip2(struct item_data *data)
 	}
 }
 
-/*==========================================
- * Returns if given item's type is stackable.
- *------------------------------------------*/
-bool itemdb_isstackable(uint16 nameid)
-{
-  uint8 type = itemdb_type(nameid);
-  switch(type) {
-	  case IT_WEAPON:
-	  case IT_ARMOR:
-	  case IT_PETEGG:
-	  case IT_PETARMOR:
-	  case IT_SHADOWGEAR:
-		  return false;
-	  default:
-		  return true;
-  }
-}
-
-/*==========================================
- * Alternate version of itemdb_isstackable
- *------------------------------------------*/
-bool itemdb_isstackable2(struct item_data *data)
+/** Checks if item is stackable or not
+* @param id Item data
+* @return True if item is stackable, false otherwise
+*/
+bool itemdb_isstackable2(struct item_data *id)
 {
-  nullpo_ret(data);
-  switch(data->type) {
+  nullpo_ret(id);
+  switch(id->type) {
 	  case IT_WEAPON:
 	  case IT_ARMOR:
 	  case IT_PETEGG:
@@ -672,11 +628,14 @@ static void itemdb_read_itemgroup_sub(const char* filename, bool silent)
 	}
 	
 	while (fgets(line,sizeof(line),fp)) {
-		uint16 nameid;
-		int j, group_id, prob = 1, amt = 1, rand_group = 1, announced = 0, dur = 0, named = 0, bound = 0;
-		char *str[3], *p;
+		int group_id = -1;
+		unsigned int j, prob = 1;
+		uint16 nameid, amt = 1, dur = 0;
+		uint8 rand_group = 1;
+		char *str[9], *p, announced = 0, named = 0, bound = BOUND_NONE;
+		struct s_item_group_random *random = NULL;
+		struct s_item_group_db *group = NULL;
 		bool found = false;
-		struct s_item_group_random *random;
 
 		ln++;
 		if (line[0] == '/' && line[1] == '/')
@@ -692,44 +651,45 @@ static void itemdb_read_itemgroup_sub(const char* filename, bool silent)
 			}
 		}
 		memset(str,0,sizeof(str));
-		for (j = 0, p = line; j < 3 && p;j++) {
+		for (j = 0, p = line; j < 9 && p;j++) {
 			str[j] = p;
-			if (j == 2)
-				sscanf(str[j],"%d,%d,%d,%d,%d,%d,%d",&prob,&amt,&rand_group,&announced,&dur,&named,&bound);
 			p = strchr(p,',');
 			if (p) *p++=0;
 		}
-		if (str[0] == NULL)
+		if (str[0] == NULL) //Empty Group ID
 			continue;
 		if (j < 3) {
-			if (j > 1) //Or else it barks on blank lines...
+			if (j > 1) // Or else it barks on blank lines...
 				ShowWarning("itemdb_read_itemgroup: Insufficient fields for entry at %s:%d\n", filename, ln);
 			continue;
 		}
 
-		//Checking group_id
+		// Checking group_id
 		trim(str[0]);
 		if (ISDIGIT(str[0][0]))
 			group_id = atoi(str[0]);
-		else //Try reads group id by const
-			script_get_constant(trim(str[0]),&group_id);
-		if (!group_id || group_id >= MAX_ITEMGROUP) {
-			ShowWarning("itemdb_read_itemgroup: Cannot save '%s' because invalid group id or group db is overflow in %s:%d\n", str[0], filename, ln);
+		else // Try reads group id by const
+			script_get_constant(trim(str[0]), &group_id);
+
+		if (group_id < 0) {
+			ShowWarning("itemdb_read_itemgroup: Invlaid Group ID '%s' (%s:%d)\n", str[0], filename, ln);
 			continue;
 		}
 
-		//Checking sub group
+		// Checking sub group
+		prob = atoi(str[2]);
+		if (str[4] != NULL) rand_group = atoi(str[4]);
 		if (rand_group < 0 || rand_group > MAX_ITEMGROUP_RANDGROUP) {
-			ShowWarning("itemdb_read_itemgroup: Invalid sub group %d for group '%s' in %s:%d\n", rand_group, str[0], filename, ln);
+			ShowWarning("itemdb_read_itemgroup: Invalid sub group '%d' for group '%s' in %s:%d\n", rand_group, str[0], filename, ln);
 			continue;
 		}
 
-		if (rand_group && prob < 1) {
-			ShowWarning("itemdb_read_itemgroup: Invalid probaility for group '%s' sub: %d in %s:%d\n", str[0], rand_group, filename, ln);
+		if (rand_group != 0 && prob < 1) {
+			ShowWarning("itemdb_read_itemgroup: Random item must has probability. Group '%s' in %s:%d\n", str[0], filename, ln);
 			continue;
 		}
 
-		//Checking item
+		// Checking item
 		trim(str[1]);
 		if (ISDIGIT(str[1][0]) && itemdb_exists((nameid = atoi(str[1]))))
 			found = true;
@@ -742,27 +702,38 @@ static void itemdb_read_itemgroup_sub(const char* filename, bool silent)
 			continue;
 		}
 
-		amt = cap_value(amt,1,MAX_AMOUNT);
-		dur = cap_value(dur,0,UINT16_MAX);
-		bound = cap_value(bound,0,4);
+		if (str[3] != NULL) amt = cap_value(atoi(str[3]),1,MAX_AMOUNT);
+		if (str[5] != NULL) announced = atoi(str[5]);
+		if (str[6] != NULL) dur = cap_value(atoi(str[6]),0,UINT16_MAX);
+		if (str[7] != NULL) named = atoi(str[7]);
+		if (str[8] != NULL) bound = cap_value(atoi(str[8]),BOUND_NONE,BOUND_MAX-1);
+
+		found = true;
+		if (!(group = (struct s_item_group_db *) idb_get(itemdb_group, group_id))) {
+			found = false;
+			CREATE(group, struct s_item_group_db, 1);
+			group->id = group_id;
+		}
 
-		//Must item (rand_group == 0), place it here
+		// Must item (rand_group == 0), place it here
 		if (!rand_group) {
-			uint16 idx = itemgroup_db[group_id].must_qty;
+			uint16 idx = group->must_qty;
 			if (!idx)
-				CREATE(itemgroup_db[group_id].must,struct s_item_group,1);
+				CREATE(group->must, struct s_item_group_entry, 1);
 			else
-				RECREATE(itemgroup_db[group_id].must,struct s_item_group,idx+1);
-
-			itemgroup_db[group_id].must[idx].nameid = nameid;
-			itemgroup_db[group_id].must[idx].amount = amt;
-			itemgroup_db[group_id].must[idx].isAnnounced = announced;
-			itemgroup_db[group_id].must[idx].duration = dur;
-			itemgroup_db[group_id].must[idx].isNamed = named;
-			itemgroup_db[group_id].must[idx].bound = bound;
-			itemgroup_db[group_id].must_qty++;
-			//If 'must' item isn't set as random item, skip the next process
+				RECREATE(group->must, struct s_item_group_entry, idx+1);
+
+			group->must[idx].nameid = nameid;
+			group->must[idx].amount = amt;
+			group->must[idx].isAnnounced = announced;
+			group->must[idx].duration = dur;
+			group->must[idx].isNamed = named;
+			group->must[idx].bound = bound;
+			group->must_qty++;
+			// If 'must' item isn't set as random item, skip the next process
 			if (!prob) {
+				if (!found)
+					idb_put(itemdb_group, group->id, group);
 				entries++;
 				continue;
 			}
@@ -771,15 +742,16 @@ static void itemdb_read_itemgroup_sub(const char* filename, bool silent)
 		else
 			rand_group -= 1;
 
-		random = &itemgroup_db[group_id].random[rand_group];
+		random = &group->random[rand_group];
 
-		//Check, if the entry for this random group already created or not
+		// Check, if the entry for this random group already created or not
 		if (!random->data_qty) {
-			CREATE(random->data,struct s_item_group,prob);
+			CREATE(random->data, struct s_item_group_entry, prob);
 			random->data_qty = 0;
 		}
 		else
-			RECREATE(random->data,struct s_item_group,random->data_qty+prob);
+			RECREATE(random->data, struct s_item_group_entry, random->data_qty+prob);
+
 		//Now put the entry to its rand_group
 		for (j = random->data_qty; j < random->data_qty+prob; j++) {
 			random->data[j].nameid = nameid;
@@ -790,6 +762,9 @@ static void itemdb_read_itemgroup_sub(const char* filename, bool silent)
 			random->data[j].bound = bound;
 		}
 		random->data_qty += prob;
+
+		if (!found)
+			idb_put(itemdb_group, group->id, group);
 		entries++;
 	}
 	fclose(fp);
@@ -978,23 +953,25 @@ static bool itemdb_read_nouse(char* fields[], int columns, int current) {
 
 /** Misc Item flags
 * <item_id>,<flag>
-* &1 - Log as dead branch
+* &1 - As dead branch item
 * &2 - As item container
 */
 static bool itemdb_read_flag(char* fields[], int columns, int current) {
 	uint16 nameid = atoi(fields[0]);
-	uint8 flag = atoi(fields[1]);
+	uint8 flag;
+	bool set;
 	struct item_data *id;
 
 	if (!(id = itemdb_exists(nameid))) {
 		ShowError("itemdb_read_flag: Invalid item item with id %d\n", nameid);
 		return true;
 	}
+	
+	flag = abs(atoi(fields[1]));
+	set = atoi(fields[1]) > 0;
 
-	if (flag&1)
-		id->flag.dead_branch = 1;
-	if (flag&2)
-		id->flag.group = 1;
+	if (flag&1) id->flag.dead_branch = set ? 1 : 0;
+	if (flag&2) id->flag.group = set ? 1 : 0;
 
 	return true;
 }
@@ -1589,8 +1566,6 @@ static void itemdb_read(void) {
 		itemdb_read_sqldb();
 	else
 		itemdb_readdb();
-
-	memset(&itemgroup_db, 0, sizeof(itemgroup_db));
 	
 	for(i=0; i<ARRAYLENGTH(dbsubpath); i++){
 		uint8 n1 = strlen(db_path)+strlen(dbsubpath[i])+1;
@@ -1647,7 +1622,8 @@ static void destroy_item_data(struct item_data* self, bool free_self) {
 		for( i = 0; i < self->combos_count; i++ ) {
 			if( !self->combos[i]->isRef ) {
 				aFree(self->combos[i]->nameid);
-				script_free_code(self->combos[i]->script);
+				if (self->combos[i]->script)
+					script_free_code(self->combos[i]->script);
 			}
 			aFree(self->combos[i]);
 		}
@@ -1675,6 +1651,24 @@ static int itemdb_final_sub(DBKey key, DBData *data, va_list ap)
 	return 0;
 }
 
+static int itemdb_group_free(DBKey key, DBData *data, va_list ap) {
+	struct s_item_group_db *group = db_data2ptr(data);
+	uint8 j;
+	if (!group)
+		return 0;
+	if (group->must_qty)
+		aFree(group->must);
+	group->must_qty = 0;
+	for (j = 0; j < MAX_ITEMGROUP_RANDGROUP; j++) {
+		if (!group->random[j].data_qty || !(&group->random[j]))
+			continue;
+		aFree(group->random[j].data);
+		group->random[j].data_qty = 0;
+	}
+	aFree(group);
+	return 0;
+}
+
 /**
 * Reload Item DB
 */
@@ -1685,23 +1679,12 @@ void itemdb_reload(void) {
 	int i,d,k;
 
 	// clear the previous itemdb data
-	for( i = 0; i < ARRAYLENGTH(itemdb_array); ++i )
+	for( i = 0; i < ARRAYLENGTH(itemdb_array); ++i ) {
 		if( itemdb_array[i] )
 			destroy_item_data(itemdb_array[i], true);
-
-	for (i = 0; i < MAX_ITEMGROUP; i++) {
-		uint8 j;
-		if (!(&itemgroup_db[i]))
-			continue;
-		if (itemgroup_db[i].must_qty)
-			aFree(itemgroup_db[i].must);
-		for (j = 0; j < MAX_ITEMGROUP_RANDGROUP; j++) {
-			if (!(&itemgroup_db[i].random[j]) || !itemgroup_db[i].random[j].data_qty)
-				continue;
-			aFree(itemgroup_db[i].random[j].data);
-		}
 	}
 
+	itemdb_group->clear(itemdb_group, itemdb_group_free);
 	itemdb_other->clear(itemdb_other, itemdb_final_sub);
 	db_clear(itemdb_combo);
 
@@ -1753,14 +1736,13 @@ void itemdb_reload(void) {
 			sd->combos.id = NULL;
 			sd->combos.count = 0;
 			if( pc_load_combo(sd) > 0 )
-				status_calc_pc(sd,0);
+				status_calc_pc(sd, SCO_FORCE);
 		}
 
 	}
 	mapit_free(iter);
 }
 
-
 /**
 * Finalizing Item DB
 */
@@ -1770,20 +1752,8 @@ void do_final_itemdb(void) {
 	for( i = 0; i < ARRAYLENGTH(itemdb_array); ++i )
 		if( itemdb_array[i] )
 			destroy_item_data(itemdb_array[i], true);
-
-	for (i = 0; i < MAX_ITEMGROUP; i++) {
-		uint8 j;
-		if (!(&itemgroup_db[i]))
-			continue;
-		if (itemgroup_db[i].must_qty)
-			aFree(itemgroup_db[i].must);
-		for (j = 0; j < MAX_ITEMGROUP_RANDGROUP; j++) {
-			if (!(&itemgroup_db[i].random[j]) || !itemgroup_db[i].random[j].data_qty)
-				continue;
-			aFree(itemgroup_db[i].random[j].data);
-		}
-	}
-
+	
+	itemdb_group->destroy(itemdb_group, itemdb_group_free);
 	itemdb_other->destroy(itemdb_other, itemdb_final_sub);
 	destroy_item_data(&dummy_item, false);
 	db_destroy(itemdb_combo);
@@ -1796,6 +1766,7 @@ void do_init_itemdb(void) {
 	memset(itemdb_array, 0, sizeof(itemdb_array));
 	itemdb_other = idb_alloc(DB_OPT_BASE);
 	itemdb_combo = idb_alloc(DB_OPT_BASE);
+	itemdb_group = idb_alloc(DB_OPT_BASE);
 	create_dummy_data(); //Dummy data item.
 	
 	itemdb_read();

+ 39 - 30
src/map/itemdb.h

@@ -23,8 +23,6 @@
 #define IG_FINDINGORE 6
 #define IG_POTION 37
 
-#define MAX_ITEMGROUP 400 ///The max. item group count (increase this when needed). TODO: Remove this limit and use dynamic size or DBMap if needed
-
 #define MAX_ITEMGROUP_RANDGROUP 4	///Max group for random item (increase this when needed). TODO: Remove this limit and use dynamic size if needed
 
 #define CARD0_FORGE 0x00FF
@@ -95,6 +93,15 @@ enum item_itemid {
 	ITEMID_M_AWAKENING_POTION			= 12242,
 	ITEMID_M_BERSERK_POTION				= 12243,
 	ITEMID_COMP_BATTLE_MANUAL			= 12263,
+	ITEMID_LOVE_ANGEL					= 12287,
+	ITEMID_SQUIRREL						= 12288,
+	ITEMID_GOGO							= 12289,
+	ITEMID_PICTURE_DIARY				= 12304,
+	ITEMID_MINI_HEART					= 12305,
+	ITEMID_NEWCOMER						= 12306,
+	ITEMID_KID							= 12307,
+	ITEMID_MAGIC_CASTLE					= 12308,
+	ITEMID_BULGING_HEAD					= 12309,
 	ITEMID_THICK_BATTLE_MANUAL			= 12312,
 	ITEMID_ANCILLA						= 12333,
 	ITEMID_DUN_TELE_SCROLL3				= 12352,
@@ -318,6 +325,31 @@ struct item_combo {
 	bool isRef;/* whether this struct is a reference or the master */
 };
 
+
+/// Struct of item group entry
+struct s_item_group_entry {
+	uint16 nameid, /// Item ID
+		duration; /// Duration if item as rental item (in minutes)
+	uint16 amount; /// Amount of item will be obtained
+	bool isAnnounced, /// Broadcast if player get this item
+		isNamed; /// Named the item (if possible)
+	char bound; /// Makes the item as bound item (according to bound type)
+};
+
+/// Struct of random group
+struct s_item_group_random {
+	struct s_item_group_entry *data;
+	uint16 data_qty;
+};
+
+/// Struct of item group that will be used for db
+struct s_item_group_db {
+	uint16 id;
+	struct s_item_group_entry *must;
+	uint16 must_qty;
+	struct s_item_group_random random[MAX_ITEMGROUP_RANDGROUP]; //! TODO: Move this fixed array to dynamic size if needed.
+};
+
 ///Main item data struct
 struct item_data {
 	uint16 nameid;
@@ -384,29 +416,6 @@ struct item_data {
 	unsigned char combos_count;
 };
 
-/* Struct of item group entry */
-struct s_item_group {
-	uint16 nameid, ///item id
-		duration; ///duration if item as rental item (in minute)
-	uint16 amount; ///amount of item will be obtained
-	bool isAnnounced, ///broadcast if player get this item
-		isNamed; ///named the item (if possible)
-	char bound; ///makes the item as bound item (according to bound type)
-};
-
-/* Struct of random group */
-struct s_item_group_random {
-	struct s_item_group *data;
-	uint16 data_qty;
-};
-
-/* Struct of item group that will be used for db */
-struct s_item_group_db {
-	struct s_item_group *must;
-	uint16 must_qty;
-	struct s_item_group_random random[MAX_ITEMGROUP_RANDGROUP]; //! TODO: Move this fixed array to dynamic size if needed.
-};
-
 struct item_data* itemdb_searchname(const char *name);
 int itemdb_searchname_array(struct item_data** data, int size, const char *str);
 struct item_data* itemdb_load(int nameid);
@@ -440,7 +449,6 @@ struct item_data* itemdb_exists(int nameid);
 const char* itemdb_typename(enum item_types type);
 const char *itemdb_typename_ammo (enum e_item_ammo ammo);
 
-int itemdb_group_bonus(struct map_session_data* sd, int itemid);
 unsigned short itemdb_searchrandomid(uint16 group_id, uint8 sub_group);
 
 #define itemdb_value_buy(n) itemdb_search(n)->value_buy
@@ -467,11 +475,11 @@ bool itemdb_isrestricted(struct item* item, int gmlv, int gmlv2, int (*func)(str
 #define itemdb_canmail(item, gmlv) itemdb_isrestricted(item , gmlv, 0, itemdb_canmail_sub)
 #define itemdb_canauction(item, gmlv) itemdb_isrestricted(item , gmlv, 0, itemdb_canauction_sub)
 
-bool itemdb_isequip(int);
-bool itemdb_isequip2(struct item_data *);
+bool itemdb_isequip2(struct item_data *id);
+#define itemdb_isequip(nameid) itemdb_isequip2(itemdb_search(nameid))
 char itemdb_isidentified(int);
-bool itemdb_isstackable(uint16 nameid);
-bool itemdb_isstackable2(struct item_data *data);
+bool itemdb_isstackable2(struct item_data *id);
+#define itemdb_isstackable(nameid) itemdb_isstackable2(itemdb_search(nameid))
 uint64 itemdb_unique_id(int8 flag, int64 value); // Unique Item ID
 bool itemdb_isNoEquip(struct item_data *id, uint16 m);
 
@@ -479,6 +487,7 @@ char itemdb_pc_get_itemgroup(uint16 group_id, struct map_session_data *sd);
 uint16 itemdb_get_randgroupitem_count(uint16 group_id, uint8 sub_group, uint16 nameid);
 
 DBMap * itemdb_get_combodb();
+DBMap * itemdb_get_groupdb();
 
 void itemdb_reload(void);
 

+ 2 - 1
src/map/map.c

@@ -65,7 +65,7 @@ char default_codepage[32] = "";
 int map_server_port = 3306;
 char map_server_ip[32] = "127.0.0.1";
 char map_server_id[32] = "ragnarok";
-char map_server_pw[32] = "ragnarok";
+char map_server_pw[32] = "";
 char map_server_db[32] = "ragnarok";
 Sql* mmysql_handle;
 
@@ -1677,6 +1677,7 @@ int map_quit(struct map_session_data *sd) {
 		status_change_end(&sd->bl, SC_GLORYWOUNDS, INVALID_TIMER);
 		status_change_end(&sd->bl, SC_SOULCOLD, INVALID_TIMER);
 		status_change_end(&sd->bl, SC_HAWKEYES, INVALID_TIMER);
+		status_change_end(&sd->bl, SC_CHASEWALK2, INVALID_TIMER);
 		if(sd->sc.data[SC_ENDURE] && sd->sc.data[SC_ENDURE]->val4)
 			status_change_end(&sd->bl, SC_ENDURE, INVALID_TIMER); //No need to save infinite endure.
 		status_change_end(&sd->bl, SC_WEIGHT50, INVALID_TIMER);

+ 4 - 1
src/map/map.h

@@ -54,6 +54,8 @@ void map_msg_reload(void);
 /** Added definitions for WoESE objects and other [L0ne_W0lf], [aleos] */
 enum MOBID {
 	MOBID_PORING			= 1002,
+	MOBID_RED_PLANT			= 1078,
+	MOBID_BLACK_MUSHROOM	= 1084,
 	MOBID_GOBLIN_1			= 1122,
 	MOBID_GOBLIN_2,
 	MOBID_GOBLIN_3,
@@ -100,6 +102,7 @@ enum MOBID {
 	MOBID_MAGICDECOY_WATER,
 	MOBID_MAGICDECOY_EARTH,
 	MOBID_MAGICDECOY_WIND,
+	MOBID_ZANZOU			= 2308,
 	MOBID_S_HORNET			= 2158,
 	MOBID_S_GIANT_HORNET,
 	MOBID_S_LUCIOLA_VESPA,
@@ -477,7 +480,7 @@ enum _sp {
 
 	SP_IGNORE_DEF_CLASS, SP_DEF_RATIO_ATK_CLASS, SP_ADDCLASS, SP_SUBCLASS, SP_MAGIC_ADDCLASS, //2062-2066
 	SP_WEAPON_COMA_CLASS, SP_IGNORE_MDEF_CLASS_RATE, SP_EXP_ADDCLASS, SP_ADD_CLASS_DROP_ITEM, //2067-2070
-	SP_ADD_CLASS_DROP_ITEMGROUP, SP_ADDMAXWEIGHT  // 2071-2072
+	SP_ADD_CLASS_DROP_ITEMGROUP, SP_ADDMAXWEIGHT, SP_ADD_ITEMGROUP_HEAL_RATE  // 2071-2073
 };
 
 enum _look {

+ 7 - 11
src/map/mercenary.c

@@ -341,7 +341,8 @@ void merc_contract_init(struct mercenary_data *md) {
  * @param flag : if inter-serv request was sucessfull
  * @return false:failure, true:sucess
  */
-bool mercenary_recv_data(struct s_mercenary *merc, bool flag){
+bool mercenary_recv_data(struct s_mercenary *merc, bool flag)
+{
 	struct map_session_data *sd;
 	struct mercenary_data *md;
 	struct s_mercenary_db *db;
@@ -349,15 +350,13 @@ bool mercenary_recv_data(struct s_mercenary *merc, bool flag){
 
 	if( (sd = map_charid2sd(merc->char_id)) == NULL )
 		return false;
-	if( !flag || i < 0 )
-	{ // Not created - loaded - DB info
+	if( !flag || i < 0 ) { // Not created - loaded - DB info
 		sd->status.mer_id = 0;
 		return false;
 	}
 
 	db = &mercenary_db[i];
-	if( !sd->md )
-	{
+	if( !sd->md ) {
 		sd->md = md = (struct mercenary_data*)aCalloc(1,sizeof(struct mercenary_data));
 		md->bl.type = BL_MER;
 		md->bl.id = npc_get_new_npc_id();
@@ -379,13 +378,11 @@ bool mercenary_recv_data(struct s_mercenary *merc, bool flag){
 		md->bl.y = md->ud.to_y;
 
 		map_addiddb(&md->bl);
-		status_calc_mercenary(md,1);
+		status_calc_mercenary(md, SCO_FIRST);
 		md->contract_timer = INVALID_TIMER;
 		md->masterteleport_timer = INVALID_TIMER;
 		merc_contract_init(md);
-	}
-	else
-	{
+	} else {
 		memcpy(&sd->md->mercenary, merc, sizeof(struct s_mercenary));
 		md = sd->md;
 	}
@@ -394,8 +391,7 @@ bool mercenary_recv_data(struct s_mercenary *merc, bool flag){
 		mercenary_set_calls(md, 1);
 	sd->status.mer_id = merc->mercenary_id;
 
-	if( md && md->bl.prev == NULL && sd->bl.prev != NULL )
-	{
+	if( md && md->bl.prev == NULL && sd->bl.prev != NULL ) {
 		if(map_addblock(&md->bl))
 			return false;
 		clif_spawn(&md->bl);

+ 4 - 5
src/map/mob.c

@@ -612,7 +612,7 @@ static int mob_spawn_guardian_sub(int tid, unsigned int tick, int id, intptr_t d
 	memcpy(md->guardian_data->guild_name, g->name, NAME_LENGTH);
 	md->guardian_data->guardup_lv = guardup_lv;
 	if( guardup_lv )
-		status_calc_mob(md, 0); //Give bonuses.
+		status_calc_mob(md, SCO_NONE); //Give bonuses.
 	return 0;
 }
 
@@ -943,14 +943,13 @@ int mob_spawn (struct mob_data *md)
 	}
 
 	memset(&md->state, 0, sizeof(md->state));
-	status_calc_mob(md, 1);
+	status_calc_mob(md, SCO_FIRST);
 	md->attacked_id = 0;
 	md->target_id = 0;
 	md->move_fail_count = 0;
 	md->ud.state.attack_continue = 0;
 	md->ud.target_to = 0;
-	if( md->spawn_timer != INVALID_TIMER )
-	{
+	if( md->spawn_timer != INVALID_TIMER ) {
 		delete_timer(md->spawn_timer, mob_delayspawn);
 		md->spawn_timer = INVALID_TIMER;
 	}
@@ -2796,7 +2795,7 @@ int mob_class_change (struct mob_data *md, int mob_id)
 	unit_skillcastcancel(&md->bl, 0);
 	status_set_viewdata(&md->bl, mob_id);
 	clif_mob_class_change(md,md->vd->class_);
-	status_calc_mob(md, 1);
+	status_calc_mob(md,SCO_FIRST);
 	md->ud.state.speed_changed = 1; //Speed change update.
 
 	if (battle_config.monster_class_change_recover) {

+ 40 - 34
src/map/npc.c

@@ -124,9 +124,9 @@ int npc_isnear_sub(struct block_list* bl, va_list args) {
 	int skill_id = va_arg(args, int);
 
 	if (skill_id > 0) { //If skill_id > 0 that means is used for INF2_NO_NEARNPC [Cydh]
-		int16 idx = skill_get_index(skill_id);
+		uint16 idx = skill_get_index(skill_id);
 
-		if (idx >= 0 && skill_db[idx].unit_nonearnpc_type) {
+		if (idx > 0 && skill_db[idx].unit_nonearnpc_type) {
 			while (1) {
 				if (skill_db[idx].unit_nonearnpc_type&1 && nd->subtype == WARP) break;
 				if (skill_db[idx].unit_nonearnpc_type&2 && nd->subtype == SHOP) break;
@@ -3723,40 +3723,46 @@ static const char* npc_parse_mapflag(char* w1, char* w2, char* w3, char* w4, con
 		map[m].flag.notomb = state;
 	else if (!strcmpi(w3,"skill_damage")) {
 #ifdef ADJUST_SKILL_DAMAGE
-		char skill[NAME_LENGTH];
+		char skill[SKILL_NAME_LENGTH];
 		int pc = 0, mob = 0, boss = 0, other = 0, caster = 0;
 
-		memset(skill,0,sizeof(skill));
-		map[m].flag.skill_damage = state;	//set the mapflag
-
-		if (sscanf(w4,"%24[^,],%d,%d,%d,%d,%d[^\n]",skill,&caster,&pc,&mob,&boss,&other) >= 3) {
-			caster = (!caster) ? SDC_ALL : caster;
-			pc = cap_value(pc,-100,MAX_SKILL_DAMAGE_RATE);
-			mob = cap_value(mob,-100,MAX_SKILL_DAMAGE_RATE);
-			boss = cap_value(boss,-100,MAX_SKILL_DAMAGE_RATE);
-			other = cap_value(other,-100,MAX_SKILL_DAMAGE_RATE);
-
-			if (strcmp(skill,"all") == 0) {	//adjust damages for all skills
-				map[m].adjust.damage.caster = caster;
-				map[m].adjust.damage.pc = pc;
-				map[m].adjust.damage.mob = mob;
-				map[m].adjust.damage.boss = boss;
-				map[m].adjust.damage.other = other;
-			}
-			else if (skill_name2id(skill) <= 0)
-				ShowWarning("npc_parse_mapflag: skill_damage: Invalid skill name '%s'. Skipping (file '%s', line '%d')\n",skill,filepath,strline(buffer,start-buffer));
-			else {	//damages for specified skill
-				int i;
-				ARR_FIND(0,MAX_MAP_SKILL_MODIFIER,i,map[m].skill_damage[i].skill_id <= 0);
-				if (i >= MAX_SKILL)
-					ShowWarning("npc_parse_mapflag: skill_damage: Skill damage for map '%s' is overflow.\n",map[m].name);
-				else {
-					map[m].skill_damage[i].skill_id = skill_name2id(skill);
-					map[m].skill_damage[i].caster = caster;
-					map[m].skill_damage[i].pc = pc;
-					map[m].skill_damage[i].mob = mob;
-					map[m].skill_damage[i].boss = boss;
-					map[m].skill_damage[i].other = other;
+		memset(skill, 0, sizeof(skill));
+		map[m].flag.skill_damage = state;	// Set the mapflag
+
+		if (!state) {
+			memset(map[m].skill_damage, 0, sizeof(map[m].skill_damage));
+			memset(&map[m].adjust.damage, 0, sizeof(map[m].adjust.damage));
+		}
+		else {
+			if (sscanf(w4, "%30[^,],%d,%d,%d,%d,%d[^\n]", skill, &caster, &pc, &mob, &boss, &other) >= 3) {
+				caster = (!caster) ? SDC_ALL : caster;
+				pc = cap_value(pc, -100, INT_MAX);
+				mob = cap_value(mob, -100, INT_MAX);
+				boss = cap_value(boss, -100, INT_MAX);
+				other = cap_value(other, -100, INT_MAX);
+
+				if (strcmp(skill,"all") == 0) {	// Adjust damages for all skills
+					map[m].adjust.damage.caster = caster;
+					map[m].adjust.damage.pc = pc;
+					map[m].adjust.damage.mob = mob;
+					map[m].adjust.damage.boss = boss;
+					map[m].adjust.damage.other = other;
+				}
+				else if (skill_name2id(skill) <= 0)
+					ShowWarning("npc_parse_mapflag: skill_damage: Invalid skill name '%s'. Skipping (file '%s', line '%d')\n", skill, filepath, strline(buffer,start-buffer));
+				else {	//damages for specified skill
+					uint8 i;
+					ARR_FIND(0, ARRAYLENGTH(map[m].skill_damage), i, map[m].skill_damage[i].skill_id <= 0);
+					if (i >= ARRAYLENGTH(map[m].skill_damage))
+						ShowWarning("npc_parse_mapflag: skill_damage: Skill damage for map '%s' is overflow.\n", map[m].name);
+					else {
+						map[m].skill_damage[i].skill_id = skill_name2id(skill);
+						map[m].skill_damage[i].caster = caster;
+						map[m].skill_damage[i].pc = pc;
+						map[m].skill_damage[i].mob = mob;
+						map[m].skill_damage[i].boss = boss;
+						map[m].skill_damage[i].other = other;
+					}
 				}
 			}
 		}

Datei-Diff unterdrückt, da er zu groß ist
+ 307 - 150
src/map/pc.c


+ 27 - 33
src/map/pc.h

@@ -149,6 +149,12 @@ enum npc_timeout_type {
 	NPCT_WAIT  = 2,
 };
 
+/// Item Group heal rate struct
+struct s_pc_itemgrouphealrate {
+	uint16 group_id; /// Item Group ID
+	short rate; /// Rate
+};
+
 struct map_session_data {
 	struct block_list bl;
 	struct unit_data ud;
@@ -207,6 +213,7 @@ struct map_session_data {
 		unsigned int prevend : 1;//used to flag wheather you've spent 40sp to open the vending or not.
 		unsigned int warping : 1;//states whether you're in the middle of a warp processing
 		unsigned int permanent_speed : 1; // When 1, speed cannot be changed through status_calc_pc().
+		unsigned int hold_recalc : 1;
 		unsigned int banking : 1; //1 when we using the banking system 0 when closed
 		unsigned int hpmeter_visible : 1;
 		bool disable_atcommand_on_npc; //Prevent to use atcommand while talking with NPC [Kichi]
@@ -322,7 +329,6 @@ struct map_session_data {
 	int ignore_mdef_by_race[RC_MAX];
 	int ignore_mdef_by_class[CLASS_MAX];
 	int ignore_def_by_race[RC_MAX];
-	int itemgrouphealrate[MAX_ITEMGROUP];
 	short sp_gain_race[RC_MAX];
 	short sp_gain_race_attack[RC_MAX];
 	short hp_gain_race_attack[RC_MAX];
@@ -520,7 +526,6 @@ struct map_session_data {
 	const char* debug_func;
 
 	unsigned int bg_id;
-	unsigned short user_font;
 
 #ifdef SECURE_NPCTIMEOUT
 	/**
@@ -558,13 +563,15 @@ struct map_session_data {
 	unsigned char channel_count;
 	struct Channel *gcbind;
 	bool stealth;
-	unsigned char fontcolor; /* debug-only */
+	unsigned char fontcolor;
 	unsigned int channel_tick;
 
 	/* [Ind] */
 	struct sc_display_entry **sc_display;
 	unsigned char sc_display_count;
 
+	unsigned char delayed_damage; //[Ind]
+
 	// temporary debugging of bug #3504
 	const char* delunit_prevfile;
 	int delunit_prevline;
@@ -592,13 +599,18 @@ struct map_session_data {
 		int16 icon;
 		int tid;
 	} bonus_script[MAX_PC_BONUS_SCRIPT];
+	
+	struct s_pc_itemgrouphealrate **itemgrouphealrate; /// List of Item Group Heal rate bonus
+	uint8 itemgrouphealrate_count; /// Number of rate bonuses
 
 	/* Expiration Timer ID */
 	int expiration_tid;
 	time_t expiration_time;
 };
 
-struct eri *pc_sc_display_ers;
+struct eri *pc_sc_display_ers; /// Player's SC display table
+struct eri *pc_itemgrouphealrate_ers; /// Player's Item Group Heal Rate table
+
 /* Global Expiration Timer ID */
 extern int pc_expiration_tid;
 
@@ -649,32 +661,6 @@ enum ammo_type {
 	A_THROWWEAPON	//9
 };
 
-//Equip position constants
-enum equip_pos {
-	EQP_HEAD_LOW           = 0x000001,
-	EQP_HEAD_MID           = 0x000200, // 512
-	EQP_HEAD_TOP           = 0x000100, // 256
-	EQP_HAND_R             = 0x000002, // 2
-	EQP_HAND_L             = 0x000020, // 32
-	EQP_ARMOR              = 0x000010, // 16
-	EQP_SHOES              = 0x000040, // 64
-	EQP_GARMENT            = 0x000004, // 4
-	EQP_ACC_L              = 0x000008, // 8
-	EQP_ACC_R              = 0x000080, // 128
-	EQP_COSTUME_HEAD_TOP   = 0x000400, // 1024
-	EQP_COSTUME_HEAD_MID   = 0x000800, // 2048
-	EQP_COSTUME_HEAD_LOW   = 0x001000, // 4096
-	EQP_COSTUME_GARMENT    = 0x002000, // 8192
-	//EQP_COSTUME_FLOOR    = 0x004000, // 16384
-	EQP_AMMO               = 0x008000, // 32768
-	EQP_SHADOW_ARMOR       = 0x010000, // 65536
-	EQP_SHADOW_WEAPON      = 0x020000, // 131072
-	EQP_SHADOW_SHIELD      = 0x040000, // 262144
-	EQP_SHADOW_SHOES       = 0x080000, // 524288
-	EQP_SHADOW_ACC_R       = 0x100000, // 1048576
-	EQP_SHADOW_ACC_L       = 0x200000, // 2097152
-};
-
 struct {
 	unsigned int base_hp[MAX_LEVEL], base_sp[MAX_LEVEL]; //Storage for the first calculation with hp/sp factor and multiplicator
 	int hp_factor, hp_multiplicator, sp_factor;
@@ -698,8 +684,10 @@ struct {
 #define EQP_HELM (EQP_HEAD_LOW|EQP_HEAD_MID|EQP_HEAD_TOP)
 #define EQP_ACC (EQP_ACC_L|EQP_ACC_R)
 #define EQP_COSTUME (EQP_COSTUME_HEAD_TOP|EQP_COSTUME_HEAD_MID|EQP_COSTUME_HEAD_LOW|EQP_COSTUME_GARMENT)
+#define EQP_COSTUME_HELM (EQP_COSTUME_HEAD_TOP|EQP_COSTUME_HEAD_MID|EQP_COSTUME_HEAD_LOW)
 #define EQP_SHADOW_GEAR (EQP_SHADOW_ARMOR|EQP_SHADOW_WEAPON|EQP_SHADOW_SHIELD|EQP_SHADOW_SHOES|EQP_SHADOW_ACC_R|EQP_SHADOW_ACC_L)
 #define EQP_SHADOW_ACC (EQP_SHADOW_ACC_R|EQP_SHADOW_ACC_L)
+#define EQP_SHADOW_ARMS (EQP_SHADOW_WEAPON|EQP_SHADOW_SHIELD)
 
 /// Equip positions that use a visible sprite
 #if PACKETVER < 20110111
@@ -839,11 +827,12 @@ int pc_isequip(struct map_session_data *sd,int n);
 int pc_equippoint(struct map_session_data *sd,int n);
 int pc_setinventorydata(struct map_session_data *sd);
 
-int pc_get_skillcooldown(struct map_session_data *sd, int id, int lv);
+int pc_get_skillcooldown(struct map_session_data *sd, uint16 skill_id, uint16 skill_lv);
 int pc_checkskill(struct map_session_data *sd,uint16 skill_id);
 short pc_checkequip(struct map_session_data *sd,int pos);
 bool pc_checkequip2(struct map_session_data *sd,int nameid,int min, int max);
 
+void pc_scdata_received(struct map_session_data *sd);
 int pc_expiration_timer(int tid, unsigned int tick, int id, intptr_t data);
 int pc_global_expiration_timer(int tid, unsigned tick, int id, intptr_t data);
 void pc_expire_check(struct map_session_data *sd);
@@ -862,14 +851,14 @@ int pc_memo(struct map_session_data* sd, int pos);
 
 int pc_checkadditem(struct map_session_data*,int,int);
 int pc_inventoryblank(struct map_session_data*);
-int pc_search_inventory(struct map_session_data *sd,int item_id);
+short pc_search_inventory(struct map_session_data *sd, uint16 nameid);
 int pc_payzeny(struct map_session_data*,int, enum e_log_pick_type type, struct map_session_data*);
 char pc_additem(struct map_session_data *sd,struct item *item,int amount,e_log_pick_type log_type);
 int pc_getzeny(struct map_session_data*,int, enum e_log_pick_type, struct map_session_data*);
 int pc_delitem(struct map_session_data *sd,int n,int amount,int type, short reason, e_log_pick_type log_type);
 
 //Bound items
-int pc_bound_chk(TBL_PC *sd,int type,int *idxlist);
+int pc_bound_chk(TBL_PC *sd,enum bound_type type,int *idxlist);
 
 // Special Shop System
 int pc_paycash( struct map_session_data *sd, int price, int points, e_log_pick_type type );
@@ -1068,6 +1057,7 @@ int map_night_timer(int tid, unsigned int tick, int id, intptr_t data); // by [y
 void pc_inventory_rentals(struct map_session_data *sd);
 int pc_inventory_rental_clear(struct map_session_data *sd);
 void pc_inventory_rental_add(struct map_session_data *sd, int seconds);
+void pc_rental_expire(struct map_session_data *sd, int i);
 
 int pc_read_motd(void); // [Valaris]
 int pc_disguise(struct map_session_data *sd, int class_);
@@ -1102,6 +1092,10 @@ void pc_bonus_script_clear(struct map_session_data *sd, uint16 flag);
 
 void pc_cell_basilica(struct map_session_data *sd);
 
+void pc_itemgrouphealrate_clear(struct map_session_data *sd);
+short pc_get_itemgroup_bonus(struct map_session_data* sd, uint16 nameid);
+short pc_get_itemgroup_bonus_group(struct map_session_data* sd, uint16 group_id);
+
 #if defined(RENEWAL_DROP) || defined(RENEWAL_EXP)
 int pc_level_penalty_mod(struct map_session_data *sd, int mob_level, uint32 mob_class, int type);
 #endif

+ 30 - 33
src/map/pet.c

@@ -68,7 +68,7 @@ void pet_set_intimate(struct pet_data *pd, int value)
 
 	pd->pet.intimate = value;
 	if( (intimate >= battle_config.pet_equip_min_friendly && pd->pet.intimate < battle_config.pet_equip_min_friendly) || (intimate < battle_config.pet_equip_min_friendly && pd->pet.intimate >= battle_config.pet_equip_min_friendly) )
-		status_calc_pc(sd,0);
+		status_calc_pc(sd,SCO_NONE);
 }
 
 int pet_create_egg(struct map_session_data *sd, int item_id)
@@ -225,7 +225,7 @@ static int pet_hungry(int tid, unsigned int tick, int id, intptr_t data)
 			pd->pet.intimate = 0;
 			pd->status.speed = pd->db->status.speed;
 		}
-		status_calc_pet(pd, 0);
+		status_calc_pet(pd,SCO_NONE);
 		clif_send_petdata(sd,pd,1,pd->pet.intimate);
 	}
 	clif_send_petdata(sd,pd,2,pd->pet.hungry);
@@ -310,7 +310,7 @@ static int pet_return_egg(struct map_session_data *sd, struct pet_data *pd)
 	pd->pet.incuvate = 1;
 	unit_free(&pd->bl,CLR_OUTSIGHT);
 
-	status_calc_pc(sd,0);
+	status_calc_pc(sd,SCO_NONE);
 	sd->status.pet_id = 0;
 
 	return 1;
@@ -366,19 +366,24 @@ int pet_data_init(struct map_session_data *sd, struct s_pet *pet)
 	pd->bl.y = pd->ud.to_y;
 
 	map_addiddb(&pd->bl);
-	status_calc_pet(pd,1);
+	status_calc_pet(pd,SCO_FIRST);
 
 	pd->last_thinktime = gettick();
 	pd->state.skillbonus = 0;
+
 	if( battle_config.pet_status_support )
 		run_script(pet_db[i].pet_script,0,sd->bl.id,0);
-	if( pd->petDB && pd->petDB->equip_script )
-		status_calc_pc(sd,0);
 
-	if( battle_config.pet_hungry_delay_rate != 100 )
-		interval = (pd->petDB->hungry_delay*battle_config.pet_hungry_delay_rate)/100;
-	else
-		interval = pd->petDB->hungry_delay;
+	if( pd->petDB ) {
+		if( pd->petDB->equip_script )
+			status_calc_pc(sd,SCO_NONE);
+
+		if( battle_config.pet_hungry_delay_rate != 100 )
+			interval = pd->petDB->hungry_delay * battle_config.pet_hungry_delay_rate / 100;
+		else
+			interval = pd->petDB->hungry_delay;
+	}
+
 	if( interval <= 0 )
 		interval = 1;
 	pd->pet_hungry_timer = add_timer(gettick() + interval, pet_hungry, sd->bl.id, 0);
@@ -717,23 +722,19 @@ static int pet_unequipitem(struct map_session_data *sd, struct pet_data *pd)
 		clif_additem(sd,0,0,flag);
 		map_addflooritem(&tmp_item,1,sd->bl.m,sd->bl.x,sd->bl.y,0,0,0,0);
 	}
-	if( battle_config.pet_equip_required )
-	{ // Skotlex: halt support timers if needed
-		if( pd->state.skillbonus )
-		{
+	if( battle_config.pet_equip_required ) { // Skotlex: halt support timers if needed
+		if( pd->state.skillbonus ) {
 			pd->state.skillbonus = 0;
-			status_calc_pc(sd,0);
+			status_calc_pc(sd,SCO_NONE);
 		}
-		if( pd->s_skill && pd->s_skill->timer != INVALID_TIMER )
-		{
+		if( pd->s_skill && pd->s_skill->timer != INVALID_TIMER ) {
 			if( pd->s_skill->id )
 				delete_timer(pd->s_skill->timer, pet_skill_support_timer);
 			else
 				delete_timer(pd->s_skill->timer, pet_heal_timer);
 			pd->s_skill->timer = INVALID_TIMER;
 		}
-		if( pd->bonus && pd->bonus->timer != INVALID_TIMER )
-		{
+		if( pd->bonus && pd->bonus->timer != INVALID_TIMER ) {
 			delete_timer(pd->bonus->timer, pet_skill_bonus_timer);
 			pd->bonus->timer = INVALID_TIMER;
 		}
@@ -746,9 +747,9 @@ static int pet_food(struct map_session_data *sd, struct pet_data *pd)
 {
 	int i,k;
 
-	k=pd->petDB->FoodID;
-	i=pc_search_inventory(sd,k);
-	if(i < 0) {
+	k = pd->petDB->FoodID;
+	i = pc_search_inventory(sd,k);
+	if( i < 0 ) {
 		clif_pet_food(sd,k,0);
 		return 1;
 	}
@@ -756,29 +757,25 @@ static int pet_food(struct map_session_data *sd, struct pet_data *pd)
 
 	if( pd->pet.hungry > 90 )
 		pet_set_intimate(pd, pd->pet.intimate - pd->petDB->r_full);
-	else
-	{
+	else {
 		if( battle_config.pet_friendly_rate != 100 )
-			k = (pd->petDB->r_hungry * battle_config.pet_friendly_rate)/100;
+			k = (pd->petDB->r_hungry * battle_config.pet_friendly_rate) / 100;
 		else
 			k = pd->petDB->r_hungry;
-		if( pd->pet.hungry > 75 )
-		{
+		if( pd->pet.hungry > 75 ) {
 			k = k >> 1;
 			if( k <= 0 )
 				k = 1;
 		}
 		pet_set_intimate(pd, pd->pet.intimate + k);
 	}
-	if( pd->pet.intimate <= 0 )
-	{
+	if( pd->pet.intimate <= 0 ) {
 		pd->pet.intimate = 0;
 		pet_stop_attack(pd);
 		pd->status.speed = pd->db->status.speed;
-	}
-	else if( pd->pet.intimate > 1000 )
+	} else if( pd->pet.intimate > 1000 )
 		pd->pet.intimate = 1000;
-	status_calc_pet(pd, 0);
+	status_calc_pet(pd,SCO_NONE);
 	pd->pet.hungry += pd->petDB->fullness;
 	if( pd->pet.hungry > 100 )
 		pd->pet.hungry = 100;
@@ -1087,7 +1084,7 @@ int pet_skill_bonus_timer(int tid, unsigned int tick, int id, intptr_t data)
 
 	if (pd->state.skillbonus != bonus) {
 		pd->state.skillbonus = bonus;
-		status_calc_pc(sd, 0);
+		status_calc_pc(sd,SCO_NONE);
 	}
 	// wait for the next timer
 	pd->bonus->timer=add_timer(tick+timer,pet_skill_bonus_timer,sd->bl.id,0);

+ 89 - 78
src/map/script.c

@@ -2289,6 +2289,7 @@ void script_hardcoded_constants(void) {
 	script_set_constant("Option_Invisible",OPTION_INVISIBLE,false);
 	script_set_constant("Option_Orcish",OPTION_ORCISH,false);
 	script_set_constant("Option_Wedding",OPTION_WEDDING,false);
+	script_set_constant("Option_Ruwach",OPTION_RUWACH,false);
 	script_set_constant("Option_Chasewalk",OPTION_CHASEWALK,false);
 	script_set_constant("Option_Flying",OPTION_FLYING,false);
 	script_set_constant("Option_Xmas",OPTION_XMAS,false);
@@ -6455,22 +6456,24 @@ BUILDIN_FUNC(getitem)
 
 	if( !strcmp(script_getfuncname(st),"getitembound") ) {
 		char bound = script_getnum(st,4);
-		if( bound < 1 || bound > 4) { //Not a correct bound type
+		if( bound > BOUND_NONE && bound < BOUND_MAX ) {
+			it.bound = bound;
+			if( script_hasdata(st,5) )
+				sd=map_id2sd(script_getnum(st,5));
+			else
+				sd=script_rid2sd(st); // Attached player
+		}
+		else { //Not a correct bound type
 			ShowError("script_getitembound: Not a correct bound type! Type=%d\n",bound);
-			return 1;
+			return SCRIPT_CMD_FAILURE;
 		}
-		it.bound = bound;
-		if( script_hasdata(st,5) )
-			sd=map_id2sd(script_getnum(st,5));
-		else
-			sd=script_rid2sd(st); // Attached player
 	} else if( script_hasdata(st,4) )
 		sd=map_id2sd(script_getnum(st,4)); // <Account ID>
 	else
 		sd=script_rid2sd(st); // Attached player
 
 	if( sd == NULL ) // no target
-		return 0;
+		return SCRIPT_CMD_SUCCESS;
 
 	//Check if it's stackable.
 	if (!itemdb_isstackable(nameid))
@@ -6499,9 +6502,9 @@ BUILDIN_FUNC(getitem)
  *------------------------------------------*/
 BUILDIN_FUNC(getitem2)
 {
-	int nameid,amount,get_count,i,flag = 0;
-	int iden,ref,attr,c1,c2,c3,c4;
-	char bound=0;
+	int nameid, amount, get_count, i, flag = 0;
+	int iden, ref, attr, c1, c2, c3, c4;
+	char bound = BOUND_NONE;
 	struct item_data *item_data;
 	struct item item_tmp;
 	TBL_PC *sd;
@@ -6509,21 +6512,23 @@ BUILDIN_FUNC(getitem2)
 
 	if( !strcmp(script_getfuncname(st),"getitembound2") ) {
 		bound = script_getnum(st,11);
-		if( bound < 1 || bound > 3) { //Not a correct bound type
+		if( bound > BOUND_NONE && bound < BOUND_MAX ) {
+			if( script_hasdata(st,12) )
+				sd=map_id2sd(script_getnum(st,12));
+			else
+				sd=script_rid2sd(st); // Attached player
+		}
+		else {
 			ShowError("script_getitembound2: Not a correct bound type! Type=%d\n",bound);
-			return 1;
+			return SCRIPT_CMD_FAILURE;
 		}
-		if( script_hasdata(st,12) )
-			sd=map_id2sd(script_getnum(st,12));
-		else
-			sd=script_rid2sd(st); // Attached player
 	} else if( script_hasdata(st,11) )
 		sd=map_id2sd(script_getnum(st,11)); // <Account ID>
 	else
 		sd=script_rid2sd(st); // Attached player
 
 	if( sd == NULL ) // no target
-		return 0;
+		return SCRIPT_CMD_SUCCESS;
 
 	data=script_getdata(st,2);
 	get_val(st,data);
@@ -6652,7 +6657,7 @@ BUILDIN_FUNC(rentitem) {
 	it.nameid = nameid;
 	it.identify = 1;
 	it.expire_time = (unsigned int)(time(NULL) + seconds);
-	it.bound = 0;
+	it.bound = BOUND_NONE;
 
 	if( (flag = pc_additem(sd, &it, 1, LOG_TYPE_SCRIPT)) )
 	{
@@ -10998,7 +11003,6 @@ static void script_detach_rid(struct script_state* st)
 	}
 }
 
-
 /*=========================================================================
  * Attaches a set of RIDs to the current script. [digitalhamster]
  * addrid(<type>{,<flag>{,<parameters>}});
@@ -11016,17 +11020,17 @@ static void script_detach_rid(struct script_state* st)
  *	0 : Players are always attached. (default)
  *	1 : Players currently running another script will not be attached.
  *-------------------------------------------------------------------------*/
-
 static int buildin_addrid_sub(struct block_list *bl,va_list ap)
 {
 	int forceflag;
 	struct map_session_data *sd = (TBL_PC *)bl;
 	struct script_state* st;
 
-	st=va_arg(ap,struct script_state*);
-	forceflag=va_arg(ap,int);
-	if(!forceflag||!sd->st)
-		if(sd->status.account_id!=st->rid)
+	st = va_arg(ap,struct script_state*);
+	forceflag = va_arg(ap,int);
+
+	if(!forceflag || !sd->st)
+		if(sd->status.account_id != st->rid)
 			run_script(st->script,st->pos,sd->status.account_id,st->oid);
 	return 0;
 }
@@ -11036,46 +11040,48 @@ BUILDIN_FUNC(addrid)
 	struct s_mapiterator* iter;
 	struct block_list *bl;
 	TBL_PC *sd;
-	if(st->rid<1){
+
+	if(st->rid < 1) {
 		st->state = END;
-		bl=map_id2bl(st->oid);
+		bl = map_id2bl(st->oid);
 	} else
-		bl=map_id2bl(st->rid); //if run without rid it'd error,also oid if npc, else rid for map
+		bl = map_id2bl(st->rid); //if run without rid it'd error,also oid if npc, else rid for map
 	iter = mapit_getallusers();
-	switch(script_getnum(st,2)){
+
+	switch(script_getnum(st,2)) {
 		case 0:
-			for( sd = (TBL_PC*)mapit_first(iter); mapit_exists(iter); sd = (TBL_PC*)mapit_next(iter)){
-				if(!script_getnum(st,3)||!sd->st)
-					if(sd->status.account_id!=st->rid) //attached player already runs.
+			for( sd = (TBL_PC*)mapit_first(iter); mapit_exists(iter); sd = (TBL_PC*)mapit_next(iter)) {
+				if(!script_getnum(st,3) || !sd->st)
+					if(sd->status.account_id != st->rid) //attached player already runs.
 						run_script(st->script,st->pos,sd->status.account_id,st->oid);
 			}
 			break;
 		case 1:
-			for( sd = (TBL_PC*)mapit_first(iter); mapit_exists(iter); sd = (TBL_PC*)mapit_next(iter)){
-				if(!script_getnum(st,3)||!sd->st)
-					if((sd->bl.m == bl->m)&&(sd->status.account_id!=st->rid))
+			for( sd = (TBL_PC*)mapit_first(iter); mapit_exists(iter); sd = (TBL_PC*)mapit_next(iter)) {
+				if(!script_getnum(st,3) || !sd->st)
+					if((sd->bl.m == bl->m) && (sd->status.account_id != st->rid))
 						run_script(st->script,st->pos,sd->status.account_id,st->oid);
 			}
 			break;
 		case 2:
-			if(script_getnum(st,4)==0){
+			if(script_getnum(st,4) == 0) {
 				script_pushint(st,0);
 				return 0;
 			}
-			for( sd = (TBL_PC*)mapit_first(iter); mapit_exists(iter); sd = (TBL_PC*)mapit_next(iter)){
-				if(!script_getnum(st,3)||!sd->st)
-					if((sd->status.account_id!=st->rid)&&(sd->status.party_id==script_getnum(st,4))) //attached player already runs.
+			for( sd = (TBL_PC*)mapit_first(iter); mapit_exists(iter); sd = (TBL_PC*)mapit_next(iter)) {
+				if(!script_getnum(st,3) || !sd->st)
+					if((sd->status.account_id != st->rid) && (sd->status.party_id == script_getnum(st,4))) //attached player already runs.
 						run_script(st->script,st->pos,sd->status.account_id,st->oid);
 			}
 			break;
 		case 3:
-			if(script_getnum(st,4)==0){
+			if(script_getnum(st,4) == 0) {
 				script_pushint(st,0);
 				return 0;
 			}
-			for( sd = (TBL_PC*)mapit_first(iter); mapit_exists(iter); sd = (TBL_PC*)mapit_next(iter)){
-				if(!script_getnum(st,3)||!sd->st)
-					if((sd->status.account_id!=st->rid)&&(sd->status.guild_id==script_getnum(st,4))) //attached player already runs.
+			for( sd = (TBL_PC*)mapit_first(iter); mapit_exists(iter); sd = (TBL_PC*)mapit_next(iter)) {
+				if(!script_getnum(st,3) || !sd->st)
+					if((sd->status.account_id != st->rid) && (sd->status.guild_id == script_getnum(st,4))) //attached player already runs.
 						run_script(st->script,st->pos,sd->status.account_id,st->oid);
 			}
 			break;
@@ -11085,11 +11091,11 @@ BUILDIN_FUNC(addrid)
 			st,script_getnum(st,3));//4-x0 , 5-y0 , 6-x1, 7-y1
 			break;
 		default:
-			if((map_id2sd(script_getnum(st,2)))==NULL){ // Player not found.
+			if((map_id2sd(script_getnum(st,2))) == NULL) { // Player not found.
 				script_pushint(st,0);
 				return 0;
 			}
-			if(!script_getnum(st,3)||!map_id2sd(script_getnum(st,2))->st) {
+			if(!script_getnum(st,3) || !map_id2sd(script_getnum(st,2))->st) {
 				run_script(st->script,st->pos,script_getnum(st,2),st->oid);
 				script_pushint(st,1);
 			}
@@ -11471,7 +11477,8 @@ BUILDIN_FUNC(removemapflag)
 			case MF_SKILL_DAMAGE:
 				{
 					map[m].flag.skill_damage = 0;
-					memset(&map[m].adjust.damage,0,sizeof(map[m].adjust.damage));
+					memset(map[m].skill_damage, 0, sizeof(map[m].skill_damage));
+					memset(&map[m].adjust.damage, 0, sizeof(map[m].adjust.damage));
 				} break;
 #endif
 		}
@@ -13170,11 +13177,11 @@ BUILDIN_FUNC(nude)
 	}
 
 	if( calcflag )
-		status_calc_pc(sd,0);
+		status_calc_pc(sd,SCO_NONE);
 	return SCRIPT_CMD_SUCCESS;
 }
 
-int atcommand_sub(struct script_state* st,int type){
+int atcommand_sub(struct script_state* st,int type) {
 	TBL_PC dummy_sd;
 	TBL_PC* sd;
 	int fd;
@@ -13627,11 +13634,10 @@ BUILDIN_FUNC(npcwalkto)
 	y=script_getnum(st,3);
 
 	if(nd) {
-		if (!nd->status.hp) {
-			status_calc_npc(nd, true);
-		} else {
-			status_calc_npc(nd, false);
-		}
+		if (!nd->status.hp)
+			status_calc_npc(nd, SCO_FIRST);
+		else
+			status_calc_npc(nd, SCO_NONE);
 		unit_walktoxy(&nd->bl,x,y,0);
 	}
 	return SCRIPT_CMD_SUCCESS;
@@ -15716,7 +15722,7 @@ BUILDIN_FUNC(getmonsterinfo)
 			script_pushconststr(st,"null");
 		else
 			script_pushint(st,-1);
-		return -1;
+		return 0;
 	}
 	mob = mob_db(mob_id);
 	switch ( script_getnum(st,3) ) {
@@ -16426,6 +16432,11 @@ BUILDIN_FUNC(openauction)
 	if( sd == NULL )
 		return 0;
 
+	if( !battle_config.feature_auction ) {
+		clif_colormes(sd, color_table[COLOR_RED], msg_txt(sd, 517));
+		return 0;
+	}
+
 	clif_Auction_openwindow(sd);
 
 	return SCRIPT_CMD_SUCCESS;
@@ -17379,13 +17390,14 @@ BUILDIN_FUNC(setfont)
 {
 	struct map_session_data *sd = script_rid2sd(st);
 	int font = script_getnum(st,2);
+
 	if( sd == NULL )
 		return 0;
 
-	if( sd->user_font != font )
-		sd->user_font = font;
+	if( sd->status.font != font )
+		sd->status.font = font;
 	else
-		sd->user_font = 0;
+		sd->status.font = 0;
 
 	clif_font(sd);
 	return SCRIPT_CMD_SUCCESS;
@@ -17396,8 +17408,8 @@ static int buildin_mobuseskill_sub(struct block_list *bl,va_list ap)
 	TBL_MOB* md		= (TBL_MOB*)bl;
 	struct block_list *tbl;
 	int mobid		= va_arg(ap,int);
-	uint16 skill_id		= va_arg(ap,int);
-	uint16 skill_lv		= va_arg(ap,int);
+	uint16 skill_id	= va_arg(ap,int);
+	uint16 skill_lv	= va_arg(ap,int);
 	int casttime	= va_arg(ap,int);
 	int cancel		= va_arg(ap,int);
 	int emotion		= va_arg(ap,int);
@@ -17407,8 +17419,7 @@ static int buildin_mobuseskill_sub(struct block_list *bl,va_list ap)
 		return 0;
 
 	// 0:self, 1:target, 2:master, default:random
-	switch( target )
-	{
+	switch( target ) {
 		case 0: tbl = map_id2bl(md->bl.id); break;
 		case 1: tbl = map_id2bl(md->target_id); break;
 		case 2: tbl = map_id2bl(md->master_id); break;
@@ -17430,6 +17441,7 @@ static int buildin_mobuseskill_sub(struct block_list *bl,va_list ap)
 
 	return SCRIPT_CMD_SUCCESS;
 }
+
 /*==========================================
  * areamobuseskill "Map Name",<x>,<y>,<range>,<Mob ID>,"Skill Name"/<Skill ID>,<Skill Lv>,<Cast Time>,<Cancelable>,<Emotion>,<Target Type>;
  *------------------------------------------*/
@@ -18118,17 +18130,16 @@ BUILDIN_FUNC(npcskill)
 	nd->level = npc_level;
 	nd->stat_point = stat_point;
 
-	if (!nd->status.hp) {
-		status_calc_npc(nd, true);
-	} else {
-		status_calc_npc(nd, false);
-	}
+	if (!nd->status.hp)
+		status_calc_npc(nd, SCO_FIRST);
+	else
+		status_calc_npc(nd, SCO_NONE);
 
-	if (skill_get_inf(skill_id)&INF_GROUND_SKILL) {
+	if (skill_get_inf(skill_id)&INF_GROUND_SKILL)
 		unit_skilluse_pos(&nd->bl, sd->bl.x, sd->bl.y, skill_id, skill_level);
-	} else {
+	else
 		unit_skilluse_id(&nd->bl, sd->bl.id, skill_id, skill_level);
-	}
+
 	return SCRIPT_CMD_SUCCESS;
 }
 
@@ -18223,24 +18234,24 @@ BUILDIN_FUNC(stand)
 
 /** Creates an array of bounded item IDs
  * countbound {<type>};
- * @param type: 1 - Account Bound; 2 - Guild Bound; 3 - Party Bound
+ * @param type: 0 - All bound items; 1 - Account Bound; 2 - Guild Bound; 3 - Party Bound
  * @return amt: Amount of items found
  */
 BUILDIN_FUNC(countbound)
 {
-	int i, type, j=0, k=0;
+	int i, type, j = 0, k = 0;
 	TBL_PC *sd;
 
 	if( (sd = script_rid2sd(st)) == NULL )
 		return SCRIPT_CMD_FAILURE;
 
-	type = script_hasdata(st,2)?script_getnum(st,2):0;
+	type = script_getnum(st,2);
 
-	for(i=0;i<MAX_INVENTORY;i++){
-		if(sd->status.inventory[i].nameid > 0 && (
-			(!type && sd->status.inventory[i].bound > 0) ||
-			(type && sd->status.inventory[i].bound == type)
-		)) {
+	for( i = 0; i < MAX_INVENTORY; i ++ ) {
+		if( sd->status.inventory[i].nameid > 0 && (
+			(!type && sd->status.inventory[i].bound) || (type && sd->status.inventory[i].bound == type)
+			))
+		{
 			pc_setreg(sd,reference_uid(add_str("@bound_items"), k),sd->status.inventory[i].nameid);
 			k++;
 			j += sd->status.inventory[i].amount;
@@ -18718,7 +18729,7 @@ BUILDIN_FUNC(bonus_script) {
 	if (sd->bonus_script[i].icon != SI_BLANK) //Gives status icon if exist
 		clif_status_change(&sd->bl,sd->bonus_script[i].icon,1,dur,1,0,0);
 
-	status_calc_pc(sd,false);
+	status_calc_pc(sd,SCO_NONE);
 	return SCRIPT_CMD_SUCCESS;
 }
 

Datei-Diff unterdrückt, da er zu groß ist
+ 238 - 202
src/map/skill.c


+ 42 - 38
src/map/skill.h

@@ -22,6 +22,8 @@ struct status_change_entry;
 #define MAX_SKILL_IMPROVISE_DB 50
 #define MAX_SKILL_LEVEL 100
 #define MAX_SKILL_CRIMSON_MARKER 3
+#define SKILL_NAME_LENGTH 31
+#define SKILL_DESC_LENGTH 31
 
 DBMap* skilldb_name2id;
 
@@ -104,51 +106,53 @@ enum e_skill_display {
 	SD_PREAMBLE  = 0x8000, // skill_area_sub will transmit a 'magic' damage packet (-30000 dmg) for the first target selected
 };
 
-#define MAX_SKILL_ITEM_REQUIRE	10
-#define MAX_SKILL_STATUS_REQUIRE 3
-#define MAX_SKILL_EQUIP_REQUIRE 10
+#define MAX_SKILL_ITEM_REQUIRE	10 /// Maximum required items
+#define MAX_SKILL_STATUS_REQUIRE 3 /// Maximum required statuses
+#define MAX_SKILL_EQUIP_REQUIRE 10 /// Maximum required equipped item
 struct skill_condition {
-	int hp,
-		mhp,
-		sp,
-		hp_rate,
-		sp_rate,
-		ammo,
-		ammo_qty,
-		weapon,
-		zeny,
-		state,
-		spiritball,
-		itemid[MAX_SKILL_ITEM_REQUIRE],
-		amount[MAX_SKILL_ITEM_REQUIRE];
-	short *eqItem;
-	enum sc_type *status;
-	uint8 status_count, eqItem_count;
+	int hp, /// HP cost
+		mhp, /// Max HP to trigger
+		sp, /// SP cost
+		hp_rate, /// HP cost (%)
+		sp_rate, /// SP cost (%)
+		ammo, /// Ammo type
+		ammo_qty, /// Amount of ammo
+		weapon, /// Weapon type
+		zeny, /// Zeny cost
+		state, /// State/condition
+		spiritball, /// Spiritball cost
+		itemid[MAX_SKILL_ITEM_REQUIRE], /// Required item
+		amount[MAX_SKILL_ITEM_REQUIRE]; /// Amount of item
+	uint16 *eqItem; /// List of equipped item
+	enum sc_type *status; /// List of Status required (SC)
+	uint8 status_count, /// Count of SC
+		eqItem_count; /// Count of equipped item
 };
 
 struct s_skill_require {
-	int hp[MAX_SKILL_LEVEL],
-		mhp[MAX_SKILL_LEVEL],
-		sp[MAX_SKILL_LEVEL],
-		hp_rate[MAX_SKILL_LEVEL],
-		sp_rate[MAX_SKILL_LEVEL],
-		zeny[MAX_SKILL_LEVEL],
-		weapon,
-		ammo,
-		ammo_qty[MAX_SKILL_LEVEL],
-		state,
-		spiritball[MAX_SKILL_LEVEL],
-		itemid[MAX_SKILL_ITEM_REQUIRE],
-		amount[MAX_SKILL_ITEM_REQUIRE];
-	short *eqItem;
-	enum sc_type *status;
-	uint8 status_count, eqItem_count;
+	int hp[MAX_SKILL_LEVEL], /// HP cost
+		mhp[MAX_SKILL_LEVEL], /// Max HP to trigger
+		sp[MAX_SKILL_LEVEL], /// SP cost
+		hp_rate[MAX_SKILL_LEVEL], /// HP cost (%)
+		sp_rate[MAX_SKILL_LEVEL], /// SP cost (%)
+		zeny[MAX_SKILL_LEVEL], /// Zeny cost
+		weapon, /// Weapon type
+		ammo, /// Ammo type
+		ammo_qty[MAX_SKILL_LEVEL], /// Amount of ammo
+		state, /// State/condition
+		spiritball[MAX_SKILL_LEVEL], /// Spiritball cost
+		itemid[MAX_SKILL_ITEM_REQUIRE], /// Required item
+		amount[MAX_SKILL_ITEM_REQUIRE]; /// Amount of item
+	uint16 *eqItem; /// List of equipped item
+	enum sc_type *status; /// List of Status required (SC)
+	uint8 status_count, /// Count of SC
+		eqItem_count; /// Count of equipped item
 };
 
 /// Database skills
 struct s_skill_db {
-	char name[NAME_LENGTH];
-	char desc[40];
+	char name[SKILL_NAME_LENGTH];
+	char desc[SKILL_DESC_LENGTH];
 	int range[MAX_SKILL_LEVEL],hit,inf,element[MAX_SKILL_LEVEL],nk,splash[MAX_SKILL_LEVEL],max;
 	int num[MAX_SKILL_LEVEL];
 	int cast[MAX_SKILL_LEVEL],walkdelay[MAX_SKILL_LEVEL],delay[MAX_SKILL_LEVEL];
@@ -261,7 +265,7 @@ enum {
 	UF_ENSEMBLE      = 0x0200,	// Duet
 	UF_SONG          = 0x0400,	// Song
 	UF_DUALMODE      = 0x0800,	// Spells should trigger both ontimer and onplace/onout/onleft effects.
-    UF_RANGEDSINGLEUNIT = 0x2000 // hack for ranged layout, only display center
+	UF_RANGEDSINGLEUNIT = 0x2000 // hack for ranged layout, only display center
 };
 
 /// Create Database item

Datei-Diff unterdrückt, da er zu groß ist
+ 223 - 173
src/map/status.c


+ 31 - 20
src/map/status.h

@@ -701,6 +701,7 @@ typedef enum sc_type {
 	SC__FEINTBOMB,
 	SC__CHAOS,
 	SC_ELEMENTAL_SHIELD,
+	SC_CHASEWALK2,
 
 #ifdef RENEWAL
 	SC_EXTREMITYFIST2, //! NOTE: This SC should be right before SC_MAX, so it doesn't disturb if RENEWAL is disabled
@@ -893,7 +894,7 @@ enum si_type {
 //	SI_DEFENCE = 179,
 //	SI_SLOWDOWN = 180,
 	SI_PRESERVE		= 181,
-	SI_INCSTR		= 182,
+	SI_CHASEWALK2	= 182,
 //	SI_NOT_EXTREMITYFIST = 183,
 	SI_INTRAVISION		= 184,
 //	SI_MOVESLOW_POTION = 185,
@@ -1725,6 +1726,12 @@ enum scb_flag
 	SCB_ALL		= 0x3FFFFFFF
 };
 
+enum e_status_calc_opt {
+	SCO_NONE  = 0x0,
+	SCO_FIRST = 0x1, /* Trigger the calculations that should take place only onspawn/once */
+	SCO_FORCE = 0x2, /* Only relevant to BL_PC types, ensures call bypasses the queue caused by delayed damage */
+};
+
 ///Enum for bonus_script's flag
 enum e_bonus_script_flags {
 	BONUS_FLAG_REM_ON_DEAD		= 0x01,	//Remove bonus when dead
@@ -1992,22 +1999,23 @@ int status_change_timer_sub(struct block_list* bl, va_list ap);
 int status_change_clear(struct block_list* bl, int type);
 void status_change_clear_buffs(struct block_list* bl, int type);
 
-#define status_calc_bl(bl, flag) status_calc_bl_(bl, (enum scb_flag)(flag), false)
-#define status_calc_mob(md, first) status_calc_bl_(&(md)->bl, SCB_ALL, first)
-#define status_calc_pet(pd, first) status_calc_bl_(&(pd)->bl, SCB_ALL, first)
-#define status_calc_pc(sd, first) status_calc_bl_(&(sd)->bl, SCB_ALL, first)
-#define status_calc_homunculus(hd, first) status_calc_bl_(&(hd)->bl, SCB_ALL, first)
-#define status_calc_mercenary(md, first) status_calc_bl_(&(md)->bl, SCB_ALL, first)
-#define status_calc_elemental(ed, first) status_calc_bl_(&(ed)->bl, SCB_ALL, first)
-#define status_calc_npc(nd, first) status_calc_bl_(&(nd)->bl, SCB_ALL, first)
-
-void status_calc_bl_(struct block_list *bl, enum scb_flag flag, bool first);
-int status_calc_mob_(struct mob_data* md, bool first);
-int status_calc_pet_(struct pet_data* pd, bool first);
-int status_calc_pc_(struct map_session_data* sd, bool first);
-int status_calc_homunculus_(struct homun_data *hd, bool first);
-int status_calc_mercenary_(struct mercenary_data *md, bool first);
-int status_calc_elemental_(struct elemental_data *ed, bool first);
+#define status_calc_bl(bl, flag) status_calc_bl_(bl, (enum scb_flag)(flag), SCO_NONE)
+#define status_calc_mob(md, opt) status_calc_bl_(&(md)->bl, SCB_ALL, opt)
+#define status_calc_pet(pd, opt) status_calc_bl_(&(pd)->bl, SCB_ALL, opt)
+#define status_calc_pc(sd, opt) status_calc_bl_(&(sd)->bl, SCB_ALL, opt)
+#define status_calc_homunculus(hd, opt) status_calc_bl_(&(hd)->bl, SCB_ALL, opt)
+#define status_calc_mercenary(md, opt) status_calc_bl_(&(md)->bl, SCB_ALL, opt)
+#define status_calc_elemental(ed, opt) status_calc_bl_(&(ed)->bl, SCB_ALL, opt)
+#define status_calc_npc(nd, opt) status_calc_bl_(&(nd)->bl, SCB_ALL, opt)
+
+void status_calc_bl_(struct block_list *bl, enum scb_flag flag, enum e_status_calc_opt opt);
+int status_calc_mob_(struct mob_data* md, enum e_status_calc_opt opt);
+int status_calc_pet_(struct pet_data* pd, enum e_status_calc_opt opt);
+int status_calc_pc_(struct map_session_data* sd, enum e_status_calc_opt opt);
+int status_calc_homunculus_(struct homun_data *hd, enum e_status_calc_opt opt);
+int status_calc_mercenary_(struct mercenary_data *md, enum e_status_calc_opt opt);
+int status_calc_elemental_(struct elemental_data *ed, enum e_status_calc_opt opt);
+int status_calc_npc_(struct npc_data *nd, enum e_status_calc_opt opt);
 
 void status_calc_misc(struct block_list *bl, struct status_data *status, int level);
 void status_calc_regen(struct block_list *bl, struct status_data *status, struct regen_data *regen);
@@ -2018,9 +2026,12 @@ int status_check_visibility(struct block_list *src, struct block_list *target);
 
 int status_change_spread( struct block_list *src, struct block_list *bl );
 
-#ifdef RENEWAL
-unsigned int status_weapon_atk(struct weapon_atk wa, struct status_data *status);
-unsigned short status_base_matk(const struct status_data* status, int level);
+#ifndef RENEWAL
+	unsigned short status_base_matk_min(const struct status_data* status);
+	unsigned short status_base_matk_max(const struct status_data* status);
+#else
+	unsigned int status_weapon_atk(struct weapon_atk wa, struct status_data *status);
+	unsigned short status_base_matk(const struct status_data* status, int level);
 #endif
 
 int status_readdb(void);

+ 6 - 8
src/map/storage.c

@@ -53,23 +53,21 @@ static int storage_comp_item(const void *_i1, const void *_i2)
  * @param items : list of items to sort
  * @param size : number of item in list
  */
-static void storage_sortitem(struct item* items, unsigned int size)
+void storage_sortitem(struct item* items, unsigned int size)
 {
 	nullpo_retv(items);
 
 	if( battle_config.client_sort_storage )
-	{
 		qsort(items, size, sizeof(struct item), storage_comp_item);
-	}
 }
 
 /**
  * Initiate storage module
  * Called from map.c::do_init()
- * @return 1
  */
-void do_init_storage(void){
-	guild_storage_db=idb_alloc(DB_OPT_RELEASE_DATA);
+void do_init_storage(void)
+{
+	guild_storage_db = idb_alloc(DB_OPT_RELEASE_DATA);
 }
 
 /**
@@ -182,7 +180,7 @@ static int storage_additem(struct map_session_data* sd, struct item* item_data,
 		return 1;
 	}
 
-	if( (item_data->bound > 1) && !pc_can_give_bounded_items(sd) ) {
+	if( (item_data->bound > BOUND_ACCOUNT) && !pc_can_give_bounded_items(sd) ) {
 		clif_displaymessage(sd->fd, msg_txt(sd,294));
 		return 1;
 	}
@@ -521,7 +519,7 @@ int guild_storage_additem(struct map_session_data* sd, struct guild_storage* sto
 		return 1;
 	}
 
-	if( (item_data->bound == 1 || item_data->bound > 2) && !pc_can_give_bounded_items(sd) ) {
+	if( (item_data->bound == BOUND_ACCOUNT || item_data->bound > BOUND_GUILD) && !pc_can_give_bounded_items(sd) ) {
 		clif_displaymessage(sd->fd, msg_txt(sd,294));
 		return 1;
 	}

+ 1 - 0
src/map/storage.h

@@ -18,6 +18,7 @@ int storage_storageget(struct map_session_data *sd,int index,int amount);
 int storage_storageaddfromcart(struct map_session_data *sd,int index,int amount);
 int storage_storagegettocart(struct map_session_data *sd,int index,int amount);
 void storage_storageclose(struct map_session_data *sd);
+void storage_sortitem(struct item* items, unsigned int size);
 void do_init_storage(void);
 void do_final_storage(void);
 void do_reconnect_storage(void);

+ 1 - 1
src/map/trade.c

@@ -379,7 +379,7 @@ void trade_tradeadditem(struct map_session_data *sd, short index, short amount)
 		return;
 	}
 
-	if( ((item->bound == 1 || item->bound > 2) || (item->bound == 2 && sd->status.guild_id != target_sd->status.guild_id)) && !pc_can_give_bounded_items(sd) ) { // Item Bound
+	if( ((item->bound == BOUND_ACCOUNT || item->bound > BOUND_GUILD) || (item->bound == BOUND_GUILD && sd->status.guild_id != target_sd->status.guild_id)) && !pc_can_give_bounded_items(sd) ) { // Item Bound
 		clif_displaymessage(sd->fd, msg_txt(sd,293));
 		clif_tradeitemok(sd, index+2, 1);
 		return;

+ 9 - 5
src/map/unit.c

@@ -2392,11 +2392,14 @@ int unit_remove_map_(struct block_list *bl, clr_type clrtype, const char* file,
 				trade_tradecancel(sd);
 			buyingstore_close(sd);
 			searchstore_close(sd);
-			if(sd->state.storage_flag == 1)
-				storage_storage_quit(sd,0);
-			else if (sd->state.storage_flag == 2)
-				storage_guild_storage_quit(sd,0);
-			sd->state.storage_flag = 0; // Force close it when being warped.
+			if (sd->menuskill_id != AL_TELEPORT) { //bugreport:8027
+				if (sd->state.storage_flag == 1)
+					storage_storage_quit(sd,0);
+				else if (sd->state.storage_flag == 2)
+					storage_guild_storage_quit(sd,0);
+
+				sd->state.storage_flag = 0; //Force close it when being warped.
+			}
 			if(sd->party_invite>0)
 				party_reply_invite(sd,sd->party_invite,0);
 			if(sd->guild_invite>0)
@@ -2664,6 +2667,7 @@ int unit_free(struct block_list *bl, clr_type clrtype)
 				sd->quest_log = NULL;
 				sd->num_quests = sd->avail_quests = 0;
 			}
+			pc_itemgrouphealrate_clear(sd);
 			break;
 		}
 		case BL_PET:

Einige Dateien werden nicht angezeigt, da zu viele Dateien in diesem Diff geändert wurden.