mirror of
https://github.com/tobspr/shapez.io.git
synced 2024-10-27 20:34:29 +00:00
Allow import in the free version, but make it limited to one savegame
This commit is contained in:
parent
fec5dfd43c
commit
1cba701b8a
@ -95,7 +95,7 @@
|
||||
h3 {
|
||||
@include Heading;
|
||||
font-weight: bold;
|
||||
@include S(margin-bottom, 15px);
|
||||
@include S(margin-bottom, 5px);
|
||||
text-transform: uppercase;
|
||||
color: $colorRedBright;
|
||||
}
|
||||
@ -105,7 +105,7 @@
|
||||
}
|
||||
|
||||
ul {
|
||||
@include S(margin-top, 15px);
|
||||
@include S(margin-top, 5px);
|
||||
@include S(padding-left, 20px);
|
||||
li {
|
||||
@include Text;
|
||||
|
@ -16,11 +16,15 @@ export class HUDWatermark extends BaseHUDPart {
|
||||
parameters.context.fillStyle = "#f77";
|
||||
parameters.context.font = "bold " + this.root.app.getEffectiveUiScale() * 17 + "px GameFont";
|
||||
parameters.context.textAlign = "center";
|
||||
parameters.context.fillText("DEMO VERSION", w / 2, 50);
|
||||
parameters.context.fillText("DEMO VERSION", w / 2, this.root.app.getEffectiveUiScale() * 35);
|
||||
|
||||
parameters.context.font = "bold " + this.root.app.getEffectiveUiScale() * 12 + "px GameFont";
|
||||
parameters.context.textAlign = "center";
|
||||
parameters.context.fillText("Please consider to buy the full version!", w / 2, 90);
|
||||
parameters.context.fillText(
|
||||
"Please consider to buy the full version!",
|
||||
w / 2,
|
||||
this.root.app.getEffectiveUiScale() * 55
|
||||
);
|
||||
|
||||
parameters.context.textAlign = "left";
|
||||
}
|
||||
|
@ -99,8 +99,8 @@ export class MainMenuState extends GameState {
|
||||
}
|
||||
|
||||
requestImportSavegame() {
|
||||
if (IS_DEMO) {
|
||||
this.dialogs.showFeatureRestrictionInfo(T.demo.features.importingGames);
|
||||
if (IS_DEMO && this.app.savegameMgr.getSavegamesMetaData().length > 0) {
|
||||
this.dialogs.showWarning(T.dialogs.oneSavegameLimit.title, T.dialogs.oneSavegameLimit.desc);
|
||||
return;
|
||||
}
|
||||
|
||||
@ -337,6 +337,11 @@ export class MainMenuState extends GameState {
|
||||
}
|
||||
|
||||
onPlayButtonClicked() {
|
||||
if (IS_DEMO && this.app.savegameMgr.getSavegamesMetaData().length > 0) {
|
||||
this.dialogs.showWarning(T.dialogs.oneSavegameLimit.title, T.dialogs.oneSavegameLimit.desc);
|
||||
return;
|
||||
}
|
||||
|
||||
if (IS_DEMO) {
|
||||
const { ok } = this.dialogs.showWarning(
|
||||
T.dialogs.demoExplanation.title,
|
||||
|
@ -61,8 +61,9 @@ demoBanners:
|
||||
intro: >-
|
||||
If you enjoy this game, please consider to buy the full version!
|
||||
advantages:
|
||||
- No advertisements & watermark
|
||||
- Dark mode
|
||||
- No advertisements
|
||||
- Unlimited savegames
|
||||
- Dark mode & more
|
||||
- >-
|
||||
Allow me to further develop shapez.io ❤️
|
||||
|
||||
@ -149,6 +150,10 @@ dialogs:
|
||||
title: Notice from the Developer
|
||||
desc: I am developing this game in my free time, and I hope you enjoy it! If you do, please consider to buy the standalone version!
|
||||
|
||||
oneSavegameLimit:
|
||||
title: Limited savegames
|
||||
desc: You can only have one savegame at a time in the demo version. Please remove the existing one or get the standalone!
|
||||
|
||||
ingame:
|
||||
# This is shown in the top left corner and displays useful keybindings in
|
||||
# every situation
|
||||
@ -472,6 +477,7 @@ demo:
|
||||
features:
|
||||
restoringGames: Restoring savegames
|
||||
importingGames: Importing savegames
|
||||
oneGameLimit: Limited to one savegame
|
||||
customizeKeybindings: Customizing Keybindings
|
||||
|
||||
settingNotAvailable: Not available in the demo.
|
||||
|
Loading…
Reference in New Issue
Block a user