Skip to content

Obstacle_lamp

Jan Sandström edited this page Apr 28, 2020 · 1 revision

An obstacle in which the player needs to light torches to progress.

The map script needs the following snippet:

local map, data = ...

local lamp = require 'maps/components/obstacle_lamp/obstacle_lamp'

lamp.init(map,data,$timeout)

where $timeout is the time in milliseconds it takes for a torch to expire. 2000 is a good default.

Apart from the common obstacle tiles the map requires:

  • One or more torches. Torches are custom entities calling the torch custom script. The tile must be prefixed torch_.
Clone this wiki locally