-
Content Count
382 -
Joined
-
Days Won
38
Content Type
Profiles
Forums
Downloads
Staff Applications
Calendar
Everything posted by Haru
-
Those keys aren't all that strong. Stronger than the ones that originally came with the 2013-08-07 client, but still weak. They don't seem to pass the test at the URL you posted.
-
The problem with that approach is that you're assuming that no monsters have the same drop listed twice (while it's a valid situation). This is the mob_db entry for PORING: // Mob DB entry for PORING{ Id: 1002 // ... Drops: { Jellopy: 7000 Knife_: 100 Sticky_Mucus: 400 Apple: 1000 Empty_Bottle: 1500 Apple: 150 Unripe_Apple: 20 Poring_Card: 1 }},If you added this in the mob_db2:{ Id: 1002 Override: true Drops: { Apple: 0 // Which apple am I removing? The first? The last? Both? }},What would happen? Also if you added: { Id: 1002 Override: true Drops: { Jellopy: 5000 // Am I replacing the existing Jellopy? Or adding a new drop? Red_Potion: 1000 // What does this do? Replaces an existing entry? Adds a new drop? }},it wouldn't be clear what the result would be. To remove all existing entries and add a completely different drops list, what would you do? If it was able to override, you'd need a reasonable way to specify that you want to empty the list. About increasing the amount of drops and mvp drops, it's possible but it requires several source modifications (and possibly a very radical change in how they're represented in the SQL DB). I'm for the change, but I expect a lot of people to complain if we do, and their control panel breaks.
-
Yes, this is something we're looking into. I would also love to have it streamlined in a similar fashion. We decided not to merge it right away because of some concerns about the file size, but it is not excluded that it'll be merged in the near future.
-
Mob DB file structure overhaul Hello~! Just like the Item DB, the Mob DB has a less than optimal (read: terrible) format, that doesn't play well with Git or any other Version Control System. For example, this is a snippet from the current file: 1012,RODA_FROG,Roda Frog,Roda Frog,5,133,0,6,5,1,11,14,0,5,1,5,5,5,10,5,10,12,1,5,21,0x81,200,2016,816,288,0,0,0,0,0,0,0,918,9000,908,500,511,300,721,7,713,2000,0,0,0,0,0,0,0,0,4014,11013,WOLF,Wolf,Wolf,25,919,0,329,199,1,37,46,0,0,1,20,28,15,32,20,10,12,1,2,22,0x1089,200,1054,504,432,0,0,0,0,0,0,0,1011,20,920,9000,2308,10,517,650,528,1050,919,5500,578,600,0,0,0,0,4029,1 1014,SPORE,Spore,Spore,16,510,0,66,108,1,24,48,0,5,1,12,12,5,19,8,10,12,1,3,21,0x81,200,1872,672,288,0,0,0,0,0,0,0,921,9000,507,800,510,50,743,10,2220,40,7033,5,578,600,0,0,0,0,4022,11015,ZOMBIE,Zombie,Zombie,15,534,0,50,33,1,67,79,0,10,1,8,7,0,15,0,10,12,1,1,29,0x3885,400,2612,912,288,0,0,0,0,0,0,0,957,9000,724,5,938,1000,958,50,727,70,0,0,0,0,0,0,0,0,4038,1 Can you tell, at a glance, if any of these mobs drops a Strawberry? You certainly can't (unless you already know). Now, after locating the Strawberry drop, what happens if we want to remove it? 1012,RODA_FROG,Roda Frog,Roda Frog,5,133,0,6,5,1,11,14,0,5,1,5,5,5,10,5,10,12,1,5,21,0x81,200,2016,816,288,0,0,0,0,0,0,0,918,9000,908,500,511,300,721,7,713,2000,0,0,0,0,0,0,0,0,4014,11013,WOLF,Wolf,Wolf,25,919,0,329,199,1,37,46,0,0,1,20,28,15,32,20,10,12,1,2,22,0x1089,200,1054,504,432,0,0,0,0,0,0,0,1011,20,920,9000,2308,10,517,650,528,1050,919,5500,0,0,0,0,0,0,4029,1 1014,SPORE,Spore,Spore,16,510,0,66,108,1,24,48,0,5,1,12,12,5,19,8,10,12,1,3,21,0x81,200,1872,672,288,0,0,0,0,0,0,0,921,9000,507,800,510,50,743,10,2220,40,7033,5,0,0,0,0,0,4022,11015,ZOMBIE,Zombie,Zombie,15,534,0,50,33,1,67,79,0,10,1,8,7,0,15,0,10,12,1,1,29,0x3885,400,2612,912,288,0,0,0,0,0,0,0,957,9000,724,5,938,1000,958,50,727,70,0,0,0,0,0,0,0,0,4038,1 How many Strawberry entries did I remove and from which lines? Can you tell at a glance? Certainly not. What happens if we try to diff it? (this is the output of 'git diff' with the modified file) @@ -16,8 +16,8 @@ 1010,WILOW,Willow,Willow,4,95,0,5,4,1,9,12,5,15,1,4,8,30,9,10,10,12,1,3,22,0x81,200,1672,672,432,0,0,0,0,0,0,0,902,9000,1019,100,907,1500,516,700,1068,3500,1067,2000,1066,1000,0,0,0,0,4010,1 1011,CHONCHON,Chonchon,Chonchon,4,67,0,5,4,1,10,13,10,0,1,10,4,5,12,2,10,12,0,4,24,0x181,200,1076,576,480,0,0,0,0,0,0,0,998,50,935,6500,909,1500,1205,55,601,100,742,5,1002,150,0,0,0,0,4009,1 1012,RODA_FROG,Roda Frog,Roda Frog,5,133,0,6,5,1,11,14,0,5,1,5,5,5,10,5,10,12,1,5,21,0x81,200,2016,816,288,0,0,0,0,0,0,0,918,9000,908,500,511,300,721,7,713,2000,0,0,0,0,0,0,0,0,4014,1 -1013,WOLF,Wolf,Wolf,25,919,0,329,199,1,37,46,0,0,1,20,28,15,32,20,10,12,1,2,22,0x1089,200,1054,504,432,0,0,0,0,0,0,0,1011,20,920,9000,2308,10,517,650,528,1050,919,5500,578,600,0,0,0,0,4029,1 -1014,SPORE,Spore,Spore,16,510,0,66,108,1,24,48,0,5,1,12,12,5,19,8,10,12,1,3,21,0x81,200,1872,672,288,0,0,0,0,0,0,0,921,9000,507,800,510,50,743,10,2220,40,7033,5,578,600,0,0,0,0,4022,1 +1013,WOLF,Wolf,Wolf,25,919,0,329,199,1,37,46,0,0,1,20,28,15,32,20,10,12,1,2,22,0x1089,200,1054,504,432,0,0,0,0,0,0,0,1011,20,920,9000,2308,10,517,650,528,1050,919,5500,0,0,0,0,0,0,4029,1 +1014,SPORE,Spore,Spore,16,510,0,66,108,1,24,48,0,5,1,12,12,5,19,8,10,12,1,3,21,0x81,200,1872,672,288,0,0,0,0,0,0,0,921,9000,507,800,510,50,743,10,2220,40,7033,5,0,0,0,0,0,4022,1 1015,ZOMBIE,Zombie,Zombie,15,534,0,50,33,1,67,79,0,10,1,8,7,0,15,0,10,12,1,1,29,0x3885,400,2612,912,288,0,0,0,0,0,0,0,957,9000,724,5,938,1000,958,50,727,70,0,0,0,0,0,0,0,0,4038,1 1016,ARCHER_SKELETON,Archer Skeleton,Archer Skeleton,31,3040,0,483,283,9,128,153,0,0,1,8,14,5,90,5,10,12,1,1,29,0x2085,300,2864,864,576,0,0,0,0,0,0,0,932,4500,756,70,2285,3,1708,35,1752,1000,507,1800,1701,150,0,0,0,0,4094,1 //1017,THIEF_BUG_FEMALE,Thief Bug Female,Thief Bug Female,10,170,0,35,18,1,33,40,5,5,1,15,10,5,23,5,10,12,1,4,27,0x651,200,988,288,768,0,0,0,0,0,0,0,955,3500,910,250,1108,15,928,200,507,400,716,50,1002,400,0,0,0,0,4026,1 Oh, so two lines were modified. Now, to locate the entry that was changed. By the way, you didn't notice that I purposely introduced a syntax error, did you? (hint: count the commas in the SPORE line: there's one less entry!) Now what happens if someone else changes the file (on a nearby, but unrelated line), and you pull the change? <<<<<<< HEAD 1012,RODA_FROG,Roda Frog,Roda Frog,5,133,0,6,5,1,11,14,0,5,1,5,5,5,10,5,10,12,1,5,21,0x81,200,2016,816,288,0,0,0,0,0,0,0,918,9000,908,500,511,300,721,7,713,2000,0,0,0,0,0,0,0,0,4014,1 1013,WOLF,Wolf,Wolf,25,919,0,329,199,1,37,46,0,0,1,20,28,15,32,20,10,12,1,2,22,0x1089,200,1054,504,432,0,0,0,0,0,0,0,1011,20,920,9000,2308,10,517,650,528,1050,919,5500,0,0,0,0,0,0,4029,1 1014,SPORE,Spore,Spore,16,510,0,66,108,1,24,48,0,5,1,12,12,5,19,8,10,12,1,3,21,0x81,200,1872,672,288,0,0,0,0,0,0,0,921,9000,507,800,510,50,743,10,2220,40,7033,5,0,0,0,0,0,4022,1 =======1012,RODA_FROG,Roda Frog,Roda Frog,5,133,0,6,5,1,11,14,0,5,1,5,5,5,10,5,10,12,1,5,21,0x81,200,2016,816,288,0,0,0,0,0,0,0,918,9000,908,500,511,300,721,7,713,2000,578,600,0,0,0,0,0,0,4014,1 1013,WOLF,Wolf,Wolf,25,919,0,329,199,1,37,46,0,0,1,20,28,15,32,20,10,12,1,2,22,0x1089,200,1054,504,432,0,0,0,0,0,0,0,1011,20,920,9000,2308,10,517,650,528,1050,919,5500,578,600,0,0,0,0,4029,1 1014,SPORE,Spore,Spore,16,510,0,66,106,1,24,48,0,5,1,12,12,5,19,8,10,12,1,3,21,0x81,200,1872,672,288,0,0,0,0,0,0,0,0,921,9000,507,800,510,50,743,10,2220,40,7033,5,578,600,0,0,0,0,4022,1 >>>>>>> upstream change Well, have fun figuring out how to merge it! (hint: a Strawberry drop was added to RODA_FROG -- could you tell? And now, are you sure nothing else was changed? Doublecheck? Would you believe it if I said that SPORE's Job EXP was also decreased by two? Anything else? I'll leave that as homework.) How do we fix it? Once again, we're switching to a different file format. Just like last time, it'll be libconfig. We're aware there are plenty of other suitable file formats out there (who said yaml?), but unfortunately this is not the time and place to change what was already started, and we'll have to stick with libconfig for the time being. (we'll see about writing some tools that leverage the Hercules libconfig parser to lessen everyone's pain). Some highlights: There is no need for those annoying sequences of zeros. If a mob drops less than 10 items, only the needed entries will be there. The mob_db2 entries can be left incomplete and set to inherit the original mob_db entry. If you want your SPORE to have higher Attack, , you can just write that in your mob_db2, and let it read the other values from the mob_db, so that if we update them, you get the update automatically We can finally add more fields (to support new features) to the file at any time, easily and without having to edit all the lines (or force you to edit all the lines of your custom mob_db2)! What does it look like? Each entry follows this structure: { // =================== Mandatory fields =============================== Id: ID (int) SpriteName: "SPRITE_NAME" (string) Name: "Mob name" (string) // =================== Optional fields ================================ Lv: level (int, defaults to 1) Hp: health (int, defaults to 1) Sp: mana (int, defaults to 0) Exp: basic experience (int, defaults to 0) JExp: job experience (int, defaults to 0) AttackRange: attack range (int, defaults to 1) Attack: [attack1, attack2] (int, defaults to 0) Def: defence (int, defaults to 0) Mdef: magic defence (int, defaults to 0) Stats: { Str: strength (int, defaults to 0) Agi: agility (int, defaults to 0) Vit: vitality (int, defaults to 0) Int: intelligence (int, defaults to 0) Dex: dexterity (int, defaults to 0) Luk: luck (int, defaults to 0) } ViewRange: view range (int, defaults to 1) ChaseRange: chase range (int, defaults to 1) Size: size (int, defaults to 1) Race: race (int, defaults to 0) Element: (type, level) Mode: { CanMove: true/false (bool) Looter: true/false (bool) Aggressive: true/false (bool) Assist: true/false (bool) CastSensorIdle:true/false (bool) Boss: true/false (bool) Plant: true/false (bool) CanAttack: true/false (bool) Detector: true/false (bool) CastSensorChase: true/false (bool) ChangeChase: true/false (bool) Angry: true/false (bool) ChangeTargetMelee: true/false (bool) ChangeTargetChase: true/false (bool) TargetWeak: true/false (bool) } MoveSpeed: move speed (int, defaults to 0) AttackDelay: attack delay (int, defaults to 4000) AttackMotion: attack motion (int, defaults to 2000) DamageMotion: damage motion (int, defaults to 0) MvpExp: mvp experience (int, defaults to 0) MvpDrops: { AegisName: chance (string: int) ... } Drops: { AegisName: chance (string: int) ... } } Here's a PORING in the old format: 1002,PORING,Poring,Poring,1,50,0,2,1,1,7,10,0,5,1,1,1,0,6,30,10,12,1,3,21,0x83,400,1872,672,480,0,0,0,0,0,0,0,909,7000,1202,100,938,400,512,1000,713,1500,512,150,619,20,0,0,0,0,4001,1 And here's the same PORING in the new format: { Id: 1002 SpriteName: "PORING" Name: "Poring" Lv: 1 Hp: 50 Sp: 0 Exp: 2 JExp: 1 AttackRange: 1 Attack: [7, 10] Def: 0 Mdef: 5 Stats: { Str: 1 Agi: 1 Vit: 1 Int: 0 Dex: 6 Luk: 30 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 3 Element: (1, 1) Mode: { CanMove: true Looter: true CanAttack: true } MoveSpeed: 400 AttackDelay: 1872 AttackMotion: 672 DamageMotion: 480 MvpExp: 0 Drops: { Jellopy: 7000 Knife_: 100 Sticky_Mucus: 400 Apple: 1000 Empty_Bottle: 1500 Apple: 150 Unripe_Apple: 20 Poring_Card: 1 } }, Not convinced yet it's better? Do you like Strawberries? Irrelevant? Not really: { Id: 1012 SpriteName: "RODA_FROG" Name: "Roda Frog" Lv: 5 Hp: 133 Sp: 0 Exp: 6 JExp: 5 AttackRange: 1 Attack: [11, 14] Def: 0 Mdef: 5 Stats: { Str: 1 Agi: 5 Vit: 5 Int: 5 Dex: 10 Luk: 5 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 5 Element: (1, 1) Mode: { CanMove: true CanAttack: true } MoveSpeed: 200 AttackDelay: 2016 AttackMotion: 816 DamageMotion: 288 MvpExp: 0 Drops: { Sticky_Webfoot: 9000 Spawn: 500 Green_Herb: 300 Azure_Jewel: 7 Empty_Bottle: 2000 Roda_Frog_Card: 1 } }, { Id: 1013 SpriteName: "WOLF" Name: "Wolf" Lv: 25 Hp: 919 Sp: 0 Exp: 329 JExp: 199 AttackRange: 1 Attack: [37, 46] Def: 0 Mdef: 0 Stats: { Str: 1 Agi: 20 Vit: 28 Int: 15 Dex: 32 Luk: 20 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 2 Element: (2, 1) Mode: { CanMove: true Assist: true CanAttack: true ChangeTargetMelee: true } MoveSpeed: 200 AttackDelay: 1054 AttackMotion: 504 DamageMotion: 432 MvpExp: 0 Drops: { Emveretarcon: 20 Claw_Of_Wolves: 9000 Mantle_: 10 Meat: 650 Monster's_Feed: 1050 Animal's_Skin: 5500 Strawberry: 600 Wolf_Card: 1 } }, { Id: 1014 SpriteName: "SPORE" Name: "Spore" Lv: 16 Hp: 510 Sp: 0 Exp: 66 JExp: 108 AttackRange: 1 Attack: [24, 48] Def: 0 Mdef: 5 Stats: { Str: 1 Agi: 12 Vit: 12 Int: 5 Dex: 19 Luk: 8 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 3 Element: (1, 1) Mode: { CanMove: true CanAttack: true } MoveSpeed: 200 AttackDelay: 1872 AttackMotion: 672 DamageMotion: 288 MvpExp: 0 Drops: { Mushroom_Spore: 9000 Red_Herb: 800 Blue_Herb: 50 Spore_Doll: 10 Hat: 40 Poison_Spore: 5 Strawberry: 600 Spore_Card: 1 } }, { Id: 1015 SpriteName: "ZOMBIE" Name: "Zombie" Lv: 15 Hp: 534 Sp: 0 Exp: 50 JExp: 33 AttackRange: 1 Attack: [67, 79] Def: 0 Mdef: 10 Stats: { Str: 1 Agi: 8 Vit: 7 Int: 0 Dex: 15 Luk: 0 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 1 Element: (9, 1) Mode: { CanMove: true Aggressive: true CanAttack: true Angry: true ChangeTargetMelee: true ChangeTargetChase: true } MoveSpeed: 400 AttackDelay: 2612 AttackMotion: 912 DamageMotion: 288 MvpExp: 0 Drops: { Decayed_Nail: 9000 Cardinal_Jewel_: 5 Sticky_Mucus: 1000 Horrendous_Mouth: 50 White_Jewel: 70 Zombie_Card: 1 } }, Is it easier to spot all the Strawberry there? I bet. { Id: 1012 SpriteName: "RODA_FROG" Name: "Roda Frog" Lv: 5 Hp: 133 Sp: 0 Exp: 6 JExp: 5 AttackRange: 1 Attack: [11, 14] Def: 0 Mdef: 5 Stats: { Str: 1 Agi: 5 Vit: 5 Int: 5 Dex: 10 Luk: 5 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 5 Element: (1, 1) Mode: { CanMove: true CanAttack: true } MoveSpeed: 200 AttackDelay: 2016 AttackMotion: 816 DamageMotion: 288 MvpExp: 0 Drops: { Sticky_Webfoot: 9000 Spawn: 500 Green_Herb: 300 Azure_Jewel: 7 Empty_Bottle: 2000 Roda_Frog_Card: 1 } }, { Id: 1013 SpriteName: "WOLF" Name: "Wolf" Lv: 25 Hp: 919 Sp: 0 Exp: 329 JExp: 199 AttackRange: 1 Attack: [37, 46] Def: 0 Mdef: 0 Stats: { Str: 1 Agi: 20 Vit: 28 Int: 15 Dex: 32 Luk: 20 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 2 Element: (2, 1) Mode: { CanMove: true Assist: true CanAttack: true ChangeTargetMelee: true } MoveSpeed: 200 AttackDelay: 1054 AttackMotion: 504 DamageMotion: 432 MvpExp: 0 Drops: { Emveretarcon: 20 Claw_Of_Wolves: 9000 Mantle_: 10 Meat: 650 Monster's_Feed: 1050 Animal's_Skin: 5500 Wolf_Card: 1 } }, { Id: 1014 SpriteName: "SPORE" Name: "Spore" Lv: 16 Hp: 510 Sp: 0 Exp: 66 JExp: 108 AttackRange: 1 Attack: [24, 48] Def: 0 Mdef: 5 Stats: { Str: 1 Agi: 12 Vit: 12 Int: 5 Dex: 19 Luk: 8 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 3 Element: (1, 1) Mode: { CanMove: true CanAttack: true } MoveSpeed: 200 AttackDelay: 1872 AttackMotion: 672 DamageMotion: 288 MvpExp: 0 Drops: { Mushroom_Spore: 9000 Red_Herb: 800 Blue_Herb: 50 Spore_Doll: 10 Hat: 40 Poison_Spore: 5 Spore_Card: 1 } }, { Id: 1015 SpriteName: "ZOMBIE" Name: "Zombie" Lv: 15 Hp: 534 Sp: 0 Exp: 50 JExp: 33 AttackRange: 1 Attack: [67, 79] Def: 0 Mdef: 10 Stats: { Str: 1 Agi: 8 Vit: 7 Int: 0 Dex: 15 Luk: 0 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 1 Element: (9, 1) Mode: { CanMove: true Aggressive: true CanAttack: true Angry: true ChangeTargetMelee: true ChangeTargetChase: true } MoveSpeed: 400 AttackDelay: 2612 AttackMotion: 912 DamageMotion: 288 MvpExp: 0 Drops: { Decayed_Nail: 9000 Cardinal_Jewel_: 5 Sticky_Mucus: 1000 Horrendous_Mouth: 50 White_Jewel: 70 Zombie_Card: 1 } }, Removed them all? Yup. Want to see a diff? sure: diff --git a/db/pre-re/mob_db.conf b/db/pre-re/mob_db.confindex 0ac34d7..ff4f0bd 100644--- a/db/pre-re/mob_db.conf+++ b/db/pre-re/mob_db.conf @@ -588,7 +588,6 @@ mob_db: ( Meat: 650 Monster's_Feed: 1050 Animal's_Skin: 5500- Strawberry: 600 Wolf_Card: 1 } }, @@ -634,7 +633,6 @@ mob_db: ( Spore_Doll: 10 Hat: 40 Poison_Spore: 5- Strawberry: 600 Spore_Card: 1 } }, Looks pretty? Very much so. What happens if we pull a commit like the one before? { Id: 1012 SpriteName: "RODA_FROG" Name: "Roda Frog" Lv: 5 Hp: 133 Sp: 0 Exp: 6 JExp: 5 AttackRange: 1 Attack: [11, 14] Def: 0 Mdef: 5 Stats: { Str: 1 Agi: 5 Vit: 5 Int: 5 Dex: 10 Luk: 5 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 5 Element: (1, 1) Mode: { CanMove: true CanAttack: true } MoveSpeed: 200 AttackDelay: 2016 AttackMotion: 816 DamageMotion: 288 MvpExp: 0 Drops: { Sticky_Webfoot: 9000 Spawn: 500 Green_Herb: 300 Azure_Jewel: 7 Empty_Bottle: 2000 Strawberry: 600 Roda_Frog_Card: 1 } }, { Id: 1013 SpriteName: "WOLF" Name: "Wolf" Lv: 25 Hp: 919 Sp: 0 Exp: 329 JExp: 199 AttackRange: 1 Attack: [37, 46] Def: 0 Mdef: 0 Stats: { Str: 1 Agi: 20 Vit: 28 Int: 15 Dex: 32 Luk: 20 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 2 Element: (2, 1) Mode: { CanMove: true Assist: true CanAttack: true ChangeTargetMelee: true } MoveSpeed: 200 AttackDelay: 1054 AttackMotion: 504 DamageMotion: 432 MvpExp: 0 Drops: { Emveretarcon: 20 Claw_Of_Wolves: 9000 Mantle_: 10 Meat: 650 Monster's_Feed: 1050 Animal's_Skin: 5500 Wolf_Card: 1 } }, { Id: 1014 SpriteName: "SPORE" Name: "Spore" Lv: 16 Hp: 510 Sp: 0 Exp: 66 JExp: 106 AttackRange: 1 Attack: [24, 48] Def: 0 Mdef: 5 Stats: { Str: 1 Agi: 12 Vit: 12 Int: 5 Dex: 19 Luk: 8 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 3 Element: (1, 1) Mode: { CanMove: true CanAttack: true } MoveSpeed: 200 AttackDelay: 1872 AttackMotion: 672 DamageMotion: 288 MvpExp: 0 Drops: { Mushroom_Spore: 9000 Red_Herb: 800 Blue_Herb: 50 Spore_Doll: 10 Hat: 40 Poison_Spore: 5 Spore_Card: 1 } }, { Id: 1015 SpriteName: "ZOMBIE" Name: "Zombie" Lv: 15 Hp: 534 Sp: 0 Exp: 50 JExp: 33 AttackRange: 1 Attack: [67, 79] Def: 0 Mdef: 10 Stats: { Str: 1 Agi: 8 Vit: 7 Int: 0 Dex: 15 Luk: 0 } ViewRange: 10 ChaseRange: 12 Size: 1 Race: 1 Element: (9, 1) Mode: { CanMove: true Aggressive: true CanAttack: true Angry: true ChangeTargetMelee: true ChangeTargetChase: true } MoveSpeed: 400 AttackDelay: 2612 AttackMotion: 912 DamageMotion: 288 MvpExp: 0 Drops: { Decayed_Nail: 9000 Cardinal_Jewel_: 5 Sticky_Mucus: 1000 Horrendous_Mouth: 50 White_Jewel: 70 Zombie_Card: 1 } }, What do you expect? No conflicts. What's changed? Here: diff --git a/db/pre-re/mob_db.conf b/db/pre-re/mob_db.confindex 0ac34d7..59a53b6 100644--- a/db/pre-re/mob_db.conf+++ b/db/pre-re/mob_db.conf @@ -541,6 +541,7 @@ mob_db: ( Green_Herb: 300 Azure_Jewel: 7 Empty_Bottle: 2000 + Strawberry: 600 Roda_Frog_Card: 1 } }, @@ -588,7 +589,6 @@ mob_db: ( Meat: 650 Monster's_Feed: 1050 Animal's_Skin: 5500 - Strawberry: 600 Wolf_Card: 1 } }, @@ -600,7 +600,7 @@ mob_db: ( Hp: 510 Sp: 0 Exp: 66 - JExp: 108 + JExp: 106 AttackRange: 1 Attack: [24, 48] Def: 0 @@ -634,7 +634,6 @@ mob_db: ( Spore_Doll: 10 Hat: 40 Poison_Spore: 5 - Strawberry: 600 Spore_Card: 1 } }, But... I have several custom mobs, do I have to manually convert all of them...? It's true that you need to convert your item database to the new format, but we can do it for you! Go to http://haru.ws/hercules/mobdbconverter/ and paste (or upload) your mob_db2.txt (or even your mob_db.txt if you have custom entries there), pick between renewal or pre-renewal (or upload your item_db if it's customized), press the Convert button, wait a few seconds and you're done! It's already converted for you. Easy, isn't it? Don't trust us? No, no, we don't need your custom mobs, you can sleep safe... But if you still don't want to paste anything on a website... well, we have provided the source code of the converter script! It's in the 'tools' folder of the Hercules repository. All you need is a Python interpreter, version 2.6 or newer (and if you're running Linux or Mac OS, on either your server or your own computer, it's almost certain that you already have that). All you have to do is run it (example: python tools/mobdbconverter.py pre-re . < db/mob_db2.txt > db/mob_db2.conf), and your item database will be converted in a split second! What if I was using SQL mob databases? Well, you're out of luck. It was deprecated long ago and it's being removed. It'll stay available for website/control panel purposes though. An automated converter (much like the db2sql plugin for the item db) will be available soon, and even executed automatically whenever we update the mob db, to keep the sql counterpart in sync! I have this event mob entry that came with an old script I downloaded... No worries, you can get it converted. Use the same script (or the provided web page) you'd use to convert an entire mob database, it'll work just fine even for a mob or two! Special thanks To Ind, for bringing up the idea, a long time ago. To Andrei Karas for actually doing it, after picking up this project from the bottom of our forgotten items box. To me, for putting this at the bottom of the forgotten items box, and burying it with several other things so that it'd stay there until now (sigh) Links Merged pull request. Web-based converter.
-
It can be an internal IP, as long as it's the IP the char and map server use to connect to the login and char server respectively (it can even be 127.0.0.1, depending on your configuration). The UNIX equivalent of the 'ipconfig' command is 'ifconfig' (/sbin/ifconfig on some systems).
-
The issue is related to #737, indeed. @@kyeme the difference between allowed and trusted is that the former keeps the ipban/DoS checks enabled for the IPs you add, while the latter disables it. As I mentioned in the comment, adding IPs to 'trusted' can be a security threat, and should never be done if the user isn't sure about what they're doing. Adding IPs to 'allowed' is instead safe and doesn't decrease security compared to what we used to have before this was implemented. In your code snippets, I see that you're using '255.0.0.0' as subnet mask. That's not recommended (I understand that you saw it in the 127.0.0.1 line above, but that's a special address), because it means you're not only adding one IP, but an entire Class A subnet (all 16 million IPs that begin with the same first byte as yours). If you want to add a single IP, the subnet mask should be 255.255.255.255. If you're adding a LAN, it is 255.255.255.0 in most cases.
-
Thank you! Fixed in https://github.com/HerculesWS/Hercules/commit/fb46ee69b8e6375597c68e54b5a390108cc584bd
-
Please try again now. I've removed some upload file size restrictions that were set by default.
-
Very interesting. Windows 10 reports the wrong version once again. I'll have to read the documentation about whatever new trick they came up with this time. In any case, it won't be a problem as far as I'm aware. The only open issue right now, is that we don't support Visual Studio 2015 (it won't even compile), so please stick with VS2013 even on Windows 10, until I get to fix it.
-
Hello everyone~! Following Ind's resignation from his administrator position last month, we've been working on transferring our services to a new host. Some services have already been transferred without any downtime (most notably the stat-server), and now it's finally time to move the rest. The remaining services will be transferred during the upcoming week, starting tomorrow (Sunday, June 28th). You can expect some downtime. [*]Forum: The forum can be expected to go offline on June 28th at 17:30 GMT, for about two hours. Some features will be temporarily disabled (commit and pull request sidebar widgets), and will be enabled again within 24 or 36 hours. - Completed [*]Wiki: The wiki can be expected to go offline on June 28th at 17:30 GMT, for about two hours. - Completed [*]Bugtracker, git repository: Bugtracker and git repository (hosted by GitHub) won't experience any downtime. [*]Stat-server: The stat-server won't experience any downtime. [*]Hercules IRC bot (commit announcements in the #hercules channel): The IRC bot will go offline on June 28th at 17:30 GMT, for about two hours. The commit announcement hook may experience a longer downtime (up to four more hours). - Completed [*]HerculesWSAPI: The HerculesWSAPI service (HPM Hooks and SQL Item DB automatic re-generation) will be disabled on June 28th at 17:30 GMT, for up to eight hours. - Completed Through the week, there may be further, brief, downtimes (10-15 minutes each), for planned upgrades and improvements of the platform and individual services. Given the complexity of the system, and the number of moving parts, there may be unforeseen delays on the scheduled times. We'll do our best to minimize those. Status updates will be posted here as well as on IRC and on Twitter.
-
Right now you can't (unless you bring your own implementation). Since I'm currently working on a large batch of fixes for the HPM, I'll add this as well.
-
Hello. I apologize for replying after a month, but it was jsut brought to my attention, and since there were no replies during this time, I feel I should. Your maths is absolutely correct, and one could think it is indeed quite weird to see that happening. Your statements about the RNG are absolutely incorrect though. You claim that we use (among other things) the character ID to seed the PRNG. This would make it sound like we use a different RNG for each character (and that we only use random numbers for character-related things). We don't. The RNG is one and only one, and it is not attached to the current character, nor it uses any character identifiers or any kind (or even knows what a character is). The very same RNG is used by the server for all sorts of calculations in-between the item drops you mention (from mob walk direction and distance, to damage calculation during attacks, to teleport or mob spawn destinations or skill success chance. There are so many calls to the RNG between two mob drops, that it would be impossible to find any correlation or pattern just by observing the game. Now, while the RNG we're using isn't perfect, it's still renown as one of the best for use cases like ours. We're using a Mersenne Twister (specifically, the mt19937ar implementation by Matsumoto Makoto (http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/emt.html). As stated by the author, there are better versions of it now (we're going to switch to the SFMT implementation, which is faster and resolves some issues in case the RNG isn't initially well seeded, as soon as possible - we need to verify that it is supported by all compilers we currently target.) This said, I've personally tested the current RNG several times, and never seen anything that makes me think it's broken. I'm attaching some test results, that show how the distribution of generated numbers (I generated numbers in the [0~9999] range, since that's what we use mostly in Hercules) looks pretty good and unbiased. All the tests were done with the following code (pasted at the end of the do_init function in map.c): #define TEST_COUNT 1000000#define NORMALIZE 10000 int64 buckets[NORMALIZE]; memset(buckets, '0', sizeof(buckets)); for (i = 0; i < TEST_COUNT; ++i) { int num = rnd()%NORMALIZE; ++buckets[num]; } FILE *fp = fopen("rng.txt", "w"); for (i = 0; i < NORMALIZE; ++i) { fprintf(fp, "]: %5"PRId64" (%2.3f%%)n", i, buckets[i], buckets[i]*100.0/TEST_COUNT); } fclose(fp);and compiled with the following hardware/software, as reported by Hercules itself:[Info]: Hercules 64-bit for Mac OS X[Info]: Git revision (src): '9a0b3ad4fb551028f593500698dd560f85cdda6c'[Info]: Git revision (scripts): '9a0b3ad4fb551028f593500698dd560f85cdda6c'[Info]: OS version: 'Mac OS X 10.10.3 14D136 [x86_64]'[Info]: CPU: 'Intel Core i5 (2.3 GHz) [2]'[Info]: Compiled with Clang v6.1.0[Info]: Compile Flags: -g -O2 -pipe -ffast-math -Wall -Wextra -Wno-sign-compare -Wno-unused-parameter -Wempty-body -Wnewline-eof -Wint-conversion -Wenum-conversion -Wshorten-64-to-32 -Wconstant-conversion -Wbool-conversion -Wformat-security -Wno-format-nonliteral -Wno-switch -Wno-missing-field-initializers -Wshadow -fno-strict-aliasing -ggdb -DMAXCONN=16384 -I../common -DHAS_TLS -DHAVE_SETRLIMIT -DHAVE_STRNLEN -DDEBUG -DDISABLE_RENEWAL -I/usr/includeThe tests show the distribution of, respectively, the first million, hundred millions, billion, ten thousands random numbers after server startup. http://jmp.sh/V12VZ7I 1,000,000 http://jmp.sh/pigjlRT 100,000,000 http://jmp.sh/NU8SigY 1,000,000,000 http://jmp.sh/R8a3lCF 10,000 As you can see, each of the possible values is generated about 0.01% times (1/10,000), without any visible bias.
-
What version of Visual Studio is that? As of VS2013 (latest released stable version), there's no snprintf in their libraries, so this should never happen. If this is VS2015 release candidate, please wait for Microsoft to release the final version, for we'll start testing with and add support for it only *after* it is released in its final version.
-
After updating Hercules to latest rev.. got this error
Haru replied to Ragnar Lothbrok's question in General Server Support
What compiler and OS? It's probably fixable by changing 'void *' to 'char *' in the ZEROED_BLOCK_SIZE definition (in cbasetypes.h). If you can confirm it, I'll commit the fix asap -
[map server error] skill_lv > 0 in function 'unknown'
Haru replied to buttletbuttlet's question in General Server Support
It should be fixed for the most part now now. If you find any more of those errors, please let me know. -
Ah, wonderful point. Yes, I'm aware of those, and I agree. Those /shouldn't/ be merged into one line. A separate 'mes' call would still be kept where necessary -- mostly with line breaks required by the dialogue's punctuation. Translation-wise, those are separate sentences anyways, so it makes less sense for them to be in the same string.
-
I personally love this idea (and I did this in the past, in custom scripts I wrote). The only argument that there might be against this is that, by changing the scripts to that format, they might word-wrap differently than official servers. I don't think it's a real issue, but I'd like to hear the others about this. As of commit 09dd209, we actually have source support for a nice syntax such as: mes "When you see a broadcast" // Yep, no semicolon, and no plus sign between this and the next line. " announcing that we have" // Just close the quotes and reopen them on the next line. " arrived at your destination," " please use one of the exits" // Ah, and yes, there can be comments between the lines. " located at the north and" " south ends of the Airship."; // ^ Well, this space is because otherwise there would be no space between "and<>south".And after the script engine parses it, it's as if there was just one long string in one line (except, it looks prettier in editors, being split in multiple lines.) This also means that the translation engine sees just one string.
-
Which is why we have a specific anti-maya-purple-cheat feature in Hercules, that prevents the server from sending the position of hidden or cloaked people altogether. Your screenshot shows that you're able to see *yourself*. That's because the client always knows where *you* are (for obvious reasons). You should try with enemy units (mobs, or PvP/GvG enemies), and you'll see that - even if you trick your client into thinking that they never hid or cloaked, it still won't show any of their moves.
-
naviluagenerator not work on Hercules latest version version
Haru replied to Thunderbolt's question in Plugin Support
The warnings you show don't seem to be a problem. The plugin should still compile. Line 150 and 155 are two lines that are the same as path.c in Hercules (and they cause a warning in your plugin because of different compiler settings -- you can disable sign comparison check warnings in your VS solution) Line 501, 566, 567, 568, 569, 570, 571 are recommending the use of a Microsoft-specific function instead of a standard function. For obvious reasons, we can't do that. You can either silence or ignore those warnings. The warnings we generally silence are: - 4018 - 4100 - 4800 - 4996 (or at the very least, 4018 and 4996 in this case). If there's any other issues that prevent the plugin from working correctly, please let me know. -
I'm personally against this (well, now the pull request got merged accidentally, but we are still in time to revert it). Is there a reason to need two separate table names? i.e. it doesn't make much sense to have both tables loaded at once, it'll always be either one or the other. Edit: if there's a real reason (other than following rAthena on something that sounds like going backwards), please tell, as I can be easily convinced if you have good arguments.
-
That's right, we unfortunately still don't support the direction constants in script headers, but only in commands (i.e. movenpc) x.x I guess that would make for a nice pull request, if anyone feels like to implement it before we do
- 40 replies
-
- guides
- scripting support
-
(and 5 more)
Tagged with:
-
We'll be updating the guidelines and including them in the doc folder of the repository soon, to give them more visibility. About the use of set, the reason why I recommend against using it at all (other than it being deprecated) is that by using direct assignment, the language is probably easier for newcomers. If they ever used any other scripting or programming language (and chance is they did at school, perhaps), they'll be probably used to direct assignment rather than a command to set variables. This way they won't have to learn a new (arguably useless) thing such as using 'set'.
- 40 replies
-
- guides
- scripting support
-
(and 5 more)
Tagged with:
-
GmOcean, good job there! Can I ask you to edit a little something, so that people will script according to the scripting style standards we're setting? (see working draft at http://herc.ws/board/topic/5062-scripting-standards/ ) Setting variables should always happen through direct assignment and without the use of the 'set' command, where possible. So, instead of set Zeny, Zeny - 1000, it should be Zeny -= 1000; instead of set .heal_price, 1000, it should be .heal_price = 1000; and so on. Some parts of the scripting standards are still being changed, so don't take everything you see there as set in stone, but the part about using 'set' to manipulate variables already is. Thank you!
- 40 replies
-
- guides
- scripting support
-
(and 5 more)
Tagged with:
-
Mumbles: see my reply in the pull request. It actually becomes easier with .@select, as you don't even need to use the @menu variable. Garr: but using labels is even worse than using a switch, and makes the script less readable. If several options lead to the same result, their case labels in the switch can be grouped together without break in between, if you don't wish to use select. Or, nobody forces you to use a switch, and you can use if/else conditions if you prefer. switch (select("a:b:c:d:e")) {case 1:case 2:case 4: mes "a, b and d lead here."; break;case 3: mes "this is c."; break;}// and e does nothing Or .@choice = select("a:b:c:d:e"));if (.@choice == 3) { mes "this is c.";} else if (.@choice < 5) { mes "a, b and d lead here.";}// and e does nothing
- 40 replies
-
- guides
- scripting support
-
(and 5 more)
Tagged with:
-
The FluxCP at the link you posted seems to be misconfigured, and doesn't even have the (weak) protection provided by the index.html files that are provided with a standard FluxCP installation. The server owner should check their setup and re-create the file they deleted. (on a side note, the only thing I was able to see by visiting the link you posted, was the file list -- none of the files were actually readable, as they all returned an HTTP error 500. I'm not sure whether the files were previously visible, and I was late to the party) That said, there are indeed some weak points and missing index.html files in FluxCP, that should be fixed. If any of the maintainers wants some insight, please PM me, as I won't be able to do it before several hours from now (possibly over IRC if you want a quick reply, or here is fine otherwise).
- 206 replies
-
- control panel
- flux
-
(and 1 more)
Tagged with: