Skip to content

sdk.input ​

Official tibia::input::TGameAction catalog + publish. Resolve by name (ToggleMounted, TGameActionUse). Do not paste RVAs. Simple actions publish through TGameClient signal 0. Parameterized Use/Look/MoveObject stay on sdk.packet / sdk.tools until a factory is wired.

lua
local M = require("sdk.input")

get ​

function · get(name)

Look up a tibia::input TGameAction catalog row by name.

Parameters

NameTypeSummary
namestringcatalog key or TGameAction* RTTI

Returns

TypeSummary
table|nilspec
string|nilerr

list ​

function · list(): GameActionRow[]

All recovered TGameAction rows.

Returns

TypeSummary
GameActionRow[]—

publishable ​

function · publishable(name: string): boolean

True when the kernel can publish this simple action.

Parameters

NameTypeSummary
namestring—

Returns

TypeSummary
boolean—

publish ​

function · publish(name, fields)

Publish a simple TGameAction through TGameClient signal 0.

Parameters

NameTypeSummary
namestring—
fields?table—

Returns

TypeSummary
Result?,ErrorMessage?, string?

toggleMounted ​

function · toggleMounted(): Result?, ErrorMessage?, string?

Publish ToggleMounted (simple TGameAction). Catalog name, not an RVA. Fails if the action is not publishable.

Returns

TypeSummary
Result?, ErrorMessage?, string?—

mount ​

function · mount(): Result?, ErrorMessage?, string?

Publish MountPlayer. Does not check whether already mounted. Use toggleMounted when the UI button is the model.

Returns

TypeSummary
Result?, ErrorMessage?, string?—

unmount ​

function · unmount(): Result?, ErrorMessage?, string?

Publish UnmountPlayer. Does not check mount state first. Pair with mount() in scripts that know the desired state.

Returns

TypeSummary
Result?, ErrorMessage?, string?—

attackFirst ​

function · attackFirst(): Result?, ErrorMessage?, string?

Publish AttackFirstTarget (battle list). Not a substitute for engagement lock/attack packets. Catalog-driven; no opcode constants.

Returns

TypeSummary
Result?, ErrorMessage?, string?—

attackNext ​

function · attackNext(): Result?, ErrorMessage?, string?

Publish AttackNextTarget. Cycles the battle-list selection. CaveBot targeting does not use this.

Returns

TypeSummary
Result?, ErrorMessage?, string?—

attackPrevious ​

function · attackPrevious(): Result?, ErrorMessage?, string?

Publish AttackPreviousTarget. Battle-list cycle, opposite of attackNext. Keep for scripts that mirror the client buttons.

Returns

TypeSummary
Result?, ErrorMessage?, string?—

startTalkingToNpc ​

function · startTalkingToNpc(): Result?, ErrorMessage?, string?

Publish StartTalkingToNPC. Npc.greet still owns the hi packet; this is the input action. Parameterized talk stays on sdk.packet.

Returns

TypeSummary
Result?, ErrorMessage?, string?—

quitGame ​

function · quitGame(): Result?, ErrorMessage?, string?

Publish QuitGame. Safety logout may use this after safe_stop. No confirm dialog from Lua.

Returns

TypeSummary
Result?, ErrorMessage?, string?—

setTactics ​

function · setTactics(opts?: table): Result?, ErrorMessage?, string?

Publish TGameActionSetTactics with fight/chase/secure/pvp.

Parameters

NameTypeSummary
opts{chase?: integer, secure?: integer, pvp?: integer }

Returns

TypeSummary
Result?, ErrorMessage?, string?—

Arcane SDK catalog generated from scripts/sdk