This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
haas:spring2022:comporg:projects:ticx [2022/01/30 20:23] – [Task] wedge | haas:spring2022:comporg:projects:ticx [2022/04/17 14:11] (current) – [topic: a bigger TIC-80 game experience] wedge | ||
---|---|---|---|
Line 25: | Line 25: | ||
| 3 | tic3 | create a pong game | 2 | 26 | | | 3 | tic3 | create a pong game | 2 | 26 | | ||
| 4 | tic4 | extend to breakout game | 2 | 26 | | | 4 | tic4 | extend to breakout game | 2 | 26 | | ||
- | | 5 | tic5 | | + | | 5 | tic5 | |
- | | 6 | tic6 | | 3 | 39 | | + | | 6 | tic6 | |
- | | 7 | tic7 | | 4 | 52 | | + | | 7 | tic7 | |
- | | 8 | tic8 | | 4 | 52 | | + | | 8 | tic8 | |
- | | 9 | tic9 | | 5 | 65 | | + | | 9 | tic9 | |
- | | 10 | ticA | | 5 | 65 | | + | | 10 | ticA | |
- | | 11 | ticB | | 6 | 78 | | + | | 11 | ticB | |
- | | 12 | ticC | | 6 | 78 | | + | | 12 | ticC | |
+ | ====topic: palette and persistence==== | ||
+ | Through playing with memory via the **peek** and **poke** functions and referencing the TIC-80 memory map, we can effect run-time and automatic changes to facilities in TIC-80 without needing to manual set something in the development environment. | ||
+ | |||
+ | Two items of focus here: | ||
+ | |||
+ | * persistent memory: 1kiB of read/write cartridge-based memory that can be used for things like saving game progress, scores, or in our current case: color settings. | ||
+ | * palette memory: those 16 colors available to us? Totally stored in memory. What's more, we can change each palette color to be one of 16.7 million available colors. Even better, letting TIC80 do it from within a program. | ||
+ | |||
+ | I want you to make a color setting program in TIC80, one that lets the user set the color of one palette color (you can pick which one, aside from #0, that you'd like to target). | ||
+ | |||
+ | On the TIC80 screen should be the following information: | ||
+ | |||
+ | * current component selected (red, green, or blue) | ||
+ | * current red level (0-255) | ||
+ | * current green level (0-255) | ||
+ | * current blue level (0-255) | ||
+ | * "press ' | ||
+ | * a tile filled entirely with the palette color that is being changed, also displayed, allowing for a real-time view of the current color being mixed (might want to scale it 4x for even better visability- but don't overlap with the other on-screen text). | ||
+ | |||
+ | Controls: | ||
+ | |||
+ | * up to you, but should somehow be explanatory (comments, on-screen directions). You can use arrow keys, mouse, etc. | ||
+ | * each color component is individually adjusted, and can fall within a range of 0-255 (don't let things go outside this range). | ||
+ | * ' | ||
+ | |||
+ | On program startup: read the red/ | ||
+ | |||
+ | |||
+ | ====topic: full palette==== | ||
+ | A similar program to the first time around, but this time you will present the user with full control of the entire palette (all 16 colors). Individual R/G/B component settings, individual palette colors. Save/load to persistent memory. | ||
+ | |||
+ | Also, I'd like further sophistication to definitely be present, not just some rudimentary up/down to select component, left/right to adjust -/+ by some value. | ||
+ | |||
+ | Implement red, green, blue mouse sliders (some line that you can click and drag, or click on some point: and the point on the line represents the 0-255 value). Sort of like how you'd find in some graphics program. | ||
+ | |||
+ | Exposure to mouse stuff is important to know, so yeah: there we go. | ||
+ | |||
+ | ====topic: timing the palette to get more colors==== | ||
+ | |||
+ | The nature of TIC80 in mimicking classic hardware designs is that of a fixed, and often reduced, color palette. 16 colors definitely fits the bill. | ||
+ | |||
+ | But, similarly, there were opportunities on old machines, just as there are with TIC80, to take advantage of the ability of knowing where we are in the drawing process, to strategically set the palette, allowing for 16 distinct colors... on a given line or lines. So, 16 unique colors on any given line, but line-to-line, | ||
+ | |||
+ | This allows for 16 colors x 136 lines = 2176 total colors displayable on the TIC-80 screen. | ||
+ | |||
+ | We don't need to go THAT far (not to 2176), but I would like you to write a TIC80 program that displays in any given frame, at least 48 colors, in some manner conducive to enhancing the user-experience (ie the additional colors make it better than if there were only 16). | ||
+ | |||
+ | Maybe a mock-up of a game: score and level data banner at the top in one color scheme, main game view in the middle, and player stats banner on the bottom. Each slice adhering to a different color palette. | ||
+ | |||
+ | Or enhance your breakout game to have many many more brick colors... | ||
+ | |||
+ | Might be worth checking: https:// | ||
+ | |||
+ | And, it should be beyond obvious: don't just lift tutorial code you find and pass it off in its entirely (with author comments stripped) as your own. You can refer to examples, but I want the final program you submit to be an effort all your own. | ||
+ | |||
+ | ====topic: a bigger TIC-80 game experience==== | ||
+ | We have spent some time exploring the basics of memory access, peripheral control, and resource manipulation across various aspects of TIC-80. We now move into a larger phase where you bring it all together in some larger, original creation. | ||
+ | |||
+ | You are to implement over the next span of weeks, a more sophisticated game of sufficient detail and utilization of TIC-80 resources that is commensurate with the timeframe involved and experiences gained. | ||
+ | |||
+ | There will be 5 checkpoints that you will submit prototype/ | ||
+ | |||
+ | * week8: initial explorations into your game. Identity in comments or a separate README file what you are looking to do, laying out a timeline for where you hope to be and what you aim to accomplish each week. You don't necessarily have to stick with this timetable or do things in order, but some manner of consistent, overall planning should be taking place. | ||
+ | * week9: snapshot of what you have. Be sure to identify what you have worked on, what works, what doesn' | ||
+ | * week10: snapshot of what you have. As above, identify what you have done, what works and doesn' | ||
+ | * week11: snapshot of what you have. As above, identify what you have done, what works and doesn' | ||
+ | * week12: finished product. | ||
+ | |||
+ | Aspects that need to be present in your finished product: | ||
+ | |||
+ | * utilization of some peripheral for gameplay (joystick, mouse) | ||
+ | * exclusive access of peripheral data via memory peeks and bitwise logic | ||
+ | * use of persistent memory | ||
+ | * code-based alteration of the palette | ||
+ | * game must utilize at least 48 unique colors | ||
+ | * some manner of sound, music (audio) must be present | ||
+ | * generated by code, stored to memory | ||
+ | |||
+ | The game can be based on an existing one (a tetris clone, a doom implementation, | ||
+ | |||
+ | It should go without saying: the code you write should be your own. Don't copy anything. | ||
+ | |||
+ | It should also go without saying: you are to be submitting code. In earlier weeks it doesn' | ||
+ | ====topic: switching this up and coding in assembly on the NES/ | ||
+ | For those that want to dive a little deeper into the inner-workings of how a computer works, you can elect to diverge from the TIC80 path for this next set of projects, and instead learn and implement a simple game in 6502 assembly for the NES. | ||
+ | |||
+ | The game can be something like breakout, asteroids, dig dug, etc. or some original idea, but does not have to be as expansive as the multi-week TIC80 game effort. | ||
+ | |||
+ | NOTE: the game cannot be pong, hopefully for obvious reasons. | ||
+ | |||
+ | To start, check out the Nerdy Nights tutorials: | ||
+ | |||
+ | * https:// | ||
+ | |||
+ | Do note: the aim here is to learn 6502 ASSEMBLY LANGUAGE for the NES, creating ROMs to run in an NES emultor. | ||
+ | |||
+ | There will be 5 checkpoints along the way where you will submit a snapshot of what is being explored/ | ||
+ | |||
+ | * week8: NES prototyping, | ||
+ | * week9: more exploring | ||
+ | * week10: perhaps the first signs of work breaking ground on the game | ||
+ | * week11: some in-progress snapshot of your game | ||
+ | * week12: NES ROM game complete and submitted | ||
+ | |||
+ | It should go without saying: the code you write should be your own. Don't copy anything. | ||
+ | |||
+ | It should also go without saying: you are to be submitting code. In earlier weeks it doesn' | ||
=====Submission===== | =====Submission===== | ||