Rex's plugins for Construct2
  • Home
  • Map
  • Tutorial/Templates
  • News
  • About

rex_maze_gen

Plugin, ACE table, Discussion thread
Dependence: None

Introduction
Generate random maze asynchronously. Reference: rot.js

Usage
Generate maze
Sample
  1. Call "Action:Generate" to generate a random maze asynchronously in a webworker. The same set of parameters will generate the same maze.
  2. "Condition:On completed" will be triggered while generating completed. "Condition:Is generating" will return true while generating.
  3. Then retrieving symbol of tiles in this maze by expressions, or condition
  • "Expression:ValueAt" : get symbol of this tile in logic ( X , Y ) ,0=empty space, 1=wall,  (-1)=not in map
  • "Condition:Is a wall": return true if a tile is a wall (or an empty space)
  • "Expression:MapWidth", "Expression:MapHeight": maze width or maze height
Cancel
Call "Action:Cancel" to cancel maze generating.
Release
Call "Action:Release" to release current maze in memory.

Official save/load
This plugin supports official save/load.

And more...
Uses rex_eventbalancer plugin + rex_loopiterator plugin to create tiles in multi-ticks, and rex_board_squareTx plugin to get the position of each tile. rex_board_squareTx plugin could support orthogonal or isometric map.

Create a free web site with Weebly
  • Home
  • Map
  • Tutorial/Templates
  • News
  • About