mirror of
https://github.com/doublespeakgames/adarkroom.git
synced 2026-06-30 16:22:30 +08:00
add confirm hyper
lets the user know what hyper mode is, and confirms turning it on. Updates .pot to match current source.
This commit is contained in:
+907
-952
File diff suppressed because it is too large
Load Diff
+28
-2
@@ -148,7 +148,7 @@
|
|||||||
$('<span>')
|
$('<span>')
|
||||||
.addClass('hyper menuBtn')
|
.addClass('hyper menuBtn')
|
||||||
.text(_('hyper.'))
|
.text(_('hyper.'))
|
||||||
.click(Engine.triggerHyperMode)
|
.click(Engine.confirmHyperMode)
|
||||||
.appendTo(menu);
|
.appendTo(menu);
|
||||||
|
|
||||||
$('<span>')
|
$('<span>')
|
||||||
@@ -487,7 +487,33 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
triggerHyperMode: function(){
|
confirmHyperMode: function(){
|
||||||
|
if (!Engine.options.doubleTime) {
|
||||||
|
Events.startEvent({
|
||||||
|
title: _('Go Hyper?'),
|
||||||
|
scenes: {
|
||||||
|
start: {
|
||||||
|
text: [_('turning hyper mode speeds up the game to x2 speed. do you want to do that?')],
|
||||||
|
buttons: {
|
||||||
|
'yes': {
|
||||||
|
text: _('yes'),
|
||||||
|
nextScene: 'end',
|
||||||
|
onChoose: Engine.triggerHyperMode
|
||||||
|
},
|
||||||
|
'no': {
|
||||||
|
text: _('no'),
|
||||||
|
nextScene: 'end'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
Engine.triggerHyperMode();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
triggerHyperMode: function() {
|
||||||
Engine.options.doubleTime = !Engine.options.doubleTime;
|
Engine.options.doubleTime = !Engine.options.doubleTime;
|
||||||
if(Engine.options.doubleTime)
|
if(Engine.options.doubleTime)
|
||||||
$('.hyper').text(_('classic.'));
|
$('.hyper').text(_('classic.'));
|
||||||
|
|||||||
Reference in New Issue
Block a user