Skip to content
This repository has been archived by the owner on May 20, 2023. It is now read-only.

OTServBR-Global - Version Stable 1.3.1 (Patch)

Compare
Choose a tag to compare
@dudantas dudantas released this 29 Apr 18:58
· 134 commits to main since this release

Release version: Stable v1.3.1 (Patch) - e06dd7ff

Download Tibia Client 12.86.11871

Download OTClient 1.0, thanks for @mehah

Fixes

  • Crash related to creature death (@dudantas, opentibiabr/canary@03e8e09e)
    The crash happened in a specific scenario, when the creature was removed (and recreated) and the target reference was not removed, when it tried to target another creature, it crashed.
  • Market issue related to stash items and gold duplication (@marcosvf132, opentibiabr/canary@7082aff3)
    There is an issue on the market that was making the item remove count 0 when accepting buy offer.
    Issue reported by @Sparkz023

Changes from Major Release version: stable 1.3.0

Canary:

Features/Enhancements

  • Complete rework on npcs shop add item functions (@dudantas, opentibiabr/canary@caf0a970)
  • Experience tracker (@marcosvf132, opentibiabr/canary@990da240)
    On the oldest protocols, the client was handling the experience changes by it's own, now on the new protorocol (12.72+), we need to send to the client the right amount of experience that the player has gainned so it can update it's tracker
  • Auto Loot, Quick Looting in stack and Auto Bank function (@omeranha, opentibiabr/canary@5cb9ff7b)
    Auto loot using your manage loot containers quick loot categories and items filter, can be enabled in config.lua!
    Quick loot in stack, up to 30 corpses, enabled using client option.
    Auto Bank function, the dropped coins from monsters will be automatically deposited to your bank account, can be enabled in config.lua.
  • No disconnect on death (@omeranha, opentibiabr/canary@4f8667a6)
    no more disconnection when player dies
  • Solved incompatibility problem with otclient redemption (@marcosvf132, opentibiabr/canary@c46f64d2)
    Readjust protocolgame to follow the right pattern. Changing hardcoded expected bytes on OnRecvFirstMessage to follow the cip client and fix incompatible with otclient protocolgamesend.
  • Decouple g_game in true singleton (@dudantas, @lgrossi, opentibiabr/canary@126e7df)
    Game class decoupled in a true singleton, thus allowing direct calls without needing to instantiate in each file.
    Credits to @lgrossi for made the decouple logic.
  • Fix build to not use asan on relase mode (@Costallat, opentibiabr/canary@87edf62)
    Not use ASAN for release build
    Remove cmake settings(replaced with presets)
    Adjust GitHub Actions triggers
  • Cmake features and update workflows to use gcc 11 (@dudantas, opentibiabr/canary@905f774)
    Update sonarcloud version and sonar/codeql/ubuntu build to use gcc 11
    Added gcc minimum version 8 in cmakelists.txt
    Reorganized find_packages
    Fix possible bug in the spdlog link library
  • Add tag serverSaveTime on config.lua (@beats-dh, opentibiabr/canary@e848604)
    With this modification, the configuration of the global server save can be done directly in config.lua, thus centralizing configurable things in a single place
  • Add missing librarys; daily reward, modal windows and reward boss (@dudantas, opentibiabr/canary@c45f1d2)
    Added somes missing librarys: daily reward, modal window, reward boss
    Added new scripts for: monsters and spells
  • Party hunt analyzer. (@marcosvf132, opentibiabr/canary@c17279a)
    Adding the "new" feature Party Hunt Analyzer. There is one thing that you must know before you start testing it, so please read the entire PR commentary.
  • Added not moveable action function (@dudantas, opentibiabr/canary@9c49c95)
    Not moveable action id = 100
    So that the item cannot be moved, just put this action id in the item
  • Add windows relelease build with address sanitizer (@Costallat, opentibiabr/canary@8552c10)
    Adds new release build with asan enabled to help tracking problems
  • Added missing effects from version 12: soulwar/tentugly/supreme cube (@Aerwix, opentibiabr/canary@371f116)
  • Added a new method to register scripts by the map position and rework on "registerLuaEvent" function (@dudantas, opentibiabr/canary@a7e6426)
    See all description on the commit
    With this modification, we can register action scripts without needing the action id/unique id or the item being on the map, as there is also a second parameter that creates the item (if it doesn't exist).
  • Decouple all global variables from extern in true singleton (@beats-dh, @lgrossi, opentibiabr/canary@b87372f)
    All the global variables * g_* were decoupled to true singletons, reducing the dependencies between the objects and simplifying the amount of calls and instances. They used to be partial singletons mixed with global variables, that way we have one, and only one instance that is accessed via the getInstance methods, that are now the * g_* functions.
  • Prey system rework (CPP) + Hunting task system (@marcosvf132, opentibiabr/canary@42af88d)
    Complete rewrite of old prey system from LUA to CPP and implementation of Hunting Tasks system;
    Do not test with GOD char or with low amount of creatures registered on bestiary. The PR already include the necessary amount of then;
    Addition of hunting task system and entire rework of prey system. All working on CPP with few LUA integration.
  • Check for message type parameter wrong (@dudantas, opentibiabr/canary@ea7fbce)
    How to test: Add a message with a wrong or none parameter, such as:
    player:sendTextMessage(MESSAGE_WRONG, "Message")
  • Rework on fluids colors and new monster race type (INK) (@marcosvf132, opentibiabr/canary@ce36520)
    Description
    Full rework on the way that the server handles the fluids, to use one single ENUM and remove all the garbage functions and maps that used to store the same values for fluids over and over again.
    Add new creature race type named INK. This new race type is used mostly on creatures on the tibia "The Secret Library". Attacking those creatures or slain then will now create the proper type of blood pool/splash.
    Resolves opentibiabr/canary#123
    OTServerBr-Global PR: #544
  • Add script casks and kegs (store item for refill potions) (@lucasgrizante, opentibiabr/canary@256a6ee)
  • Move client version from config.lua to definitions.h (@dudantas, opentibiabr/canary@4580324c)
    It's a tag that works at the compilation level and shouldn't be in config.lua, because the version is always just one and cannot be modified at the configuration level.
  • Rework on items to extinquish OTB file and use client 12 protobuf instead (@marcosvf132, opentibiabr/canary@68d0475c)
    See the commit description for more information

New Lua functions

Fix

  • Register Npc Type - add missing currency method for npcs revscriptsys (@Aerwix, opentibiabr/canary@9f37c02a)
  • Bestiary tracker list loader (@marcosvf132, opentibiabr/canary@9a02596f)
  • Reverting item tier to 0 + Market/Cyclopedia item tier (@marcosvf132, opentibiabr/canary@4c7a35a3)
  • Life and mana leech amount/chance attribute (@guispiller, opentibiabr/canary@56ddcf2f)
    Fix to correct the item tags of mana leech and life leech items attributes.
    Extra: added attributes missing on some soulwar weapons.
  • "allowpickupable" tag on items.xml, resolves trashholder items (@dudantas, opentibiabr/canary@e3df5835)
  • Ring transformation on creation (@marcosvf132, opentibiabr/canary@0eacb35b)
    Rings was transforming into wrong itemIDs on creation.
  • Add missing duration timestamp attribute for decay system (@beats-dh, opentibiabr/canary@15275499)
  • logout message connection lost on bed and offline training and remove unused tag on druid familiar (@omeranha, opentibiabr/canary@e6abcc8f)
    Fixes connection lost message when using an bed or offline training statues, added a check to identify when a player was "forced" removed
  • Auto Bank not removing coins from monster corpse (@omeranha, opentibiabr/canary@0059314e)
  • docker-compose: add env to correct mysql host (@bruno-costa, opentibiabr/canary@611a44ef)
  • Few hireling issues (@marcosvf132, opentibiabr/canary@3808591d)
    Fix hireling outfit change client crash.
    Fix hireling server crash when saying 'hi - lamp - yes'.
    Convert hireling itemids from serverID to clientID.
  • 'wound' bestiary charm register (@marcosvf132, opentibiabr/canary@deeb21ff)
    Wound bestiary charm was not showing on the cyclopedia charm store due to one miss config on the Lua file.
  • Multiple purchase of the same mount from store. (@Corlyone, opentibiabr/canary@3e94dc2b)
    When buying a mount, it was possible to buy it indefinitely, causing the player to lose coins.
  • Not be able to accept offer if you are a character on the same account (@dudantas, opentibiabr/canary@65b53485)
    Fix for player selling offer not receiving money if offline (thanks and credits for @gccris)
    Added verification to prevent transactions with characters of the same account
  • [Fx] Rework of checkCreatureAsKnown and fix of client debug (@beats-dh, @lgrossi, opentibiabr/canary@77f152e3)
    Before, if you moved with the char diagonally for a while or even normally at a certain time, the debug client "closes unexpectedly" with this fix it doesn't happen anymore.
    Note: walking diagonally forces the client to debug faster.
    Credits fix code: @mrianura
  • crash on buy own offer in market (@dudantas, opentibiabr/canary@d488fae)
    Removed some unnecessary delete pointers
  • Added check to ensure the item is not imbued twice with the same imbuement (@dudantas, opentibiabr/canary@dd03479)
  • Add decayImbuementTime function for use of updateInventoryImbuement (@dudantas, opentibiabr/canary@8559f3c)
    Function to avoid sending the message "imbuement already exists" when equipping/unequipping and deterioration of the item's imbue time
  • Quiver checking for ammunition level (@andersonfaaria, opentibiabr/canary@f50096b)
    Description
    Added check for minReqLevel of ammunitions in quiver both for total count of arrow as well as to select which ammunition to use
    Actual behaviour
    Quiver ignore level requirement as stated in opentibiabr/canary#77
    Expected behaviour
    Quiver actually doesn't throw ammunitions which has higher level requirement than player level
  • Fixed on death events for monsters that don't have corpses (@dudantas, opentibiabr/canary@6db7c30)
    onDeath events not working for corpseless monsters
    Added a sanity check to ensure the corpse is not used by monsters that don't have a corpse
  • Fix green skull from party (653c65a)
    Fix missing green skull on current character
  • Fix crash of invalid discord url and wrong player death event name typo (@beats-dh, opentibiabr/canary@5714e14)
    Fixed player death event name typo (from "Player Death" to "PlayerDeath"), on login.lua is: player:registerEvent("PlayerDeath")
    Fixed a bug that we have in the discord webhook in the project, and the bug happens when the server can't access the discord because of an invalid url or a lack of connection from the discord itself
    Behaviour actual:
    Server crash "closes unexpectedly" if invalid url is set in "config.lua" or "discord_webhook.lua"
    Expected:
    The server has to work normally regardless of whether the url is correct or not and whether discord receives it or not
  • Remove increment rune name to item name (@dudantas, opentibiabr/canary@08087b0)
    Item name was being replaced by rune name in "register" function
    Added the condition to only replace if the item name is empty, so that some system that checks the name of the pre-established item cannot be bugged
  • Fixed bug where quickloot would only looting the first corpses (@dudantas, opentibiabr/canary@0e75d7b)
  • Convert destroy field rune ids to client id and remove unused corpses table (@gpedro, opentibiabr/canary@93d9d98)
  • Fix exercise training and somes nil scripts (@dudantas, opentibiabr/canary@1f81077)
  • Conversion of server id to client id on gamestore.lua and init.lua and indent file gamestore.lua (@dudantas, opentibiabr/canary@f81f904)
  • Add 'non-aggresive' tag on healing 'doTargetCombatHealth' (@marcosv132, opentibiabr/canary@6f42a91)
    Missing check to make the combat 'non-aggresive' when healing a player's mana, by potion or any script that uses doTargetCombatHealth(...)
  • Remove unsafe addEvent from gamestore (@andersonfaaria, opentibiabr/canary@1330cef)
  • Fix crash related to reload scripts and fix reload npcs not working correctly and others fixes (see description) (@dudantas, opentibiabr/canary@5141874)
    This is intended to:
    Resolve critical issues.
    See all description on the commit.
  • Fixed rune that was only used in the tile and added to set for no-moveable item for action by position (@dudantas, opentibiabr/canary@1da1ac1)
    Moved the check inside the iterator, making the rune no longer access the tile check and can be used inside the backpack
    Modified so if the item set to be crafted is a moveable item, then the script will set the unmovable flag to prevent any player from moving the item.
  • Add missing function and fix nil values scripts (@dudantas, opentibiabr/canary@fa74d67)
    Added function for summon familiar and fixed somes wrong functions
  • Fixed halved healing spells, changed overtime healing color from blue to red (@soderlight, opentibiabr/canary@d58c242)
  • Fix typo on config tags from "togle" to "toggle" and somes others fixes (@dudantas, opentibiabr/canary@c921c87)
    Added the "global" in the tags of the global save server, and some synchronizations with the global repository: https://github.com/opentibiabr/otservbr-global
  • Fix drowning logic (@lucasgrizante, opentibiabr/canary@5c42078
  • Fix rune "id" method incrementing item id in the items.xml (@dudantas, opentibiabr/canary@0ea8dd6)
    Method "spell:id()" is of use only of spell instant, to set the cooldown sprite
  • Fix convert daily reward ids to client id (@lucasgrizante, opentibiabr/canary@1ca7847)

GitHub

  • Set workflows branch from "master" to "main" (@dudantas, opentibiabr/canary@46cf35b)

  • Update GitHub actions (@Costallat, opentibiabr/canary@a9cd5c7)
    Update and improve Github Actions
    Add new forms
    Update bug form
    Fix labels

  • Add issue auto label (@Costallat, opentibiabr/canary@76fd4f6)

  • Set windows default build as release (@Costallat, opentibiabr/canary@657db93)
    Refactor cmake presets to keep windows release as the default preset to
    help newcomers

  • Fix build docker, missing include header (@dudantas, opentibiabr/canary@c02a492)
    Added the proper checks in the addImbuement function
    The setImbuement Function has been set to private, to prevent someone from using it and making the bug again
    Added clearImbuement function to clear imbuement

  • [Remove] Removed benchmark from storage duplication (@andersonfaaria, opentibiabr/canary@0b218582)
    This was something I have added back then to show the function wasn't heavy and it's already something proven. In one of the commits someone put the processed message inside the condition which removed its purpose and would spam server console with a line that is not relevant as the goal was to show total process time and not individual time for each duplicate found.

Closed issues:

opentibiabr/canary#58, opentibiabr/canary#60, opentibiabr/canary#61, opentibiabr/canary#64, opentibiabr/canary#65, opentibiabr/canary#76, opentibiabr/canary#77, opentibiabr/canary#78, opentibiabr/canary#79, opentibiabr/canary#83, opentibiabr/canary#85, opentibiabr/canary#87, opentibiabr/canary#90, opentibiabr/canary#92, opentibiabr/canary#93, opentibiabr/canary#123, opentibiabr/canary#159, opentibiabr/canary#216, opentibiabr/canary#229, opentibiabr/canary#240, opentibiabr/canary#241, opentibiabr/canary#243, opentibiabr/canary#244, opentibiabr/canary#245, opentibiabr/canary#246, opentibiabr/canary#252, opentibiabr/canary#256, opentibiabr/canary#257, opentibiabr/canary#258, opentibiabr/canary#260, opentibiabr/canary#265, opentibiabr/canary#267, opentibiabr/canary#275, opentibiabr/canary#276, opentibiabr/canary#277, opentibiabr/canary#285, opentibiabr/canary#288, opentibiabr/canary#304, opentibiabr/canary#311, opentibiabr/canary#312, opentibiabr/canary#313, opentibiabr/canary#314, opentibiabr/canary#315, opentibiabr/canary#320, opentibiabr/canary#340

OTServBR-Global Modifications

Enhancements/Features

Fixed problems (Global):

  • Convert ids from dawnport quest to client id and register items for knight (@painer15999, bf89f02)
  • Fix npc puffels npcHandler variable (@soderlight, 1a7518e)
  • Fix script decay.lua for work only for players (@dudantas, b010445)
  • Fix script potions.lua effect and create flask inside container (@omeranha, e26f864)
  • Fix wrong heavy package ID (rashid quest) (@soderlight, a503d78)
  • Fix npcs shop and reward chest attribute (@dudantas, 3c3b9c7)
  • Fix items ids and attributes (@majestyotbr, 3046996)
  • Remove benchmark details (@andersonfaaria, de39c8f)
  • Added missing royal spear config to npcs: Brengus, Cedrik, Robert and Willard (@kasiula03, e56efe8)
  • Fix NPCs Captain Max (Calassa), Grizzly Adams and Melfar (@soderlight, 3395293)
  • Added corpseType to some corpses (@Rechdan, 4104b3f)
  • (Canary Compatibility) Fix item tier (@marcosvf132, d2b5d5d)
    To syncronize Canary and OTServBR-Global changes.
    opentibiabr/canary@4c7a35a
  • Convert map 'nightmare isle/darashia-west' from serverID to clientID (@marcosvf132, f344d0b)
  • Modifications on Player:onLook, fix quests.lua order, remove duplicate ids and fix suggestions from lua extension (@beats-dh, dd353ff)
  • Many item.xml fixes + login.lua indentation (@guispiller, c095b32)
    This changes are to fix some missing otbr/canary converting ids, there were some decays, rotates and wraps with the wrong IDs
    QoL on channels login.lua
  • Few hireling issues (@marcosvf132, 279bf75)
    Fix hireling outfit change client crash.
    Fix hireling server crash when saying 'hi - lamp - yes'.
  • Fix familiar not entering pz zone and improvement to familiar spells (@dudantas, 4416bdf)
  • Fix minotaur cult monsters (@dybik08, 3f46da4)
    This contains fixes for minotaur cult monsters.
  • Fix "Wound" bestiary charm register (@marcosvf132, 9a9c34c)
    Wound bestiary charm was not showing on the cyclopedia charm store due to one miss config on the Lua file.
  • Fix talkDelay from npcs (@dudantas, 712b984)
    Resolves #486
    Added delay to the function "NpcHandler:setMessage" and fixed talkDelay from the others functions.
    The modifications only apply to speeches that contain more than one message.
  • Fix nil errors on somes scripts (@dudantas, 723d697)
  • Register missing enchanted werewolf amulet (@dudantas, 8bbe05d)
  • Somes npcs fixes (wrong functions and missing variables) (@dudantas, c538fcf)
    Set from delayedSay and selfSay to npcHandler:say and fixed somes missing/wrong variables
    Fixed hireling crash (bad handle on SayEvent function)
  • Fix allowMovement storage typo (@gpedro, 174f4d1)
    Fixed typo from STORAGE to Storage in "allowMovement" and "hasAllowMovement" functions
  • Fix party skills (@kasiula03, e85fcac)
    Fix naming for variable parameter in onCastSpell for train_party, heal_party and protect_party scripts.
    Additionally, shielding buff has been changed from 2 to 3 to match real tibia skill.
  • Fix key doors (not registered key 2969), dawnport quest and thieves guild quest (@dudantas, 354b722)
  • Fix bug in enchanted werewolf and enchanted theurgic amulets and registed cobra crossbow attributes (@painer15999, 3fb9cf0)
  • Fix message type of locked door from event advance to info descr (@travisani, 099f34f)
  • Remove unsafe use of AddEvent in Oberon (@gpedro, @gesior, ebe238e)
    Resolves #476
  • Fix revision on monster flags and elemental damages (@guispiller, ad635b6)
  • Fix healing source on 'mass healing' and potions (@marcosvf132, 1c70b1a)
    Using the spell 'exura gran mas res' or using a health potion on another player is not registering the source of the action. This PR add it so the server, the client and other systems can track the action how it should be.
  • Fix Client IDs on NPCs and quest_system2 (@guispiller, 65aa5f1)
  • Convert ids to client id, storages fixes and quests fixes (@soderlight, 70bd181)
  • Fixing wrong aid and uid conversions (@guispiller, a820648)
  • Remove unsafe addEvent from gamestore (@andersonfaaria, 83754e7)
  • Fix Destroy Rune field list (@andersonfaaria, fb285f4)
    Moved lib table to script rune
    Converted server ids to client id
  • Fix NPCs not working due to wrong parameters (@guispiller, d02d847)
  • Fix nil storages from ferumbras ascendant quest (@dudantas, d388b13)
  • Fix keys would be given without proper key actions (@lucascebertin, ee54985)
    Fix issue #528 where some keys are given without proper key actions.
  • Fix weapons shoot effects and eldritch wands/rods not attacking (@guispiller, 8e1eb61)
  • Add missing outfits and mounts to talkactions (@daanyx, 75ea3ec)
  • (Npc) Convert shop from Gnomally to client id (@gpedro, 556a5da)
  • (Npc) Update items from Willard shop sell (@sircurse, 1212d2e)
  • (Npc) fix Eruaran addons (@gpedro, bb926cb)
  • (Canary Compatibility) - Prey system rework (CPP) and Hunting Task system (@marcosvf132, db97c32)
    This PR is a complementation of this Canary commit: opentibiabr/canary@42af88d
    Complete rewrite of old prey system from LUA to CPP and implementation of Hunting tasks system.
  • Fix mana potion not healing mana (@dudantas, e101237)
  • (Npc) changed prices in NPC Imbuement to avoid illicit enrichment (@sircurse, 941aa23)
    This NPC was selling imbuements items at a very low price, for instance, you could buy "Some Grimeleech Wings" at 100gps and sell this same item to Yasir by 1200gps
  • Rework and fix on kegs and casks scripts (@dudantas, 9d9a2e8)
    Script logic reworked, fixed some bugs and removed unnecessary checks
  • Fix offline training bed (bed graphics was not updating when player went to sleep) (@sircurse, 2a3bfdd)
    Fix to issue #526
  • Fix rune "id" method incrementing item id in the items.xml (@dudantas, bdc756a)
    Canary commit (optional): opentibiabr/canary@0ea8dd6
  • Fix npcs name on script "npcs by time" and fix on startup spawn npcs by night/day (@dudantas, 6eeedef)
    Added the monsters in npcs.xml, attached the NPCS name in the Global Event script and added the Respawntype tags for whether each NPC must be created (when opening the server) during the day or night
  • (Canary Compatibility) Rework on fluids colors and new monster race type (INK) (@marcosvf132, 87e53b9)
  • Fix for cask to be used in house only and removing wrong charges and empty potion flasks (@dudantas, ecbfdcb)

Closed issues:

#279, #281, #282, #286, #292, #299, #313, #319, #336, #357, #358, #376, #385, #386, #406, #409, #424, #429, #432, #433, #438, #439, #441, #447, #449, #450, #451, #452, #453, #456, #459, #460, #462, #468, #474, #476, #478, #481, #484, #486, #494, #495, #497, #500, #502, #506, #509, #510, #520, #522, #526, #527, #528, #530, #534, #552, #563

Global map new areas and fixes (Credits to @majestyotbr, @JohneVictor, @guispiller):

Complete modifications in the commit: 2d59b5e

Antrum of the Fallen - pos 32603, 31844, 10;
Bounacean Lion - pos 32470, 32492, 8;
Boss Room Neferi The Spy - 33886, 31477, 6, ;
Boss Room Sister Hetai - 33883, 31467, 9,;
Cursed Crypt - pos 32601, 31861, 9;
Deathling Menace - pos 32366, 32543, 8;
Dwelling of the Forgotten - pos 32062, 31461, 11;
Forest of Life - pos 32399, 32496, 11;
Forge (Thanks for Stewart) - pos 32208, 32281, 7;
Gaffir Secret Room - 33302, 31196, 9;
Grotto of the Lost - pos 32123, 31442, 14;
Ruins of Nuur - pos 33806, 31692, 8;
Salt Caves - pos 33970, 31652, 7;
Too Hot To Handle - pos 32603, 31844, 10;
Task: Lava Fishing - pos 32532, 31086, 15;
Task: The Mega Magmaoid - pos 32529, 31154, 15;
Room Lesh The Seer - pos 32406, 32470, 6;
Stealth Mission - pos 33894, 31311, 15;
Supply Mission - pos 33964, 31307, 15;
1st Mate Ratticus - pos 33897, 31391, 15;
The Trekkie's Journey - pos 33960, 31375, 15;
Haunted House - pos 32690, 32241, 6;
Tomb of Scarlet - pos 33101, 32630, 8;
Tibia Cults - pos 33039, 31911, 14;
Hunt Feaster of Soul - pos 31912, 32355, 8;
Boss Room The Brainstealer - pos 32539, 31122, 15;
Rascacoon Kraken Boss - pos 33803, 31390, 7, / 33733, 31187, 7;
A Pirates Tail - pos 33927, 31364, 7;