655 B
655 B
event onPlayerChangeMana
This event is triggered when player mana changes.
Original: onPlayerChangeMana
Parameters
dictkwargs:intplayerid: the id of the player mana points gets changed.intoldMP: the previous mana points of the player.intnewMP: the new mana points of the player.
Usage
import g2o
@g2o.event('onPlayerChangeMana')
def onChangeMana(**kwargs):
print(f'Player {kwargs['playerid']} changed mana: {kwargs['oldMP']} -> {kwargs['newMP']}')