Skip to content

PyEvents

No properties found.

No enums found.

(callback) Subscribe to player hits changed event. Callback receives the new hits value as an integer. Example:

def on_hits_changed(new_hits):
API.SysMsg(f"Player hits changed to: {new_hits}")
API.Events.OnPlayerHitsChanged(on_hits_changed)
while not API.StopRequested:
API.ProcessCallbacks()
API.Pause(0.25)

Parameters:

NameTypeOptionalDescription
callbackobject❌ NoPython function to call when player hits change

Return Type: void (Does not return anything)


(callback) Called when a buff is added to your char. Callback receives a Buff object.

Parameters:

NameTypeOptionalDescription
callbackobject❌ No

Return Type: void (Does not return anything)


(callback) Called when a buff is removed from your char. Callback receives a Buff object.

Parameters:

NameTypeOptionalDescription
callbackobject❌ No

Return Type: void (Does not return anything)


(callback) Called when the player dies. Callback receives your characters serial.

Parameters:

NameTypeOptionalDescription
callbackobject❌ No

Return Type: void (Does not return anything)


(callback) Called when a container is opened. Callback receives the container serial.

Parameters:

NameTypeOptionalDescription
callbackobject❌ No

Return Type: void (Does not return anything)


(callback) Called when the player moves. Callback receives a PositionChangedArgs object with .NewLocation available in the object.

Parameters:

NameTypeOptionalDescription
callbackobject❌ No

Return Type: void (Does not return anything)


(callback) Called when a new item is created. Callback receives the item serial.

Parameters:

NameTypeOptionalDescription
callbackobject❌ No

Return Type: void (Does not return anything)