POLE 1.0 TRY

The builder.

POLE is the foundational data object for games run by the FLAG Game Engine. It also is a visual editor and asset creation tool. Use it to create game Assets and layout various Scenes for your game. All Asset and Scene information is stored in the POLE object. When finished, export the object and include the POLE.js file with your game. Import a POLE.js file back into the editor to make further adjustments.

POLE is not a code editor. There is no way to write code or behaviors in POLE. You will not find any phony-baloney drag and drop behavior system in the editor. Everything created in the POLE is available for manipulation by FLAG with good old fashioned JavaScript.

File

Export

After creating the game Assets and Scenes, export the POLE object and include the POLE.js file with your game.

Import

Import a POLE.js file to make further adjustments or changes to the POLE object.

Edit

Undo

POLE includes up to 10 levels of undo, however, not every action is undoable.

View

Hide Tools

Toggle visibility of Tools menu.

Hide Menus

Toggle visibility of Menus.

Hide POLE

Toggle visibility of POLE object.

Hide Grid

Toggle visibility of the Grid.

Show Walkables

Toggle visibility of walkable tiles. Green tiles, or 1's, are walkable and red tiles, or 0's, are non-walkable.

Show Box2D

Toggle visibility of Box2D debug draw.

Tools

Select

Select Sprites and Actors to adjust their position on the Map.

Move Map

Drag the Scene's Map position.

Draw Tiles

Draw Tiles on the Map.

Erase Tiles

Erase Tiles on the Map.

Draw Tile Sprites

Draw Tile Sprites on the Map.

Erase Tile Sprites

Erase Tile Sprites on the Map.

Draw Tiled Objects

Draw Tiled Objects on the Map.

Erase Tiled Objects

Erase Tiled Objects on the Map.

Add Sprite

Add Sprites to the Scene.

Add Actor

Add Actors to the Scene.

Walkable Tiles

Set walkable tiles on the map. Choose Show Walkables in the View menu. Green are walkable, red are non-walkable.

Zoom In

Zoom in on Map.

Zoom Out

Zoom out on Map.

Zero Map

Zero's the Map to the Pointer click.

Assets

Images

Images are used to render all visual objects in a Scene. Several object types are image dependent including Tiles, Tile Sprites, Tiled Objects and Sprites. Image objects are stored in POLE's images list, however, only a name and URL are stored. The source file of the image is loaded into a Scene's images list by FLAG.

Tiles

Images can be broken down into smaller pieces called Tiles. Tiles can be used to draw large Maps with a small amounts of image data. Tiles can also hold frames of animation, like in a Tile Sprite, or be grouped together to form Tiled Objects. Tiles are rendered using a row and column location.

Tile Sheets

A Tile Sheet is a collection of Tiles. The Tiles must be the same size and arranged, as a grid, on an image. A Tile Sheet uses only one image, however, a single image can be broken down into many Tile Sheets. Basic information for a Tile Sheet is stored, as an object, in POLE's tileSheets list. FLAG uses this list to breakdown the Tile Sheet into individual Tiles which are loaded into the Scene's tileSheets list.

Tiles on a Tile Sheet are numbered starting at 1. The 0 index is reserved for a blank or non-rendered Tile.

Tile Sprites

A Tile Sprite is a sequence of Tiles, from a Tile Sheet, used to give a rendered Tile frames of animation. In POLE, Tile Sprites are stored, as objects, in the Tile Sheet's animations list. FLAG uses this list to create Tile Sprite instances which are loaded into the Scene's tileSprites list.

Tiled Object Sheets

Tiled Object Sheets are used to create a group of Tiles that form a larger object, called a Tiled Object. The group of Tiles is contained in a frame. A Tiled Object Sheet can have multiple frames. With multiple frames, you can add animation to the group of Tiles. Tiled Object Sheets are stored, as objects, in POLE's tiledObjectSheets list. FLAG uses this list to breakdown the Tiled Object Sheet into individual Tiles which are loaded into the Scene's tiledObjectSheets list.

Tiled Object Sheet Animations

