Jump to content
Ridley

April & May Digest 2020

Recommended Posts

April & May Digest 2020

The following digest covers the months of April 1st - May 31st 2020


Team Changes

  • None

 

Added

  • Added the possibility to declare local NPC functions as public or private. (#2142)

    • Functions declared as public can be called from other scripts with the syntax `"npc name"::function_name()`.

    • The configuration option `script_configuration.functions_private_by_default` controls whether functions are public or private when not specified.

  • Added a new cast condition `MSC_MAGICATTACKED` to the mob skill database, allowing mobs to react to magical attacks. (#2733, issue #2578)

  • Added support for level-specific values in the skill database fields `Hit`, `AttackType`, `InterruptCast`, `CastDefRate`, `Requirement.State`, `Unit.Id`, `Unit.Interval`, `Unit.Target`, `Requirements.Items.Amount` (part of #2731)

    • Removed hardcoded required item amounts for various skills, moving them to the skill database.

  • Added support for `Requirements.Items.Any` in the skill database, allowing skills that require any one of their item conditions to be verified (as opposed to all). (part of #2731, issue #1250)

  • Added support for `Requirements.Equip` in the skill database, allowing to specify a required equipment to cast a skill. (part of #2731)

    • Removed hardcoded equip requirements for various skills, moving them to the skill database.

  • Added support for `Requirements.MaxSPTrigger` in the skill database, allowing to specify a maximum SP percentage that allows to cast a skill. (part of #2731)

  • Added/updated packets, encryption keys and message tables for clients up to 2020-05-20. (#2713)

  • Added support for the gcc sanitizer flags `address-use-after-scope`, `pointer-overflow`, `builtin`, `pointer-compare`, `pointer-subtract`, `shift-exponent`, `shift-base`, `sanitize-address-use-after-scope`. (part of #2713)

  • Added support for binary and octal number literals in scripts and libconfig configuration files, using the syntax 0b000 / 0o000. (#2671)
    Added support for number separators in number literals in scripts and libconfig configuration files. The symbol `_` can be used as grouping separator (`1_000_000`, `0x_ffff_ffff`, etc). (part of #2671)

  • Added support for overriding `ENABLE_SC_SAVING`, `MAX_CARTS`, `MAX_SLOTS`, `MAX_AMOUNT`, `MAX_ZENY`, `MAX_BANK_ZENY`, `MAX_FAME`, `MAX_CART` through CFLAGS. (#2220)

  • Added a `skill_enabled_npc` battle flag allowing to specify whether self-targeted or targeted skills can be used while interacting with NPCs. (part of #2718, issue #862)

  • Added the `loudhailer()` script command, as used by the `Megaphone_` item. (#2758, issue #2751)

  • Added the new pets (including the jRO exclusive ones) and their related items/monsters to the renewal database. (#2689)

  • Added constants `ALL_MOBS_NONBOSS`, `ALL_MOBS_BOSS`, `ALL_MOBS` for the special mob IDs for global skill assignment in the mob skill database. (part of #2691)

  • Added support for `__func__` on Windows, since it's now available in every supported compiler. (part of #2691)

  • Added documentation for the mob skill database. See `doc/mob_skill_db.conf`. (#2680)

  • Added missing functions for the name ack packets for `BL_ITEM` and `BL_SKILL`. (part of #2695)

  • Added/updated packets and encryption keys for clients up to 2020-04-14. (#2695)

  • Added support for packets `ZC_LAPINEUPGRADE_OPEN`, `CZ_LAPINEUPGRADE_CLOSE` and `ZC_LAPINEUPGRADE_RESULT` and a placeholder for `CZ_LAPINEUPGRADE_MAKE_ITEM`. (part of #2695)

  • Added a new cell type `cell_noskill`, to block skill usage. (#2188)

  • Added/updated packets, encryption keys and message tables for clients up to 2020-04-01. (#2663)

  • The `setpcblock()` and `checkpcblock()` can now be used on another character by passing the account id. (#2668)

  • Added new StatusChange types (`SC_POPECOOKIE`, `SC_VITALIZE_POTION`, `SC_SKF_MATK`, `SC_SKF_ATK`, `SC_SKF_ASPD`, `SC_SKF_CAST`, `SC_ALMIGHTY`) and updated relevant items. (#2658, related to #1177)

  • Added _libbacktrace_ support (currently Linux-only) for better error call stack logging. (#2581)

 

Changed

  • Added validation for the maximum length of permanent string variables and consolidated it to 255 characters. This requires a database migration. (#2705, issue #1037)

  • Split the `mapreg` SQL table into separate tables for integer and string variables. This requires a database migration. (#2720)

  • Updated the AUTHORS file to include names and emails from every commit so far. A helper script `tools/authors.sh` to extract them has been added. (#2729, issue #245)

  • Updated the drop chance of the Black and White Wing Suits. (#2739, issue #562)

  • Improved validation and bounds checking in the skill database loader. (#2731)

    • Increased the maximum length of the skill descriptions (display names) to 50. (part of #2731)

    • Increased the maximum skill level to 20 (to support `NPC_RUN`). (part of #2731)

    • Capped the SkillInstances values to 25 (`MAX_SKILLUNITGROUP`) in the skill database. (part of #2731)

  • Extended the `item_enabled_npc` battle flag and the `enable_items()`/`disable_items()` script commands with finer grained options to allow the use of usable items or equipment while interacting with NPCs. (#2718)

  • Changed the default setting of `player_warp_keep_direction` to match the official servers' setting. (#2752)

  • Replaced the (failing) gitlab-ci centos6 builds with centos8 (released in september 2019). (#2759)

  • Removed warning messages about missing elements in the mob db, since it's an optional field. (part of #2689)

  • Updated the renewal pet database with the correct values and bonuses. (part of #2689, issue #2435)

  • Changed `mob_getfriendstatus()` to consider character as friends of their support monsters, for consistency with `mob_getfriendhprate()`. (part of #2691)

  • Changed `MSC_AFTERSKILL` to trigger on any skill when its `ConditionData` is 0, for consistency with `MSC_SKILLUSED`. (part of #2691)

  • Improved data validation and error reporting in the mob skill database. (part of #2691)

  • Changed return values of `mob_skill_use()` and `mobskill_event()`. Any third party code that uses them needs to be updated. (part of #2691)

  • Changed the battle configuration flag `manner_system` to be applied immediately to any existing `SC_NOCHAT`. (#2696, issue #227)
    Changed the `atcommand()` command to ignore `PCBLOCK_COMMANDS`. (#2062)

  • Extended the atcommand `@fakename` with a new `options` parameter, to select which names will be displayed. (#2637, related to issue #1966 and #2168)

  • Refactored the pet system code. (#2600, issues #2434 and #303)

    • Added enumerations for pet hunger/intimacy levels

    • Added value capping to `pet_set_intimate()` function.

    • Adjusted pet catch rate calculation. The old, custom, calculation can be restored by setting the `pet_catch_rate_official_formula` battle config flag to false.

    • Adjusted pet intimacy calculation when feeding.

    • Improved validation of the Pet DB fields and of the input of various pet related functions.

    • Removed the redundant `SpriteName` field from pet DB.

    • Changed `EggItem` field in pet DB to be mandatory.

    • Added new field `HungerDecrement` to pet DB. This replaces the `pet_hungry_friendly_decrease` battle config setting.

    • Added new field `Intimacy.StarvingDelay` to pet DB.

    • Added new field `Intimacy.StarvingDecrement` to pet DB.

    • Increased `MAX_MOB_DB` to 22000.

    • Added pet DB documentation file. (`doc/pet_db.txt`)

    • Removed fields from pet DB where default values can be used.

    • Added intimacy validation to pet DB `EquipScript` fields. This replaces the `pet_equip_min_friendly` battle config setting.

    • Adjusted `inter_pet_tosql()` and `inter_pet_fromsql()` functions to use prepared statements.

    • Refactored and/or updated code style of various functions that were touched by this pull request.

  • Added a backtrace to the error message of `clif_unknownname_ack()`. (part of #2663)

  • Added a `UNIQUE` constraint to the `userid` column of the `login` SQL table to prevent having multiple accounts with the same name. (#2666, related to #2169)

  • Increased the column size of `list`for the `ipbanlist` SQL table to accomodate for non-wildcard IPv4 and for IPv6 compatiblity. (#2665, issue #2631)

 

Fixed

  • Fixed the logic and interaction between the (element)proof Potions and Undead Scrolls and their status icons. (#2708)

  • Fixed an issue in the Lost Puppies quest causing the dogs to be unable to reappear. (#2698)

  • Fixed a possible data corruption caused by gender mismatch after a changesex/changecharsex operation. (#2714, issue #985)

  • Fixed a warning and name truncation when receiving a whisper message with a recipient name with a length of 24 characters. This allows to whisper to scripts with a name length up to 20 (through the `NPC:name` syntax). (#2721, issue #718)

  • Fixed interaction between `itemskill()` other item/skill uses, including other `itemskill()`. The autocast code has been changed to use a vector, to allow multiple concurrent skills. (#2699)

    • It's now possible to use multiple `itemskill()` calls in the same item, as long there is at most one targeted skill, and it's the last one used.

    • It's now possible to use items while the target cursor for a previously activated skill is visible, without aborting it. (issue #816)

    • It's now possible to use a scroll while casting another skill (and the provided skill will be cast after the current one finishes). (issue #1026)

  • Fixed use of Fly Wing/Butterfly Wing while riding a cash shop mount (Boarding Halter) and having a falcon. (part of #2699, issue #2750)

  • Fixed the `Requirements.MaxHPTrigger` conditions for mercenary skills. (part of #2731)

  • Fixed a possible memory corruption or crash in the mob delayed removal function. (part of #2713, issue #2719)

  • Fixed a crash in the `npcshopdelitem()` script command. (part of #2713)

  • Fixed a crash in the achievement progress update code. (part of #2713)

  • Fixed a possible crash in the RODEX check name function. (part of #2713)

  • Added null pointer checks for missing view data in clif and status code. (part of #2713)

  • Added a check for the current map in mob and map code. (part of #2713)

  • Fixed an error or possible crash when a mob dies on an invalid map. (part of #2713)

  • Fixed an incorrect npc ID for the MOTD script after reloading or unloading scripts. (part of #2713)

  • Fixed an use after free in `party->broken()`. (part of #7213)

  • Fixed a possible crash in `mapif->guild_withdraw()`. (part of #2713)

  • Fixed a null pointer error in `unit->steptimer()`. (#2723, issue #2707)

  • Fixed the left-shift of a negative value in `GN_CRAZYWEED_ATK`. (#2734, issue #1151)

  • Fixed a missing "Beloved" attribute on the eggs of renamed pets. (#2744, issue #2743)

  • Fixed an inverted logic in the `storage_use_item` battle flag. (#2746)

  • Fixed the mineffect map property flag so that it's not affected by the character's minimized effects but only by the map type. It's enabled on all the guild castles, regardless of whether WoE is running. (#2754, issue #803)

  • Fixed a crash in the equip check code if a character logs wearing an item that was previously, but is no longer, equippable. (#2745)

  • Fixed a compiler warnings in 32 bit builds. (#2759)

  • Fixed `SC_AUTOTRADE`, `SC_KSPROTECTED` and `SC_NO_SWITCH_EQUIP` incorrectly recognized as unknown status changes. (#2686, issue #2684)

  • Prevented `SC_KSPROTECTED` from starting on dead monsters. (part of #2686)

  • Fixed character unhiding while disguised or when using `@option 0`. (#2687, issues #1556 and #2104)

  • Fixed an incorrect order of operations causing results too small in various calculations related to free cell search, mob skill chances/delays, exp penalty, pet hunger and friendly rates, cast duration. (#2690)

  • Fixed errors caused by `pet_ai_sub_hard()` called for monsters that haven't been added to a map yet. (#2693)

  • Fixed a wrong packet error displayed when using an incorrect password for the char-login connection. (part of #2695)

  • Fixed a security check in the lapine ack packet handler. (part of #2695)

  • Fixed some incorrect assumptions about the skill index values, causing the Bard/Dancer soul link to grant the wrong skills. (#2710, issue #2670)

  • Fixed some conditions that could cause a skill to be attempted to save to the database with a negative skill level, resulting in query errors and data loss. (part of #2710)

  • Fixed the skill type of `RK_DRAGONBREATH` and `RK_DRAGONBREATH_WATER` to be `BF_WEAPON` and support the `bLongAtkRate` bonus. (#1304)

  • Fixed `SC_TELEKINESIS_INTENSE` to add percent MATK instead of fixed MATK. (part of #1304)

  • Fixed a regression that prevented pets from hatching. (#2685, issue #2683)

  • Fixed memory violations and incorrect handling of `npc_data` in the quest info code. (#2682)

  • Fixed an issue that prevented the fake name to show up when using `@fakename` in RE clients. (part of #2637)

  • Fixed a compiler error in `PACKET_ZC_SE_CASHSHOP_OPEN`. (part of #2663, issue #2669)

  • Added missing libraries into the plugins Makefile, causing a linking error when a plugin uses MySQL or other libraries. (part of #2663)

  • Fixed a bug causing failed assertions that appeared when attacking a skill unit (such as Ice Wall). (#2678)

  • Fixed a bug causing failed assertions in `timer_do_delete()`, related to `ud->walktimer`. (#2676)

  • Fixed a bug allowing to equip bullets and grenades regardless of the weapon type. (#2660, issue #2661, related to #2579)

  • Fixed a memory leak in barter NPCs. (#2655)

  • Fixed a pointer overflow in the script command `getiteminfo()`.  (#2656)

  • Refactored and fixed several bugs in the skill auto-cast system. (#2657, issue #1211)

 

Deprecated

  • Deprecated the (unintended and undocumented) possibility of calling local NPC functions as event labels if their name started with `On`. (part of #2142, issue #2137)
    •   The functionality is now disabled by default, and can be enabled by changing the `script_configuration.functions_as_events` setting.

 

Removed

  • Removed old debug code from the `SC_DANCING` case of `status_change_end_()`. (#2736, issue #2716)
  • Removed useless `FixedCastTime` values from the pre-re skill database. (part of #2731)
  • Removed the `pet_hungry_friendly_decrease` battle config setting, superseded by the `HungerDecrement` field of the Pet DB. (part of #2600)
  • Removed the `pet_equip_min_friendly` battle config setting, superseded by the code inside the Pet DB `EquipScript` fields. (part of #2600)
  • Removed the redundant `SpriteName` field from pet DB. (part of #2600)

 

Special thanks to

@Haru, @4144, @Kenpachi, @Asheraf, @hemagx, @skyleo, @meko, @Zarbony@Jedzkie, @danieldpl

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

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