Meta tags:
Headings (most frequently used words):
-
Text of the page (most frequently used words):
the (179), byte (178), sta (134), lda (121), and (60), 0b__ (59), wall (47), mus_del_1 (46), cmp (44), this (38), for (37), player (37), mus_rest (35), game (31), value (27), jsr (26), done (26), rts (26), beq (25), mode (22), 111 (22), move (21), jmp (21), off (20), inx (20), bne (19), yes (19), function (19), musica (19), musicb (19), 0b__111 (19), score_pf1 (18), select (18), new (18), music (18), inc (15), screen (15), get (15), row (15), position (15), score_pf2 (14), mus_del_2 (14), ldx (13), wsync (13), top (13), left (13), digits (13), all (12), return (12), playfield (12), digit (12), store (12), ror (12), volume (12), tmp0 (11), 128 (11), scanline (11), pf1 (11), pf2 (11), picture (11), reset (11), musaind (10), musbind (10), start (10), processing (10), play (10), next (10), score (10), time (10), bottom (10), right (10), 255 (10), 0b__1 (10), playr1y (9), turn (9), end (9), beam (9), over (9), count (9), repeat (9), gap (9), change (9), with (9), delay (9), frequency (9), wallstart (8), set (8), back (8), tay (8), stx (8), frame (8), index (8), graphics (8), keep (8), ldy (8), half (8), pattern (8), 112 (8), moving (8), note (8), tmp1 (7), tmp2 (7), scancnt (7), line (7), are (7), not (7), walls (7), need (7), players (7), process (7), bump (7), sound (7), table (7), skill_values (7), ma_song_1 (7), mb_song_1 (7), wallcnt (6), initialize (6), out (6), hold (6), scanlines (6), frames (6), area (6), pf0 (6), bcc (6), bits (6), again (6), past (6), only (6), now (6), blank (6), called (6), check (6), ora (6), pro (6), sbc (6), sec (6), asl (6), copy (6), near (6), control (6), ma_song_2 (6), mb_song_2 (6), hardware (5), walldely (5), debounce (5), musadel (5), musbdel (5), main (5), current (5), one (5), visible (5), collision (5), rows (5), lower (5), skip (5), point (5), that (5), once (5), settings (5), moves (5), expertise (5), restart (5), initializes (5), per (5), did (5), audv0 (5), audv1 (5), leave (5), every (5), when (5), increment (5), rol (5), 0xf0 (5), channel (5), command (5), jump (5), pointer (5), tone (5), muscmd_jump (5), muscmd_control (5), muscmd_volume (5), mus_del_4 (5), playr0y (4), mus_tmp0 (4), mus_tmp1 (4), walldrela (4), walldrelb (4), walldrelc (4), gapbits (4), musavol (4), musbvol (4), init_selmode (4), bit (4), wait (4), here (4), playing (4), part (4), between (4), drawframe (4), tax (4), sty (4), take (4), through (4), field (4), clc (4), adc (4), each (4), force (4), first (4), hmp0 (4), changed (4), let (4), swcha (4), joystick (4), switches (4), selexp (4), coordinate (4), dec (4), gapok (4), 100 (4), 0x0f (4), changes (4), novice (4), muschana (4), txa (4), 0x1f (4), silence (4), muschanb (4), word (4), musics (4), duration (4), mus_del_3 (4), wall_inc (3), walldelyr (3), entropya (3), entropyc (3), wallhei (3), clear (3), flag (3), electron (3), vsync (3), signal (3), while (3), counting (3), random (3), buildrow (3), lookup (3), lsr (3), upper (3), nowall (3), another (3), kill (3), desired (3), make_score (3), adjust_dif (3), parameters (3), new_gaps (3), motion (3), sel_reset_chk (3), toggle (3), move_walls (3), based (3), hit (3), setmovep0 (3), 240 (3), setmovep1 (3), but (3), selstartgame (3), gop1hit (3), effects (3), effect (3), alone (3), count10s (3), find (3), swchb (3), difficulty (3), values (3), audc0 (3), audf0 (3), tick (3), fxrun (3), 336 (3), 224 (3), song (3), 896 (3), 6502 (2), ram (2), entropyb (2), init (2), video_kernel (2), vblank (2), vertical (2), sync (2), three (2), timer (2), 2752 (2), lengthy (2), logic (2), number (2), dogameovermode (2), doplaymode (2), selmode (2), continue (2), playmode (2), gomode (2), zero (2), from (2), drawvisiblerows (2), ready (2), grp0 (2), grp1 (2), already (2), must (2), 109 (2), showscore (2), gr_player (2), group (2), object (2), showp0 (2), showp1 (2), calculate (2), oline (2), into (2), want (2), caller (2), second (2), side (2), various (2), other (2), timep0pos (2), cpx (2), mark (2), timep1pos (2), high (2), initial (2), hmp1 (2), init_playmode (2), background (2), colubk (2), greenish (2), init_music (2), has (2), noselect (2), process_music (2), any (2), nofirst (2), cxp0fb (2), cxp1fb (2), nohit (2), init_gomode (2), movep0left (2), movep0right (2), don (2), movement (2), movep1left (2), movep1right (2), collide (2), toggled (2), 2nd (2), selp1on (2), both (2), gocheckp1 (2), show (2), win (2), init_go_fx (2), process_go_fx (2), gokeepgoing (2), them (2), run (2), walldone (2), wallok (2), builds (2), far (2), less (2), gapdone (2), two (2), count100s (2), 100s (2), 10s (2), countdone (2), nibble (2), image (2), code (2), space (2), single (2), amateur (2), expp0ama (2), expp1 (2), expnop1 (2), expp1ama (2), expdone (2), can (2), describes (2), adjnextrow (2), adjchecktable (2), adjbump (2), last (2), seldebounce (2), nothing (2), active (2), temporaries (2), audc1 (2), reload (2), commands (2), notes (2), musdob (2), muscmdjumpa (2), handle (2), muscmdctrla (2), muscmdtonea (2), musnotea (2), musdodone (2), muscmdjumpb (2), muscmdctrlb (2), muscmdtoneb (2), musnoteb (2), hitting (2), gives (2), ma1_01 (2), ma1_end (2), ma2_01 (2), ma2_end (2), mb1_01 (2), mb1_end (2), mb2_01 (2), mb2_end (2), makes (2), _cpu, atari2600, definitions, include, stella, asm, usage, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 157, 163, 164, 165, 166, 167, 168, 0xf000, sei, interrupts, cld, decimal, 0xff, stack, txs, environment, electrons, drain, trigger, hmove, tell, objects, release, machine, tim64t, cycles, 228, begins, routines, travels, selecting, video, what, doing, ends, intim, 37th, returns, expected, come, cxclr, detection, very, pp2, scan, 218, lines, where, using, enabled, divide, eight, bcs, draw, transfering, patterns, 182, 183, soon, list, loading, make, sure, will, always, onto, some, waiting, pass, power, variables, colupf, redish, 126, colup0, white, colup1, black, reflection, ctrlpf, todo, inits, fresh, dex, resp0, dey, cpy, resp1, positions, base, expert, double, build, 192, see, pressed, restore, old, either, games, 200, bright, doesn, selects, button, stay, adjust, hmclr, stop, even, onscreen, didn, going, sequence, finished, still, running, down, reaches, passes, else, placed, solid, randomish, update, seed, too, than, roll, times, rolls, passed, implementation, got, tens, iny, tya, multiply, put, together, have, plenty, registers, premium, 3nd, 4th, 5th, there, drawn, their, respective, 0x40, 0x80, adjusts, also, they, starting, match, our, try, checks, debounces, transitions, xxxxxxsr, same, before, eor, low, audio, pure, tones, pointers, data, levels, maximum, tables, contain, individual, channels, ended, voice, subtract, flags, accidental, carry, audf1, soundeffect, counter, type, poly, max, soundeffects, divisor, timing, total, getting, multiplied, yield, ticks, songs, least, common, multiple, 2688, full, how, progresses, instance, entry, says, indicates, 8x8, 11111, images, numbers, extra, which, multiplication, easier, leading, 0xf7fa, vectors, vector, program,
Text of the page (random words):
off sta pf1 play field 1 off sta pf2 play field 2 off sta wsync next scanline jmp video_kernel buildrow lda scancnt where are we on the screen cmp 6 if we are in the bcc showscore score area and 7 lower 3 bits as an index again tay using y to lookup graphics lda gr_player y get the graphics if enabled on this row tax hold it for return as player 0 tay hold it for return as player 1 lda scancnt scanline count again lsr a this time lsr a we divide lsr a by eight 8 rows in picture cmp playr0y scanline group of the p0 object beq showp0 yes keep the picture ldx 0 not time for player 0 no graphics showp0 cmp playr1y scanline group of the p1 object beq showp1 yes keep the picture ldy 0 not time for player 0 no graphics showp1 lda wallstart calculate clc the bottom adc wallhei of sta tmp0 the wall lda scancnt scanline count cmp wallstart past upper part of wall bcc nowall no skip it cmp tmp0 past lower part of wall bcs nowall yes skip it the wall is on this row lda walldrela draw wall sta tmp0 by transfering lda walldrelb playfield sta tmp1 patterns lda walldrelc to sta tmp2 return area rts done nowall the wall is not on this row lda 0 no walls on this row sta tmp0 clear sta tmp1 out sta tmp2 the playfield rts done showscore and 7 oline 182 only need the lower 3 bits tay oline 183 soon to be an index into a list at this point the beam is past the loading of the playfield for the left half we want to make sure that the right half of the playfield is off so do that now ldx 0 blank bit pattern stx tmp0 this will always be blank stx pf1 turn off playfield stx pf2 for right half of the screen tax another index lda score_pf1 y lookup the pf1 graphics for this row sta tmp1 return it to the caller tay we ll need this value again in a second lda score_pf2 x lookup the pf2 graphics for this row sta tmp2 return it to the caller sta wsync now on the next row sty pf1 repeat the left side playfield sta pf2 onto the new row lda score_pf2 x kill some time waiting for the lda score_pf2 x beam to pass the left half lda score_pf2 x of the playfield again lda score_pf2 x lda score_pf2 x lda score_pf2 x ldx 0 return 0 off for player 0 ldy 0 and player 1 the beam is past the left half of the field again turn off the playfield stx pf1 0 to pf1 stx pf2 and pf2 rts done init this function is called once at power up reset to initialize various game settings and variables lda 64 wall is sta colupf redish lda 126 p0 is sta colup0 white lda 0 p1 sta colup1 black lda 5 right half of playfield is reflection of left sta ctrlpf and playfield is on top of players todo other hardware inits here ldx 4 player 0 position count ldy 3 player 1 position count sta wsync get a fresh scanline timep0pos dex kill time while the beam moves cpx 0 to desired bne timep0pos position sta resp0 mark player 0 s x position timep1pos dey kill time while the beam moves cpy 0 to desired bne timep1pos position sta resp1 mark player 1 s x position jsr expertise initialize the players y positions base on expert settings lda 10 wall is sta wallhei 10 double scanlines high lda 0 set score to sta wallcnt 0 jsr make_score blank the score digits lda 0 blank bits sta score_pf2 5 on the end of each sta score_pf1 5 digit pattern jsr adjust_dif initialize the wall parameters jsr new_gaps build the wall s initial gap lda 112 set wall position off bottom sta wallstart to force a restart on first move lda 0 zero out sta hmp0 player 0 motion sta hmp1 and player 1 motion rts done init_playmode this function initializes the game play mode lda 192 background is sta colubk greenish lda 1 game mode is sta mode select lda 255 restart wall score to sta wallcnt 0 on first move lda 112 force wall to start sta wallstart over on first move jsr init_music initialize the music rts done playmode this function is called once per frame to process the main game play jsr sel_reset_chk check to see if reset select has changed cmp 0 is select pressed beq noselect no skip stx debounce restore the old value jsr init_selmode and let select mode process the toggle rts done noselect jsr process_music process any playing music jsr move_walls move the walls cmp 1 wall on first row bne nofirst no move on inc wallcnt bump the score jsr adjust_dif change the wall parameters based on score lda wallcnt change the jsr make_score score pattern jsr new_gaps calculate the new gap position nofirst lda cxp0fb player 0 collision with playfield sta tmp0 hold it lda cxp1fb player 1 collision with playfield ora tmp0 did either and 128 player hit cmp 0 wall beq nohit no move on jsr init_gomode go to game over mode rts done nohit lda swcha joystick and 128 player 0 cmp 0 moving left beq movep0left yes move left lda swcha joystick and 64 player 0 cmp 0 moving right beq movep0right yes move right lda 0 not moving value jmp setmovep0 don t move the player movep0right lda 16 1 jmp setmovep0 set hmp0 movep0left lda 240 1 setmovep0 sta hmp0 new movement value p0 lda swcha joystick and 8 player 1 cmp 0 moving left beq movep1left yes move left lda swcha joystick and 4 player 0 cmp 0 moving right beq movep1right yes move right lda 0 not moving value jmp setmovep1 don t move the player movep1right lda 16 1 jmp setmovep1 set hmp0 movep1left lda 240 1 setmovep1 sta hmp1 new movement value p1 rts done init_selmode this function initializes the games select mode lda 0 turn off sta audv0 all sta audv1 sound lda 200 background sta colubk greenish bright lda 2 now in sta mode select game mode rts done selmode this function is called once per frame to process the select mode the wall moves here but doesn t change or collide with players this function selects between 1 and 2 player game jsr move_walls move the walls jsr sel_reset_chk check the reset select switches cmp 1 reset button beq selstartgame yes start game cmp 3 reset and select beq selstartgame yes start game cmp 2 select only bne selexp no stay in this mode lda playr1y select toggled get player 1 y coordinate cmp 255 2nd player on the screen beq selp1on no toggle it on lda 255 yes sta playr1y toggle it off jmp selexp move to expertise selp1on lda 12 y coordinate sta playr1y on screen now jmp selexp move to expertise selstartgame jsr init_playmode reset toggled start game selexp jsr expertise adjust both players for pro settings rts done init_gomode this function initializes the game over game mode sta hmclr stop both players from moving lda cxp0fb p0 collision and 128 with wall cmp 0 did p0 hit the wall bne gocheckp1 yes leave it at bottom lda 2 no move player 0 sta playr0y up the screen to show win gocheckp1 lda cxp1fb p1 collision and 128 with wall cmp 0 did p1 hit the wall bne gop1hit yes leave it at the bottom lda playr1y is p1 even cmp 255 on the screen 2 player game beq gop1hit no skip it lda 2 player 1 is onscreen and didn t collide sta playr1y move up the screen to show win gop1hit lda 0 going to sta mode game over mode sta audv0 turn off any sta audv1 sound jsr init_go_fx initialize sound effects rts done gomode this function is called every frame to process the game over sequence when the sound effect has finished the game switches to select mode jsr process_go_fx process the sound effects cmp 0 effects still running beq gokeepgoing yes let them run jsr init_selmode when effect is over go to select mode gokeepgoing rts done move_walls this function moves the wall down the screen and back to position 0 when it reaches or passes 112 dec walldely wall motion timer lda walldely time to cmp 0 move the wall bne walldone no leave it alone lda walldelyr reset the sta walldely delay count lda wallstart current wall position clc increment adc wall_inc wall position cmp 112 at the bottom bcc wallok no leave it alone lda 0 else restart sta wallstart wall at top of screen lda 1 return flag that wall did restart rts done wallok sta wallstart store new wall position walldone lda 0 return flag that wall did not restart rts done new_gaps this function builds the pf0 pf1 and pf2 graphics for a wall with the gap pattern gapbits placed at random in the 20 bit area lda 255 start with sta walldrela solid wall in pf0 sta walldrelb and pf1 lda gapbits store the gap pattern sta walldrelc in pf2 lda entropya get adc entropyb a randomish adc entropyc number sta entropyc update the random seed and 15 0 to 15 cmp 12 too far to the right beq gapok no 12 is ok bcc gapok no less than 12 is ok sbc 9 back up 9 gapok cmp 0 gap already at far left beq gapdone yes done sec roll gap ror walldrelc left rol walldrelb desired ror walldrela times sec all rolls sbc 1 done jmp gapok no do them all gapdone rts new wall pattern is ready make_score this function builds the pf1 and pf2 graphics rows for the byte value passed in a the current implementation is two digits only pf2 is blank ldx 0 100 s digit ldy 0 10 s digit count100s cmp 100 need another 100s digit bcc count10s no move on to 10s inx count sec value sbc 100 take off this 100 jmp count100s keep counting count10s cmp 10 need another 10s digit bcc countdone no got all the tens iny count sec value sbc 10 take off this 10 jmp count10s keep counting countdone asl a one s digit asl a 8 asl a to find picture tax one s digit picture to x tya now the 10 s digit asl a multiply asl a by 8 asl a to find picture tay 10 s picture in y lda digits y get the 10 s digit and 0xf0 upper nibble sta score_pf1 store left side lda digits x get the 1 s digit and 0x0f lower nibble ora score_pf1 put left and right half together sta score_pf1 and store image we have plenty of code space time and registers are at a premium so copy past the code for each row lda digits 1 y repeat for 2nd line of picture and 0xf0 sta score_pf1 1 lda digits 1 x and 15 ora score_pf1 1 sta score_pf1 1 lda digits 2 y repeat for 3nd line of picture and 0xf0 sta score_pf1 2 lda digits 2 x and 0x0f ora score_pf1 2 sta score_pf1 2 lda digits 3 y repeat for 4th line of picture and 0xf0 sta score_pf1 3 lda digits 3 x and 0x0f ora score_pf1 3 sta score_pf1 3 lda digits 4 y repeat for 5th line of picture and 0xf0 sta score_pf1 4 lda digits 4 x and 0x0f ora score_pf1 4 sta score_pf1 4 lda 0 for now sta score_pf2 there sta score_pf2 1 is sta score_pf2 2 no sta score_pf2 3 100s sta score_pf2 4 digit drawn rts done expertise this function changes the y position of the players based on the position of their respective pro novice switches the player 1 position is not changed if the mode is a single player game lda swchb check p0 and 0x40 pro novice settings cmp 0 amateur beq expp0ama yes near the bottom of screen lda 8 pro near the top jmp expp1 store and check p0 expp0ama lda 12 near the bottom expp1 sta playr0y player 0 y coordinate ldx playr1y is p1 on cpx 255 the screen beq expnop1 no skip all this lda swchb check p1 and 0x80 pro novice settings cmp 0 amateur beq expp1ama yes near the bottom of the screen ldx 8 pro near the top jmp expdone store and out expp1ama ldx 12 novice near the bottom expdone stx playr1y player 1 y coordinate expnop1 rts done adjust_dif this function adjusts the wall game difficulty values based on the current score the music can also change with the difficulty a single table describes the new values and when they take effect ldx 0 starting at index 0 adjnextrow lda skill_values x get the score match cmp 255 at the end of the table bne adjchecktable no check this row rts end of the table leave it alone adjchecktable cmp wallcnt is this our row bne adjbump no bump to next inx copy lda skill_values x new sta wall_inc wall increment inx copy lda skill_values x new sta walldely wall sta walldelyr delay inx copy lda skill_values x new sta gapbits gap pattern inx copy lda skill_values x new sta musaind musica index inx copy lda skill_values x new sta musbind musicb index lda 1 force sta musadel music to sta musbdel start new rts done adjbump inx move inx x inx to inx next inx row of inx table jmp adjnextrow try next row sel_reset_chk this function checks for changes to the reset select switches and debounces the transitions xxxxxxsr select reset ldx debounce get the last value lda swchb new value and 3 only need bottom 2 bits cmp debounce same as before beq seldebounce yes return nothing changed sta debounce hold new last value eor 255 active low to active high and 3 only need select reset rts return changes seldebounce lda 0 return 0 rts nothing changed init_music this function initializes the hardware and temporaries for 2 channel music lda 6 audio control sta audc0 to pure sta audc1 tones lda 0 turn off sta audv0 all sta audv1 sound sta musaind music pointers sta musbind to top of data lda 1 force sta musadel music sta musbdel reload lda 15 set volume levels sta musavol to sta musbvol maximum rts done process_music this function is called once per frame to process the 2 channel music two tables contain the commands notes for individual channels this function changes the notes at the right time dec musadel current note on channel a ended bne musdob no let it play muschana ldx musaind voice a index lda musica x get the next music command cmp 0 jump beq muscmdjumpa yes handle it cmp 1 control beq muscmdctrla yes handle it cmp 2 volume bne muscmdtonea no must be a note inx point to volume value inc musaind bump the music pointer lda musica x get the volume value inc musaind bump the music pointer sta musavol store the new volume value jmp muschana keep processing through a tone muscmdctrla inx point to the control value inc musaind bump the music pointer lda musica x get the control value inc musaind bump the music pointer sta audc0 store the new control value jmp muschana keep processing through a tone muscmdjumpa inx point to jump value txa x to tay y pointer to jump value inx point one past jump value txa into a so we can subtract sec new sbc musica y index sta musaind store it jmp muschana keep processing through a tone muscmdtonea ldy musavol get the volume and 0x1f lower 5 bits are frequency cmp 0x1f is this a silence bne musnotea no play it ldy 0 frequency of 31 flags silence musnotea sta audf0 store the frequency sty audv0 store the volume lda musica x get the note value again inc musaind bump to the next command ror a the upper ror a three ror a bits ror a hold ror a the and 7 delay clc no accidental carry rol a every delay tick rol a is 4 frames sta musadel store the note delay musdob dec musbdel bne musdodone muschanb ldx musbind lda musicb x cmp 0 beq muscmdjumpb cmp 1 beq muscmdctrlb cmp 2 bne muscmdtoneb inx inc musbind lda musicb x inc musbind sta musbvol jmp muschanb muscmdctrlb inx inc musbind lda musicb x inc musbind sta audc1 jmp muschanb muscmdjumpb inx txa tay inx txa sec sbc musicb y sta musbind jmp muschanb muscmdtoneb ldy musbvol and 0x1f cmp 0x1f bne musnoteb ldy 0 musnoteb sta audf1 sty audv1 lda musicb x inc musbind ror a ror a ror a ror a ror a and 7 clc rol a rol a sta musbdel musdodone rts done init_go_fx this function initializes the hardware and temporaries to play the soundeffect of a player hitting the wall lda 5 set counter for frame delay sta mus_tmp1 between frequency change...
|