Skip to content

function setPlayerStrength

This function will set the player strength points for all players.
Original: setPlayerStrength

Declaration

async def setPlayerStrength(id : int, strength : int)

Parameters

int id: the player id.
int strength: strength points amount.

Source code in src/pyg2o/functions/player.py
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
async def setPlayerStrength(id : int, strength : int):
    """
    This function will set the player strength points for all players.
    Original: [setPlayerStrength](https://gothicmultiplayerteam.gitlab.io/docs/0.3.0/script-reference/server-functions/player/setPlayerStrength/)

    ## Declaration
    ```python
    async def setPlayerStrength(id : int, strength : int)
    ```
    ## Parameters
    `int` **id**: the player id.
    `int` **strength**: strength points amount.
    """
    data = f'return {get_call_repr()}'

    server = await PythonWebsocketServer.get_server()
    result = await server.make_request(data)
    return result