junglejourney
changeset 219:02610f059ac0
Ensured that writable sound data is stored in RAM.
| author | David Boddie <david@boddie.org.uk> |
|---|---|
| date | Tue Oct 18 00:04:04 2011 +0200 |
| parents | 958f6c30e575 |
| children | f25989daa9f9 |
| files | build.py loader.oph mapcode.oph |
| diffstat | 3 files changed, 17 insertions(+), 6 deletions(-) [+] |
line diff
1.1 --- a/build.py Mon Oct 17 23:05:31 2011 +0200 1.2 +++ b/build.py Tue Oct 18 00:04:04 2011 +0200 1.3 @@ -179,7 +179,7 @@ 1.4 # 1 * 0x60 (tree) 1.5 # 1 * 0x60 (tree)) 1.6 # 1.7 - # 5760 space 1.8 + # 5760 note data (8 bytes) 1.9 # 1.10 # 577E joystick support (0=off; 1=on) 1.11 # 577F weapon counter (0=fire one subtile below; 1=fire two subtiles below)
2.1 --- a/loader.oph Mon Oct 17 23:05:31 2011 +0200 2.2 +++ b/loader.oph Tue Oct 18 00:04:04 2011 +0200 2.3 @@ -117,8 +117,8 @@ 2.4 code_block: .byte <code_file_name, >code_file_name 2.5 .byte $00, $1e, 0, 0 2.6 .byte $00, $1e, 0, 0 2.7 - .byte $35, $20, 0, 0 2.8 - .byte $35, $3e, 0, 0 2.9 + .byte $40, $20, 0, 0 2.10 + .byte $40, $3e, 0, 0 2.11 2.12 init_load_window_vdu_bytes: .byte 28,0,30,19,27 2.13
3.1 --- a/mapcode.oph Mon Oct 17 23:05:31 2011 +0200 3.2 +++ b/mapcode.oph Tue Oct 18 00:04:04 2011 +0200 3.3 @@ -4254,11 +4254,12 @@ 3.4 damage_sound: .byte 1,0, 2,0, 40,0, 4,0 3.5 item_sound: .byte $13,0, 3,0, 32,0, 3,0 3.6 key_sound: .byte $13,0, 4,0, 50,0, 5,0 3.7 -note_sound: .byte $13,0, 241,255 3.8 -note_pitch: .byte 0,0 3.9 -note_duration: .byte 4,0 3.10 emerge_sound: .byte 2,0, 3,0, 0,0, 2,0 3.11 3.12 +.alias note_sound $5760 3.13 +.alias note_pitch $5764 3.14 +.alias note_duration $5766 3.15 + 3.16 play_note: ; A=pitch, Y=duration 3.17 3.18 sta note_pitch 3.19 @@ -4340,6 +4341,14 @@ 3.20 jmp copy_title ; optimise away the rts 3.21 3.22 init: 3.23 + ; Set up note data. 3.24 + ldx #7 3.25 + set_up_note_loop: 3.26 + lda note_data,x 3.27 + sta $5760,x 3.28 + dex 3.29 + bpl set_up_note_loop 3.30 + 3.31 jsr cls ; clear the text window 3.32 3.33 lda #26 ; unset the text window 3.34 @@ -4398,6 +4407,8 @@ 3.35 3.36 rts 3.37 3.38 +note_data: .byte $13,0, 241,255, 0,0, 4,0 3.39 + 3.40 high_score_default_name1: .byte "RETRO " 3.41 high_score_default_name2: .byte " SOFTWARE" 3.42