A Tiled Object Sheet Animation is a sequence of fames, from a Tiled Object Sheet, used to give a rendered Tiled Object frames of animation. In POLE, Tiled Object Sheet Animations are stored, as objects, in the Tiled Object Sheet's animations list. FLAG uses this list to add animations to Tiled Object instances which are loaded into the Scene's tiledObjects list.

Sprites

Sprites are display objects that have frames. Frames can be rendered in sequence to display animation. Sprites can manipulated using FLAG and WIND. They also serve as the display object for Actor Bodies. Sprites are rendered using an x and y location, however they also maintain a row and column property.

Sprite Sheets

A Sprite Sheet is a collection of frames. The frames must be the same size and arranged, as a grid, on an image. A Sprite Sheet uses only one image, however, a single image can be broken down into many Sprite Sheets. Basic information for a Sprite Sheet is stored, as an object, in POLE's spriteSheets list. FLAG uses this list to breakdown the Sprite Sheet into individual frames which are loaded into the Scene's tileSheets list.

Frames on a Sprite Sheet are numbered starting at 0.

Sprite Sheet Animations

A Sprite Sheet Animation is a sequence of fames, from a Sprite Sheet, used to give a rendered Sprite frames of animation. In POLE, Sprite Sheet Animations are stored, as objects, in the Sprite Sheet's animations list. FLAG uses this list to add animations to Sprite instances which are loaded into the Scene's sprites list.

Actors

Actors are a collection of Bodies and Joints. Every Actor must contain at least one Body. Bodies of Actors can be held together by Joints. Both the Bodies and Joints are available to Box2D for physics simulations. Bodies can contain a Sprite.

Actors are stored, as objects, in POLE's actors list. Actor instances are loaded into the Scene's actors list.

Sounds

Sounds currently require two file types to cover all browsers including an .ogg file and an .mp3 file. Basic Sound data is stored, as objects, in POLE's sounds list. The browser compatible Sound file is loaded into FLAG's Sounds list at runtime.

Scenes

Set Up

A Scene is a collection of assets available for manipulation and display at runtime. POLE can contain multiple Scenes. Each Scene is stored, as an object, in POLE's scenes list. FLAG displays only one Scene at a time. A Scene is displayed once it is loaded into FLAG's Scene object.

Layers

Every Scene must have at least one layer. Layers contain all tile information for rendering a Scene's Map. Layers are rendered consecutively starting with layer 0. Layers are stored, as objects, in POLE's layers list.

Walkable Tiles

The Walkable Tiles array is a matrix populated by 1's and 0's. 1's represent walkable tiles, 0's represent non-walkable tiles. The array is used in the pathfinding algorithm called by the TilePath method. Walkable Tiles can also generate static world collider shapes for use in Box2D physics simulations. Walkable Tiles can be altered using the Walkable Tiles tool in POLE.

Walkable Tile information is stored in a scene's walkableTiles array in POLE and loaded into the Scene's walkableTiles array at runtime.

Assets

Instances of game Assets can be loaded into a Scene through POLE or at runtime using FLAG.

Tile Sprites

Instances of Tile Sprites are stored, as objects, in the Scene's tileSprites array.

Tiled Objects

Instances of Tiled Objects are stored, as objects, in the Scene's tiledObjects array.

Sprites

Instances of Sprites are stored, as objects, in the Scene's sprites array.

Actors

Instances of Actors are stored, as objects, in the Scene's actors array.

Box2D

Every Scene can have a unique set up for the Box2D physics engine.

Use Walkable Tile Colliders

Walkable Tile Colliders are created by FLAG, at runtime, when a Scene is loaded. It uses the walkableTiles array to create Box2D static Bodies around tiles that are non-walkable and adds those Bodies to the Scene's worldColliders list.

World Colliders

World Colliders are custom convex polygon shaped static Bodies used for collision in the Scene. World Colliders are stored, as objects, in the Scene's worldColliders list.

Gravity

Controls the force of gravity in the Scene.

Game

Display

Controls how the game is displayed and adapts to the size of the browser and device.

FPS

Controls the Frames Pre Second of FLAG.

FLAG WIND