waytale - v0.3.0
    Preparing search index...

    Class WaytaleMap

    A visually represented map to hold gadgets and for avatars to walk around in. Belongs to a space, gets built from a config. Has collision information for each tile.

    document map config, link to docs

    mixinPropertyObserver

    Index

    Constructors

    • Create new map based on configuration.

      Parameters

      • url: string

        URL of the map (deprecated)

      • mapConfig: object

        config to build a map from

      Returns WaytaleMap

      remove url parameter

    Properties

    avatar: any
    avatars: {} = {}

    a key-value map of avatars, indexed by their ID

    config: object

    configuration details from which this map was built

    gadgets: WaytaleGadget[] = []

    list of gadgets in this space

    likely this will change to Object<number, WaytaleGadget>

    getGadgetsAt: (x: any, y: any) => any
    url: string

    URL of the map (deprecated)

    Methods

    • Check whether the tile at given location is walkable, i.e. no collision is defined for it.

      Parameters

      • position: number[]

        tile position

      Returns boolean

      • whether the tile is walkable or not