2017-08-22 00:58:41 +02:00
|
|
|
(function() {
|
|
|
|
var act1 = {};
|
|
|
|
|
2017-08-23 23:31:50 +02:00
|
|
|
var controlPanelSprite = kontra.sprite({x: 16, y: 13, width: 3, height: 2});
|
|
|
|
|
|
|
|
act1.init = function() {
|
2017-08-24 15:33:46 +02:00
|
|
|
if (muri.currentRoom === 'stasis_dark') {
|
2017-08-23 23:31:50 +02:00
|
|
|
muri.get('bubble')
|
|
|
|
.story([
|
|
|
|
[['Beep', 'Bip, Bip'], [20, 15]],
|
|
|
|
[['Urgh ... ...', 'Where I am?', 'What happened?'], [35, 40]],
|
|
|
|
[['I can\'t see a thing ...', '... need to turn on the light ...'], [35, 40]]
|
|
|
|
]);
|
|
|
|
}
|
|
|
|
};
|
2017-08-22 00:58:41 +02:00
|
|
|
|
|
|
|
act1.update = function() {
|
2017-08-23 23:31:50 +02:00
|
|
|
if (muri.get('mouse').clickedOn(controlPanelSprite)) {
|
|
|
|
muri.get('mouse').releaseClick();
|
|
|
|
|
2017-08-24 15:33:46 +02:00
|
|
|
if (muri.currentRoom === 'stasis_dark') {
|
|
|
|
muri.currentRoom = 'stasis';
|
2017-08-23 23:31:50 +02:00
|
|
|
muri.get('bubble')
|
|
|
|
.talk([
|
|
|
|
'Ah, much better.',
|
|
|
|
'Looks like something happened to my stasis capsule.'
|
|
|
|
]);
|
|
|
|
} else {
|
|
|
|
muri.get('bubble')
|
|
|
|
.talk(['No, I will not turn off the light again!']);
|
|
|
|
}
|
|
|
|
}
|
2017-08-22 00:58:41 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
act1.render = function() {
|
|
|
|
};
|
|
|
|
|
|
|
|
muri.modules.push(act1);
|
|
|
|
}());
|