docs: Added onPlayerUseCheat and NPC related events

This commit is contained in:
AURUMVORXX
2024-11-06 11:49:08 +03:00
parent d54bd06fef
commit f6fd5893a4
7 changed files with 126 additions and 0 deletions

View File

@@ -0,0 +1,21 @@
# `event` onNpcActionFinished
This event is triggered when NPC action was finished.
Original: [onNpcActionFinished](https://gothicmultiplayerteam.gitlab.io/docs/0.3.0/script-reference/server-events/npc/onNpcActionFinished/)
## Parameters
* `dict` **kwargs**:
* `int` **npc_id**: the npc identifier.
* `int` **action_type**: the action type.
* `int` **action_id**: the unique action identifier.
* `bool` **result**: the result of finished action.
## Usage
```python
import g2o
@g2o.event('onNpcActionFinished')
def onActionFinished(**kwargs):
print(f'NPC {kwargs['npc_id']} finished action {kwargs['action_type']} with the result {kwargs['result']}.')
```