wobblyhead hg > minor_monsters
comparison doc/roadmap.md @ 8:2c4fed8baed9
art update, persistent sound setting, tower selling as double action
| author | ark |
|---|---|
| date | 2026-10-19 13:37 +0200 |
| parents | 910b26feca76 |
| children | 53f015966118 |
comparison
equal
deleted
inserted
replaced
| 7:4fd2da999ba4 | 8:2c4fed8baed9 |
|---|---|
| 61 checks and previews | 61 checks and previews |
| 62 - map images are written as jpeg, quality 88. the maps have no transparency | 62 - map images are written as jpeg, quality 88. the maps have no transparency |
| 63 - tower strips are split at columns without ink. ink is anything darker | 63 - tower strips are split at columns without ink. ink is anything darker |
| 64 than luminance 225. outline gaps of up to about 4 pixels are closed before | 64 than luminance 225. outline gaps of up to about 4 pixels are closed before |
| 65 the fill. the white paper edge outside the outline fades to transparent | 65 the fill. the white paper edge outside the outline fades to transparent |
| 66 - tools/cut_sheet.py cuts the sprites out of source_sheet_2.jpg into art/. it | 66 - tools/cut_sheet.py cuts the sprites out of art_sources/source_sheet_2.jpg |
| 67 into art/. it | |
| 67 is run by hand, not by the build. one hand-set box per drawing; in each box | 68 is run by hand, not by the build. one hand-set box per drawing; in each box |
| 68 the largest connected outline is the drawing and other ink is dropped. | 69 the largest connected outline is the drawing and other ink is dropped. |
| 69 outline ink is darker than luminance 150. sprites stay at the sheet's | 70 outline ink is darker than luminance 150. sprites stay at the sheet's |
| 70 scale, which is the scale the first cutouts had, so [scale] is unchanged. | 71 scale, which is the scale the first cutouts had, so [scale] is unchanged. |
| 71 coins and maps are not on the inked sheet and stay as they were | 72 coins and maps are not on the inked sheet and stay as they were |
| 73 - game_won.png and game_won_button.png were cut once from | |
| 74 art_sources/game_won.jpg with the cut function of cut_sheet.py; the scan | |
| 75 has no boxes in the script | |
| 76 - tools/cut_digits.py takes every connected stroke on digits.png as one | |
| 77 character. ink is darker than luminance 150, strokes under 30 pixels are | |
| 78 specks. rows are told apart by the stroke centre, and the characters of | |
| 79 each row are listed in the script. the scaled height is 66.5 pixels, the | |
| 80 median of the drawings | |
| 72 - the empty part of the hp bars is a darkened copy made by the build | 81 - the empty part of the hp bars is a darkened copy made by the build |
| 73 (hpm_empty, hpb_empty). the blue bars for slowed monsters have the hue of | 82 (hpm_empty, hpb_empty). the blue bars for slowed monsters have the hue of |
| 74 every pixel set to 220 degrees, which leaves the black outline as it is | 83 every pixel set to 220 degrees, which leaves the black outline as it is |
| 75 (hpm_slow, hpb_slow, each with its _empty copy) | 84 (hpm_slow, hpb_slow, each with its _empty copy) |
| 76 - sprite sizes go into config.js, so the game knows them before the images | 85 - sprite sizes go into config.js, so the game knows them before the images |
| 121 map3. 2 s between groups, 4 s before the boss. totals: 102, 199, 398, 600 | 130 map3. 2 s between groups, 4 s before the boss. totals: 102, 199, 398, 600 |
| 122 coins | 131 coins |
| 123 | 132 |
| 124 game: | 133 game: |
| 125 | 134 |
| 126 - scripts share the namespace object MM. storage.js is not written until | 135 - scripts share the namespace object MM. storage.js keeps the settings in |
| 127 there are settings to store (architecture.md, persistence) | 136 the localStorage entry minor_monsters, as version 1 |
| 128 - the simulation runs on wall clock time: at 60 frames per second, 2x gives | 137 - the simulation runs on wall clock time: at 60 frames per second, 2x gives |
| 129 two steps per frame. at most 4 steps per frame and speed step; a longer | 138 two steps per frame. at most 4 steps per frame and speed step; a longer |
| 130 frame drops the rest | 139 frame drops the rest |
| 131 - game flow: the first map is debug.start_map, and only the first map | 140 - game flow: the first map is debug.start_map, and only the first map |
| 132 starts at debug.start_wave; the next maps start at wave 1. | 141 starts at debug.start_wave; the next maps start at wave 1. |
| 133 debug.start_coins applies to every map. the splash screen pauses the | 142 debug.start_coins applies to every map. the splash screen pauses the |
| 134 first map without counting the pause for the sell refund, and only its | 143 first map without counting the pause for the sell refund, and only its |
| 135 play button responds. the next map starts with its break running, as | 144 play button responds. the next map starts with its break running, as |
| 136 does the first map after a lost map. the screens use placeholders: a | 145 does the first map after a lost map. the splash screen has a pale veil |
| 137 pale veil with the title and byline in the system font, a play | 146 over the map, the other screens a dark one |
| 138 triangle, one star for a won map and three for the game, a broken heart | 147 - screens: the scale is the same for all four drawings, set so the widest |
| 139 for a lost map, an arrow for next and a circular arrow for restart | 148 and the tallest fit 92 % of the window width and 90 % of its height, at |
| 149 most 1. the separate button image is drawn over the button in the | |
| 150 drawing; [art.screen] in game.toml holds where, measured by matching the | |
| 151 images. its tap area is the button image. it pulses by 4 % over 1.2 s; | |
| 152 under the mouse it is 8 % larger with a shadow | |
| 140 - a break starts when all monsters of the wave are gone, killed or escaped, | 153 - a break starts when all monsters of the wave are gone, killed or escaped, |
| 141 not when the last one has spawned. during a break the wave counter shows | 154 not when the last one has spawned. during a break the wave counter shows |
| 142 the next wave | 155 the next wave |
| 143 - monsters move at constant speed; the hop is drawn only. a hop spends 80 % | 156 - monsters move at constant speed; the hop is drawn only. a hop spends 80 % |
| 144 of its time in the air and 20 % landing. the idle bob is a slow breathing | 157 of its time in the air and 20 % landing. the idle bob is a slow breathing |
| 158 range. with no sample in that range, only the side towards the nearest | 171 range. with no sample in that range, only the side towards the nearest |
| 159 one gets a spike. the preview shows the same sides. on map0 about half the | 172 one gets a spike. the preview shows the same sides. on map0 about half the |
| 160 placement cells give one side, most of the rest two, a few three | 173 placement cells give one side, most of the rest two, a few three |
| 161 - t2 slow: each running slow keeps its own time, and the strongest one | 174 - t2 slow: each running slow keeps its own time, and the strongest one |
| 162 applies. a slowed monster also hops slower, by the same factor | 175 applies. a slowed monster also hops slower, by the same factor |
| 163 - tower menu: tapping a built tower shows an upgrade and a sell button above | 176 - tower menu: tapping a built tower shows the tower_popup bubble, 168 css |
| 164 it, or below it when there is no room above, kept inside the map. the | 177 pixels wide, above it, or below it when there is no room above, kept |
| 165 upgrade button shows the cost of the next level and is dimmed when it | 178 inside the map. upgrade and sell sit in it side by side, each with its |
| 166 cannot be afforded; at level 5 it is left out. the sell button shows the | 179 price below, and each takes half of the bubble as tap area. the upgrade |
| 167 refund. selling clears the selection; upgrading keeps it | 180 price is the cost of the next level, dimmed when it cannot be afforded; at |
| 181 level 5 upgrade is left out and sell takes the whole bubble. the sell | |
| 182 price is the refund. selling clears the selection; upgrading keeps it | |
| 183 - selling takes two taps. the first arms it: sell_button pulses by 15 % | |
| 184 every 0.5 s with a red glow. the second sells. a tap anywhere else, | |
| 185 another button or the map, cancels it; there is no timeout | |
| 168 - the pause refund counts pauses: each purchase records the pause it was | 186 - the pause refund counts pauses: each purchase records the pause it was |
| 169 made in. a purchase made during the current pause is refunded in full | 187 made in. a purchase made during the current pause is refunded in full |
| 170 - placement: a tap within the footprint radius or 28 css pixels of the | 188 - placement: a tap within the footprint radius or 28 css pixels of the |
| 171 preview builds. the shop choice is cleared after building, and a second tap | 189 preview builds. the shop choice is cleared after building, and a second tap |
| 172 on the chosen shop button cancels it. a tap on a built tower selects it and | 190 on the chosen shop button cancels it. a tap on a built tower selects it and |
| 173 shows its range. a refused tap shows a red cross for 0.5 s. shop buttons | 191 shows its range. a refused tap shows a red cross for 0.5 s. shop buttons |
| 174 the player cannot afford are dimmed and do nothing | 192 the player cannot afford are dimmed and do nothing |
| 175 - flying coins: one sprite per coin, at most 8, started 0.05 s apart, flying | 193 - flying coins: one sprite per coin, at most 8, started 0.05 s apart, flying |
| 176 in game time on an arc. they are dropped when the map ends | 194 in game time on an arc. they are dropped when the map ends |
| 177 - placeholder icons: c0 for coins, m0 for waves, a drawn heart, one triangle | 195 - top bar: coin_icon, heart and monster_icon with their counters. each |
| 178 per game speed step (digits for debug speeds), a skip icon with countdown | 196 counter keeps the width of a usual largest value (3, 2 and 5 |
| 179 and bonus for the early start. the top bar needs about 500 css pixels of | 197 characters), so the next one does not move. pause shows pause_button |
| 180 width; narrower screens are not handled | 198 while the game runs and play_button while it is paused. speed shows the |
| 199 drawing of the current speed; debug speeds show their number. the early | |
| 200 start button shows the countdown on next_wave, without the bonus. the top | |
| 201 bar needs about 670 css pixels of width; narrower screens are not handled | |
| 202 - numbers: the digit variant of each place depends on the digit and its | |
| 203 place counted from the right, so the variants differ along a number but a | |
| 204 number keeps its look. top bar digits are 28 css pixels high, prices 18, | |
| 205 with coin_icon in front, as behind the amount it reads as an extra zero | |
| 206 - shop: items are 84 x 72 css pixels, drawn on shop_bubble. the chosen | |
| 207 item switches between shop_bubble_dark and shop_bubble_dark2 every 0.4 s | |
| 208 - death puffs: at the monster's centre, at sprite scale. they grow from 60 % | |
| 209 to full size over the first half of their time and fade out over the | |
| 210 second half. they are dropped when the map ends | |
| 181 - debug switches: all from architecture.md. start_coins -1 means the map's own value, seed 0 a new seed per | 211 - debug switches: all from architecture.md. start_coins -1 means the map's own value, seed 0 a new seed per |
| 182 run | 212 run |
| 183 - sound: the play button on the splash screen starts the sound; taps | 213 - sound: the play button on the splash screen starts the sound; taps |
| 184 before it leave sound off. later pointer and touch events resume audio | 214 before it leave sound off. later pointer and touch events resume audio |
| 185 if the browser has suspended it. sound is switched off only in the | 215 if the browser has suspended it. switching sound off mutes the output at |
| 186 config. beeps | 216 once and stops new sounds; the button tap is played after switching, so |
| 187 use a square wave. variants are picked with Math.random, not the seeded | 217 it is heard when sound goes on. beeps use a square wave. variants are picked with Math.random, not the seeded |
| 188 generator, so sound does not change a repeated run. a sound that cannot be | 218 generator, so sound does not change a repeated run. a sound that cannot be |
| 189 played at once (audio still locked) is dropped, not queued | 219 played at once (audio still locked) is dropped, not queued |
| 190 - towers at scale 0.25 are small: t1 level 1 is about 43 x 30 map pixels. | 220 - towers at scale 0.25 are small: t1 level 1 is about 43 x 30 map pixels. |
| 191 worth a look with the hop and squash check of step 3 | 221 worth a look with the hop and squash check of step 3 |
