Appearance
API
52 modules from 2026.08.27-r2.
| Module | Require | Summary |
|---|---|---|
sdk.action_broker | sdk.action_broker | @type library Global action broker for coordinating independent scripts. Actions reserve one or more channels atomically, then keep those channels until their acknowledgement arrives (or the action fails/cancels). Network callbacks only enqueue copied evidence; pump() is the sole callback execution point. |
sdk.alert_service | sdk.alert_service | Typed-event/live-snapshot alert service. Native notification is optional; history and callbacks work identically in tests and headless environments. |
sdk.cave_action_graph | sdk.cave_action_graph | Deterministic checkpoint action graph. Documents contain data only: custom behavior is resolved by registered callback name, never by executing strings. |
sdk.combat_rotation | sdk.combat_rotation | @type library Ordered spell/rune combat rotation. Rule selection is deterministic; all execution is deferred through the global action broker and revalidated at send time against live creatures, inventory, tiles, cooldowns and safety. |
sdk.combat_safety | sdk.combat_safety | Fail-closed combat/PvP/AoE safety for shipped high-level bots. Low-level Packet/LocalPlayer methods intentionally remain primitives. |
sdk.combat_shapes | sdk.combat_shapes | Exact affected-tile resolution for player spells, runes and direct attacks. |
sdk.container_service | sdk.container_service | Event-driven open-container lifecycle, indexing, roles, and bounded traversal. Physical identities are stable for one session generation; runtime container ids may be reused by the client and are therefore never exposed as identity. |
sdk.creatures | sdk.creatures | Creature classify + packet cache (skull, party, type, summoner). Kind matches Engine/CreatureCatalog.cpp ClassifyKind, then the live TCreature.kind byte when applyCreatureData has remapped protobuf 0/1/2/5/7 onto compact 0..4 (player/monster/npc/summon-own/summon-other). |
sdk.data | sdk.data | Catalogs. Official client map.dat / staticdata.dat win over Canary. NPCs and towns come from sdk/data/_client_npcs.lua (JSON decode of client/npcs.json). Canary _*.lua is the fallback when the client extract is missing. Spec: docs/superpowers/specs/2026-08-21-sharptibia-data-design.md |
sdk.destinations | sdk.destinations | @type library Semantic destination and multi-hop NPC travel resolver. It converts the generated town/NPC/travel catalog into a small graph; local walking remains the responsibility of sdk.path / sdk.navigator. |
sdk.engine | sdk.engine | High-level reads: local player, creatures, viewport, typed inbound events. GetLocalPlayer / GetCreatures take native game.get_local_player / game.get_creatures when those C++ exports return a snapshot, then overlay TPlayerData (capacity, xp, ...) from the session walk. The walks below are also the fallback when native returns nil. GetPlayers / GetMonsters / GetNpcs use ClassifyKind. |
sdk.equipment_rules | sdk.equipment_rules | Ordered conditional loadout selector. This module only calls loadouts.apply; all actual mutations remain in the brokered equipment-loadout module. |
sdk.farm_planner | sdk.farm_planner | @type library Versioned farming-plan runtime. The browser/backend owns immutable plan documents; this module validates and maps the latest downloaded document onto the proven farming modules, derives the active hierarchical task, enforces hunt polygons, applies stop conditions, and publishes compact status. |
sdk.healing_service | sdk.healing_service | @type library Self-only healing/support policy service. Rules decide what should happen; the global action broker decides when it may happen alongside other scripts. |
sdk.hunt_analytics | sdk.hunt_analytics | @type library Authoritative hunt/session analytics. The service consumes typed protocol events and (optionally) terminal action-broker snapshots. It never parses chat text and never sends telemetry over the network. |
sdk.intent_arbiter | sdk.intent_arbiter | @type library Deterministic action-channel arbiter used by the farming planner. Intents are plain tables and may reserve one or more channels. The arbiter adds bounded urgency/risk/waiting bonuses to the base priority so low-priority work eventually runs without allowing it to overtake emergencies. |
sdk.inventory | sdk.inventory | Live backpack / equipped / depot / stash stacks from TContainerStorage. Gold sums gold coin (3031), platinum (3035), crystal (3043). Depot and stash return "not open" when those windows are closed. |
sdk.kite | sdk.kite | Maximin pack goal + Path.to. Does not walk or attack. Ranger: pick a reachable tile that maximizes min Chebyshev to the pack while staying in [min_range, attack_range] when possible. Spec: docs/superpowers/specs/2026-08-21-sdk-kite-design.md |
sdk.localplayer | sdk.localplayer | Local character: Player reads plus talk / walk / use / attack. Actions return ok, err. |
sdk.math | sdk.math | Tile-grid position helpers. Chebyshev is the default distance (Tibia walk/attack range). Direction numbers match Canary/TFS: N=0 E=1 S=2 W=3 SW=4 SE=5 NW=6 NE=7 None=8. Spec: docs/superpowers/specs/2026-08-21-sdk-position-design.md |
sdk.mem | sdk.mem | Low-level conversion, layout, session, queue, string, RTTI, and hex helpers. For SDK internals and typed-event fallbacks. Application scripts start at sdk.engine. |
sdk.monster_telemetry | sdk.monster_telemetry | @type library Passive, bounded monster telemetry. This module never issues game actions. Creature snapshots provide movement/health observations; KillTracking is the authoritative kill source. Classification is descriptive and includes an explicit confidence instead of presenting learned behavior as fact. |
sdk.movement | sdk.movement | Thin wrappers around native game.walk / game.move_to. Combat remains acknowledgement-driven one-tile walking; bounded town recovery segments use moveTo so the official client can keep its normal pre-walk cadence. |
sdk.navigator | sdk.navigator | Stateful one-tile movement controller. Prevents walk queue flooding, remembers temporarily blocked tiles, and suppresses immediate direction reversals that cause left/right oscillation. |
sdk.npc | sdk.npc | NPC greet / say / trade / buy / sell. nearest() walks TCreatureStore and accepts only positively typed or catalog-confirmed NPCs. bank / travel pick a clerk or boat/carpet by catalog, then greet + NPC talk (mode 12). Server-side range, open trade window, and capacity still apply. |
sdk.packet | sdk.packet | Catalog lookup + enqueue for uncovered protocol ops. Resolve by name (TalkMessage / GameclientMessageTalk), never by RVA. Nested objects (ObjectPosition, ObjectIdentifier) are not packets; write their live vtable the same way. Do not hard-code catalog counts: the IDA-generated inbound table is refreshed whenever the client protocol moves. |
sdk.party_assist | sdk.party_assist | @type library Party following and optional friend healing without using client follow. Movement and healing use disjoint broker channels so target combat continues. |
sdk.path | sdk.path | A* on Data.map.walkable / game.map.find_path. Cross-floor uses stairs and teleports from world.bin. Does not walk or attack. 8-way; diagonal is illegal if either adjacent cardinal is blocked. Live creatures do not block. Default Chebyshev cap is 128. Spec: docs/superpowers/specs/2026-08-21-sdk-path-design.md |
sdk.player | sdk.player | Snapshot wrapper for any creature (player, NPC, monster). Reads only; actions live on LocalPlayer. Kind is ClassifyKind (id band + npc/monster catalogs) plus the live TCreature.kind byte. |
sdk.profile | sdk.profile | Per-character key/value store on game.storage, plus alarm predicates. Alarms log/callback as before and use the optional native alert sink. |
sdk.rule_engine | sdk.rule_engine | @type library Generic deterministic rule selection with explicit cooldown ownership. Rules are ordered by descending priority, ascending explicit order, and then insertion order. Selection never marks a cooldown; callers retain control of side effects by calling mark() only after the chosen action was accepted. |
sdk.schedule | sdk.schedule | Timers on game.on("tick"). after / every are non-blocking. wait(ms) yields only when the caller is a coroutine. |
sdk.session | sdk.session | Credential-free session recovery. The native layer invokes Tibia's official retained-credential reconnect slot. This module adds an opt-in retry policy; it never accepts account, password, authenticator, session-key, character, or packet parameters. |
sdk.skills | sdk.skills | Live skill levels from TPlayerSkillStats. use() speaks the words through Packet.talk (mode 1). |
sdk.status | sdk.status | Live self-status cache: conditions, server target, tactics, last vitals. Filled from inbound PlayerState (162), UpdateTarget (163), SetTactics (167), PlayerDataCurrent (160). Official protobuf assign: PlayerState has_bits bit0=state u64@24, bit1=icons u32@32. |
sdk.tile | sdk.tile | Unified static/live tile view. Reads only; actions belong to tools/path APIs. |
sdk.tiles | sdk.tiles | Live items on a tile. A full snapshot is read from Tibia's RTTI-identified TWorldMapStorage; CreateOnMap / ChangeOnMap / DeleteOnMap keep it current. game.map is static terrain. This module is the live ordered object stack. |
sdk.tools | sdk.tools | Rope, shovel, machete, door. UseTwoObjects / UseObject from the catalog. Item ids are Canary / sdk.data names, not opcodes. |
sdk.transitions | sdk.transitions | Automatic entrances for pathing. Interactive blockers are discovered from Tibia's live map stack and approached by the caller; request() performs one brokered use and verifies the resulting teleport/open state. |
sdk.world_navigation | sdk.world_navigation | Asynchronous multi-floor route planner. Heavy WorldGrid A* runs on the MapService worker; the game thread executes only a small semantic action graph made of bounded walking legs and verified transition actions. |
sdk.world_objects | sdk.world_objects | Semantic fixed/dynamic map objects from the live TWorldMapStorage stack. Classification prefers official client lens-help flags, then generated Canary interaction metadata, then conservative exact-name fallbacks. |
sdk.zoom | sdk.zoom | Official world-map camera scaling for the current client. IDA confirms that TGameSessionBase owns shared_ptr<TWorldMapCamera> at session+0xC8 and that the official float setter rebuilds both QMatrix4x4 instances and emits the viewport-change signal. The server viewport remains the constructor-default 18x14 rectangle (15x11 playable plus margins). |
game | — | Native global installed by the script host. on returns 0 when called outside an active file script; keep every positive id and release it in stop() with off for deterministic reloads. |
game.dbg | — | Research/fallback kernel. Prefer sdk.packet and named catalog rows. Do not paste RVAs or live addresses into shared scripts. |
game.overlay | — | — |
game.log | — | — |
game.map | — | Native map reads return nil plus an error while loading/off-thread. A false walkability value is authoritative only after ready() succeeds. |
game.http | — | HTTP is asynchronous. poll(id) returns nil with no error while pending, nil, error for an unknown id, or one terminal response and then removes it. |
game.alert | — | — |
game.storage | — | Per-script storage. Names are 1..80 ASCII letters/digits/_/-/. and must not be . or ... Payloads are limited to 2 MiB. |
game.session | — | Low-level native session facade. reconnect accepts no arguments and reuses only state retained inside the official client. true, status means queued locally; confirm completion through WorldEntered or state().in_world. |
game.planner | — | — |