-
Notifications
You must be signed in to change notification settings - Fork 6
/
TODO.txt
79 lines (46 loc) · 1.77 KB
/
TODO.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
# Notes for future
[!] As a principle, operations that act on values on the top of the stack should *consume* those values. That is, they should not be able to see a value they have not popped, as this leads to weird, non-intuitive bugs.
Exceptions here are ones that copy parts of memory.
- Tests
- machine
- assembler
- compiler
- Comment primary parts of project - parser, machine etc
- Memory bank support
- C-like language that can be used to write code for the VirtualMachineConsole
- Implement support for dealing with signed values (duplicate instructions that deal with unsigned)
##### Plan for graphics
- Execute game code until it's time to draw a frame
- Pause game code, saving the ip
- Begin drawing background and then sprites, based on the objects in a particular region of memory
- Begin drawing background and then foreground
- Both are combinations of tiles
- The screen should be made up of 256x256 pixels, which is 32x32 tiles (8x8 pixels each)
- A fixed, linear region of memory that strides of 32 bits (pointer to tile, pointer to palette entry)
- One for background :: 2048 bytes
- One for foreground :: 2048 bytes
- Continuous video memory is 4096 bytes (4kb)
Total memory: 64kb
Video memory: 4kb
Input memory: ~5b
0xffffff00
- Objects are structures that describe
- The palette of the sprite
- It's position
A +-----------------+ 0x0000
| |
| Data |
| |
B +-----------------+ 0x5555
| |
| Program Code |
| |
C +-----------------+ 0xAAAA
| |
| Stack |
| |
D +-----------------+ 0xFFFF
A - Always 0x0000
B - Dependent on amount of statically assigned Data
C - Soft/hard cutoff point
D - Always 0xFFFF