Advertisement
lovejoy777

Agon Light2 Basic Auto Loading Screen

Nov 25th, 2023 (edited)
1,644
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
ZXBasic 6.05 KB | Source Code | 0 0
  1.    10 REM BBC Basic Auto Start Screen
  2.    20 REM Written by Steve Lovejoy aka lovejoy777
  3.    30 REM Icon design by Arnold Meszaros (netangel)
  4.    40 REM FOR THE AGON LIGHT2
  5.    45 :
  6.    50 REM INITIAL SCREEN
  7.    60 PRINT TAB(3,4) "MODE 0 = 80x60:16 colours"
  8.    70 PRINT TAB(3,5) "MODE 1 = 80x60:4 colours"
  9.    80 PRINT TAB(3,6) "MODE 2 = 80x60:2 colours"
  10.    90 PRINT TAB(3,7) "MODE 3 = 80x30:64 colours"
  11.   100 PRINT TAB(3,8) "MODE 4 = 80x30:16 colours"
  12.   110 PRINT TAB(3,9) "MODE 7 = 40x25:16 colours:teletext"
  13.   120 PRINT TAB(3,10) "MODE 8 = 40x30:64 colours"
  14.   130 PRINT TAB(3,11) "MODE 12 = 40X25:364 colours"
  15.   140 COLOUR 1 : INPUT TAB(3,13)"PICK YOUR SCREEN MODE"; mode%
  16.   145 REM MAIN START UP SCREEN
  17.    150 PROC_VARS : REM LOAD VARS.
  18.    200 PROC_INIT : REM LOAD UDF CHARS ETC.
  19.    250 PROC_DRAW_LOGO : REM DRAW LOGO TO SCREEN.
  20.    300 PROC_TITLE_TEXT : REM DRAW TEXT TO SCREEN.
  21.    350 PROC_DRAW_COLOUR_PALETTE : REM DRAW CURRENT PALETTE TO SCREEN.
  22.    400 PROC_READYUP : REM DRAW READY UP TEXT TO SCREEN AND SET PROMPT.
  23.    450 :
  24.    460 NEW : REM CLEAR PROGRAM FROM MEMORY.
  25.    480 REM END OF PROGRAM.
  26.    490 :
  27.    500 DEF PROC_DRAW_LOGO : REM ************************ DRAW_LOGO ********************************
  28.    510 REM DISPLAY THE LOGO LINE BY LINE.
  29.    520 REM FROM PREVIOUSLY USER DEFINED CHARS.
  30.    530 COLOUR 14: PRINT TAB(2,1);"  ";CHR$(200);CHR$(201);"   ";
  31.    540 COLOUR 14: PRINT TAB(2,2);"  ";CHR$(202);CHR$(203);"   ";
  32.    550 COLOUR 14: PRINT TAB(2,3);" ";CHR$(204);CHR$(205);CHR$(206);CHR$(207);"  ";
  33.    560 COLOUR 14: PRINT TAB(2,4);CHR$(208);CHR$(209);CHR$(210);CHR$(211);CHR$(212);CHR$(213);" ";
  34.    570 COLOUR 14: PRINT TAB(2,5);CHR$(214);CHR$(215);CHR$(216);CHR$(209);CHR$(217);CHR$(218);" ";
  35.    580 COLOUR 14: PRINT TAB(2,6);CHR$(219);CHR$(220);CHR$(221);CHR$(222);CHR$(223);CHR$(224);" ";
  36.    590 COLOUR 14: PRINT TAB(2,7);CHR$(225);CHR$(226);CHR$(227);CHR$(228);CHR$(229);CHR$(230);" ";
  37.    600 COLOUR 14: PRINT TAB(2,8);CHR$(231);CHR$(232);CHR$(233);CHR$(234);CHR$(235);CHR$(236);" ";
  38.    610 ENDPROC
  39.    620 :
  40.    700 DEF PROC_TITLE_TEXT : REM *************************** TITLE_TEXT *****************
  41.    710 REM DISPLAY TITLE SCREEN TEXT AND INFO LINE BY LINE.
  42.    720 PRINT TAB(10,1);"* AGON LIGHT2 with eZ80 CPU *"
  43.    730 PRINT TAB(10,3);"MODE:";M%;" (";W%;"x";H%;") COLOURS:";C%;
  44.    740 VDU 31,10,5 : REM position cursor
  45.    750 *VERSION : REM print BBC BASIC VERSION.
  46.    760 PRINT TAB(10,7)"BASIC Bytes Free: ";F%;
  47.    780 ENDPROC
  48.    790 :
  49.    800 DEF PROC_DRAW_COLOUR_PALETTE : REM ******************** COLOUR_PALATTE ****************
  50.    810 REM display the current colour pallette
  51.    820 VDU 23,238,255,255,255,255,255,255,255,255 : REM filled block for colour pallette
  52.    830 :
  53.    840 VDU 31,0,10 : REM move cursor, loop colours, print coloured filled char
  54.    850 FOR PC%=0 TO C%-1 : REM 1st 32 COLOURS
  55.    860 COLOUR PC%
  56.    870 IF PC% <=31 THEN PRINT ;CHR$(238);
  57.    880 NEXT PC%
  58.    890 :
  59.    900 IF C% >=32 THEN VDU 10 : VDU 13 : REM move cursor, loop colours, print coloured filled char
  60.    910 FOR PC%=31 TO C%-1 : REM Last 32 colours
  61.    920 COLOUR PC%
  62.    930 IF PC% >31 THEN PRINT ;CHR$(238);
  63.    940 NEXT PC%
  64.    945 ENDPROC
  65.    950 :
  66.    955 DEF PROC_READYUP : REM ************************ READYUP ************************
  67.    960 REM set colours
  68.    965 COLOUR BG%: COLOUR FG%
  69.    970 REM MOVE CURSOR DOWN AND LEFT.
  70.    975 VDU 10 : VDU 13 : VDU 10
  71.    980 REM SET READY PROMPT.
  72.    985 PRINT "AGON READY."
  73.    990 ENDPROC
  74.    995 :
  75.   1000 DEF PROC_INIT : REM ****************************** INIT ************************
  76.   1010 CLS
  77.   1020 REM Agon Light "Sitting Kung Fu man" load logo chars.
  78.   1030 REM second number after the (23 VDU cmd) is the char number, then the char data.
  79.   1040 VDU 23,200,7,15,31,31,31,31,31,63
  80.   1050 VDU 23,201,192,224,240,240,240,240,240,248
  81.   1060 VDU 23,202,63,63,31,15,15,15,7,7
  82.   1070 VDU 23,203,248,248,240,224,224,224,192,192
  83.   1080 VDU 23,204,0,1,7,15,31,63,127,127
  84.   1090 VDU 23,205,7,199,199,195,227,225,240,240
  85.   1100 VDU 23,206,192,195,195,135,135,15,15,31
  86.   1110 VDU 23,207,0,0,224,240,248,252,252,254
  87.   1120 VDU 23,208,0,0,1,1,3,3,7,7
  88.   1130 VDU 23,209,255,255,255,255,255,255,255,255
  89.   1140 VDU 23,210,248,248,248,240,224,225,193,195
  90.   1150 VDU 23,211,63,63,127,255,255,255,255,255
  91.   1160 VDU 23,212,255,255,255,255,255,255,223,223
  92.   1170 VDU 23,213,0,0,128,128,128,192,192,192
  93.   1180 VDU 23,214,7,7,15,15,15,15,15,31
  94.   1190 VDU 23,215,255,247,231,231,231,199,135,130
  95.   1200 VDU 23,216,199,135,135,143,15,15,31,31
  96.   1210 VDU 23,217,207,207,207,199,199,195,129,1
  97.   1220 VDU 23,218,224,224,224,240,240,240,240,240
  98.   1230 VDU 23,219,31,31,31,31,15,15,15,31
  99.   1240 VDU 23,220,128,128,128,128,129,143,135,143
  100.   1250 VDU 23,221,31,63,15,0,128,224,224,195
  101.   1260 VDU 23,222,252,240,128,0,3,7,35,243
  102.   1270 VDU 23,223,1,1,1,129,193,225,241,241
  103.   1280 VDU 23,224,240,240,240,240,240,240,240,240
  104.   1290 VDU 23,225,31,31,3,3,3,3,7,15
  105.   1300 VDU 23,226,223,255,255,255,255,255,254,254
  106.   1310 VDU 23,227,199,135,135,7,15,15,31,31
  107.   1320 VDU 23,228,241,241,241,248,248,248,248,248
  108.   1330 VDU 23,229,253,255,255,255,255,255,255,127
  109.   1340 VDU 23,230,240,248,248,224,224,224,240,248
  110.   1350 VDU 23,231,31,63,63,63,31,31,15,0
  111.   1360 VDU 23,232,254,252,252,252,248,248,224,0
  112.   1370 VDU 23,233,31,60,32,0,0,0,0,0
  113.   1380 VDU 23,234,120,28,12,12,0,0,0,0
  114.   1390 VDU 23,235,127,127,127,127,127,63,15,0
  115.   1400 VDU 23,236,248,252,252,252,252,248,240,0
  116.   1410 VDU 23,237,255,254,252,248,240,224,192,128
  117.   1500 ENDPROC
  118.   2000 :
  119.   2010 DEF PROC_VARS : REM ************** VARS ****************
  120.   2020 M% = mode%: REM Screen mode
  121.   2030 BG% = 132: REM Background color (blue)
  122.   2040 FG%= 15: REM Foreground color (white)
  123.   2050 MODE M%: COLOUR BG%: COLOUR FG%: CLS
  124.   2060 W%=FN_GETBYTE_VDP(&13): REM Screen width in chars
  125.   2070 H%=FN_GETBYTE_VDP(&14): REM Screen height in chars
  126.   2080 C%=FN_GETBYTE_VDP(&15): REM Number of colours
  127.   2090 F%=HIMEM-LOMEM: REM Free BASIC bytes
  128.   2100 :
  129.   2500 ENDPROC
  130.   2510 DEF FN_GETBYTE_VDP(V%): A%=&A0: L%=V%: =USR(&FFF4)
  131.   2520 DEF FN_GETWORD_VDP(V%): =FN_GETBYTE_VDP(V%)+256*FN_GETBYTE_VDP(V%+1)
  132.   2530 :
  133.  
Tags: agon light
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement