Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Constructors

  • new MoveEvent(game: any, data: any, active: any, key_name: any, keep_reveal: any, keep_custom_psynergy: any, is_npc: any, dash: any, dest_unit_in_tile: any, dest: any, npc_label: any, camera_follow: any, camera_follow_duration: any, final_direction: any, follow_hero_on_finish: any, finish_events: any, minimal_distance: any, keep_npc_collision_disable: any, deactive_char_on_end: any, camera_unfollow_char_on_finish: any, wait_after: any, reset_previous_camera_target: any): MoveEvent
  • Parameters

    • game: any
    • data: any
    • active: any
    • key_name: any
    • keep_reveal: any
    • keep_custom_psynergy: any
    • is_npc: any
    • dash: any
    • dest_unit_in_tile: any
    • dest: any
    • npc_label: any
    • camera_follow: any
    • camera_follow_duration: any
    • final_direction: any
    • follow_hero_on_finish: any
    • finish_events: any
    • minimal_distance: any
    • keep_npc_collision_disable: any
    • deactive_char_on_end: any
    • camera_unfollow_char_on_finish: any
    • wait_after: any
    • reset_previous_camera_target: any

    Returns MoveEvent

Properties

camera_follow: boolean
camera_follow_duration: number
camera_unfollow_char_on_finish: boolean
dash: boolean
data: GoldenSun
deactive_char_on_end: boolean
dest: EventValue | { x: number | EventValue; y: number | EventValue }
dest_unit_in_tile: boolean
final_direction: number
finish_events: GameEvent[]
follow_hero_on_finish: boolean
game: Game
is_npc: boolean
keep_npc_collision_disable: boolean
minimal_distance: number
npc_label: string
previous_camera_target: ControllableChar | InteractableObjects
previous_dash_value: boolean
reset_previous_camera_target: boolean
wait_after: number
CAMERA_TRANSITION_DURATION: 400 = 400
MINIMAL_DISTANCE: 3 = 3
events: {}

The events object where the keys are the ids.

Type declaration

id_incrementer: number

The GameEvents id incrementer.

labeled_events: {}

The events object where the keys are the events labels.

Type declaration

Accessors

  • get active(): boolean
  • get id(): number
  • get keep_reveal(): boolean
  • get key_name(): string
  • get origin_npc(): NPC

Methods

  • _destroy(): void
  • _fire(): Promise<void>
  • destroy(): void
  • This function is the one that should be called to destroy an event. It should never be overriden. Call this function to destroy this event. This can be called whenever an associated entity is destroyed, like maps, NPCs etc.

    Returns void

  • finish(char: ControllableChar, previous_force_char_stop_in_event: boolean, previous_move_freely_in_event: boolean): void
  • fire(origin_npc?: NPC): void
  • This function is the one that should be called to start a event. It should never be overriden. Always before this function is called, it's checked whether Reveal psynergy is being casted, if yes, it's stopped before this event start.

    Parameters

    • Optional origin_npc: NPC

      the NPC that originated this game event.

    Returns void

    if the child class has an async fire function, returns its Promise.

  • go_to_finish(char: ControllableChar, previous_force_char_stop_in_event: boolean, previous_move_freely_in_event: boolean): Promise<void>
  • on_position_reach(char: ControllableChar, previous_force_char_stop_in_event: boolean, previous_move_freely_in_event: boolean): Promise<void>
  • set_event_activation(activate: boolean): void
  • get_char(data: GoldenSun, options: { is_npc?: boolean; npc_index?: number; npc_label?: string }): Hero | NPC
  • A helper function that defines the ControllableChar based on inputs. The controllable char can be a hero or a npc.

    Parameters

    • data: GoldenSun

      The GoldenSun instance.

    • options: { is_npc?: boolean; npc_index?: number; npc_label?: string }

      Some options to help defining the char.

      • Optional is_npc?: boolean

        Whether it's a npc or not.

      • Optional npc_index?: number

        The npc index number.

      • Optional npc_label?: string

        The npc unique label identifier.

    Returns Hero | NPC

    the defined char.

  • get_labeled_event(key_name: string): GameEvent
  • reset(): void

Generated using TypeDoc