fix(saves): return valid cloud settings and persist tutorial skips
Return the unframed BLK expected by the cloud settings client. Allow the basic ground tutorial to be skipped and save the tutorial preference immediately.
This commit is contained in:
1 parent
a2667a16a0
commit
32e9201a5f
4 files changed
+63
-12
No files matched your search
@@ -5,10 +5,12 @@
|
||||
* condition:t="" means every player has it (the UI scripts ask with hasFeature, which falls
|
||||
* back to the native local_player_has_feature, scripts/user/features.nut).
|
||||
*
|
||||
* AllowedToSkipBaseTutorials: lets the player skip the base tutorials. The stock tutorial
|
||||
* offer (scripts/tutorials/nextTutorialHandler.nut) enables its skip and close buttons only
|
||||
* with this feature (tutorialsData.nut canSkipByFeature). The offline version makes the
|
||||
* tutorial optional (local verification).
|
||||
* AllowedToSkipBaseTutorials / AllowedToSkipBaseTankTutorials: let the player skip or close
|
||||
* every branch's base tutorial offer. `scripts/tutorials/tutorialsData.nut` gates air and naval
|
||||
* base tutorials on `AllowedToSkipBaseTutorials` and ground base tutorials (`lightTank`,
|
||||
* `lightTank_action`) on `AllowedToSkipBaseTankTutorials`; without both, `NextTutorialHandler`
|
||||
* hides its "do not ask me again" checkbox and close button until the tutorial is started once
|
||||
* (local verification).
|
||||
*
|
||||
* PaymentMethods: lets scripts/onlineShop/onlinePurchase.nut offer GJN payment directly
|
||||
* inside the Golden Eagles and Premium Account windows (stock game_settings.blk restricts it
|
||||
@@ -18,7 +20,11 @@ import { ensureBlock, setParam, type BlkBlock } from '@wto/blk';
|
||||
|
||||
export const GAME_SETTINGS_PATH = 'config/game_settings.blk';
|
||||
|
||||
export const OFFLINE_FEATURES: readonly string[] = ['AllowedToSkipBaseTutorials', 'PaymentMethods'];
|
||||
export const OFFLINE_FEATURES: readonly string[] = [
|
||||
'AllowedToSkipBaseTutorials',
|
||||
'AllowedToSkipBaseTankTutorials',
|
||||
'PaymentMethods',
|
||||
];
|
||||
|
||||
/** Give every player the features; returns the ones that were not on for everyone before. */
|
||||
export function enableFeaturesForEveryone(gameSettings: BlkBlock, names: readonly string[]): string[] {
|
||||
|
||||
Reference in new issue
Block a user