LAYER => LAYERS, oops
This commit is contained in:
parent
683ab6a2c9
commit
a4c1aa869b
@ -250,9 +250,9 @@ function parse_level(bytes, number) {
|
|||||||
// pgchip grants directions to ice blocks on cloners by putting a clone block
|
// pgchip grants directions to ice blocks on cloners by putting a clone block
|
||||||
// beneath them instead
|
// beneath them instead
|
||||||
if (l === 1 && 0x0e <= tile_byte && tile_byte <= 0x11 &&
|
if (l === 1 && 0x0e <= tile_byte && tile_byte <= 0x11 &&
|
||||||
cell[LAYER.actor] && cell[LAYER.actor].type.name === 'ice_block')
|
cell[LAYERS.actor] && cell[LAYERS.actor].type.name === 'ice_block')
|
||||||
{
|
{
|
||||||
cell[LAYER.actor].direction = extra.direction;
|
cell[LAYERS.actor].direction = extra.direction;
|
||||||
let type = TILE_TYPES['cloner'];
|
let type = TILE_TYPES['cloner'];
|
||||||
cell[type.layer] = {type};
|
cell[type.layer] = {type};
|
||||||
continue;
|
continue;
|
||||||
@ -267,8 +267,8 @@ function parse_level(bytes, number) {
|
|||||||
|
|
||||||
// Fix the "floor/empty" nonsense here by adding floor to any cell with no terrain on bottom
|
// Fix the "floor/empty" nonsense here by adding floor to any cell with no terrain on bottom
|
||||||
for (let cell of level.linear_cells) {
|
for (let cell of level.linear_cells) {
|
||||||
if (! cell[LAYER.terrain]) {
|
if (! cell[LAYERS.terrain]) {
|
||||||
cell[LAYER.terrain] = { type: TILE_TYPES['floor'] };
|
cell[LAYERS.terrain] = { type: TILE_TYPES['floor'] };
|
||||||
}
|
}
|
||||||
// TODO we could also deal with weird cases where there's terrain /on top of/ something
|
// TODO we could also deal with weird cases where there's terrain /on top of/ something
|
||||||
// else: things underwater, the quirk where a glider will erase the item underneath...
|
// else: things underwater, the quirk where a glider will erase the item underneath...
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user