Don't do certain things if bossClear is active
Preparation for when the endgame is added later.
This commit is contained in:
parent
e1854b47c9
commit
dbc1272c05
1 changed files with 5 additions and 1 deletions
|
@ -86,6 +86,10 @@ Level = function(levelName) {
|
||||||
initParaloop();
|
initParaloop();
|
||||||
|
|
||||||
level.map.rocks.forEach(function(rock) {
|
level.map.rocks.forEach(function(rock) {
|
||||||
|
if (rock.bossonly && Memory.global.bossClear) {
|
||||||
|
return; // Don't spawn this rock any more.
|
||||||
|
}
|
||||||
|
|
||||||
var obj = Rock(level, rock.x, rock.y, rock.z, rock.type);
|
var obj = Rock(level, rock.x, rock.y, rock.z, rock.type);
|
||||||
placeEntityInGrid(obj);
|
placeEntityInGrid(obj);
|
||||||
|
|
||||||
|
@ -144,7 +148,7 @@ Level = function(levelName) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Boss.
|
// Boss.
|
||||||
if (level.map.boss) {
|
if (level.map.boss && !Memory.global.bossClear) {
|
||||||
boss = Boss(
|
boss = Boss(
|
||||||
level,
|
level,
|
||||||
dolphin.position.x + Math.cos(dolphin.angle) * 250,
|
dolphin.position.x + Math.cos(dolphin.angle) * 250,
|
||||||
|
|
Loading…
Add table
Reference in a new issue