/[projet1]/public/oric/demos/OricTech/code/scroller.s
Defence Force logotype

Annotation of /public/oric/demos/OricTech/code/scroller.s

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1346 - (hide annotations)
Sat Jan 9 16:14:40 2016 UTC (3 years, 9 months ago) by dbug
File size: 19032 byte(s)
Updated Oric Tech to use the new FloppyBuilder API, and fixed some bugs.
1 dbug 1283
2     #include "defines.h"
3     #include "script.h"
4     #include "floppy_description.h"
5 dbug 1346 #include "loader_api.h"
6 dbug 1283
7     .zero
8    
9     *=20 ; Before is the load zero page stuff...
10    
11     tmp0 .dsb 2
12     tmp1 .dsb 2
13    
14     _MessageScrollerPtr .dsb 2
15    
16     _OverlayStartPtr .dsb 2 ; Pointer to the current starting line
17     _OverlayCounter .dsb 1 ; How many lines we want to move
18     _OverlayDirection .dsb 1 ; Direction for the decount (0=does not move)
19     _OverlayLineInc .dsb 1 ; How much we increment between each line (a big hack to not show the overlay at all)
20    
21     character_offset .dsb 1
22     character_width .dsb 1
23    
24     _BackgroundMapActive .dsb 1
25     _BackgroundMapX .dsb 1 ; Map position
26     _BackgroundMapDX .dsb 1 ; Map increment (signed)
27    
28     _BackgroundBottomActive .dsb 1
29     _BackgroundBottomX .dsb 1 ; Map position
30     _BackgroundBottomDX .dsb 1 ; Map increment (signed)
31    
32     _ScrollerCommand .dsb 1
33     _ScrollerCommandParam1 .dsb 1
34     _ScrollerCommandParam2 .dsb 1
35     _ScrollerCommandParam3 .dsb 1
36     _ScrollerCommandParam4 .dsb 1
37    
38    
39     .text
40    
41     _main
42     _TechTechInit
43     // jmp _TechTechInit
44     .(
45     // Clear the screen
46     // $9800 + 32*8 = $9900
47     lda #0
48     ldy #$c0-$98
49     loop_clear_outer
50     ldx #0
51     loop_clear_inner
52     sta $9800,x
53     inx
54     bne loop_clear_inner
55     inc loop_clear_inner+2
56     dey
57     bne loop_clear_outer
58    
59    
60     ;bloooo jmp bloooo
61    
62     // Put the text attribute at the bottom right to foce us back to TEXT mode
63     // poke((char*)0xbfdf,26); // 50hz Text attribute
64     lda #26
65     sta $a000
66     sta $bfdf
67    
68     // Load files
69     // Load the 6x8 font
70 dbug 1346 LoadFile(LOADER_FONT_6x8)
71 dbug 1283
72     // Load the VIP scroll stuff (HAS TO BE BEFORE _BufferCharset30x40)
73 dbug 1346 LoadFileAt(LOADER_VIP_SCROLL,_BufferCharset)
74 dbug 1283
75     // Copy the 96*8=768 bytes of charset data while adding an attribute neutral value bit to avoid glitches in case of screen conflict
76     ldx #0
77     loop_copy_std_charset
78     lda _BufferCharset+CHARMAP_SIZE+256*0,x
79     ora #64
80     sta $b400+8*32+256*0,x
81     lda _BufferCharset+CHARMAP_SIZE+256*1,x
82     ora #64
83     sta $b400+8*32+256*1,x
84     lda _BufferCharset+CHARMAP_SIZE+256*2,x
85     ora #64
86     sta $b400+8*32+256*2,x
87     inx
88     bne loop_copy_std_charset
89    
90     // Load the BIG scroll stuff (HAS TO BE BEFORE _BufferInverseVideo)
91 dbug 1346 LoadFileAt(LOADER_FONT_30x40,_BufferCharset30x40)
92 dbug 1283
93     // Copy the 15*8=768 bytes of charset data while adding an attribute neutral value bit to avoid glitches in case of screen conflict
94     ldx #127
95     loop_copy_alt_charset
96     lda _BufferCharset30x40+BIGFONT_SIZE+256*0,x
97     ora #64
98     sta $b800+8*32+256*0,x
99     dex
100     bpl loop_copy_alt_charset
101    
102     //
103     // Load the 36x128 overlay file (#define LOADER_OVERLAY_SIZE 5376)
104     //
105 dbug 1346 LoadFileAt(LOADER_OVERLAY,_BufferInverseVideo) // <-- memory overwrite at the moment, need to fix that
106 dbug 1283
107     // Filter the content of the buffer to only have zeroes and 128 values
108     // 36*128=4608 bytes = 18*256
109     .(
110     lda #0
111     ldy #18
112     loop_inverse_outer
113     ldx #0
114     loop_inverse_inner
115     sec
116     load_value
117     lda _BufferInverseVideo,x ; 32/33
118     sbc #32
119     beq skip
120     lda #128
121     skip
122     update_value
123     sta _BufferInverseVideo,x
124     inx
125     bne loop_inverse_inner
126     inc load_value+2
127     inc update_value+2
128     dey
129     bne loop_inverse_outer
130     .)
131    
132     lda #<_BufferInverseVideo
133     sta _OverlayStartPtr+0
134     lda #>_BufferInverseVideo
135     sta _OverlayStartPtr+1
136    
137     lda #128-16
138     sta _OverlayCounter
139    
140     lda #0
141     sta _OverlayDirection
142    
143     lda #0
144     sta _OverlayLineInc
145    
146     // Load the sample sound
147 dbug 1346 LoadFileAt(LOADER_SAMPLE_BOOMTSCHACK,_SampleSound)
148 dbug 1283
149     // Load the second sample sound
150 dbug 1346 LoadFileAt(LOADER_SAMPLE_DEFENCE,_SampleSoundDefence)
151 dbug 1283
152     // Load the second sample sound
153 dbug 1346 LoadFileAt(LOADER_SAMPLE_FORCE,_SampleSoundForce)
154 dbug 1283
155     // Load the second sample sound
156 dbug 1346 LoadFileAt(LOADER_SAMPLE_MUSIC_NON_STOP,_SampleSoundMusicNonStop)
157 dbug 1283
158     // Load the second sample sound
159 dbug 1346 LoadFileAt(LOADER_SAMPLE_TECHNO_POP,_SampleSoundTechnoPop)
160 dbug 1283
161     // Load the second sample sound
162 dbug 1346 LoadFileAt(LOADER_SAMPLE_CHIME_START,_SampleSoundChimeStart)
163 dbug 1283
164     // Load the second sample sound
165 dbug 1346 LoadFileAt(LOADER_SAMPLE_CHIME_END,_SampleSoundChimeEnd)
166 dbug 1283
167     // Initialize the various elements of the big text scroller
168     jsr _BigScrollerInit
169    
170     // Initialize the colortext mode
171     /*
172     screen=(char*)0xa000;
173     for (y=0;y<200;y++)
174     {
175     if ((y<=128) || (y>=160))
176     {
177     screen[0]= RastersInk[y]; // Color
178     screen[1]=16+RastersPaper[y]; // Color
179    
180     screen[2]=26; // TEXT
181     }
182     screen+=40;
183     }
184     */
185     // First part is the hires setup loop
186     .(
187     ;bla jmp bla
188    
189     lda #<$a000
190     sta tmp0+0
191     lda #>$a000
192     sta tmp0+1
193     ldx #0
194     loop_hires
195     ; The 128-159 zone is where the text scroller is located, it also overlaps the area with the charsets
196     cpx #128
197     bcc top_rasters
198     cpx #168
199     bcc skip
200    
201     bottom_rasters
202     ldy #1
203     lda _RastersPaper-168+120-1,x ; Paper color
204     //lda #16+5 ;_RastersPaper-168+128,x ; Paper color
205     ora #16
206     sta (tmp0),y
207    
208     iny
209     lda #26 ; TEXT attribute
210     sta (tmp0),y
211     jmp skip
212    
213     top_rasters
214     ldy #0
215     lda _RastersInk,x ; Ink color
216     sta (tmp0),y
217    
218     iny
219     lda _RastersPaper,x ; Paper color
220     ora #16
221     sta (tmp0),y
222    
223     iny
224     lda #26 ; TEXT attribute
225     sta (tmp0),y
226     jmp skip
227    
228    
229     skip
230     jsr _PtrPlus40
231     inx
232     cpx #176
233     bne loop_hires
234     .)
235    
236     // Second part is the TEXT setup loop
237     // From Line 16, need to clear 5 lines of TEXT
238     lda #32
239     ldx #40*5
240     loop_clear_scroller
241     sta $bb80+40*16-1,x
242     dex
243     bne loop_clear_scroller
244    
245     /*
246     screen=(char*)0xbb80;
247     for (y=0;y<28;y++)
248     {
249     if (y>=25)
250     {
251     // 3 last lines of TEXT
252     screen[0]= 1;
253     screen[1]=16+7;
254    
255     screen[2]=26; // TEXT
256     screen[39]=26; // TEXT
257     }
258     else
259     if ((y<16) || (y>=21) )
260     {
261     // Rest of the screen
262     screen[2]=26; // TEXT
263     screen[39]=30; // HIRES
264     }
265     else
266     {
267     // ALT font scroller
268     screen[0]=26; // TEXT
269     screen[1]=(16+RastersPaper[y*8])|128; // Color
270     screen[2]=9|128; // ALT
271     screen[39]=0|128; // whatever
272     }
273     screen+=40;
274     }
275    
276     */
277     .(
278     ;bla jmp bla
279    
280     lda #<$bb80
281     sta tmp0+0
282     lda #>$bb80
283     sta tmp0+1
284     ldx #0
285     loop_text
286     cpx #25
287     bcs lastLinesOfText
288     cpx #21
289     bcs bottomOfTheScreen
290     cpx #16
291     bcs altFontScroller
292    
293     restOfTheScreen
294     ldy #0
295     lda #26 ; TEXT attribute
296     sta (tmp0),y
297    
298     ldy #39
299     lda #30 ; HIRES attribute
300     sta (tmp0),y
301    
302     jmp skip
303    
304     altFontScroller
305     ldy #0
306     ;lda #26 ; TEXT attribute
307     lda #9 ; ALT mode
308     sta (tmp0),y
309    
310     iny
311     lda #16+4+128 ; Paper color
312     sta (tmp0),y
313    
314     ;iny
315     ;lda #9+128 ; ALT mode
316     ;sta (tmp0),y
317    
318     ldy #39
319     lda #0|128 ; Whatever (in video inverse)
320     sta (tmp0),y
321    
322     jmp skip
323    
324     bottomOfTheScreen
325     ldy #0
326     lda #1 ; RED ink
327     sta (tmp0),y
328    
329     iny
330     lda #16+0 ; BLACK paper
331     sta (tmp0),y
332    
333     iny
334     lda #16+0 ; BLACK paper
335     sta (tmp0),y
336    
337     ldy #39
338     lda #16+0 ; BLACK paper
339     sta (tmp0),y
340    
341     jmp skip
342    
343     lastLinesOfText
344     ldy #0
345     lda #1 ; Ink color
346     sta (tmp0),y
347    
348     iny
349     lda #16+0 ; Paper color
350     sta (tmp0),y
351    
352     iny
353     lda #26 ; TEXT attribute
354     sta (tmp0),y
355     ldy #39
356     sta (tmp0),y
357    
358     jmp skip
359    
360     skip
361     jsr _PtrPlus40
362     inx
363     cpx #28
364     bne loop_text
365     .)
366    
367    
368     lda #0
369     ldx #39
370     loop_clean_line
371     sta $bb80+40*21+1,x // neutral attribute to hide characters under
372     dex
373     bne loop_clean_line
374     lda #26
375     sta $a000+40*21*8+2 // First byte of the line 21 -> go to texthires to show the rasters
376     lda #30
377     sta $bb80+40*21+0 // First byte of the line 21 -> back to hires to show the rasters
378    
379    
380     /*
381     lda #26
382     sta $a000+40*128+0 // First byte of the ALT scroller area -> back to text
383     lda #9
384     sta $a000+40*128+1 // First byte of the ALT scroller area -> back to text
385    
386     lda #26
387     sta $a000+40*127+0 // First byte of the ALT scroller area -> back to text
388    
389    
390     lda #16+1
391     sta $bb80+40*16+1 // First byte of the line 21 -> back to hires to show the rasters
392     */
393    
394     lda #26
395     sta $a000+40*128+39 // First byte of the ALT scroller area -> back to text
396    
397    
398     ; b900=start of the reconfigurated area
399    
400    
401     // Then initialize the sample player
402     jsr _DigiPlayer_InstallIrq
403    
404    
405     //
406     // And now the actual demo main loop
407     //
408     /*
409     while (1)
410     {
411     VSync();
412     BigScrollerUpdate();
413     DisplayBackground();
414     }
415     */
416     demo_loop
417    
418     .(
419     wait_sync
420     lda _VblCounter
421     beq wait_sync
422     lda #0
423     sta _VblCounter
424     .)
425    
426     jsr _BigScrollerUpdate
427     jsr _DisplayBackground
428     jmp demo_loop
429    
430    
431     rts
432     .)
433    
434     _PtrPlus40
435     .(
436     clc
437     lda tmp0+0
438     adc #40
439     sta tmp0+0
440     bcc skip
441     inc tmp0+1
442     skip
443     rts
444     .)
445    
446    
447    
448     _BigScrollerInit
449     ;jmp _BigScrollerInit
450     .(
451     ; Start by initializing the arrays
452     ldx #0
453     loop_init
454     lda #0
455     sta _BigFontOffset,x
456     lda #1
457     sta _BigFontWidth,x
458    
459     inx
460     cpx #128
461     bne loop_init
462    
463     ; Then for each known character, set the actual correct information
464     ldx #0
465     lda #0
466     loop
467     ldy _BigFontCharacter,x
468     beq end
469    
470     sta _BigFontOffset,y ; Save the offset
471    
472     sta tmp0
473     lda _BigFontCharacterWidth,x ; Load the width
474     sta _BigFontWidth,y ; Save the width
475     clc
476     adc tmp0
477    
478     inx
479     jmp loop
480     end
481    
482     jsr ScrollerDisplayReset
483    
484     lda #0
485     sta character_offset
486     sta character_width
487     sta _BackgroundMapActive
488     sta _BackgroundMapDX
489     sta _BackgroundBottomActive
490     sta _BackgroundBottomDX
491    
492     lda #36
493     sta _BackgroundMapX
494     sta _BackgroundBottomX
495     rts
496     .)
497    
498     _BigFontOffset .dsb 128 ; Where in the picture does the letter start
499     _BigFontWidth .dsb 128 ; How many column wide is the character
500    
501     ScrollerDisplayReset
502     lda #<_BigScrollMessage
503     sta _MessageScrollerPtr
504     lda #>_BigScrollMessage
505     sta _MessageScrollerPtr+1
506     rts
507    
508     ScrollerIncPointer
509     inc _MessageScrollerPtr
510     bne skipscrollermove
511     inc _MessageScrollerPtr+1
512     skipscrollermove
513     rts
514    
515     _BigScrollerUpdate
516     .(
517     ; Scroll the entire thing to the left by one character
518     ldx #2
519     loop
520     lda $bb80+40*16+1,x
521     sta $bb80+40*16+0,x
522    
523     lda $bb80+40*17+1,x
524     sta $bb80+40*17+0,x
525    
526     lda $bb80+40*18+1,x
527     sta $bb80+40*18+0,x
528    
529     lda $bb80+40*19+1,x
530     sta $bb80+40*19+0,x
531    
532     lda $bb80+40*20+1,x
533     sta $bb80+40*20+0,x
534    
535     inx
536     cpx #38
537     bne loop
538    
539     ; Then we introduce one new line of characters
540     ; The font description is BIGFONT_WIDTH (184 characters) wide at this point
541     ldx character_offset ; New column
542     dec character_width ; Check if it was the last one
543     bpl continue_character
544    
545     new_character
546     ldy #0
547     lda (_MessageScrollerPtr),y
548     jsr ScrollerIncPointer
549     cmp #32
550     bcc SpecialCommand
551    
552     tay
553     ldx _BigFontOffset,y
554     stx character_offset
555     lda _BigFontWidth,y
556     sta character_width
557     jmp insert_column
558    
559     continue_character
560     bne insert_column
561     ldx #0 ; Insert the separator between characters so they are not all glued together
562     insert_column
563     lda _BufferCharset30x40+BIGFONT_WIDTH*0,x
564     sta $bb80+40*16+38
565     lda _BufferCharset30x40+BIGFONT_WIDTH*1,x
566     sta $bb80+40*17+38
567     lda _BufferCharset30x40+BIGFONT_WIDTH*2,x
568     sta $bb80+40*18+38
569     lda _BufferCharset30x40+BIGFONT_WIDTH*3,x
570     sta $bb80+40*19+38
571     lda _BufferCharset30x40+BIGFONT_WIDTH*4,x
572     sta $bb80+40*20+38
573    
574     inc character_offset
575    
576     rts
577    
578    
579     SpecialCommand
580     //jmp SpecialCommand
581    
582     cmp #SCROLLER_TOP_ACTIVE
583     beq ScrollerTopActive
584     cmp #SCROLLER_TOP_SET_X
585     beq ScrollerTopSetX
586     cmp #SCROLLER_TOP_SET_DX
587     beq ScrollerTopSetDX
588    
589     cmp #SCROLLER_BOTTOM_ACTIVE
590     beq ScrollerBottomActive
591     cmp #SCROLLER_BOTTOM_SET_X
592     beq ScrollerBottomSetX
593     cmp #SCROLLER_BOTTOM_SET_DX
594     beq ScrollerBottomSetDX
595    
596     cmp #SCROLLER_OVERLAY_SET_Y
597     beq ScrollerOverlaySetY
598     cmp #SCROLLER_OVERLAY_SET_LINEINC
599     beq ScrollerOverlaySetLineInc
600     cmp #SCROLLER_OVERLAY_SET_DIRECTION
601     beq ScrollerOverlaySetDirection
602    
603     //; Anything else we treat as an end of scroll
604     jsr ScrollerDisplayReset
605     jmp new_character
606    
607    
608     ScrollerTopActive
609     lda (_MessageScrollerPtr),y
610     sta _BackgroundMapActive
611     jmp IncrementAndReadBack
612    
613     ScrollerTopSetX
614     clc
615     lda (_MessageScrollerPtr),y
616     adc #36
617     sta _BackgroundMapX
618     jmp IncrementAndReadBack
619    
620     ScrollerTopSetDX
621     lda (_MessageScrollerPtr),y
622     sta _BackgroundMapDX
623     jmp IncrementAndReadBack
624    
625     ScrollerBottomActive
626     lda (_MessageScrollerPtr),y
627     sta _BackgroundBottomActive
628     jmp IncrementAndReadBack
629    
630     ScrollerBottomSetX
631     clc
632     lda (_MessageScrollerPtr),y
633     adc #36
634     sta _BackgroundBottomX
635     jmp IncrementAndReadBack
636    
637     ScrollerBottomSetDX
638     lda (_MessageScrollerPtr),y
639     sta _BackgroundBottomDX
640     jmp IncrementAndReadBack
641    
642     ScrollerOverlaySetY
643     lda (_MessageScrollerPtr),y
644     sta _OverlayStartPtr+0
645     jsr ScrollerIncPointer
646     lda (_MessageScrollerPtr),y
647     sta _OverlayStartPtr+1
648     jmp IncrementAndReadBack
649    
650     ScrollerOverlaySetLineInc
651     lda (_MessageScrollerPtr),y
652     sta _OverlayLineInc
653     jmp IncrementAndReadBack
654    
655     ScrollerOverlaySetDirection
656     lda (_MessageScrollerPtr),y
657     sta _OverlayDirection
658     jmp IncrementAndReadBack
659    
660     IncrementAndReadBack
661     jsr ScrollerIncPointer
662     jmp new_character
663    
664     .)
665    
666    
667     /*
668     #define PAINT(XX,YY) sta _BufferInverseVideo+INVERSE_WIDTH*YY+XX
669    
670     PaintCrap
671     lda #128
672     PAINT(0,0)
673     PAINT(1,1)
674     PAINT(2,2)
675     PAINT(3,3)
676     rts
677     */
678    
679    
680     _DisplayBackground
681     .(
682     lda _BackgroundMapActive
683     bne continue
684     jmp end_top
685    
686     continue
687     //jsr PaintCrap
688    
689     ;
690     ; Update the overlay position based on the current coordinate
691     ;
692     .(
693     lda #<_patch_ora+1
694     sta tmp0+0
695     lda #>_patch_ora+1
696     sta tmp0+1
697    
698     lda _OverlayStartPtr+0
699     sta tmp1+0
700     lda _OverlayStartPtr+1
701     sta tmp1+1
702    
703     ldx #15
704     loop_patch
705     ldy #0
706     lda tmp1+0
707     sta (tmp0),y ; Low byte
708     clc
709     adc _OverlayLineInc ;#INVERSE_WIDTH
710     sta tmp1+0
711    
712     iny
713     lda tmp1+1
714     sta (tmp0),y ; High byte
715     adc #0
716     sta tmp1+1
717    
718     clc
719     lda tmp0+0
720     adc #(_patch_ora2-_patch_ora)
721     sta tmp0+0
722     bcc skip
723     inc tmp0+1
724     skip
725     dex
726     bne loop_patch
727    
728    
729     lda _OverlayDirection
730     beq go_end
731     bmi go_up
732    
733     go_down
734     clc
735     lda _OverlayStartPtr+0
736     adc #INVERSE_WIDTH
737     sta _OverlayStartPtr+0
738     lda _OverlayStartPtr+1
739     adc #0
740     sta _OverlayStartPtr+1
741    
742     dec _OverlayCounter
743     bne go_end
744     lda #255
745     sta _OverlayDirection
746     lda #128-16
747     sta _OverlayCounter
748     jmp go_end
749    
750     go_up
751     sec
752     lda _OverlayStartPtr+0
753     sbc #INVERSE_WIDTH
754     sta _OverlayStartPtr+0
755     lda _OverlayStartPtr+1
756     sbc #0
757     sta _OverlayStartPtr+1
758    
759     dec _OverlayCounter
760     bne go_end
761     lda #1
762     sta _OverlayDirection
763     lda #128-16
764     sta _OverlayCounter
765     jmp go_end
766    
767     go_end
768    
769     /*
770     lda #<_BufferInverseVideo
771     sta _OverlayStartPtr+0
772     lda #>_BufferInverseVideo
773     sta _OverlayStartPtr+1
774     lda #128-28
775     sta _OverlayCounter
776     lda #1
777     sta _OverlayDirection
778     */
779    
780     .)
781    
782    
783    
784    
785     ;
786     ; Display the top part
787     ;
788     clc
789     lda _BackgroundMapX
790     tay
791     adc _BackgroundMapDX
792     sta _BackgroundMapX
793    
794     ldx #36
795     loop_top
796     ; Top part
797     lda _BufferCharset+CHARMAP_WIDTH*0-1,y
798     _patch_ora
799     ora _BufferInverseVideo+INVERSE_WIDTH*0-1,x
800     sta $bb80+40*0+2,x
801    
802     lda _BufferCharset+CHARMAP_WIDTH*1-1,y
803     _patch_ora2
804     ora _BufferInverseVideo+INVERSE_WIDTH*1-1,x
805     sta $bb80+40*1+2,x
806    
807     lda _BufferCharset+CHARMAP_WIDTH*2-1,y
808     ora _BufferInverseVideo+INVERSE_WIDTH*2-1,x
809     sta $bb80+40*2+2,x
810    
811     lda _BufferCharset+CHARMAP_WIDTH*3-1,y
812     ora _BufferInverseVideo+INVERSE_WIDTH*3-1,x
813     sta $bb80+40*3+2,x
814    
815     lda _BufferCharset+CHARMAP_WIDTH*4-1,y
816     ora _BufferInverseVideo+INVERSE_WIDTH*4-1,x
817     sta $bb80+40*4+2,x
818    
819     lda _BufferCharset+CHARMAP_WIDTH*5-1,y
820     ora _BufferInverseVideo+INVERSE_WIDTH*5-1,x
821     sta $bb80+40*5+2,x
822    
823     lda _BufferCharset+CHARMAP_WIDTH*6-1,y
824     ora _BufferInverseVideo+INVERSE_WIDTH*6-1,x
825     sta $bb80+40*6+2,x
826    
827     lda _BufferCharset+CHARMAP_WIDTH*7-1,y
828     ora _BufferInverseVideo+INVERSE_WIDTH*7-1,x
829     sta $bb80+40*7+2,x
830    
831     lda _BufferCharset+CHARMAP_WIDTH*8-1,y
832     ora _BufferInverseVideo+INVERSE_WIDTH*8-1,x
833     sta $bb80+40*8+2,x
834    
835     lda _BufferCharset+CHARMAP_WIDTH*9-1,y
836     ora _BufferInverseVideo+INVERSE_WIDTH*9-1,x
837     sta $bb80+40*9+2,x
838    
839     lda _BufferCharset+CHARMAP_WIDTH*10-1,y
840     ora _BufferInverseVideo+INVERSE_WIDTH*10-1,x
841     sta $bb80+40*10+2,x
842    
843     lda _BufferCharset+CHARMAP_WIDTH*11-1,y
844     ora _BufferInverseVideo+INVERSE_WIDTH*11-1,x
845     sta $bb80+40*11+2,x
846    
847     lda _BufferCharset+CHARMAP_WIDTH*12-1,y
848     ora _BufferInverseVideo+INVERSE_WIDTH*12-1,x
849     sta $bb80+40*12+2,x
850    
851     lda _BufferCharset+CHARMAP_WIDTH*13-1,y
852     ora _BufferInverseVideo+INVERSE_WIDTH*13-1,x
853     sta $bb80+40*13+2,x
854    
855     lda _BufferCharset+CHARMAP_WIDTH*14-1,y
856     ora _BufferInverseVideo+INVERSE_WIDTH*14-1,x
857     sta $bb80+40*14+2,x
858    
859     dey
860     dex
861     beq end_top
862     jmp loop_top
863     end_top
864    
865    
866     ;
867     ; Display the Bottom part
868     ;
869     lda _BackgroundBottomActive
870     beq end_bottom
871    
872     ;
873     ; Display the top part
874     ;
875     clc
876     lda _BackgroundBottomX
877     tay
878     adc _BackgroundBottomDX
879     sta _BackgroundBottomX
880    
881     ldx #36
882     loop_bottom
883     lda _BufferCharset+CHARMAP_WIDTH*15-1,y
884     sta $bb80+40*22+2,x
885    
886     lda _BufferCharset+CHARMAP_WIDTH*16-1,y
887     sta $bb80+40*23+2,x
888    
889     lda _BufferCharset+CHARMAP_WIDTH*17-1,y
890     sta $bb80+40*24+2,x
891    
892     lda _BufferCharset+CHARMAP_WIDTH*18-1,y
893     sta $bb80+40*25+2,x
894    
895     lda _BufferCharset+CHARMAP_WIDTH*19-1,y
896     sta $bb80+40*26+2,x
897    
898     lda _BufferCharset+CHARMAP_WIDTH*20-1,y
899     sta $bb80+40*27+2,x
900    
901     dey
902     dex
903     bne loop_bottom
904     end_bottom
905    
906    
907     ; Force hires on the last byte
908     lda #30
909     sta $bfdf
910    
911     ;lda #26
912     ;sta $a000+40*128+0
913    
914     rts
915     .)
916    
917     _BigFontCharacter
918     .byt " ABCDEFGHIJKLMNOPQRSTUVWXYZ123456789?()!-.,;",0
919    
920     _BigFontCharacterWidth
921     .byt 2 ; space
922     .byt 5,5,5,5,5,5,5,5,2,5 ; ABCDEFGHIJ
923     .byt 5,5,5,5,5,5,5,5,5,5 ; KLMNOPQRST
924     .byt 5,5,5,5,5,5 ; UVWXYZ
925     .byt 3,5,5,5,5,5,5,5,5 ; 123456789
926     .byt 5,3,3,2,3,1,2,2 ; ?()!-.,;
927    
928     _BigScrollMessage
929    
930     .byt "HELLO EVERYBODY AT VIP 2O15!!! "
931    
932     .byt "I (DBUG) WISH I WAS THERE WITH YOU... "
933     .byt SCROLLER_TOP_ACTIVE,1
934    
935     .byt "THIS LITTLE INTRO IS MY WAY OF SAYING THANKS ;) "
936     .byt SCROLLER_BOTTOM_ACTIVE,1
937     .byt "AND AS USUAL BARELY MADE THE DEADLINE... "
938     .byt SCROLLER_BOTTOM_SET_DX,1
939    
940     .byt "LET MOVE THINGS AROUND!!! "
941     .byt SCROLLER_TOP_SET_DX,255
942    
943     .byt "I GUESS WE CAN STILL ADD STUFF??? "
944     .byt SetOverlayPosition(0)
945     .byt SCROLLER_OVERLAY_SET_LINEINC,INVERSE_WIDTH ; Show the overlay
946    
947     .byt "LET MOVE THAT ONE TOO!!! "
948     .byt SCROLLER_OVERLAY_SET_DIRECTION,1
949     .byt SCROLLER_TOP_SET_DX,1
950    
951     .byt "INTRO MUSIC BY MAD MAX, THIS MUSIC BY KRAFTWERK, REMAINING STUFF BY DBUG... "
952    
953     .byt SCROLLER_TOP_SET_DX,0
954     //.byt SCROLLER_TOP_SET_X,0
955     .byt "GREETING TO: POPSY TEAM, LNX, AAA, "
956     .byt SCROLLER_BOTTOM_SET_DX,2
957     .byt "X-MEN, HMD, DRIFTERS, "
958     .byt SCROLLER_TOP_SET_DX,1
959     .byt "RIBBON, MOV, VORTEX, "
960     .byt SCROLLER_BOTTOM_SET_DX,3
961     .byt "CALODOX, ORION, JFF, CONDENSE, "
962     .byt SCROLLER_TOP_SET_DX,255
963     .byt "MDR, SYN(RJ), NOON, COCOON, MJJ, RAZOR, "
964     .byt SCROLLER_BOTTOM_SET_DX,4
965     .byt "REBELS, ADINPSZ, BRAINSTORM, NO EXTRA, KIKI, SECTOR 1 "
966     .byt SCROLLER_BOTTOM_SET_DX,253
967     .byt "TCB, OVR, TBL, WCZ, TKZ348, AND YOU SINCE YOU ARE WATCHING IT! "
968     .byt SCROLLER_BOTTOM_SET_DX,0
969    
970     .byt "I HOPE YOU LIKED IT! "
971     .byt "LET'S WRAP NOW... "
972     .byt " "
973     .byt SCROLLER_END

  ViewVC Help
Powered by ViewVC 1.1.26