image of READY prompt

Wang2200.org

Listing of file='NEWYEAR' on disk='vmedia/2282_graphics_crt_demos.wvd.zip'

# Sector 128, program filename = 'NEWYEAR'
0001 REM %HOLIDAY GREETING PROGRAM - 12/31/79 - by R.L. Droz
0002 COM P$3
0003 DIM S1$64,Y$4,M$(6),C(12,2),M(6,3)
   : C=12
   : M=6
   : M5=6
0005 PRINT HEX(0D03),,HEX(020400020F0E);" NEW YEAR'S GREETING PROGRAM. "
   : PRINT
0010 LINPUT "GRAPHIC CRT IS AT WHICH ADDRESS?" -P$
0015 MAT SEARCH "0413151617", = STR(P$,2,2) TO L$
   : IF STR(L$,,2)=HEX(0000) THEN 5
0020 SELECT PLOT  <P$>,#15 <P$>
   : $OPEN #15
0021 Y$="19" & STR(Q1$,7,2)
0022 PRINT AT(4,0);
   : LINPUT "WHAT YEAR ARE WE CELEBRATING?"-Y$
0023 IF VER(Y$,"NNNN")<4 THEN 22
0025 SELECT D
0030 PLOT  <,,HEX(03E5)>
0035 GOSUB '60(999,"HAPPY NEW YEAR")
0036 S1$="]]] " & Y$ & " ]]]"
0040 GOSUB '60(Y9,S1$)
0045 SELECT P9
   : PRINT "PROGRAM RUNNING ..."
0050 PRINT "ENTER '$RELEASE TERMINAL TO";#PART;"' TO HALT THIS PROGRAM."
0055 $PSTAT="GREETING"
   : $RELEASE TERMINAL
0060 RESTORE
   : MAT READ M$
0061 DATA " ","Whoopee!!","Yeah!","Happy New Year!","Good Luck","Cheers"
0064 PLOT  <1,0,C>,<10,0,S>
0065 T1=300
   : B1=5
   : F1=4
0066 FOR C6=1 TO 12
   : C(C6,1)=INT(T1*RND(1))
   : C(C6,2)=1
   : NEXT C6
0067 MAT M=CON
0080 GOSUB '64
0085 GOSUB '66(M5*RND(1)+1)
0095 $BREAK 20
   : GOTO 80
0100 REM % CENTER WORDS
0105 DEFFN'60(Y9,S1$)
   : C=MIN(INT(80/LEN(S1$)),4)
   : S=MAX(10*C,800/LEN(S1$))
0110 $TRAN (S1$, " ]  ") R
   : PLOT  <,,R>,<C,,C>,<S,,S>,<S/2,MIN(512-S,Y9),S1$>
0115 Y9=MIN(Y9,512)-2.5*S
   : RETURN
0120 REM % PLOT ABSOLUTE
0125 DEFFN'61(X,Y,P1$)
   : X=ROUND((X,0)
   : Y=ROUND((Y,0)
0130 IF P1$="U" THEN PLOT  <X-X1,Y-Y1,U>
   : ELSE PLOT  <X-X1,Y-Y1,D>
0135 X1=X
   : Y1=Y
   : RETURN
0140 DEFFN'62
   : X1,Y1=0
   : PLOT  <,,R>
   : RETURN
0200 DEFFN'31
   : SELECT P
   : COM CLEAR  P$
   : $CLOSE
   : LOAD DC T "START"
0205 DEFFN'20
   : PLOT  <,,HEX(03)>
   : RETURN
0249 REM % CREATE CONFETI
0250 DEFFN'64
0252 FOR C6=1 TO 12
   : ON C(C6,2)+1 GOSUB 260,270,275
   : NEXT C6
0253 RETURN
0259 REM CREATE
0260 C(C6,1)=T1
0265 IF RND(1)>.5 THEN C(C6,2)=1
   : ELSE C(C6,2)=2
0267 RETURN
0269 REM MOVE BOX
0270 GOSUB '63(C6)
   : RETURN
0274 REM MOVE STREAMER
0275 GOSUB '65(C6)
   : RETURN
0299 REM %MOVE BOX
0300 DEFFN'63(I9)
0305 PLOT  <,,R>,<,,HEX(E2)>,<800*(I9-1)/12,C(I9,1),U>
0310 PLOT  <B1,0,D>,<0,-B1,D>,<-B1,0,D>,<0,B1,D>
0315 C(I9,1)=C(I9,1)-F1
   : IF C(I9,1)>B1/2 THEN 320
   : C(I9,2)=0
   : RETURN
0320 PLOT  <,,HEX(E1)>,<0,-F1,U>
0325 PLOT  <B1,0,D>,<0,-B1,D>,<-B1,0,D>,<0,B1,D>
0330 RETURN
0339 REM %MOVE STREAMER
0340 DEFFN'65(I9)
0345 PLOT  <,,R>,<,,HEX(E2)>,<800*(I9-1)/12+B1,C(I9,1),U>
0350 GOSUB 390
0355 PLOT  <,,HEX(E1)>
0360 FOR S9=1 TO 5
   : GOSUB 390
   : NEXT S9
0365 C(I9,1)=C(I9,1)-3*F1
   : IF C(I9,1)<B1/2 THEN C(I9,2)=0
0370 RETURN
0389 REM STREAMER SEGMENT
0390 PLOT  <B1/2,-F1/2,D>,<B1/2,-F1/2,D>,<-B1/2,-F1/2,D>,<-B1/2,-F1/2,D>,<-B1/
     2,-F1/2,D>,<B1/2,-F1/2,D>
0395 RETURN
0399 REM %PUT UP MESSAGE
0400 DEFFN'66(I9)
   : IF RND(1)<.3 THEN 490
0405 PLOT  <,,R>,<,,HEX(E2)>,<M(I9,1),M(I9,2),STR(M$(M(I9,3)))>
0410 M(I9,1)=700*RND(1)
   : M(I9,2)=T1*RND(1)
   : M(I9,3)=M*RND(1)+1
0415 PLOT  <,,R>,<,,HEX(E1)>,<M(I9,1),M(I9,2),STR(M$(M(I9,3)))>
0420 RETURN
0490 IF M(I9,3)=1 THEN RETURN
0495 PLOT  <,,R>,<,,HEX(E2)>,<M(I9,1),M(I9,2),STR(M$(M(I9,3)))>
   : RETURN