Commit graph

163 commits

Author SHA1 Message Date
Eduardo Dantas
44a980b07e
build(cache): share vcpkg dependencies across CMake and Visual Studio (#1800)
Add shared vcpkg dependency cache for CMake and Visual Studio builds

This commit adds a content addressed vcpkg dependency cache that can be reused across compatible Git worktrees independent forks CMake presets and Visual Studio Solution builds.

The goal is to reduce repeated dependency installation and rebuild time while keeping build outputs isolated per worktree. The cache only shares dependency artifacts that are proven compatible through a complete dependency contract. Project build outputs such as object files PCH files PDB files generated sources intermediate files and executables remain local to each checkout.

The shared cache is opt in. When the cache is not configured or when the resolver cannot prove that reuse is safe both CMake and Visual Studio fall back to local worktree specific vcpkg roots.

Main behavior added

• Shares vcpkg downloads globally

• Shares vcpkg binary packages globally

• Shares expanded vcpkg installed trees only when the dependency fingerprint matches

• Shares vcpkg buildtrees and packages only when the dependency fingerprint matches

• Keeps CMake build trees local to each worktree

• Keeps Visual Studio output directories local to each worktree

• Keeps generated files intermediate files executables PCH files PDB files and object files local

• Allows compatible Git worktrees to reuse dependency artifacts

• Allows compatible forks to reuse dependency artifacts

• Allows compatible CMake presets and Visual Studio configurations to converge on the same dependency cache

• Falls back to local vcpkg storage when shared cache safety cannot be verified

CMake integration

The new CMake shared cache module runs before project initialization and resolves the vcpkg dependency contract before the normal configure flow continues.

The resolver validates the manifest registries overlays triplets features vcpkg revision compiler toolset SDK and cache implementation before selecting fingerprinted dependency roots. This prevents incompatible configurations from sharing the same expanded dependency tree.

If the CMake version is too old for the shared cache module and shared cache variables are present the build warns and continues with build local vcpkg storage instead.

CMake preset changes

• Removes hardcoded VCPKG_INSTALLED_DIR values from presets

• Lets the shared cache resolver select the installed root when safe

• Keeps local fallback behavior available

• Replaces the previous preset binary source override with clean packages and clean buildtrees options

• Prevents Visual Studio CMake presets from inheriting Ninja compiler overrides where they should not

• Keeps CMake build outputs under their configured build preset directories

Visual Studio integration

The Visual Studio bridge uses the same dependency resolver as CMake. It evaluates each Solution configuration through MSBuild, generates a machine local ignored SharedVcpkgCache props file and revalidates the complete contract before vcpkg manifest installation.

Different Visual Studio configurations receive separate consumer fingerprints. They can still share an expanded dependency tree when their dependency inputs are identical, but their consumer contracts remain separate so MSBuild specific details cannot corrupt CMake or another Solution configuration.

The Visual Studio project now imports vcpkg props more reliably, supports the generated shared cache props, and validates the generated contract through SharedVcpkgCache targets before dependency installation and build preparation.

Visual Studio changes included

• Adds SharedVcpkgCache targets

• Adds generated SharedVcpkgCache props support

• Adds vcpkg bootstrap property resolution from VCPKG ROOT

• Keeps local fallback when the shared Solution cache is inactive

• Validates manifest root target triplet host triplet configuration toolset SDK and install options before using the shared cache

• Pins the Visual Studio instance used by vcpkg for the shared Solution contract

• Requires the dependency CMake tool used by the generated contract

• Revalidates the generated contract before vcpkg manifest install

• Uses fingerprinted installed buildtrees and packages roots for compatible Solution builds

• Keeps Solution outputs local

Shared cache safety boundaries

The shared cache is intentionally conservative. It only activates when the environment and contract can be fully validated.

Safety rules enforced

• The shared pool must be on a verified local fixed filesystem

• The shared pool must live outside every registered checkout

• UNC paths are rejected for the shared cache root

• Reparse points and symlink escapes are rejected in sensitive paths

• Mutable dependency roots are isolated by full contract fingerprint

• vcpkg and shared cache operation locks protect mutable cache operations

• Existing authenticated VCPKG BINARY SOURCES values are preserved

• Existing authenticated binary source values are never printed

• Existing authenticated binary source values are never persisted by the helper

• Cleanup fails closed when validation is incomplete

• Cleanup refuses to run while build related processes are active

• Cleanup validates repositories configure trees generated contracts paths identities and locks before removing transient data

• CI containers runtime data deployment paths and release behavior remain unchanged unless shared cache is explicitly enabled

PowerShell tooling

This commit adds setup audit cleanup repository registration and Solution contract generation tools.

The main shared cache setup script configures the cache root registers the current Git repository family manages relevant user environment variables configures vcpkg downloads and binary cache locations updates managed sccache base directories and can invoke the Solution bridge when applicable.

The Solution cache script evaluates MSBuild properties resolves the shared dependency contract through the CMake resolver writes the generated props file and supports audit only and validate only modes.

Both PowerShell tools require PowerShell 7 2 and run under strict mode.

Tooling added

• tools configure shared build cache ps1

• tools configure shared solution cache ps1

• setup mode for shared cache configuration

• audit only mode for validating existing shared cache state

• guarded transient vcpkg cleanup

• guarded fingerprint specific transient cleanup

• repository registration and unregister support

• generated Solution props creation

• generated Solution props validation

• generated Solution props audit

• MSBuild property based contract evaluation

• local fixed filesystem validation

• active build process protection before cleanup

Protobuf and Solution build fixes

This branch also includes follow up fixes around protobuf generation and Solution build behavior.

Protobuf and Solution changes

• Fixes Solution protobuf generation by using one normalized absolute proto root

• Uses the host triplet protoc path for protobuf generation

• Adds incremental inputs and outputs to the ProtoCompile target

• Excludes generated protobuf compile items when protobuf support is disabled

• Keeps protobuf generated source handling tied to RunProtoCompile

• Lets both CMake and Solution builds honor configured global vcpkg binary sources

• Avoids leaking Ninja compiler overrides into Visual Studio CMake presets

Documentation and repository updates

• Adds shared build cache documentation

• Documents setup and migration flow

• Documents CMake and Visual Studio integration

• Documents cache contract rules

• Documents concurrency and locking behavior

• Documents fallback behavior

• Documents recovery and cleanup procedures

• Documents cross fork compatibility rules

• Updates README with shared cache guidance

• Updates gitignore for generated local shared cache files

• Updates CI path filters so vcpkg configuration overlay and cache related changes trigger the correct workflows

Validation performed

• PowerShell parser validation for both cache tools

• PowerShell 5 1 prerequisite failure verified

• CMake preset validation

• JSON validation

• Visual Studio project XML validation

• Evaluated MSBuild property and item checks

• Checked protobuf enabled mode

• Checked protobuf disabled mode

• Local shared cache Solution build validation

• GitHub Actions Windows CMake matrix

• GitHub Actions Windows Solution matrix

Overall this commit adds a safe content addressed shared dependency cache for OTClient builds. It lets compatible CMake and Visual Studio configurations reuse expensive vcpkg dependency artifacts while keeping all build outputs local and falling back to worktree local storage whenever the shared contract cannot be fully validated.
2026-08-13 18:47:47 -03:00
Eduardo Dantas
ef446a9d0c
feat(client): add automatic modern asset installation (#1727)
Add automatic client-asset installation for modern Tibia versions in OTC, with the UI and runtime support needed for a safe download-and-install flow.

Main changes:
- Add modules/client_assets to orchestrate descriptor and release resolution, downloads, retries, cancellation, archive extraction, optional LZMA handling, and SHA-256 integrity checks.
- Add richer install logs in the console, including download phases, install phases, and final install paths.
- Add support for packaged runtime files, including large DLLs distributed through archives.
- Make client_entergame depend on client_assets.
- Check required assets during login for modern clients version 1281 and newer.
- Prompt the user to download missing modern assets instead of requiring manual setup.
- Allow the client list and version selection to work with installed modern asset sets.

Install layout:
- Install things assets under data/things/<version>.
- Install sound assets under data/sounds/<version>.
- Keep extra runtime files in the existing client root/bin flow.
- Preserve the existing OTC asset layout as the source of truth instead of introducing a separate permanent path.

UI improvements:
- Improve missing-assets and progress dialog sizing and text wrapping.
- Improve progress behavior for downloads without Content-Length.
- Add indeterminate progress behavior for unknown-length phases.
- Add an hourglass busy indicator for indeterminate phases.
- Reduce the perception that the installer is stuck during long extraction steps.

Runtime and build support:
- Add libarchive usage and linking for archive extraction.
- Add SHA-256 helpers and Lua bindings used by client_assets.
- Add safer extraction and path normalization in ResourceManager.
- Adjust the Emscripten HTTP login path to follow the same HTTP/HTTPS fallback behavior used by native login.

Security and integrity:
- Enable strictManifestSha256 by default.
- Disable raw fallback on hash mismatch by default.
- Key releasesCache per source URL and repository to avoid stale cross-source cache reuse.
- Add an LZMA decompression output cap to reduce memory-exhaustion risk.

Compatibility:
- Keep existing classic asset behavior unchanged.
- Use the new auto-install flow only for modern versions when required assets are missing.
- Keep the scope limited to client-side asset automation and required runtime support.
- No server-side Canary behavior is changed by this PR.

This makes modern client setup safer and more automatic by downloading, validating, extracting, and installing missing assets directly from OTC while preserving the existing classic asset flow.
2026-05-28 16:18:44 -03:00
Majesty
e44efba282
docs: update README and build guides (#1725)
Documentation:
- Updated support protocol compatibility with revised documentation references.
- Streamlined Windows compilation guides by simplifying vcpkg setup instructions.
- Enhanced clarity of PowerShell setup steps for both CMake and Visual Studio build workflows.
2026-05-21 14:27:37 -03:00
kokekanon
4a87cebb11
feat: protocol 15.24 packets and features (#1604)
New Features:
- Task Board (Bounty, Weekly, Shop) with Preferred & Soulseal modals, Kill Tracker, Offline Training dialog, Vocation tutorial, infobanner notifications, redesigned NPC chat/trade, and multi-slot action bar.

Gameplay Enhancements:
- Expanded Cyclopedia stats, talisman upgrades, weekly rewards/progress, soulseal fights, taskboard shop/offers and offline training actions.

UI / Graphics:
- Per-source spell-effect opacity sliders, status icon bar, HUD/scroll improvements, many new templates/styles, screenshot UI updates, and small label/icon fixes.

Bug Fixes:
- Miscellaneous UI behavior, layout and robustness improvements.
2026-05-20 11:26:11 -03:00
Majesty
e0a885c590
docs: update README and add build guides (#1717)
Documentation:
- Added comprehensive platform-specific compilation guides for Android, Debian, Ubuntu 24.04, Windows (CMake and Visual Studio Solution) and WSL (Debian and Ubuntu 24.04), covering prerequisites, environment setup, dependency management, build workflows and Android APK generation/asset steps.
- Updated README: replaced previous build badges with a single CI badge and removed the legacy "Current compiling tutorials" subsection.
2026-05-19 10:47:43 -03:00
André Morais
d809b0cabf
feat: wheel of destiny (#1578)
Co-authored-by: LIBERGOD <37589902+libergod@users.noreply.github.com>
2026-01-30 16:45:21 -03:00
kokekanon
62ea289953
feat: healthcircle for monk vocations (#1588) 2026-01-12 22:39:14 -03:00
Luan Luciano
7b132aa98a
feat: compatibility with 15.11 (only bytes)
Co-authored-by: kokekanon <114332266+kokekanon@users.noreply.github.com>
2025-12-21 12:06:28 -03:00
kokekanon
920d64884f
fix: #1451 add: GameTileAddThingWithStackpos 2025-11-17 17:07:19 -03:00
divinity76
74c7d107e6
fix: make README.md table of contents clickable (#1431) 2025-11-09 12:59:15 -03:00
kokekanon
7579f8458e fix: blessing (#1355)
The tooltip is not there yet because I can't find the packets.
2025-10-14 14:07:18 -03:00
Renato Machado
7c49b50990
readme: add more videos about html/css syntax 2025-09-28 15:14:13 -03:00
surfaceflinger
d8d9e720ad
fix: discord-rpc in cmake (#925)
* fix: discord-rpc in cmake

* Update README.md

* fix: update Discord RPC configuration instructions and logging

* Update README.md

* fix: rename TOGGLE_DISCORD_RPC to ENABLE_DISCORD_RPC for consistency

---------

Co-authored-by: LIBERGOD <37589902+libergod@users.noreply.github.com>
2025-09-16 10:24:11 -07:00
Renato Machado
e376723075
Update README.md 2025-08-08 20:46:17 -03:00
kokekanon
dbe3815790
feat: protocol 14.00 ~ 14.12 packets and features (#1171)
* feature: packets + features 14.10 [NO FIX LOGIN]

* fix header by murilo | dudantas

* fix: old protocol 11.00 [g_game.enableFeature(GameHeader1400);]

fix: old protocol 11.00 [g_game.enableFeature(GameHeader1400);]

* test

* test

* clear

* clear

* revert me changes of  header protocol

* header -> feat: version 14 - 1173

Co-Authored-By: murilo09 <78226931+murilo09@users.noreply.github.com>
Co-Authored-By: Eduardo Dantas <eduardo.dantas@hotmail.com.br>

* clear

* format

* format

* format

* clear

---------

Co-authored-by: murilo09 <78226931+murilo09@users.noreply.github.com>
Co-authored-by: Eduardo Dantas <eduardo.dantas@hotmail.com.br>
2025-07-30 15:17:32 -03:00
Renato Machado
e42fc458d1
Update README.md 2025-07-01 21:56:58 -03:00
Rodrigo Paixão
94a3346acf
feat: new shop (based in store) (#1151) 2025-05-12 14:31:32 -03:00
kokekanon
0a33a812e8
feat: Daily Reward in Html / css (#1143) 2025-05-06 16:01:47 -03:00
kokekanon
f3771ade73
fix: extended view (#1137) 2025-04-12 21:33:19 -03:00
InnerCircleTFS
4694714921
feat: Cam system by kondra (#1116) 2025-03-16 17:20:00 -03:00
kokekanon
bcbb3a3b74
fix : store in TFS 10.98 and 13.10 (#1100) 2025-02-14 21:25:02 -03:00
kokekanon
8288c1b751
improve : quickLoot features (#1096) 2025-02-14 21:24:52 -03:00
kokekanon
3576cc652c
fix: combat control (#1094) 2025-02-04 10:53:29 -03:00
kokekanon
ac3deac9e1
fix: game_outfit custom compatible with canary (familiar, outfit/mount in store) (#962)
Co-authored-by: Luan Luciano <luanluciano@outlook.com>
Co-authored-by: Rodrigo Paixão <god.rodrigo@hotmail.com>
Co-authored-by: Renato Machado <mehahx@gmail.com>
2025-01-23 18:44:53 -03:00
Marcin Jałocha
262d238f1f
improve: remove bot protection macro 2025-01-14 12:47:32 -03:00
InnerCircleTFS
06aa9080c3
feat: keybinds by oen | (limited) Part 1 (#996) 2024-12-17 18:27:38 -03:00
InnerCircleTFS
5c5dc582a9
improve: UIGraph with new features by oen (#984)
UIGraph widget got massive update including:

Multiple graphs in a single widget
Showing value of a closest point on a line when widget is hovered
Better performance due to A LOT of caching

author: Oen
2024-12-09 17:04:32 -03:00
kokekanon
f6c5789912
fix: market in TFS 10.98 and canary 11.00 | fix issue : #911 (#912) 2024-10-13 14:19:51 -03:00
kokekanon
205e80bf83
feat: Vips Groups | fix issue: #730 (#908) 2024-10-06 02:58:00 -03:00
Luan Luciano
134c6dc52a
feat: full cyclopedia module (#868) 2024-10-01 16:40:04 -03:00
kokekanon
213b3154d7
improve: readme infos 2024-08-09 14:26:03 -03:00
Luan Luciano
767e1ff44f
fix: using OTC with TFS main using minimal HTTP login server 2024-07-03 10:23:52 -03:00
Renato Machado
e4b6995e48
Update README.md 2024-04-03 19:09:16 -03:00
Renato Machado
9b8cf1831e
Update README.md 2024-04-03 19:04:39 -03:00
SkullzOTS
5c012ca031
feat: Typing Icon (#582) 2024-03-23 13:32:30 -03:00
Renato Machado
16197cd5a3
Update README.md 2024-03-04 12:06:55 -03:00
Ben Dol
e9ab65432b
feat: Local Lua Debugger support for VSCode! (#671)
* Added Local Lua Debugger support for VSCode!

* Add README credit

* Don't know the syntax lol

* Okay ignore this
2023-12-08 18:15:41 -03:00
Ben Dol
c8ae6c1cd6
Framework Cleanup (no more client code in fw) (#666)
* Moved <client/...> includes from framework (we should never cross contaminate fw/client)

GraphicalApplication was the biggest offender, we need to ensure that this is a base graphical application class and not a client specific class.
Created UIQrCode widget
Minor additions and clean up

* Fix for latest version

* Finished, no more client code in the framework!

* Update README

* Revert

* fix cmake build

* Update review suggestions

Remove `image-source-base64` in favour of `image-source: base64:/path/image`

* Added CHANGELOG.md to help with noting breaking changes

* More framework improvements and some client improvements:

- Readd FRAMEWORK_GRAPHICS (so we can have no graphics support)
- Added creatureDiagonalWalkSpeed/playerDiagonalWalkSpeed upgrade_classification
- Added getCountOrSubType to Item lua binding
- Added startEvent to EventDispatcher (to start stored ScheduledEvent's)
- Removed g_drawPool from the application.cpp (we use dispatchPoll)
- Added startTime calculator when logging module starts
- Allow commenting out otml using #
- Added some math functions
- Added onAdopted/onAbandoned to UIWidget for when they are added to/from parent UIWidget's
- Added some more helper methods to UIWidget
- Added visibleOnly to UIWidget getChildBefore/getChildAfter methods
- Added onHovered for only hovered widget events
- Make getChildIndex take child as optional parameter, if not provided it returns this widgets child index
- Added sha1Encrpyt method
- General clean up

* Rename ApplicationDrawEvents#setLoadingAsyncTexture to onLoadingAsyncTextureChanged

* Update setup.otml

* Added a todo

* Clean up

* Revert old code (oops)

* Reverting onAdopted, etc

* Add improved version

* Improve getHoveredChild

* Recommended fixes/clean up

* Moved missed graphical sources to FRAMEWORK_GRAPHICS
2023-12-07 21:28:42 -03:00
Renato Machado
83a7a36853 Update README.md 2023-12-04 18:42:45 -03:00
SkullzOTS
be826a4acf
feat: Smooth Walk Elevation (#663)
Co-authored-by: Renato Machado <mehahx@gmail.com>
2023-11-30 21:01:49 -03:00
Renato Machado
60ed8a77c9 Update README.md 2023-11-26 14:12:23 -03:00
Renato Machado
11cecb8c35
feat: v8 Bot 2023-11-21 22:27:20 -03:00
Renato Machado
5876849eb1
feat: Shader with framebuffer 2023-11-21 20:17:54 -03:00
Joao Pasqualini Costa
14944377ab
feat: QR Code support, with auto generate it from string 2023-09-25 17:27:32 -03:00
Joao Pasqualini Costa
eee8012baf
feat: colored text
Make possible to have multiple colors in a text
2023-08-02 13:39:44 -03:00
Renato Machado
0c735a551c
feat: Tile Widget (#579)
local widget = g_ui.createWidget('Panel')
widget:setSize({ width = 100, height = 100 })
widget:setBackgroundColor('black')

g_game.getLocalPlayer():getTile():setWidget(widget)
2023-08-01 18:04:26 -03:00
Renato Machado
d13beb2a83
Update README.md 2023-07-12 17:50:04 -03:00
Renato Machado
dd8b22f4f1
refactor: auto reload module rewritten from lua to c++ 2023-07-12 17:45:03 -03:00
Renato Machado
a8329efbbd
feat: data/setup.otml 2023-05-13 23:44:59 -03:00
Renato Machado
4d43431b62
feat: config default font to creature/static-text/animated-text/widget text 2023-05-13 19:51:28 -03:00