Skip to content

Commit f608e21

Browse files
committed
changed asm symbol prefixes for Prog8 v10.0
1 parent 18035c7 commit f608e21

File tree

4 files changed

+64
-64
lines changed

4 files changed

+64
-64
lines changed

c64/keyboard.p8

+5-5
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ no_shift ; otherwise clear keypress
3737
lda #$0
3838

3939
check_k
40-
sta p8_keypress
40+
sta p8v_keypress
4141

4242
; Check for K
4343
lda #%11101111 ; Row 4 (PA4)
@@ -46,9 +46,9 @@ check_k
4646
and #%00100000 ; Col 5 (PB5)
4747

4848
bne check_l
49-
lda p8_keypress
49+
lda p8v_keypress
5050
ora #$02
51-
sta p8_keypress
51+
sta p8v_keypress
5252

5353
rts ; Return, we don't check for L
5454

@@ -60,9 +60,9 @@ check_l
6060
and #%00000100 ; Col 2 (PB2)
6161

6262
bne return
63-
lda p8_keypress
63+
lda p8v_keypress
6464
ora #$04
65-
sta p8_keypress
65+
sta p8v_keypress
6666

6767
return
6868
rts

convert.p8

+3-3
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ convert {
1919
lsr a
2020
lsr a
2121
tay
22-
lda p8_convert.p8_table,y
22+
lda p8b_convert.p8v_table,y
2323
}}
2424
}
2525

@@ -30,7 +30,7 @@ convert {
3030
%asm {{
3131
and #$0F
3232
tay
33-
lda p8_convert.p8_table,y
33+
lda p8b_convert.p8v_table,y
3434
}}
3535
}
3636

