narrat 2.0.6 → 2.0.9-rc-1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (103) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +105 -38
  3. package/dist/app.vue.d.ts +96 -106
  4. package/dist/audio.7z +0 -0
  5. package/dist/components/MainMenu.vue.d.ts +12 -12
  6. package/dist/components/Skills.vue.d.ts +22 -22
  7. package/dist/components/debug/debug-menu.vue.d.ts +48 -48
  8. package/dist/components/dialog-picture.vue.d.ts +9 -9
  9. package/dist/components/game-dialog.vue.d.ts +65 -65
  10. package/dist/components/hud.vue.d.ts +12 -12
  11. package/dist/components/inventory-ui.vue.d.ts +30 -30
  12. package/dist/components/loading-bar.vue.d.ts +10 -10
  13. package/dist/components/menu-buttons.vue.d.ts +26 -26
  14. package/dist/components/notification-toast.vue.d.ts +6 -6
  15. package/dist/components/quests-ui.vue.d.ts +20 -20
  16. package/dist/components/utils/modal.vue.d.ts +6 -6
  17. package/dist/components/volume-controls.vue.d.ts +7 -7
  18. package/dist/config.d.ts +151 -151
  19. package/dist/constants.d.ts +1 -1
  20. package/dist/data/characters.json +62 -62
  21. package/dist/data/config.json +182 -182
  22. package/dist/data/example.rpy +367 -360
  23. package/dist/data/refactor.rpy +30 -30
  24. package/dist/defaultConfig.d.ts +2 -2
  25. package/dist/demo/demo.d.ts +1 -1
  26. package/dist/dialog-box.vue.d.ts +37 -37
  27. package/dist/exports/config.d.ts +1 -1
  28. package/dist/exports/display.d.ts +2 -2
  29. package/dist/exports/plugins.d.ts +20 -20
  30. package/dist/fonts/OpenDyslexic.ttf.svg +2326 -2326
  31. package/dist/gameloop.d.ts +3 -3
  32. package/dist/lib/lib.d.ts +15 -15
  33. package/dist/lib.css +1 -1
  34. package/dist/main.d.ts +5 -5
  35. package/dist/narrat.es.js +256 -227
  36. package/dist/narrat.es.js.map +1 -1
  37. package/dist/narrat.umd.js +84 -84
  38. package/dist/narrat.umd.js.map +1 -1
  39. package/dist/plugins/NarratPlugin.d.ts +11 -11
  40. package/dist/stores/audio-store.d.ts +12 -12
  41. package/dist/stores/dialog-store.d.ts +31 -31
  42. package/dist/stores/hud-stats-store.d.ts +22 -22
  43. package/dist/stores/inventory-store.d.ts +37 -37
  44. package/dist/stores/main-store.d.ts +283 -276
  45. package/dist/stores/notification-store.d.ts +12 -12
  46. package/dist/stores/quest-log.d.ts +39 -39
  47. package/dist/stores/rendering-store.d.ts +13 -13
  48. package/dist/stores/screens-store.d.ts +23 -23
  49. package/dist/stores/skills.d.ts +36 -36
  50. package/dist/stores/vm-store.d.ts +155 -148
  51. package/dist/types/app-types.d.ts +4 -4
  52. package/dist/types/character-types.d.ts +27 -27
  53. package/dist/types/dialog-box-types.d.ts +10 -10
  54. package/dist/types/game-save.d.ts +21 -21
  55. package/dist/types/parser.d.ts +93 -92
  56. package/dist/types/state.d.ts +3 -3
  57. package/dist/utils/ajax.d.ts +1 -1
  58. package/dist/utils/audio-loader.d.ts +13 -13
  59. package/dist/utils/characters.d.ts +5 -5
  60. package/dist/utils/data-helpers.d.ts +19 -19
  61. package/dist/utils/debounce.d.ts +14 -14
  62. package/dist/utils/error-handling.d.ts +3 -3
  63. package/dist/utils/helpers.d.ts +6 -6
  64. package/dist/utils/images-loader.d.ts +6 -6
  65. package/dist/utils/logger.d.ts +11 -11
  66. package/dist/utils/object-iterators.d.ts +8 -8
  67. package/dist/utils/promises.d.ts +1 -1
  68. package/dist/utils/randomId.d.ts +1 -1
  69. package/dist/utils/save-helpers.d.ts +3 -3
  70. package/dist/utils/skillchecks.d.ts +17 -17
  71. package/dist/utils/string-helpers.d.ts +3 -3
  72. package/dist/utils/time-helpers.d.ts +2 -2
  73. package/dist/vm/commands/arithmetic-commands.d.ts +17 -17
  74. package/dist/vm/commands/audio-commands.d.ts +8 -8
  75. package/dist/vm/commands/choice.d.ts +37 -37
  76. package/dist/vm/commands/clear_dialog.d.ts +2 -2
  77. package/dist/vm/commands/command-helpers.d.ts +2 -2
  78. package/dist/vm/commands/command-plugin.d.ts +43 -30
  79. package/dist/vm/commands/flow-commands.d.ts +14 -14
  80. package/dist/vm/commands/if.d.ts +10 -10
  81. package/dist/vm/commands/index.d.ts +2 -2
  82. package/dist/vm/commands/inventory-commands.d.ts +15 -15
  83. package/dist/vm/commands/logic-command.d.ts +42 -42
  84. package/dist/vm/commands/notify.d.ts +4 -4
  85. package/dist/vm/commands/quest-commands.d.ts +30 -30
  86. package/dist/vm/commands/screen-commands.d.ts +8 -8
  87. package/dist/vm/commands/set.d.ts +6 -6
  88. package/dist/vm/commands/skill-commands.d.ts +33 -33
  89. package/dist/vm/commands/stats-commands.d.ts +12 -12
  90. package/dist/vm/commands/string-commands.d.ts +9 -9
  91. package/dist/vm/commands/text-field.d.ts +7 -7
  92. package/dist/vm/commands/text.d.ts +13 -13
  93. package/dist/vm/commands/wait.d.ts +4 -4
  94. package/dist/vm/vm-helpers.d.ts +16 -16
  95. package/dist/vm/vm-parser.d.ts +19 -19
  96. package/dist/vm/vm-parser.test.d.ts +1 -1
  97. package/dist/vm/vm.d.ts +19 -19
  98. package/package.json +79 -79
  99. package/CHANGELOG.md +0 -776
  100. package/dist/.DS_Store +0 -0
  101. package/dist/img/.DS_Store +0 -0
  102. package/dist/music/.DS_Store +0 -0
  103. package/dist/sounds/.DS_Store +0 -0
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2020 Liana Pigeot
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ MIT License
2
+
3
+ Copyright (c) 2020 Liana Pigeot
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,38 +1,105 @@
1
- # 🚀 Narrat
2
-
3
- ## Narrat 2.0
4
-
5
- This is the narrat 2.0 branch. See the [Narrat 2.0 update docs](https://docs.get-narrat.com/readme/narrat-2.0) for more info, or look at the changelog.
6
-
7
- 2.0 version can be installed with `npm install narrat@next`, as it's not pushed as the main release yet (main release is still 1.x).
8
-
9
- There are syntax changes in usage of $if functions and also an auto script converter available in the [2.0 update docs](https://docs.get-narrat.com/readme/narrat-2.0).
10
-
11
- ## Original Docs
12
-
13
- ![example workflow](https://github.com/nialna/narrat/actions/workflows/main.yml/badge.svg)
14
-
15
- A narrative game engine for text-based games. Inspired by renpy syntax, but built to be customisable, extendable and web-focused. See the [website](https://get-narrat.com)
16
-
17
- ![Narrat banner image](https://gblobscdn.gitbook.com/assets%2F-Mh95QNKFZeeRV90-ZSq%2F-MiI7tyjjriQTQI80bhM%2F-MiI83Ys6ED75AlZ_dVT%2Fnarrat-banner.jpg?alt=media&token=9d72e03f-c2ba-4fcb-8579-491b0f8940d8)
18
-
19
- You can [try a little demo](https://get-narrat.com/demo/). It contains a built version of the [narrat demo repo](https://github.com/nialna/narrat-demo).
20
-
21
- Game dialogue info is written in files with a similar syntax to Renpy (.rpy files). Those files get loaded by the game engine which plays through them. This allows us to use [renpy syntax highlighting](https://marketplace.visualstudio.com/items?itemName=LuqueDaniel.languague-renpy) in vs code easily. It is **not renpy** though, just inspired from it. Eventually narrat might have its own language and file extension support.
22
-
23
- ## Usage
24
-
25
- See the [Documentation](https://docs.get-narrat.com/) for more info, or jump directly in the [Getting Started Guide](https://docs.get-narrat.com/getting-started)
26
-
27
- ## Features
28
-
29
- - Flexible dialog writing with branching and conditions
30
- - Multiple script files support with labels and jumps to organise script writing
31
- - Multiple speaking characters support with icons and poses
32
- - Custom variables in scripts to create flags or other data the game needs to track
33
- - Seamless saving and reloading
34
- - UI with buttons that can be used for example to create world maps with clickable locations (the buttons can be controlled in scripts)
35
- - Sound and music support
36
- - Delays between script lines
37
- - Electron build to turn the game into a pc/mac/linux app (template to be updated with example soon)
38
- - Skill checks (Feature still early, needs a UI for viewing skills and creating characters)
1
+ # 🚀 Narrat
2
+
3
+ ![example workflow](https://github.com/nialna/narrat/actions/workflows/main.yml/badge.svg)
4
+
5
+ Narrat is a game engine for making interactive narrative RPGs packed with features.. Create your game by editing with a Simple scripting syntax. It supports Skills with skill check rolls, an Items inventory, and has a Quests System. The script system is very powerful and allows branching choices, functions, variables and conditions.
6
+
7
+ More info on the [narrat website](https://get-narrat.com). There is an [online demo](https://get-narrat.com/demo/) available to try in the browser.
8
+
9
+ ## Getting Started
10
+
11
+ The best way to get started in a minute is to follow the [Getting Started](https://docs.get-narrat.com/guides/getting-started) documentation page. It shows you to download the ready-to-use game template to get started writing a game with narrat.
12
+
13
+ ## Development (for contributors)
14
+
15
+ Narrat is written in [TypeScript](https://www.typescriptlang.org/). It uses the [Vue](https://vuejs.org/) framework for front-end development. It also uses [pinia](https://pinia.vuejs.org/) for state management
16
+
17
+ ### Requirements
18
+
19
+ - [node.js](https://nodejs.org/en/) (Downloading LTS is fine)
20
+ - A text editor capable of editing a TypeScript and Vue.js project. Recommended: [VSCode](https://code.visualstudio.com/) and the extension [Volar](https://marketplace.visualstudio.com/items?itemName=ms-vscode.vscode-volar) for Vue.
21
+
22
+ ### Running the engine for development
23
+
24
+ 1. Install dependencies
25
+
26
+ `npm install`
27
+
28
+ 2. Run the demo
29
+
30
+ `npm start`
31
+
32
+ This starts the engine on the demo page with the `example.rpy` demo script loaded for testing.
33
+
34
+ ### Available npm commands
35
+
36
+ - `start`: Start the demo for development
37
+ - `build`: The main build command, builds the library in a state ready to use or publish.
38
+ - `test`: Unit tests, used in CI
39
+ - `dev`: Same as start
40
+ - `generate-types`: Generates `.d.ts` type declaration files for the library (auto run on builds)
41
+ - `fix-type-aliases`: Uses [tsc-alias](https://www.npmjs.com/package/tsc-alias) to auto-replace [path mappings](https://www.typescriptlang.org/docs/handbook/module-resolution.html#path-mapping) in the built files, as the TypeScript compiler doesn't do it. (auto run at the end of builds)
42
+ - `lint`: Runs the linter on the code (used in CI)
43
+ - `check-types`: Validates TypeScript types.
44
+
45
+ ### CI info
46
+
47
+ The following tasks run on CI, and CI is required to pass for pull requests to be merged:
48
+
49
+ - Linting
50
+ - Engine build
51
+ - Unit tests (currently only the parser is unit tested)
52
+ - TypeScript type checking.
53
+
54
+ Please make sure your code passes lint/tests/build/type checks before opening a PR.
55
+
56
+ ### Working on the code
57
+
58
+ The narrat codebase isn't currently documented, outside of the [usage docs](https://docs.get-narrat.com). The code is fully written in TypeScript though and should be clearly separated enough to be approachable.
59
+
60
+ ### Engine architecture
61
+
62
+ The narrat engine runs primarily as a Vue app. All the UI in the game is made of Vue components, and when a game uses narrat it effectively creates a Vue app.
63
+
64
+ #### App state
65
+
66
+ The engine's state is stored in pinia. It is split in separate pinia modules for different areas of the engine. They can all be found in the [src/stores](src/stores) folder.
67
+
68
+ - `audio`: handles playing and stopping audio and music
69
+ - `dialog`: Receives and stores all lines of dialogue created by game scripts which appear at the right of the game in the main interactive narrative view.
70
+ - `hud`: Stores stats which are displayed on the hud
71
+ - `inventory`: Manages the player's item inventory
72
+ - `main`: Manages app-level logic and other generic systems like startup/reset/load/save
73
+ - `notifications`: Manages notifications which appear at the top of the screen
74
+ - `quests`: Manages quests and objectives
75
+ - `rendering`: Manages the layout's state for dynamically placing and resizing the game UI
76
+ - `skills`: Manages player skills and xp. Also store skill check states
77
+ - `vm`: Manages the virtual machine which runs the scripting language and controls the game flow.
78
+
79
+ All stores can be accessed anywhere in the code with the `use` hooks (example: `useVM()`).
80
+
81
+ #### Scripting language (VM and parser)
82
+
83
+ The scripting language for narrat runs in a virtual machine which has its state stored in the Vue app with Pinia.
84
+
85
+ The narrat scripting language relies on the parser and the vm. The code for the parser is mainly in [src/vm/vm-parser.ts](src/vm/vm-parser.ts). The parser is in charge of taking the `.rpy` files as input, and returning a tree of parsed expressions that the engine can use.
86
+
87
+ The actual VM is what runs narrat games, and generally controls the flow of the application. The general logic for the vm is in the `vm` store, but there is also some logic sprinkled in the `src/vm` file.
88
+
89
+ All the actual operations available to the scripting language (like `talk`) are defined as Command plugins. The built-in commands included in the language by default are in the [src/vm/commands](src/vm/commands/) folder. More command can be added by games by registering plugins.
90
+
91
+ #### Adding new commands
92
+
93
+ Language commands are defined in the `vm/commands` folder. It should be easy to add new commands to the game engine by looking at the existing commands as an example. New command plugins are included in the `vm/commands/index` file.
94
+
95
+ #### Config file
96
+
97
+ The main config file has a type defined in `src/config.ts`. The vast majority of the config options for narrat are passed in this config files, which games must provide to the engine when starting. New options for the engine should be added to the type for the config file, and also have their default value included in the `src/defaultConfig.ts` file.
98
+
99
+ Engine code can access the config with the `getConfig()` function.
100
+
101
+ #### Plugin system
102
+
103
+ There is now a plugin system developers can use to add new functionality to narrat (more documentation soon). See the [narrat-bitsy](https://github.com/liana-pigeot/narrat-bitsy) plugin for an example.
104
+
105
+ (Note: The narrat-bitsy plugin hasn't been updated for 2.0.0 and might be a bit out of date).
package/dist/app.vue.d.ts CHANGED
@@ -1,106 +1,96 @@
1
- import { PropType } from 'vue';
2
- import { DialogBoxParameters } from './types/dialog-box-types';
3
- import { GameConfig } from './types/app-types';
4
- import { AppOptions } from './config';
5
- import { DialogKey } from './stores/dialog-store';
6
- declare const _default: import("vue").DefineComponent<{
7
- config: PropType<GameConfig>;
8
- options: PropType<AppOptions>;
9
- }, {
10
- dialog: import("vue").ComputedRef<{
11
- speaker: string;
12
- text: string;
13
- pose?: string | undefined;
14
- choices?: {
15
- choice: string;
16
- originalIndex: number;
17
- allowed: boolean;
18
- }[] | undefined;
19
- textField?: boolean | undefined;
20
- interactive: boolean;
21
- id: string;
22
- }[]>;
23
- stack: import("vue").ComputedRef<{
24
- currentIndex: number;
25
- branchData: {
26
- branch: {
27
- code: string;
28
- command: {
29
- commandType: string;
30
- operator: string;
31
- args: (import("./types/parser").Parser.Primitive | {
32
- code: string;
33
- command: any;
34
- fileName: string;
35
- line: number;
36
- })[];
37
- options: import("./types/parser").Parser.DefaultArg;
38
- staticOptions: {};
39
- };
40
- fileName: string;
41
- line: number;
42
- }[];
43
- args?: string[] | undefined;
44
- };
45
- label: string;
46
- scope: {
47
- [key: string]: any;
48
- };
49
- onComplete?: ((result: any) => void) | undefined;
50
- returnValue: any;
51
- }[]>;
52
- modal: import("vue").ComputedRef<string | false>;
53
- flowState: import("vue").ComputedRef<"menu" | "playing">;
54
- }, {
55
- lineTitle: string;
56
- lineText: string;
57
- gameLoaded: boolean;
58
- loadingStep: string;
59
- loadingPercentage: number;
60
- hasSave: boolean;
61
- }, {
62
- dialogLength(): number;
63
- lastDialog(): DialogKey | undefined;
64
- picture(): string | undefined;
65
- backgroundStyle(): any;
66
- layoutWidth(): number;
67
- gameTitle(): string;
68
- inGame(): boolean;
69
- layoutHeight(): number;
70
- backgroundSize(): {
71
- width: number;
72
- height: number;
73
- left: number;
74
- top: number;
75
- };
76
- dialogWidth(): number;
77
- dialogStyle(): any;
78
- gameWidth(): number;
79
- gameHeight(): number;
80
- appStyle(): any;
81
- gameStyle(): any;
82
- screenRatio(): number;
83
- dialogContainerStyle(): any;
84
- currentLine: () => import("./types/parser").Parser.ParsedExpression<import("./types/parser").Parser.DefaultArg, {}> | undefined;
85
- screenWidth: () => number;
86
- screenHeight: () => number;
87
- canvasWidth: () => number;
88
- canvasHeight: () => number;
89
- topOffset: () => number;
90
- leftOffset: () => number;
91
- layoutMode: () => "horizontal" | "vertical";
92
- }, {
93
- setupMachine(): Promise<void>;
94
- getSaveFile(): string | null;
95
- startGame(): Promise<void>;
96
- loadGame(): Promise<void>;
97
- isDialogActive(i: number): boolean;
98
- nextLine(): void;
99
- updateScreenSize(): void;
100
- closeModal(): void;
101
- getDialogBoxOptions(dialogKey: DialogKey, index: number): DialogBoxParameters;
102
- }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
103
- config: PropType<GameConfig>;
104
- options: PropType<AppOptions>;
105
- }>>, {}>;
106
- export default _default;
1
+ import { PropType } from 'vue';
2
+ import { GameConfig } from './types/app-types';
3
+ import { AppOptions } from './config';
4
+ declare const _default: import("vue").DefineComponent<{
5
+ config: PropType<GameConfig>;
6
+ options: PropType<AppOptions>;
7
+ }, {
8
+ dialog: import("vue").ComputedRef<{
9
+ speaker: string;
10
+ text: string;
11
+ pose?: string | undefined;
12
+ choices?: {
13
+ choice: string;
14
+ originalIndex: number;
15
+ allowed: boolean;
16
+ }[] | undefined;
17
+ textField?: boolean | undefined;
18
+ interactive: boolean;
19
+ id: string;
20
+ }[]>;
21
+ stack: import("vue").ComputedRef<{
22
+ currentIndex: number;
23
+ branchData: {
24
+ branch: {
25
+ code: string;
26
+ command: {
27
+ commandType: string;
28
+ operator: string;
29
+ args: (import("./types/parser").Parser.Primitive | {
30
+ code: string;
31
+ command: any;
32
+ fileName: string;
33
+ line: number;
34
+ })[];
35
+ options: import("./types/parser").Parser.DefaultArg;
36
+ staticOptions: {};
37
+ };
38
+ fileName: string;
39
+ line: number;
40
+ }[];
41
+ args?: string[] | undefined;
42
+ };
43
+ label: string;
44
+ scope: {
45
+ [key: string]: any;
46
+ };
47
+ onComplete?: ((result: any) => void) | undefined;
48
+ returnValue: any;
49
+ }[]>;
50
+ modal: import("vue").ComputedRef<string | false>;
51
+ flowState: import("vue").ComputedRef<"menu" | "playing">;
52
+ }, {
53
+ lineTitle: string;
54
+ lineText: string;
55
+ gameLoaded: boolean;
56
+ loadingStep: string;
57
+ loadingPercentage: number;
58
+ hasSave: boolean;
59
+ }, {
60
+ backgroundStyle(): any;
61
+ layoutWidth(): number;
62
+ gameTitle(): string;
63
+ inGame(): boolean;
64
+ layoutHeight(): number;
65
+ backgroundSize(): {
66
+ width: number;
67
+ height: number;
68
+ left: number;
69
+ top: number;
70
+ };
71
+ gameWidth(): number;
72
+ gameHeight(): number;
73
+ appStyle(): any;
74
+ gameStyle(): any;
75
+ screenRatio(): number;
76
+ currentLine: () => import("./types/parser").Parser.ParsedExpression<import("./types/parser").Parser.DefaultArg, {}> | undefined;
77
+ screenWidth: () => number;
78
+ screenHeight: () => number;
79
+ canvasWidth: () => number;
80
+ canvasHeight: () => number;
81
+ topOffset: () => number;
82
+ leftOffset: () => number;
83
+ layoutMode: () => "horizontal" | "vertical";
84
+ }, {
85
+ setupMachine(): Promise<void>;
86
+ getSaveFile(): string | null;
87
+ startGame(): Promise<void>;
88
+ loadGame(): Promise<void>;
89
+ nextLine(): void;
90
+ updateScreenSize(): void;
91
+ closeModal(): void;
92
+ }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
93
+ config: PropType<GameConfig>;
94
+ options: PropType<AppOptions>;
95
+ }>>, {}>;
96
+ export default _default;
package/dist/audio.7z ADDED
Binary file
@@ -1,12 +1,12 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {
2
- playTime: () => {
3
- start: number;
4
- previousPlaytime: number;
5
- };
6
- }, {
7
- quit(): void;
8
- mainMenu(): void;
9
- closeMenu(): void;
10
- getPlayTimeString(): string;
11
- }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
12
- export default _default;
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {
2
+ playTime: () => {
3
+ start: number;
4
+ previousPlaytime: number;
5
+ };
6
+ }, {
7
+ quit(): void;
8
+ mainMenu(): void;
9
+ closeMenu(): void;
10
+ getPlayTimeString(): string;
11
+ }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
12
+ export default _default;
@@ -1,22 +1,22 @@
1
- import { SkillData } from '../config';
2
- import { SkillsState } from '../stores/skills';
3
- declare const _default: import("vue").DefineComponent<{}, {
4
- skills: import("vue").ComputedRef<SkillsState>;
5
- }, {
6
- chosenSkill: boolean | String;
7
- }, {
8
- skillsToDisplay(): SkillsState;
9
- skillConf(): {
10
- [key: string]: SkillData;
11
- };
12
- xpPerLevel(): number;
13
- }, {
14
- getSkillStyle(skill: string): any;
15
- getSkillName(skill: string): string;
16
- clickSkill(skill: string): void;
17
- closeSkill(): void;
18
- xpBarWidth(xp: number): {
19
- width: string;
20
- };
21
- }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
22
- export default _default;
1
+ import { SkillData } from '../config';
2
+ import { SkillsState } from '../stores/skills';
3
+ declare const _default: import("vue").DefineComponent<{}, {
4
+ skills: import("vue").ComputedRef<SkillsState>;
5
+ }, {
6
+ chosenSkill: boolean | String;
7
+ }, {
8
+ skillsToDisplay(): SkillsState;
9
+ skillConf(): {
10
+ [key: string]: SkillData;
11
+ };
12
+ xpPerLevel(): number;
13
+ }, {
14
+ getSkillStyle(skill: string): any;
15
+ getSkillName(skill: string): string;
16
+ clickSkill(skill: string): void;
17
+ closeSkill(): void;
18
+ xpBarWidth(xp: number): {
19
+ width: string;
20
+ };
21
+ }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
22
+ export default _default;
@@ -1,48 +1,48 @@
1
- import { Parser } from '../../types/parser';
2
- declare const _default: import("vue").DefineComponent<{}, {
3
- skills: import("vue").ComputedRef<import("../../stores/skills").SkillsState>;
4
- skillChecks: import("vue").ComputedRef<{
5
- [key: string]: import("../../stores/skills").SkillCheckState;
6
- }>;
7
- }, {
8
- showDebug: boolean;
9
- jumping: boolean;
10
- searchString: string;
11
- matches: string[];
12
- matchCursor: number;
13
- }, {
14
- labels(): string[];
15
- variables(): {
16
- [key: string]: any;
17
- };
18
- playing: () => boolean;
19
- errors: () => {
20
- text: string;
21
- }[];
22
- playTime: () => {
23
- start: number;
24
- previousPlaytime: number;
25
- };
26
- flowState: () => "menu" | "playing";
27
- data: () => import("../../stores/vm-store").DataState;
28
- script: () => Parser.ParsedScript;
29
- }, {
30
- finishJumping(): void;
31
- labelSelected(event: any): void;
32
- close(): void;
33
- closeErrors(): void;
34
- open(): void;
35
- toggle(): void;
36
- jump(): void;
37
- getMatchResultStyle(index: number): {
38
- background: string;
39
- } | undefined;
40
- onSearchInput(): void;
41
- save(): void;
42
- wordCount(): void;
43
- countWordsInScriptLine(scriptLine: Parser.ParsedExpression): number;
44
- countWordsInString(string: string): number;
45
- countWordsInScriptBranch(branch: Parser.Branch): number;
46
- getPlayTimeString(): string;
47
- }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
48
- export default _default;
1
+ import { Parser } from '../../types/parser';
2
+ declare const _default: import("vue").DefineComponent<{}, {
3
+ skills: import("vue").ComputedRef<import("../../stores/skills").SkillsState>;
4
+ skillChecks: import("vue").ComputedRef<{
5
+ [key: string]: import("../../stores/skills").SkillCheckState;
6
+ }>;
7
+ }, {
8
+ showDebug: boolean;
9
+ jumping: boolean;
10
+ searchString: string;
11
+ matches: string[];
12
+ matchCursor: number;
13
+ }, {
14
+ labels(): string[];
15
+ variables(): {
16
+ [key: string]: any;
17
+ };
18
+ playing: () => boolean;
19
+ errors: () => {
20
+ text: string;
21
+ }[];
22
+ playTime: () => {
23
+ start: number;
24
+ previousPlaytime: number;
25
+ };
26
+ flowState: () => "menu" | "playing";
27
+ data: () => import("../../stores/vm-store").DataState;
28
+ script: () => Parser.ParsedScript;
29
+ }, {
30
+ finishJumping(): void;
31
+ labelSelected(event: any): void;
32
+ close(): void;
33
+ closeErrors(): void;
34
+ open(): void;
35
+ toggle(): void;
36
+ jump(): void;
37
+ getMatchResultStyle(index: number): {
38
+ background: string;
39
+ } | undefined;
40
+ onSearchInput(): void;
41
+ save(): void;
42
+ wordCount(): void;
43
+ countWordsInScriptLine(scriptLine: Parser.ParsedExpression): number;
44
+ countWordsInString(string: string): number;
45
+ countWordsInScriptBranch(branch: Parser.Branch): number;
46
+ getPlayTimeString(): string;
47
+ }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
48
+ export default _default;
@@ -1,9 +1,9 @@
1
- declare const _default: import("vue").DefineComponent<{
2
- pictureUrl: StringConstructor;
3
- }, unknown, unknown, {
4
- boxStyle(): any;
5
- layoutMode: () => "horizontal" | "vertical";
6
- }, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
7
- pictureUrl: StringConstructor;
8
- }>>, {}>;
9
- export default _default;
1
+ declare const _default: import("vue").DefineComponent<{
2
+ pictureUrl: StringConstructor;
3
+ }, unknown, unknown, {
4
+ boxStyle(): any;
5
+ layoutMode: () => "horizontal" | "vertical";
6
+ }, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
7
+ pictureUrl: StringConstructor;
8
+ }>>, {}>;
9
+ export default _default;