client runtime · Lua API
Open77.playerInteractions
Runs inside the game process. Reads and presentation are local; anything that changes shared state has to go through the server.
accept
Open77.playerInteractions.accept(interactionId)Queue acceptance of the local player's offered invitation.
Declare dependency 'open77_player_interactions >=1.0.0'. This is an asynchronous resource-export facade: call from a managed coroutine and await the Promise; nil plus reason indicates dispatch/rejection. No presentation capability is required for consumers. Resolving a request ID means queued, not accepted by the server. Observe onPlayerInteractionResult or result(requestId), then lifecycle state events.
Parameters 1
| Name | Type | Use | Default |
|---|---|---|---|
interactionId | string | required | — |
Returns
- Open77.Promise resolving to request ID; nil, reason on rejection
Example
CreateThread(function()
local pending, err = Open77.playerInteractions.accept(interactionId)
if not pending then print(err); return end
local value, rejected = pending:await()
if rejected then print(rejected); return end
print(value)
end)Player interactions guide · Registered in ResourceHost.cpp as LuaPlayerInteractionExport (line 24704).
cancel
Open77.playerInteractions.cancel([interactionId])Queue cancellation of an action the local player participates in; defaults to their current action.
Declare dependency 'open77_player_interactions >=1.0.0'. This is an asynchronous resource-export facade: call from a managed coroutine and await the Promise; nil plus reason indicates dispatch/rejection. No presentation capability is required for consumers. Resolving a request ID means queued, not accepted by the server. Observe onPlayerInteractionResult or result(requestId), then lifecycle state events.
Parameters 1
| Name | Type | Use | Default |
|---|---|---|---|
interactionId | string | optional | — |
Returns
- Open77.Promise resolving to request ID; nil, reason on rejection
Example
CreateThread(function()
local pending, err = Open77.playerInteractions.cancel(interactionId)
if not pending then print(err); return end
local value, rejected = pending:await()
if rejected then print(rejected); return end
print(value)
end)Player interactions guide · Registered in ResourceHost.cpp as LuaPlayerInteractionExport (line 24704).
current
Open77.playerInteractions.current([playerId])Read a player's active reservation; defaults to the local player.
Declare dependency 'open77_player_interactions >=1.0.0'. This is an asynchronous resource-export facade: call from a managed coroutine and await the Promise; nil plus reason indicates dispatch/rejection. No presentation capability is required for consumers. Client observations are not authority for inventory, healing or rewards.
Parameters 1
| Name | Type | Use | Default |
|---|---|---|---|
playerId | integer | optional | — |
Returns
- Open77.Promise resolving to state or nil; nil, reason on rejection
Example
CreateThread(function()
local pending, err = Open77.playerInteractions.current()
if not pending then print(err); return end
local value, rejected = pending:await()
if rejected then print(rejected); return end
print(value)
end)Player interactions guide · Registered in ResourceHost.cpp as LuaPlayerInteractionExport (line 24704).
decline
Open77.playerInteractions.decline(interactionId)Queue refusal of the local player's offered invitation.
Declare dependency 'open77_player_interactions >=1.0.0'. This is an asynchronous resource-export facade: call from a managed coroutine and await the Promise; nil plus reason indicates dispatch/rejection. No presentation capability is required for consumers. Resolving a request ID means queued, not accepted by the server. Observe onPlayerInteractionResult or result(requestId), then lifecycle state events.
Parameters 1
| Name | Type | Use | Default |
|---|---|---|---|
interactionId | string | required | — |
Returns
- Open77.Promise resolving to request ID; nil, reason on rejection
Example
CreateThread(function()
local pending, err = Open77.playerInteractions.decline(interactionId)
if not pending then print(err); return end
local value, rejected = pending:await()
if rejected then print(rejected); return end
print(value)
end)Player interactions guide · Registered in ResourceHost.cpp as LuaPlayerInteractionExport (line 24704).
get
Open77.playerInteractions.get(interactionId)Read one visible active interaction; missing is not an error.
Declare dependency 'open77_player_interactions >=1.0.0'. This is an asynchronous resource-export facade: call from a managed coroutine and await the Promise; nil plus reason indicates dispatch/rejection. No presentation capability is required for consumers. Client observations are not authority for inventory, healing or rewards.
Parameters 1
| Name | Type | Use | Default |
|---|---|---|---|
interactionId | string | required | — |
Returns
- Open77.Promise resolving to state or nil; nil, reason on rejection
Example
CreateThread(function()
local pending, err = Open77.playerInteractions.get(interactionId)
if not pending then print(err); return end
local value, rejected = pending:await()
if rejected then print(rejected); return end
print(value)
end)Player interactions guide · Registered in ResourceHost.cpp as LuaPlayerInteractionExport (line 24704).
isReserved
Open77.playerInteractions.isReserved([playerId])Check the visible reservation cache; defaults to the local player.
Declare dependency 'open77_player_interactions >=1.0.0'. This is an asynchronous resource-export facade: call from a managed coroutine and await the Promise; nil plus reason indicates dispatch/rejection. No presentation capability is required for consumers. Client observations are not authority for inventory, healing or rewards.
Parameters 1
| Name | Type | Use | Default |
|---|---|---|---|
playerId | integer | optional | — |
Returns
- Open77.Promise resolving to boolean; nil, reason on rejection
Example
CreateThread(function()
local pending, err = Open77.playerInteractions.isReserved()
if not pending then print(err); return end
local value, rejected = pending:await()
if rejected then print(rejected); return end
print(value)
end)Player interactions guide · Registered in ResourceHost.cpp as LuaPlayerInteractionExport (line 24704).
list
Open77.playerInteractions.list()Read copied active states visible in this routing bucket.
Declare dependency 'open77_player_interactions >=1.0.0'. This is an asynchronous resource-export facade: call from a managed coroutine and await the Promise; nil plus reason indicates dispatch/rejection. No presentation capability is required for consumers. Client observations are not authority for inventory, healing or rewards.
Returns
- Open77.Promise resolving to state[]; nil, reason on rejection
Example
CreateThread(function()
local pending, err = Open77.playerInteractions.list()
if not pending then print(err); return end
local value, rejected = pending:await()
if rejected then print(rejected); return end
print(value)
end)Player interactions guide · Registered in ResourceHost.cpp as LuaPlayerInteractionExport (line 24704).
respond
Open77.playerInteractions.respond(interactionId, accepted)Queue acceptance or refusal of the local player's offered invitation. Only the target may respond.
Declare dependency 'open77_player_interactions >=1.0.0'. This is an asynchronous resource-export facade: call from a managed coroutine and await the Promise; nil plus reason indicates dispatch/rejection. No presentation capability is required for consumers. Resolving a request ID means queued, not accepted by the server. Observe onPlayerInteractionResult or result(requestId), then lifecycle state events.
Parameters 2
| Name | Type | Use | Default |
|---|---|---|---|
interactionId | string | required | — |
accepted | boolean | required | — |
Returns
- Open77.Promise resolving to request ID; nil, reason on rejection
Example
CreateThread(function()
local pending, err = Open77.playerInteractions.respond(interactionId, true)
if not pending then print(err); return end
local value, rejected = pending:await()
if rejected then print(rejected); return end
print(value)
end)Player interactions guide · Registered in ResourceHost.cpp as LuaPlayerInteractionExport (line 24704).
result
Open77.playerInteractions.result(requestId)Read a cached server acknowledgement for a queued request; acknowledgements expire after30seconds.
Declare dependency 'open77_player_interactions >=1.0.0'. This is an asynchronous resource-export facade: call from a managed coroutine and await the Promise; nil plus reason indicates dispatch/rejection. No presentation capability is required for consumers. Client observations are not authority for inventory, healing or rewards.
Parameters 1
| Name | Type | Use | Default |
|---|---|---|---|
requestId | string | required | — |
Returns
- Open77.Promise resolving to result table or nil; nil, reason on rejection
Example
CreateThread(function()
local pending, err = Open77.playerInteractions.result(requestId)
if not pending then print(err); return end
local value, rejected = pending:await()
if rejected then print(rejected); return end
print(value)
end)Player interactions guide · Registered in ResourceHost.cpp as LuaPlayerInteractionExport (line 24704).
// For agents & LLMsthis page as Markdownllms.txtllms-full.txt
