Commit graph

344 commits

Author SHA1 Message Date
LeoTK
eb68ed9672
fix: fiendish and influenced spawn (#3889)
New Features:
• Teleport command now cycles per-player through fiendish/influenced
forge monsters and creatures by name, with clear status messages.

Bug Fixes
• Forge population reliably clears, repopulates, and removes stale
entries each update.
• Fiendish and influenced creation respect configured limits and stop
early when full.
• Creation logic decoupled so influenced and fiendish counts update
independently and avoid improper gating.
2026-03-31 09:13:58 -03:00
Eduardo Dantas
a6c61d08a8
feat: implement player food tracking & Lua binding (#3851)
New Features:
• Food effect duration tracking added — consumable foods now create
visible active food buffs with remaining time.
• Many consumables now grant timed food effects (commonly 1 hour; select
items extend up to 24 hours).
• Character summary now lists active foods and remaining durations for
easier management.
• Various dishes updated to set or refresh their food timers when
consumed.
2026-03-12 04:05:23 -03:00
Everton Zoelner
b1e31b59e5
feat: add skill trainer item for offline skill training (#3865)
• Added a new skill trainer item that enables offline training for fist fighting and shielding skills.
2026-02-19 16:46:12 -03:00
Eduardo Dantas
d23f2c8651
fix: add starting items for Monk vocation (#3860)
New Features:
• Added MONK vocation: Players can now create characters of the new MONK
class with specialized starting equipment, including a jo staff, brass
armor set, boots, scarf, and a starter container filled with essentials
like a shield, rope, shovel, and health potions.
2026-02-18 10:36:36 -03:00
Eduardo Dantas
5e357d8a81
feat: add Way of the Monk quest and monk-related content (#3794)
feat: add Way of the Monk quest, monster updates, and core data improvements

This commit introduces the complete implementation of the Way of the Monk quest, along with multiple updates to monsters, bosses, items, and core gameplay data.

Quest:
• Added full quest definition for Way of the Monk, including mission flow, shrine tracking, and storage handling.
• Registered the new quest module in the quest catalog.
• Introduced new storage keys related to monk quest progression and items.
• Added a sample monk player migration (DB version 55) for testing purposes.
• Added Blue Valley to the towns list to support quest locations.

Monsters and Bosses:
• Added new monster Tame Terror Bird with complete stats, behaviors, and loot.
• Reworked Mitmah Vanguard boss with updated events, attributes, attacks, defenses, elemental modifiers, loot, and lifecycle hooks.
• Expanded loot tables for bosses such as The Brainstealer and The Monster, including monk-related items and potions.

Items and Loot:
• Updated frazzlemaw and guzzlemaw loot to drop traditional sai instead of sai.
• Added monk-related item IDs to destruction scripts and Dawnport cleanup logic.

Gameplay:
• Added Monk’s Apparition to the Soul War quest apparition list.
• Introduced a new combat formula for fist fighting skill.
• Removed legacy fist fighting attack speed configuration from server settings.

Workflow:
• Improved GitHub Actions workflow to ensure reusable checks run on the correct branch.
2026-02-12 23:03:25 -03:00
LeoTK
a82fef0af0
feat: new sounds ambient and music (#3526)
Add a zone-based ambient and music sound system with day/night support

Introduces a Lua-driven ambient and music sound system with zone triggers
and day/night variants. Adds engine and Lua APIs for ambient/music effects,
new sound enums, player methods, and protocol support. Includes admin
commands to force periods and manually trigger sounds for testing.
2026-01-30 08:20:51 -03:00
Luis Pablo
eb782bca7e
feat: fiery horseshoe action to add mount to player (#3781) 2026-01-11 09:28:43 -03:00
Eduardo Dantas
14b5b0cf8f
refactor: event callback system and update usages (#3684)
Refactor event callback dispatch and Lua invocation

Simplify Lua callback execution by removing explicit function-pointer parameters from C++ callback invocations and centralizing dispatch through the callback manager, with short-circuit behavior. Update combat callbacks to use dispatchReturnValue and change creatureOnCombat to mutate CombatDamage instead of returning tuples. Fix callback registration to be stably sorted by descending priority, enforce duplicate blocking only when skipDuplicationCheck is false, and ignore disabled callbacks or invalid script IDs. Align EventCallback construction with current usage and clean up redundant includes. Update documentation and Lua scripts to match the new callback types and argument conventions, and add unit tests covering ordering duplication rules, short-circuiting, and the damage mutation roundtrip.
2026-01-09 01:19:51 -03:00
Eduardo Dantas
907f35f904
feat: add event scheduler by json (#3085)
Add JSON JSON-based event scheduler system

Introduce a new JSON-driven event scheduler to manage in-game events more easily and flexibly. Add initial events.json data, documentation, and example scripts. Integrate event-driven effects into server gameplay logic, including login notifications, bestiary and bosstiary bonuses, forge success rate adjustments, and fast exercise handling. Ensure backward compatibility by supporting both XML and JSON schedules, with JSON loaded after scripts. Update the build configuration to require and link the nlohmann_json library, and include scheduler access in the player logic.
2026-01-08 17:21:22 -03:00
Eduardo Dantas
6777872e4e
feat/improve: create "custom loot" for monsters (#3080)
This update introduces several enhancements to the loot system, allowing
for more flexible loot management across different monsters without the
need to modify each monster's individual script. A global loot option
has been added, which is disabled by default, to assign items that any
monster can drop. This feature simplifies the addition of common loot
across multiple monsters, enhancing the modularity of loot management.

The "registerLoot" function has been improved to eliminate code
duplication and enhance efficiency. The "closeContainer" function has
been updated to remove problematic code that could cause crashes when
"container" used before "erase". Additionally, a new Lua function,
"getMonsterTypeByName", has been introduced to facilitate getting
monster types.
2025-10-30 18:19:31 -03:00
James
4d9bc97e8c
fix: familiar time (#3747)
These changes make a small but significant fix to the familiar system
on player login. It ensures that the remaining familiar summon time is
never negative by clamping the value to zero. This prevents potential
issues if the stored summon time is in the past.

- Clamp `familiarTimeLeft` to zero to prevent negative values by using
`math.max(0, familiarSummonTime - os.time())` in
`familiarOnLogin.onLogin`
(`data/scripts/creaturescripts/familiar/on_login.lua`).

Resolves #3710
2025-10-27 12:23:46 -03:00
Luan Santos
6cb692acc5
fix: type safety on raid checks (#3675)
Ensure the database state is initialized to avoid RAID check exceptions.
Otherwise, errors like the following can occur:

[2025-31-08 09:34:43.520] [thread 140345198] [error] Lua Script Error Detected
---------------------------------------
Interface: Scripts Interface
Script ID: data/scripts/globalevents/raids.lua:callback
Error Description: data/libs/systems/raids.lua:87: attempt to perform arithmetic on local 'checksToday' (a nil value)
stack traceback:
        [C]: in function '__add'
        data/libs/systems/raids.lua:87: in function 'canStart'
        data/libs/systems/raids.lua:51: in function 'tryStart'
        data/scripts/globalevents/raids.lua:11: in function <data/scripts/globalevents/raids.lua:5>
---------------------------------------
2025-09-03 12:39:06 -03:00
Eduardo Dantas
3c7b7debbe
improve: refactor storages in PlayerStorage component and optimized save (#3664)
The Player has previously managed the storage system through a raw
storageMap, with direct insertions, deletions, and range generation
(genReservedStorageRange). This change caused unnecessary complete
rewrites on save and spreads logic across Player, IOLoginData, and
related components.

Changes
- Introduced a new PlayerStorage component to encapsulate all
storage-related logic
- Removed the legacy storageMap from Player, centralizing load/save and
manipulation in the new component
- Implemented incremental persistence: only modified or removed keys are
saved to the database, avoiding complete rewrites
- Added support for reserved key ranges (outfits, familiars) within
PlayerStorage::getReservedRange
- Updated IOLoginDataLoad and IOLoginDataSave to delegate load/save to
PlayerStorage
- Added missing benchmark.cpp implementation and updated build files
accordingly
- Removed storage name in favor of KV.

This change refactor improves code organization, maintainability, and
performance. By persisting only modified keys instead of the full
storage set, save operations are faster and reduce unnecessary database
load.
2025-09-03 01:01:46 -03:00
Luis Pablo
aeb2986218
enhancement: add functionality to items used to obtain the second familiar (#3662) 2025-08-27 10:53:57 -03:00
Luis Pablo
1943015e87
fix: spirit of purity mount (#3661) 2025-08-27 10:53:31 -03:00
LeoTK
831a56158f
Fix: A-Z order GetAllKv (#3643)
It's a very simple modification to make all the kvs return in alphabetical order to improve the way they are viewed.
2025-08-20 14:11:20 -03:00
Luis Pablo
5ab2147fd0
feat: azzilon (#3634) 2025-08-20 14:08:33 -03:00
Luis Pablo
20280ed42f
fix: reset exp boosts at server initialization (#3633) 2025-07-26 21:13:07 -03:00
Luis Pablo
b055a3c963
enhancement: delete duplicated /raid talkaction (#3626) 2025-07-26 20:52:34 -03:00
Luis Pablo
7d560c5130
enhancement: add ability to give minor charms to players as god (#3622) 2025-07-15 19:45:39 -03:00
LeoTK
f535f0eabb
feat: new talkaction ban (#3511)
This new ban command allows you to enter the days for the reason, fixed the maximum days bug, checks if the player has already been banned.
2025-07-06 18:39:52 -03:00
LeoTK
7c5ef29239
feat: new talkaction manage kv (#3502)
Modifications now allow to apply and check the kv of targets.
2025-07-06 16:11:13 -03:00
Eduardo Dantas
acdba2cdad
feat: protocol 14.12 (#3524)
feat: add client and server features for gameplay and UI improvements

- Renamed Supply Stash to Stash and removed depot slot limit count
- Added advanced filters for Stash item categories
- Reworked Cyclopedia Combat Stats into Offense, Defense, and Misc Stats
- Added detailed tooltips and integrated stats into Skills widget
- Introduced Magical Archive interface for spells and runes with filters
- Overhauled Quest Log and Tracker with pinning, search, sort, compact display, and notifications
- Enhanced Exaltation Forge with boots tier bonus and Dust management
- Redesigned Charms System with new Major and Minor charms and balance changes
- Added new mounts and outfits for customization
- Improved server and client behavior with advanced stash, spell archive, detailed stats, and enhanced tier systems
- Verified features through manual and in-game testing
2025-06-08 16:12:15 -03:00
murilo09
71cfb708f3
feat: support to protocol 14.05 (#3164)
Support Tibia 14.05: https://github.com/dudantas/tibia-client/releases/tag/14.05.70ce66
2025-05-13 15:30:29 -03:00
LeoTK
e295283278
new: killer list (#3517)
This way the killer list will show who gave the final hit, who did the
most damage and all other participants, whether monsters or players.

PR Complement: https://github.com/opentibiabr/myaac/pull/134
2025-05-12 22:42:57 -03:00
gabrielgg98
5bdbc207bd
fix: remove duplicated buy house command (#3476) 2025-04-28 20:13:28 -03:00
LeoTK
c082f5867b
feat: talkaction playericon (#3488)
This new command is to add an icon to the player, it also has a counter
function to use the command, follow the examples:

/playericon 1, 10 -- this way it will apply icon 1 with the counter at
10 and it will decrease every second after reaching 0, it will be
removed after 10 seconds.

/playericon 1, 10, up -- this way the counter will start at 0 and will
go up to 10 after 10 seconds, it will remove the icon.
2025-04-22 13:54:50 -03:00
Eduardo Dantas
714fd2ff7c
fix: low blow charm aligned to global behaviour (#3392)
This change fixes an issue in the `Combat::applyExtensions` function
where the "Low Blow" charm critical hit was incorrectly triggering the
global critical hit as well, resulting in unexpected behavior. The bug
was caused by the independent calculation of `lowBlowChance` using
`charm->percent` alone, which led to a downstream misinterpretation of
critical hits. The fix adjusts the "Low Blow" chance calculation to
`baseChance + charm->percent`, aligning it with the Tibia Global
mechanics where "Low Blow" acts as an extension of the base critical
chance, only triggering when the global critical does not occur.
Additionally, this PR adapts `applyExtensions` to handle multiple
targets instead of a single target, improving compatibility with
area-based combat effects.

Co-authored-by: valdzera <146901121+valdzera@users.noreply.github.com>
2025-03-15 13:51:28 -03:00
bdzicc
7d23e86b65
fix: corrected mana spent for exercise wand (#3431) 2025-03-14 18:28:26 -03:00
Eduardo Dantas
ccb2afcc4a
feat: magic shield potion excluded from exhaustion system (#3393)
Fix to the magic shield potion not trigger the exhaustion.

Co-authored-by: valdzera <146901121+valdzera@users.noreply.github.com>
2025-02-27 23:53:58 -03:00
Eduardo Dantas
348b44c9c6
feat: checks if someone is training on the dummy (#3397)
• Dummy Movement Restriction:
Before: The dummy could be moved or rotated without strict ownership
verification.
Now: Only the house owner is allowed to move or rotate the dummy.
Additionally, the system checks if someone is training on the dummy
before allowing the action. This prevents unauthorized modifications and
ensures that the dummy is only used as intended.

• Enhanced Account-Level Checks:
New Feature: A "buy house" talk action has been added specifically for
god-level accounts.
Improvement: The system now verifies the player's account type when
processing talk actions. This means that if a talk action requires a
certain account privilege (for example, only GM-level or lower actions),
the system will enforce that check. In short, even if a character
appears eligible based on their group, the underlying account type must
also have the necessary permissions.
2025-02-25 09:52:19 -03:00
Eduardo Dantas
721e9ed1dc
fix: aleta grav behaviour (#3398)
This fixes multiple issues regarding house door list handling and
door usage via the "aleta grav" spell. The changes ensure that:

• The "House Door List" spell now works correctly when the player is
both in front of and inside the door.
• Both door lists are properly loaded from the database, and cached
entries are cleared once applied.
• The door usage check now validates that the player's current tile
belongs to the same house as the door, preventing usage when the player
is outside the house.
2025-02-25 08:57:01 -03:00
Guilherme
3e06551ca4
fix: mass healing area aug II wheel of destiny (#3391) 2025-02-23 05:54:29 -03:00
Marco
a00094b98f
fix: unintended depot message and improve code (#3361) 2025-02-23 05:54:00 -03:00
Leilani A.
ab32754446
fix: spells and runes interactions (#3328) 2025-02-09 20:28:13 -03:00
mdbeng
7bd52c0347
fix: casks and kegs (#3344) 2025-02-08 15:39:28 -03:00
Marco
8e4a4197cc
fix: colored loot message on bosses (#3342) 2025-02-08 15:38:40 -03:00
Marco
f3f2d64c6e
fix: weight error when adding potions to container (#3331) 2025-02-08 15:35:01 -03:00
Eduardo Dantas
ff7c7ff18a
fix: stash bugs and adjustments (#3324)
Allow GM access to depot tiles and refine supply stash notifications:
• Fixed "Your depot contains/stash contains" message to appear in the "serverlog".
• Enable God/GM accounts to step on depot tiles to trigger stash/depot search.
• Restrict the "You can't use supply stash right now." message to normal players only.
• Activate step-in tile functionality on player login, excluding only teleports.
2025-02-08 15:30:48 -03:00
Majesty
b1aa7d64b1
feat: update foods action (#3335) 2025-02-06 18:48:55 -03:00
Felipe
7a51fdb71d
feat: soul pit arena/animus mastery/soul core (#3230)
SoulPit fighting arena along with Animus Mastery Logic.

---------

Co-authored-by: Pedro Henrique Alves Cruz <phac@cin.ufpe.br>
2025-01-28 14:33:54 -03:00
Samuel Gomes
8046913229
fix: magic wall and rush wood onlook description (#3273) 2025-01-26 13:15:30 -03:00
Eduardo Dantas
e1a8ee3e30
Revert "fix: item usage under players and doors" (#3248)
Reverts opentibiabr/canary#3239

This caused inconsistencies in the "onUse" of other things, several
people reported bugs in onUse to me so I preferred to revert, so the
author can analyze it better and we can test the new pr with the reports
made. For example, when there is a "border" below a dummy, it gets the
id of the border and not the dummy (when using exercise rod)
2025-01-14 16:24:10 -03:00
Leilani A.
7ecfabcec7
fix: item usage under players and doors (#3239) 2025-01-12 06:10:28 -03:00
Eduardo Dantas
eebff8794c
fix: revert some onSpawn monstertype callbacks (#3194) 2025-01-12 05:55:43 -03:00
Leilani A.
441dd651d4
fix: getstorage talkaction sanitization (#3240)
Now all strings can be correct sanitized.
2025-01-11 14:27:12 -03:00
Pedro Cruz
3ac0bab131
perf: wheel (#3157)
Fixes performance issues in the wheel ui, also add the disable of the apply button when the changes be applied and some functions calling order.
2025-01-10 08:29:14 -03:00
murilo09
13dbc4f4d3
feat: login and disconnect protection (#3223)
Tibia 9.50: https://www.tibia.com/news/?subtopic=newsarchive&id=2009
X-Logging: https://tibia.fandom.com/wiki/X-Logging
2025-01-09 13:39:40 -03:00
Jean Carlo de Souza
15e3f1dec2
fix: prevent player corpses from being removed during tile cleaning (#3205) 2025-01-02 14:19:12 -03:00
murilo09
142aafbfdf
fix: balancing 13.40 (#3206) 2025-01-02 13:30:17 -03:00