Jump to content

Haru

Administrators
  • Content Count

    382
  • Joined

  • Days Won

    38

Everything posted by Haru

  1. Haru

    Compiling Problem

    Umm, never seen anything like that o.o I'm not familiar with TortoiseGit, but it should work like any other git client... Could you show the full content of the build output pane after a clean and rebuild? (the tab next to the one you screenshotted - I don't remember the exact name, and I don't have a windows PC nearby to check)
  2. Rationale: This is a follow-up to the Mob DB conversion to libconfig format from some months ago, and brings it on par with the Item DB. Contents: - The JName field has been restored (and made optional), for the entries that need it. - Several numeric values in the mob DB have been replaced with constants (race, size, element), to make it more readable. - The db2sql plugin can now produce SQL scripts for both item and mob databases. - Some floating point rounding errors have been fixed (i.e. before this update, the 100% of 820 was, apparently, 819). Impact: - This changeset does not affect backwards compatibility of the mob database, although it's recommended to update any custom entries to use the new constants. - When running the db2sql plugin, only the current mode (renewal or pre-renewal) is generated. If both are wanted, both the core and the plugin will need to be compiled twice, in each of the modes. Details: The format of Mob DB entries was changed (but the old format is still supported, although not recommended): { /* Before */ Id: 1001 SpriteName: "SCORPION" Name: "Scorpion" Lv: 24 // ... ViewRange: 10 ChaseRange: 12 Size: 0 Race: 4 Element: (3, 1) Mode: { // ... } MoveSpeed: 200 // ... }, { /* After */ Id: 1001 SpriteName: "SCORPION" Name: "Scorpion" Lv: 24 // ... ViewRange: 10 ChaseRange: 12 Size: "Size_Small" Race: "RC_Insect" Element: ("Ele_Fire", 1) Mode: { // ... } MoveSpeed: 200 // ... }, The mob_db scripts are now updated automatically by the HerculesWSAPI bot, like the Item Database. Merge Date: Fri, 5 Feb 2016 00:19:58 +0300 Related Pull Requests: - #993 - https://github.com/HerculesWS/Hercules/pull/993 - Mob DB support for the db2sql plugin [Haru] Related Commits: - 50de6b4 - https://github.com/HerculesWS/Hercules/commit/50de6b4 - Mon, 7 Dec 2015 02:58:02 +0100 - Modified Mob DB loader to behave like the Item DB loader [Haru] - b7c5b53 - https://github.com/HerculesWS/Hercules/commit/b7c5b53 - Sat, 19 Dec 2015 18:15:04 +0100 - Added apply_percentrate and apply_percentrate64 functions [Haru] - 8121e1d - https://github.com/HerculesWS/Hercules/commit/8121e1d - Sun, 20 Dec 2015 02:24:07 +0100 - Replaced several floating-point operations with integer operations [Haru] - 84a16af - https://github.com/HerculesWS/Hercules/commit/84a16af - Sat, 19 Dec 2015 16:07:22 +0100 - Removed duplicate code from the db2sql plugin [Haru] - 9e92231 - https://github.com/HerculesWS/Hercules/commit/9e92231 - Sat, 19 Dec 2015 16:11:43 +0100 - Changed DB2SQL plugin to not cross-convert databases [Haru] - 25451ef - https://github.com/HerculesWS/Hercules/commit/25451ef - Sun, 6 Dec 2015 18:40:27 +0100 - Renamed some db2sql* plugin functions to itemdb2sql* [Haru] - e1c5556 - https://github.com/HerculesWS/Hercules/commit/e1c5556 - Mon, 7 Dec 2015 04:29:55 +0100 - Added modb2sql converter to the db2sql plugin [Haru] - 519263f - https://github.com/HerculesWS/Hercules/commit/519263f - Sun, 20 Dec 2015 02:53:44 +0100 - Preliminary update of the mob_db sql scripts to the latest txt snapshot [Haru] - 867b94b - https://github.com/HerculesWS/Hercules/commit/867b94b - Sun, 20 Dec 2015 03:27:24 +0100 - Replaced numeric elements with Ele_* constants in the mob database [Haru] - 2e13fef - https://github.com/HerculesWS/Hercules/commit/2e13fef - Sun, 20 Dec 2015 13:35:20 +0100 - Replaced numeric races with RC_* constants in the mob db [Haru] - ca40527 - https://github.com/HerculesWS/Hercules/commit/ca40527 - Sun, 20 Dec 2015 13:38:45 +0100 - Replaced numeric sizes with Size_* constants in the mob db [Haru] - 0426f8c - https://github.com/HerculesWS/Hercules/commit/0426f8c - Sun, 20 Dec 2015 03:28:55 +0100 - Re-added support for the JName field in the mob db [Haru] - f434a9f - https://github.com/HerculesWS/Hercules/commit/f434a9f - Sun, 20 Dec 2015 05:03:08 +0100 - Re-added JName for the monsters that require it [Haru] - dcc9ee4 - https://github.com/HerculesWS/Hercules/commit/dcc9ee4 - Sun, 20 Dec 2015 05:19:46 +0100 - Updated Mob Skill DB SQL script [Haru] - 88a6bbe - https://github.com/HerculesWS/Hercules/commit/88a6bbe - Fri, 5 Feb 2016 00:19:58 +0300 - Merge pull request #993 from HerculesWS/mobdb2sql [Andrei Karas] - 3414587 - https://github.com/HerculesWS/Hercules/commit/3414587 - Thu, 4 Feb 2016 22:20:40 +0100 - HPM Hooks Update [Hercules.ws] - f6ee3f1 - https://github.com/HerculesWS/Hercules/commit/f6ee3f1 - Thu, 4 Feb 2016 22:20:42 +0100 - ItemDB SQL Sync [Hercules.ws]
  3. Rationale: This is an (unplanned) episode in the txt->libconfig conversion project. The reason for the conversion is that we suddenly needed a way to add attributes (specifically, "deprecated" to some constants, since simply removing them would mean that any scripts using them would silently fail (talk about terrible script engine). Contents: The Constants Database (db/const.txt) has been converted to the usual libconfig format. This allows us to add new attributes to the constants. Old, unused, constants have been marked as deprecated using the facilities provided by the new database format (mostly, Job_Alchem, VAR_*), and their use will now trigger a warning at parse time (previously, it would result in a value of zero being used silently, in a very nasty way). A new docuemntation file (doc/constants.md) is provided, listing all the constants available to the scripting engine (coming from Constants DB, Item DB, Mob DB, Skill DB or even hardcoded in source), since there wasn't any centralized place where all the constants were listed. The file will get automatically updated in future through the HerculesWSAPI bot. The document is readily available online through the following link: https://github.com/HerculesWS/Hercules/blob/master/doc/constants.md (it will always point to the latest version) Impact: The impact of this changeset on customizations is low. If using custom constants in const.txt, users can either use the provided script to re-generate their constants.conf, or add the entries manually. Details: The format of constants.conf is the following: constants_db: { /************* Entry structure (short) ************************************ Identifier: value // (int) ************* Entry structure (full) ************************************* Identifier: { Value: value // (int) Parameter: true // (boolean) Defaults to false. Deprecated: true // (boolean) Defaults to false. } **************************************************************************/ (each entry can use either the short or full format). A special "comment__" field can be added, to generate a corresponding title in the documentation file. Comments will have no other effects (they're not normally parsed, but they're available to plugins). Merge Date: Wed, 13 Jan 2016 19:22:45 +0300 Related Pull Requests: - #1088 - https://github.com/HerculesWS/Hercules/pull/1088 - Constdb revamp [Haru] - #908 - https://github.com/HerculesWS/Hercules/pull/908 - Add EQP_ = Equipment Position constants [AnnieRuru] - #1124 - https://github.com/HerculesWS/Hercules/pull/1124 - Constdb2doc plugin (doc/constants.md) [Haru] Related Commits: - a815472 - https://github.com/HerculesWS/Hercules/commit/a815472 - Sun, 10 Jan 2016 02:01:55 +0100 Converted const.txt to libconfig format [Haru] - 6ae9045 - https://github.com/HerculesWS/Hercules/commit/6ae9045 - Sun, 10 Jan 2016 02:33:15 +0100 Added support to mark constants in db/constants.conf as deprecated [Haru] - 3f56ffc - https://github.com/HerculesWS/Hercules/commit/3f56ffc - Sun, 10 Jan 2016 02:33:41 +0100 Marked Job_Alchem and Job_Baby_Alchem as deprecated [Haru] - 99f707e - https://github.com/HerculesWS/Hercules/commit/99f707e - Wed, 13 Jan 2016 11:47:47 +0100 Added converter script from const.txt to constants.conf [Haru] - 49081f4 - https://github.com/HerculesWS/Hercules/commit/49081f4 - Wed, 13 Jan 2016 19:22:45 +0300 Merge pull request #1088 from HerculesWS/constdb [Andrei Karas] - 9e48e2a - https://github.com/HerculesWS/Hercules/commit/9e48e2a - Wed, 13 Jan 2016 17:23:31 +0100 HPM Hooks Update [Hercules.ws] (dastgir/master) - de33b02 - https://github.com/HerculesWS/Hercules/commit/de33b02 - Fri, 15 Jan 2016 20:34:26 +0100 Fixed a typo in the constdb converter script [Haru] - a1310e2 - https://github.com/HerculesWS/Hercules/commit/a1310e2 - Wed, 6 Jan 2016 16:38:43 +0800 Remove VAR_ constants - there are 2 same constants for setlook script command, remove the wrong one - VAR_ constant added by l one_wolf is invalid https://github.com/HerculesWS/Hercules/commit/f4278f36db32f35e535a0ea8feb1cf83ca95019e, so use the LOOK_ constant [AnnieRuru] - 7610346 - https://github.com/HerculesWS/Hercules/commit/7610346 - Sat, 16 Jan 2016 20:23:57 +0100 Merge pull request #908 from AnnieRuru/request_26 [Haru] - e3253b4 - https://github.com/HerculesWS/Hercules/commit/e3253b4 - Mon, 25 Jan 2016 16:52:27 +0100 Added source support for special comments in the constdb [Haru] - 72a75cb - https://github.com/HerculesWS/Hercules/commit/72a75cb - Mon, 25 Jan 2016 15:53:56 +0100 Added constdb2doc plugin [Haru] - 15bca8f - https://github.com/HerculesWS/Hercules/commit/15bca8f - Mon, 25 Jan 2016 16:00:44 +0100 Generated doc/constants.md [Haru] (HEAD -> constdb2doc, origin/constdb2doc) Trivia: The constdb2doc plugin introduced in 72a75cb is based on my 'vimsyntaxgen' plugin (see https://github.com/HerculesWS/StaffPlugins/tree/master/Haru/vimsyntaxgen).
  4. That's certainly true, the RO population is declining and all, but please understand that Hercules has very little to do with the number of players playing the game. I'm not here to implement the latest NPCs or to obtain information from official servers (I don't even have an account on official servers, nor I have access to any inside information or leaks), but you can't deny that other developers in the Hercules team are constantly adding new features or adapting to game mechanics changes. My role here is to oversee the development, review code, and bring architectural improvements when they're necessary. Please also keep in mind that, while Hercules is mostly a Ragnarok Online emulator, it provides a foundation that can be used with other games (see The Mana World / evol online for an example).
  5. Rationale: Historically, we've received several crash reports or null pointer reports that were of barely any use, because they were produced by servers built without debug information. Contents: The default build mode, when using the UNIX ./configure && make build scripts, is now set to include debug information. Impact: The performance decrease when built in debug mode should be negligible. In any case, it's still possible to disable the debug mode while compiling. Users concerned with minimal performance improvements, who don't want a readable backtrace in case of issues, can still pass --disable-debug to the configure script. Details: The configure script provides a command line flag to enable/disable/configure the debug mode options: Before this commit, the default, when passing no options, was equivalent to: ./configure --disable-debug After this commit, the default will be: ./configure --enable-debug Another recommended option worth mentioning, that might improve the debugger's ability to produce meaningful information (in case of gdb) is: ./configure --enable-debug=gdb Merge Date: Sun, 10 Jan 2016 18:34:56 +0300 Related Pull Requests: - #1090 - https://github.com/HerculesWS/Hercules/pull/1090 - Enable debug information in configure by default. [Andrei Karas] Related Commits: - d0af903 - https://github.com/HerculesWS/Hercules/commit/d0af903 - Sun, 10 Jan 2016 18:34:56 +0300 Enable debug information in configure by default. [Andrei Karas] - c01f745 - https://github.com/HerculesWS/Hercules/commit/c01f745 - Sun, 10 Jan 2016 18:41:19 +0100 Merge pull request #1090 from 4144/enabledebug [Haru]
  6. January! Fixed, thank you (the one in the title was correct)
  7. Rationale: This is part of a larger source cleanup project. Following the code style guidelines we decided to adopt (linux kernel guidelines), typedefs should be avoided except where necessary. At the same time, we noticed that we have far too many explicit casts through the code, that might easily hide a coding error (for example a variable that changed type), so we're going to try and remove as many of those as possible as well. Contents: The various TBL_* typedefs are completely unnecessary (they're only needed for internal use by the BL_CAST() macro). As such, they shouldn't be used through the code, so they have been deprecated (they're not marked as deprecated yet, due to technical reasons, but you can assume they are). Taking the chance, the BL_CAST() macro was changed to a family of macros (BL_CAST, BL_CCAST, BL_UCAST, BL_UCCAST), each with different behavior and purpose: - BL_CAST(): Casts its argument to the specified type, after ensuring the block list was of the correct type. The argument must be non-constant, and it may be evaluated more than once (i.e. unsafe to use with mapit->next(x)) - BL_CCAST(): Same as BL_CAST, but it takes a const block list pointer, and returns a const object. - BL_UCAST(): Casts its argument to the specified type, without verifying the source block list (it is the caller's care to do that). The argument is guaranteed to be evaluated only once, making it suitable to be used with mapit->next(x) or similar functions. - BL_UCCAST(): Same as BL_UCAST(), but takes a const block list pointer, and returns a const object. Impact: Custom code may stop compiling until the appropriate changes are made. Changes are easy/trivial (mostly doable as a find and replace) Details: Any use of the TBL_* typedefs must be replaced with the corresponding struct: - TBL_PC -> struct map_session_data - TBL_NPC -> struct npc_data - TBL_MOB -> struct mob_data - TBL_ITEM -> struct flooritem_data - TBL_CHAT -> struct chat_data - TBL_SKILL -> struct skill_unit - TBL_PET -> struct pet_data - TBL_HOM -> struct homun_data - TBL_MER -> struct mercenary_data - TBL_ELEM -> struct elemental_data Any explicit casts of a struct block_list to any of the above types, should be replaced with the most appropriate BL_CAST() variant (as described above). Merge Date: Wed, 6 Jan 2016 17:36:33 +0300 Related Pull Requests: - #1034 - https://github.com/HerculesWS/Hercules/pull/1034 - Changed all TBL_* to the appropriate structs [Haru] - #1024 - https://github.com/HerculesWS/Hercules/pull/1024 - Change all TBL_* to actual struct to follow unix kernel syntax [hemagx] Related Commits: - b69f7b8 - https://github.com/HerculesWS/Hercules/commit/b69f7b8 - Sat, 26 Dec 2015 11:17:14 +0200 Change all TBL_PC to struct map_session_data as per style guidelines [hemagx] - 1249dc2 - https://github.com/HerculesWS/Hercules/commit/1249dc2 - Sat, 26 Dec 2015 11:17:14 +0200 Change all TBL_MOB to struct mob_data as per strly guidelines [hemagx] - 3364658 - https://github.com/HerculesWS/Hercules/commit/3364658 - Sat, 26 Dec 2015 11:17:14 +0200 Change all TBL_HOM to struct homun_data as per style guidelines [hemagx] - 00c95f6 - https://github.com/HerculesWS/Hercules/commit/00c95f6 - Sat, 26 Dec 2015 11:17:14 +0200 Change all TBL_MER to struct mercenary_data as per style guidelines [hemagx] - b040c61 - https://github.com/HerculesWS/Hercules/commit/b040c61 - Sat, 26 Dec 2015 11:17:14 +0200 Change all TBL_SKILL to struct skill_data as per style guidelines [hemagx] - 829ebdd - https://github.com/HerculesWS/Hercules/commit/829ebdd - Sat, 26 Dec 2015 11:17:14 +0200 Change all TBL_PET to struct pet_data as per style guidelines [hemagx] - 1f71f41 - https://github.com/HerculesWS/Hercules/commit/1f71f41 - Sat, 26 Dec 2015 11:17:14 +0200 Change all TBL_ELEM to struct elemental_data as per style guidelines [hemagx] - 3007a37 - https://github.com/HerculesWS/Hercules/commit/3007a37 - Sat, 26 Dec 2015 11:17:14 +0200 Change all TBL_NPC to struct npc_data as per style guidelines [hemagx] - a1b0dae - https://github.com/HerculesWS/Hercules/commit/a1b0dae - Sun, 27 Dec 2015 17:35:25 +0100 Introduced the BL_UCAST() macro as an alternative to explicit casts [Haru] - aa574e3 - https://github.com/HerculesWS/Hercules/commit/aa574e3 - Mon, 28 Dec 2015 15:14:22 +0100 Added const variants of BL_CAST/BL_UCAST: BL_CCAST/BL_UCCAST [Haru] - b3c722e - https://github.com/HerculesWS/Hercules/commit/b3c722e - Sun, 27 Dec 2015 18:17:24 +0100 Replaced some explicit casts with BL_UCAST/BL_UCCAST [Haru] - f878d5e - https://github.com/HerculesWS/Hercules/commit/f878d5e - Mon, 28 Dec 2015 00:16:39 +0100 Replaced some explicit casts with BL_UCAST/BL_UCCAST [Haru] - 2055585 - https://github.com/HerculesWS/Hercules/commit/2055585 - Mon, 28 Dec 2015 00:24:24 +0100 Replaced some map->id2sd calls with the proper map->id2XX function [Haru] - 5db8be9 - https://github.com/HerculesWS/Hercules/commit/5db8be9 - Mon, 28 Dec 2015 02:05:09 +0100 Moved status_get_homXXX macros to status.c [Haru] - 0e05c1e - https://github.com/HerculesWS/Hercules/commit/0e05c1e - Mon, 28 Dec 2015 15:13:02 +0100 Replaced some explicit casts with BL_UCAST [Haru] - e3eac13 - https://github.com/HerculesWS/Hercules/commit/e3eac13 - Mon, 28 Dec 2015 15:41:36 +0100 Replaced the remaining explicit casts with BL_CAST/BL_UCAST [Haru] - d5199ce - https://github.com/HerculesWS/Hercules/commit/d5199ce - Wed, 6 Jan 2016 17:36:33 +0300 Merge pull request #1034 from HerculesWS/bl_cast [Andrei Karas] - f0fb759 - https://github.com/HerculesWS/Hercules/commit/f0fb759 - Wed, 6 Jan 2016 15:37:16 +0100 HPM Hooks Update [Hercules.ws] - 0772dd0 - https://github.com/HerculesWS/Hercules/commit/0772dd0 - Wed, 6 Jan 2016 23:56:48 +0300 Fix null pointer access after previous commits. [Andrei Karas] - 2af2132 - https://github.com/HerculesWS/Hercules/commit/2af2132 - Fri, 8 Jan 2016 16:51:59 +0100 Fixed a mapserver crash (too small allocation) [Haru] Trivia: While many of the changes here would have been possible with find and replace, I decided to review each and every of them (the actual replacement was mostly done with a vim macro, but not fully automated so I could see what the code was, and possibly do additional cleanup by hand), in order to review up some old, wrong code. It turned out that we were casting things that we didn't need to cast, or using wrong map->bl2XX() functions in several places. It costed some hours of work, but it was definitely worth it.
  8. Oh come on everyone, where have you all been during the past 7 months? I mean, there's been a warning since June, when a NPC was using a number instead of a constant (the only thing that changed now is that it's extended to the '-1', everything else was already changed last June)
  9. The constants don't need to be looked up, since they have somewhat of a meaning (they already tell you if a NPC is a man, a woman, an animal, a monster or a thing for example, and they describe in a way or another what it looks like). Numbers on the other hand, are just numbers, and don't have any descriptive meaning. It's discouraged to use numbers, since they're too easy to mistake (and several errors in the past, both in scripts and in source, were caused by misplaced numbers, very hard to detect while reviewing code)
  10. @@Oxxy 49 66 20 79 6F 75 20 70 72 65 66 65 72 20 72 65 61 64 69 6E 67 20 6E 75 6D 62 65 72 73 20 74 68 61 6E 20 77 6F 72 64 73 2C 20 6E 6F 74 68 69 6E 67 20 70 72 65 76 65 6E 74 73 20 79 6F 75 20 66 72 6F 6D 20 64 65 66 69 6E 69 6E 67 20 74 68 6F 73 65 20 6E 75 6D 62 65 72 73 20 61 73 20 63 6F 6E 73 74 61 6E 74 73 2C 20 62 79 20 65 64 69 74 69 6E 67 20 63 6F 6E 73 74 61 6E 74 73 2E 63 6F 6E 66 2E. Sarcasm aside, it's just ASCII codes. If you decode it, it contains a solution that should work for you. @@vykimo If you're not pleased, you can use any other emulator. We provide both content updates and architecture modernization, and we will keep doing so as long as the project lives. If you want to stick to the early 2000's coding practices *and* use Hercules at the same time, then feel free to make your own fork, and undo the changes you don't like. As you can see in my post, I specified the related commits, so they're easy to revert.
  11. Not intentional, I'll look into it Okay, checked. The reason is that we don't parse the view ID, if the shop NPC is floating. I'll probably change that (I believe it's a good idea to enforce the syntax more strictly, to avoid unexpected issues later)
  12. Rationale: This is part of the NPC scripts standardization project. In the past, NPCs were defined with numeric View IDs, while now we've replaced most of them with more human-readable (and as such easier to maintain) constants - the same constants that AEGIS scripts use, making the numeric IDs obsolete (and deprecated). Contents: When the NPC View IDs were converted to constants, the only leftover was the special ID '-1' we use for invisible / floating NPCs, that didn't have an equivalent constant defined at the time. This changeset defines a constant 'FAKE_NPC' for it, and replaces all the '-1' view IDs with the new constant. The exception for the -1 case is removed from the code (making it effectively deprecated, just like the other numeric IDs). Impact: The impact of this changeset on custom scripts is low. All old code will still work (but it'll throw a deprecation warning). It's recommended to update all the affected code as soon as possible - the support for the old style IDs may be removed from the code at any time in the future (after at least a month from the commit). Details: The use of the sprite ID '-1' in NPC headers to specify an invisible NPC is now deprecated. 'FAKE_NPC' should be used instead. This affects all NPC types (script, shop, trader, duplicate, etc) /* Before: */ - script TurboTrap#tt_main -1,{ // ... } in_moc_16,65,162,0 duplicate(SinTrap) 02_2 -1,0,0 /* Now: */ - script TurboTrap#tt_main FAKE_NPC,{ // ... } in_moc_16,65,162,0 duplicate(SinTrap) 02_2 FAKE_NPC,0,0 Merge Date:Thu, 31 Dec 2015 23:40:48 +0100 Related Pull Requests: - #1000 - https://github.com/HerculesWS/Hercules/pull/1000 - define FAKE_NPC as -1 in const.txt [AnnieRuru] Related Commits: - ef171a8 - https://github.com/HerculesWS/Hercules/commit/ef171a8 - Mon, 21 Dec 2015 19:59:38 +0800 define FAKE_NPC as -1 in const.txt [AnnieRuru] - efaaf84 - https://github.com/HerculesWS/Hercules/commit/efaaf84 - Mon, 21 Dec 2015 20:12:45 +0800 Replace -1,{ with FAKE_NPC,{ replace using Notepad++ [AnnieRuru] - b4c99db - https://github.com/HerculesWS/Hercules/commit/b4c99db - Tue, 29 Dec 2015 02:16:49 +0100 Replaced leftover -1 view IDs with FAKE_NPC [Haru] - 32a42ee - https://github.com/HerculesWS/Hercules/commit/32a42ee - Tue, 29 Dec 2015 02:17:26 +0100 Extended the numeric view ID deprecation to '-1' (FAKE_NPC) [Haru] - 0e99004 - https://github.com/HerculesWS/Hercules/commit/0e99004 - Thu, 31 Dec 2015 23:40:48 +0100 Merge branch 'AnnieRuru-request_29' into hercules [Haru] Trivia: Commit efaaf84 was done with a find and replace in Notepad++, to globally replace '-1' view IDs with 'FAKE_NPC' (as described in the commit notes). Commit b4c99db caught the leftovers (less common cases where the -1 is not followed by ',{'), and was powered by vim macros and grep (and vimgrep). It also features manual clean up of trailing whitespace or extra tabs in a small subset of the affected lines.
  13. For a fact, the FluxCP project doesn't really have a maintainer right now. It's an open source project, though, and it's on github, so anyone can make a pull request if there's a bug (and someone will merge it). I have never audited the entire fluxcp code / structure (and probably never will, it's over-complicated), but only parts of it.
  14. @@Dastgir yes, strings are "unlimited" (meaning that you can add as many translations as you want - because translated strings count against your plan's limit), but it doesnt seem to be able to load more than 30,000 *source* strings. @@4144 the problem is that Hercules doesn't care about the file encoding... We just parse the strings and send them as they are to the client (and the client prints them according to the selected langtype, as it used to happen in the windows 9x days). This means that the strings ee read aren't necessarily cp949, but they may be in any codepage or even in unicode already, depending on who wrote the scripts and for what client (I write them in utf8 for example, since I use an utf8 capable client). Since we don't know what codepage the source files are, we can't reliably convert them. If we want to do this, we could perhaps specify it somewhere in the config, and implement some codepage-aware handling of strings. This might add some dependencies a bit too heavy though (iconv? x.x)
  15. An update on transifex: now gettext validates the file correctly (see huld-improvements branch), but transifex still can't load it. The error message is now "'utf8' codec can't decode byte 0xa1 in position 4915429: invalid start byte". I believe it gets confused by the strings in CP949/EUC-KR encoding (which are invalid if the file is read as utf8)
  16. Yep... we're not passing the strings through sv_escape_c.
  17. Oh, you're right, that's fixed in the huld-improvements branch, I forgot about that. The string it's choking on is msgid "by pressing the '^4D4DFFCtrl^000000' and the '^4D4DFF - ^000000,' '^4D4DFF = ^000000,' or '^4D4DFF ^000000' keys."I'll fix that as well (and all other escape sequences)
  18. Just made an account to try transifex as well. Here's my feedback so far: poeditor project url: https://poeditor.com/join/project/Dw7RGEwo1A Good: - it integrates with github, and it can pull .pot files (and changes to it) from there Bad: - Even with the account that should allow unlimited strings, it doesn't load more than 30,000 strings per file (we have about 120,000). The integration idea is nice in theory, but considering that the .pot file we generate is over 20MB big, it's a bad idea to keep it in the repository. We'd need to make a separate repository for it. But the 30,000 strings limit makes it all useless. crowdin project url: https://crowdin.com/project/hercules Good: - Seems to load all 120,000 strings - Offers an API (and an opensource, crossplatform API client), so we could upload the translations via Hercules bot automatically. - It integrates with the desktop application POEdit, so people who don't want to use the web UI, can use the desktop application. Bad: - No automatic git integration I like the API this service offers. It doesn't pull from a git repository, but keeping a 20MB+ translations file in the repository is out of the question anyways. With the API, we can automatically upload from the Hercules API bot after every commit that alters strings. I think it's an ideal situation. The POEdit integration is nice, although I haven't tried it out yet (I will). transifex Good: - N/A (I was unable to test it) Bad: - It seems to have problems with our .pot file (it errors on the r, saying it's an invalid character - it can't handle carriage returns) Unfortunately I was unable to try this out, because of the r error.
  19. That way won't really solve it though. It needs to be collapsed into one string (in languages like Italian, the sentence order is different, so you can't keep the "how much do" and the "cost" parts separate, but you need to reorder them - see my sprintf example above This is a proof of concept of what the NPC scripts would look like with this change (I only did the Parmy Gianino NPC): https://gist.github.com/MishimaHaruna/4b0e735d8f6fffb005ad --- Okay, since AnnieRuru brought up a good argument in favor of hard-wrapping strings in some languages (specifically, Eastern Asian languages), I went and tested a bit, and it turns out that the client understands the r character: See image: That allows us to use sprintf this way: mes sprintf(_("How much dor" "12 %s,r" "1 %sr" "and 5 %s costr" "after a 24 %% discount?"), getitemname(Red_Potion), getitemname(Wing_Of_Butterfly), getitemname(Wing_Of_Fly));
  20. I signed up for a test. Both poeditor.com and crowdin.com seem promising, both offer free accounts for OSI-licensed software. Crowdin integrates with the POEdit desktop app.
  21. Sure, I don't mind. The problem with this is that different languages will have different sentence order, so if we want it to be easily translatable, we can't really split sentences with a +, like we've been doing so far. For example, given the following sentence (npc/jobs/2-2/alchemist.txt:565) mes "How much do"; mes "12 Red Potions,"; mes "1 Butterfly Wing"; mes "and 5 Fly Wings cost"; mes "after a 24 % discount?";If we change it to: mes "How much do"; mes "12 " + getitemname(Red_Potion) + ","; mes "1 " + getitemname(Wing_Of_Butterfly); mes "and 5 "+ getitemname(Wing_Of_Fly) + " cost"; mes "after a 24 % discount?";then it would generate the strings:"How much do";"12 "",""1 ""and 5 "" cost""after a 24 % discount?"Translating them individually to another language (for example, Italian), would get you this:"Quanto";"12 "",""1 ""e 5 "" costano""con uno sconto del 24 %?"which produces the (broken) sentence: mes "Quanto"; mes "12 " + getitemname(Red_Potion) + ","; mes "1 " + getitemname(Wing_Of_Butterfly); mes "e 5 "+ getitemname(Wing_Of_Fly) + " costano"; mes "con uno sconto del 24 %?";while the correct sentence should look like: mes "Quanto vengono a costare"; mes "12 " + getitemname(Red_Potion) + ","; mes "1 " + getitemname(Wing_Of_Butterfly); mes "e 5 "+ getitemname(Wing_Of_Fly); mes "con uno sconto del 24 %?";This would be easily translatable if the sentence was written in this form: mes sprintf(_("How much do 12 %s, 1 %s and 5 %s cost after a 24%% discount?"), getitemname(Red_Potion), getitemname(Wing_Of_Butterfly), getitemname(Wing_Of_Fly));because it'd produce just one translatable sentence:"How much do 12 %s, 1 %s and 5 %s cost after a 24%% discount?"which could be easily translated to:"Quanto vengono a costare 12 %s, 1 %s e 5 %s con uno sconto del 24%%?"Edit: even better would be to implement positional tokens (%1, %2, %3, etc) instead of "dumb" %s. In some cases it might be necessary to reorder the translated elements in a way that can't be achieved with a simple %s. But as a beginning, a simple sprintf would be enough.
  22. The format of 'mes' messages also needs improvements (ie merge all the lines of a sentence into the same string, be it separated by n or not). I'm personally for not separating it by n (except in the places where a line break is needed), so that the text flow will change accordingly to the font use by a (hexed) client. For mob and NPC names, we currently don't have a plan. I'm open to ideas. Announce/dispbottom, etc are all translatable, by using the _() macro. FluxCP currently doesn't have a maintainer, so I'm not sure whether it'll happen.
  23. Yes, it's pretty much ready, I fixed various issues yesterday. It still needs more testing, but I should be able to pull request it today
  24. Yes, you probably have to keep the 0x part to input them on that website. About the safety of posting those keys... Well, they are in the client. Just like you edit them, someone could read them from the exe, so it's not like they're something really secret. The purpose is mostly to have them change at every packet, to avoid WPE packet spamming, not really to prevent other kinds of attacks.
  25. 1. If the key passes the test on that URL, you can use it on all clients, yes (provided that you compile Hercules with the same key) 2. That URL will tell you. I don't really know how to generate a strong key, but I observed that the second key must be an odd number (ending with 1, 3, 5, 7, 9, B, D, F). If it's an even number, it will repeat after a few iterations. Not all the sets with an odd key are strong, but all sets where the second key is even, are weak (that happens because of the key schedule function that Gravity uses). 3. I'll try to explain it briefly. After each packet sent, the client (and the server), applies a function to the current encryption (sub-)key to make it different for each packet sent (this is what prevents tools such as WPE from working for packet spamming, because if the key changes, a packet can't be re-played as it is). Each packet will be a different encryption/decryption sub-key, which is derived from the three original keys, by applying some sort of mathematical function (this is called the key schedule). The page you linked, runs the key schedule algorithm over and over (iterates it) several times, checking if the encryption sub-key changes every time. When it detects that the key didn't change, it reports a failure. The iteration number is how many times the key schedule function was applied before it started repeating the same key. I hope it makes any sense
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.