@@ -46,7 +46,7 @@ convert {
4646
asmsub to_nibble(ubyte cnv @A) -> ubyte @A {
4747
%asm {{
4848
ldy #6
49-
- cmp p8_table,y
49+
- cmp p8v_table,y
5050
beq +
5151
dey
5252
bpl -

cx16/joystick.p8

+4-4
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,16 @@ joystick {
2424
; Get joystick info from kernal to variables
2525
asmsub pull_info() clobbers(A, X, Y) {
2626
%asm {{
27-
lda p8_selected_joystick
27+
lda p8v_selected_joystick
2828
and #7
2929
jsr cx16.joystick_get
3030
eor #$ff ; reverse bit pattern for easier testing
3131
cmp #$ff ; Hack around NES keybord emulator issue
3232
beq skip_store ; if all bits set assume skip setting joy_info
33-
sta p8_joy_info
33+
sta p8v_joy_info
3434
skip_store:
35-
stx p8_joy_info2
36-
sty p8_joy_info3
35+
stx p8v_joy_info2
36+
sty p8v_joy_info3
3737
rts
3838
}}
3939
}

enemy.p8

+52-52
Original file line numberDiff line numberDiff line change
@@ -289,23 +289,23 @@ enemy {
289289
; enemyRef[EN_SUBPOS] |= main.LEFTMOST
290290
; }
291291
%asm {{
292-
lda #p8_main.p8_LEFTMOST ; check LEFTMOST (=1) is set
293-
ldy #p8_enemy.p8_EN_SUBPOS
294-
and (p8_enemyRef),y ; AND with EN_SUBPOS
292+
lda #p8b_main.p8c_LEFTMOST ; check LEFTMOST (=1) is set
293+
ldy #p8b_enemy.p8c_EN_SUBPOS
294+
and (p8v_enemyRef),y ; AND with EN_SUBPOS
295295
beq _move_left_else ; and branch
296-
lda (p8_enemyRef),y ; Get EN_SUBPOS
297-
and #p8_main.p8_NOT_LEFTMOST ; AND with ~main.LEFTMOST
298-
sta (p8_enemyRef),y
296+
lda (p8v_enemyRef),y ; Get EN_SUBPOS
297+
and #p8b_main.p8c_NOT_LEFTMOST ; AND with ~main.LEFTMOST
298+
sta (p8v_enemyRef),y
299299
sec
300-
ldy #p8_enemy.p8_EN_X
301-
lda (p8_enemyRef),y
300+
ldy #p8b_enemy.p8c_EN_X
301+
lda (p8v_enemyRef),y
302302
sbc #1
303-
sta (p8_enemyRef),y
303+
sta (p8v_enemyRef),y
304304
rts
305305
_move_left_else
306-
lda (p8_enemyRef),y ; Get EN_SUBPOS
307-
ora #p8_main.p8_LEFTMOST ; OR with main.LEFTMOST
308-
sta (p8_enemyRef),y
306+
lda (p8v_enemyRef),y ; Get EN_SUBPOS
307+
ora #p8b_main.p8c_LEFTMOST ; OR with main.LEFTMOST
308+
sta (p8v_enemyRef),y
309309
rts
310310
}}
311311
}
@@ -318,23 +318,23 @@ _move_left_else
318318
; enemyRef[EN_X]++
319319
; }
320320
%asm {{
321-
lda #p8_main.p8_LEFTMOST ; check LEFTMOST (=1) is set
322-
ldy #p8_enemy.p8_EN_SUBPOS
323-
and (p8_enemyRef),y ; AND with EN_SUBPOS
321+
lda #p8b_main.p8c_LEFTMOST ; check LEFTMOST (=1) is set
322+
ldy #p8b_enemy.p8c_EN_SUBPOS
323+
and (p8v_enemyRef),y ; AND with EN_SUBPOS
324324
beq _move_right_else; and branch
325-
lda (p8_enemyRef),y ; Get EN_SUBPOS
326-
and #p8_main.p8_NOT_LEFTMOST ; AND with ~main.LEFTMOST
327-
sta (p8_enemyRef),y
325+
lda (p8v_enemyRef),y ; Get EN_SUBPOS
326+
and #p8b_main.p8c_NOT_LEFTMOST ; AND with ~main.LEFTMOST
327+
sta (p8v_enemyRef),y
328328
rts
329329
_move_right_else
330-
lda (p8_enemyRef),y ; Get EN_SUBPOS
331-
ora #p8_main.p8_LEFTMOST ; OR with main.LEFTMOST
332-
sta (p8_enemyRef),y
330+
lda (p8v_enemyRef),y ; Get EN_SUBPOS
331+
ora #p8b_main.p8c_LEFTMOST ; OR with main.LEFTMOST
332+
sta (p8v_enemyRef),y
333333
clc
334-
ldy #p8_enemy.p8_EN_X
335-
lda (p8_enemyRef),y
334+
ldy #p8b_enemy.p8c_EN_X
335+
lda (p8v_enemyRef),y
336336
adc #1
337-
sta (p8_enemyRef),y
337+
sta (p8v_enemyRef),y
338338
rts
339339
}}
340340
}
@@ -347,23 +347,23 @@ _move_right_else
347347
; enemyRef[EN_SUBPOS] |= main.TOPMOST
348348
; }
349349
%asm {{
350-
lda #p8_main.p8_TOPMOST ; check TOPMOST (=2) is set
351-
ldy #p8_enemy.p8_EN_SUBPOS
352-
and (p8_enemyRef),y ; AND with EN_SUBPOS
350+
lda #p8b_main.p8c_TOPMOST ; check TOPMOST (=2) is set
351+
ldy #p8b_enemy.p8c_EN_SUBPOS
352+
and (p8v_enemyRef),y ; AND with EN_SUBPOS
353353
beq _move_up_else ; and branch
354-
lda (p8_enemyRef),y ; Get EN_SUBPOS
355-
and #p8_main.p8_NOT_TOPMOST ; AND with ~main.TOPMOST
356-
sta (p8_enemyRef),y
354+
lda (p8v_enemyRef),y ; Get EN_SUBPOS
355+
and #p8b_main.p8c_NOT_TOPMOST ; AND with ~main.TOPMOST
356+
sta (p8v_enemyRef),y
357357
sec
358-
ldy #p8_enemy.p8_EN_Y
359-
lda (p8_enemyRef),y
358+
ldy #p8b_enemy.p8c_EN_Y
359+
lda (p8v_enemyRef),y
360360
sbc #1
361-
sta (p8_enemyRef),y
361+
sta (p8v_enemyRef),y
362362
rts
363363
_move_up_else
364-
lda (p8_enemyRef),y ; Get EN_SUBPOS
365-
ora #p8_main.p8_TOPMOST ; OR with main.TOPMOST
366-
sta (p8_enemyRef),y
364+
lda (p8v_enemyRef),y ; Get EN_SUBPOS
365+
ora #p8b_main.p8c_TOPMOST ; OR with main.TOPMOST
366+
sta (p8v_enemyRef),y
367367
rts
368368
}}
369369
}
@@ -376,23 +376,23 @@ _move_up_else
376376
; enemyRef[EN_Y]++
377377
; }
378378
%asm {{
379-
lda #p8_main.p8_TOPMOST ; check TOPMOST (=2) is set
380-
ldy #p8_enemy.p8_EN_SUBPOS
381-
and (p8_enemyRef),y ; AND with EN_SUBPOS
379+
lda #p8b_main.p8c_TOPMOST ; check TOPMOST (=2) is set
380+
ldy #p8b_enemy.p8c_EN_SUBPOS
381+
and (p8v_enemyRef),y ; AND with EN_SUBPOS
382382
beq _move_down_else ; and branch
383-
lda (p8_enemyRef),y ; Get EN_SUBPOS
384-
and #p8_main.p8_NOT_TOPMOST ; AND with ~main.TOPMOST
385-
sta (p8_enemyRef),y
383+
lda (p8v_enemyRef),y ; Get EN_SUBPOS
384+
and #p8b_main.p8c_NOT_TOPMOST ; AND with ~main.TOPMOST
385+
sta (p8v_enemyRef),y
386386
rts
387387
_move_down_else
388-
lda (p8_enemyRef),y ; Get EN_SUBPOS
389-
ora #p8_main.p8_TOPMOST ; OR with main.TOPMOST
390-
sta (p8_enemyRef),y
388+
lda (p8v_enemyRef),y ; Get EN_SUBPOS
389+
ora #p8b_main.p8c_TOPMOST ; OR with main.TOPMOST
390+
sta (p8v_enemyRef),y
391391
clc
392-
ldy #p8_enemy.p8_EN_Y
393-
lda (p8_enemyRef),y
392+
ldy #p8b_enemy.p8c_EN_Y
393+
lda (p8v_enemyRef),y
394394
adc #1
395-
sta (p8_enemyRef),y
395+
sta (p8v_enemyRef),y
396396
rts
397397
}}
398398
}
@@ -406,11 +406,11 @@ _move_down_else
406406
; txt.setcc(tmp_x+1, tmp_y+1, main.CLR, 1)
407407
; txt.setcc(tmp_x, tmp_y+1, main.CLR, 1)
408408
%asm {{
409-
ldy #p8_enemy.p8_EN_X
410-
lda (p8_enemyRef),y
409+
ldy #p8b_enemy.p8c_EN_X
410+
lda (p8v_enemyRef),y
411411
sta txt.setcc.col
412-
ldy #p8_enemy.p8_EN_Y
413-
lda (p8_enemyRef),y
412+
ldy #p8b_enemy.p8c_EN_Y
413+
lda (p8v_enemyRef),y
414414
sta txt.setcc.row
415415
lda #$20
416416
sta txt.setcc.character

0 commit comments

Comments
 (0)