Description

Loads a graphic resource or audio

Usage

Constructor

  • type {String}

    Resource type

  • file {Integer}

    file name

  • id {Integer}

    Resource id

  • callback {Function} optional

    (optional) Call when the resource is loaded

Example

RPG.Path.load("animations", "anim.png", "12", function() {
    RPGJS.Path.get("animations", "12"); // => Graphics/Animations/anim.png
});

Properties

Switches

instance of the Game_Switches class

Variables

instance of the Game_Variables class

SelfSwitches

instance of the Game_SelfSwitches class

Map

instance of the Game_Map class

Actors

instance of the Game_Actors class

Player

instance of the Game_Player class

System

instance of the Game_System class

Methods

defines

Initializes the canvas

setData

Assigns data to the game

setMaterials

Assigns data to the game

setMap

Defines the data of new map

setEvent

Defines the data of new event on a map

ready

Calls a function when the canvas is loaded

Discussion