tuxemon.event.actions.npc_speed module

final class tuxemon.event.actions.npc_speed.NpcSpeed(npc_slug, speed)[source]

Bases: EventAction

Set the NPC movement speed to a custom value.

Script usage

npc_speed <npc_slug> <speed>
Script parameters:
  • npc_slug – Either “player” or npc slug name (e.g. “npc_maple”).

  • speed – Speed amount.

Parameters:
  • npc_slug (str) –

  • speed (float) –

name: ClassVar[str] = 'npc_speed'
npc_slug: str
speed: float
start()[source]

Called only once, when the action is started.

For all actions, you will need to override this method.

For actions that only need to run one frame you can simply put all the code here. If the action will need to run over several frames, you can init your action here, then override the update method.

Return type:

None