Dicey LLvLYDICEY by Brian D Cook from ZX Computing Aug/Sep'85 0:7:.5,3:.353333,0::10 ,3;3;1;"Do you want instructions?";12 ,6;"(press 'y' or 'n')" =""5 123658j\,0:="y"9100#:8  92706$ 1:0:7: Q10 ,0;1;1;6;"The board is now being set up..." #9905&:9900&: graphics  7t(5):r(5):z$(6):t$="\/":b$="/\" ]d(5,2,1):i=15:n=12:p:d(i,n,1)=p:n:i "1board co-ords & initial counter display #y(9 ):x(13 ) (.i=08:y(i+1)=2*i:i 2Ui=17:x(i)=2*i:i:i=813 :x(i)=2*i+1:i play=1go=-13600:5000:5500| m=03106 n=110 2400` 3500 n H21,0;1;6;" SECOND ROLL " %play=2go=13000 >play=1go=-13600:5000:5500| m=03106 n=110  2400` " 3500 'n ,H21,0;1;6;" THIRD ROLL " 6 3600 ;&play=1go=-16300 @21,0;x$ J/#1;6;"Press any key to continue" T 0: ^go=-1370r hMplay=21;21,0;" PLAYER ONE " iMplay=11;21,0;" SPECTRUM " m 70F rMplay=22;21,0;" PLAYER TWO " sMplay=12;21,0;" YOURSELF " | 70F dice & counter plotting i=15:d(i,1,1),d(i,2,1):16,0:0,-16:-16,0:0,16:1;0;4;19,6*(i-1);i;"-":i i=19 i=e1i=e2i i=10 2040 I1;1;6;y(i),x(f(i));t$;y(i)+1,x(f(i));b$:i  e1e2  disp1=disp1*go:disp2=disp2*go  f(e1)=f(e1)+disp1 f(e1)<1f(e1)=1  f(e1)>13 f(e1)=13 *J1;1;6;y(e1),x(f(e1));t$;y(e1)+1,x(f(e1));b$ 4e2 >f(e2)=f(e2)+disp2 Hf(e2)<1f(e2)=1 R f(e2)>13 f(e2)=13 \J1;1;6;y(e2),x(f(e2));t$;y(e2)+1,x(f(e2));b$ f `reset dice values j.i=1m:r(t(i))=1+(*6):i t.01z# =,(*10 ) ~ re-roll +r$="":"Enter y if O.K. or n if not ";r$ r$"y"r$"n"3000 r$="y"3106 !"How many dice for re-roll? ";m 'm=m:m<1m>53030 Q#1;1;2;7;"Enter the re-roll dice numbers":125} =i=1m:"Dice # ";i;" for re-roll? ";t(i):t(i)=t(i) 't(i)<1t(i)>53050 i: print dice values Ji=15:19,6*i-3;7;0;r(i):i  sort dice values (n=14:i=15-n >r(i)12 total<233995 stotal>25high=3 x-total>22total<26high=2 }total<10 low=3 +total>9 total<13 low=2 #x$(1)32 3985  high or low 4010: combination decision &play=1go=-13994 y21,0;"You now have a choice...........":200:21,0;"Hi/Lo or ";x$(122);"?" "'hl' for Hi/Lo or 'x' ";r$ r$"hl"r$"x"3990 r$="hl"4010 run :i=14:r(i)r(i+1)+13998 i disp1=(3r(1)=6)+(2r(1)=5):e1=7:x$="A "+("HIGH"r(1)=6)+("LOW"r(1)=5)+" RUN" 9x$(1)=32 x$=" NOTHING OF ANY VALUE!"  -x$=("HIGH OF "high)+("LOW OF "low)+total ,disp1=(highhigh)+(lowlow):disp2=0 -e1=(8high)+(9 low):e2=0   win check a=0:b=0 i=19 f(i)<4a=a+1 f(i)>10 b=b+1 i !a>2b>24575  i=120 ~play=221,5;1;1;1;6;"PLAYER "+("ONE"a>2)+("TWO"b>2)+" HAS WON" play=121,5;1;1;1;6;("SPECTRUM HAS WON!!!"a>2)+("YOU WIN! WELL DONE."b>2) .01z# =,i:i *r$="":"Another game? ('y' or 'n') ";r$ r$=""4590 r$="y"46604  "r$="":"STOP? ('s' or 'n') ";r$ r$=""4620   r$="s" * 4590 4:"You now have the option to "''"change the game mode. "''"Firstly enter ""1"" or ""2"" for"''"the number of players then (if"''"you are playing the Spectrum)"''"enter ""-1"" if you wish to go"''"first, otherwise enter ""1""." >"One or Two players? ";play H3play=play:play<1play>24670> Rplay=260< \$"""-1"" to go first, or ""1"" ";go f8go=go:go=0go>+1go<-14700\ p 60< set priority marker $p(9 ):a1=0:a2=0 =i=19 : any counters in red areas? f(i)<4a1=a1+1 f(i)>10 a2=a2+1 i #a12a225210Z  b1=7 i=19 %f(i)3b1=f(i):b2=i i b1=75130  b2<7p(b2)=1:  p(b2)=b2:  b1=14 i=16 &f(i)10 b1=f(i):b2=i (i:b1=145180< 2p(b2)=1: <i=79 F&f(i)10 b1=f(i):b2=i Pi:p(b2)=b2: Za125280 d b1=14 ni=19 x%f(i)3b1=f(i):b2=i i b27p(b2)=b2: p(b2)=1: a225380 a2=0:i=79 f(i)>10 a2=a2+1 i:a2<25350 i=79 f(i)>10 p(i)=i i:  b1=14:i=16 &f(i)>10 f(i)15640:run not worthwhile e1=73106 8e1=0e2=0m=1:t(1)=5: 4p(7)75640:run not worthwhile i=14 $r(i)=e1m=1:t(1)=i: i @p(8)8total<205720X:high not wwhile total>235690: i=35 &r(i)<46210B 0 :i=45 Dr(i)<36210B N X@p(9 )9 total>155800:low not w'while btotal<12 5770 li=13 vr(i)>36210B i: i=12 r(i)>26210B  )disp1=1disp2=15860 'disp115980\:not a pair i=15 #r(i)e1p(e1)=06210B -p(e1)>1m=4:i>1t(i)=i i: 4p(e1)>1p(e2)>15910:2 pair NG Vp(e1)=0p(e2)=059404:2 pair OK, re-roll odd '2 pair, re-roll 1 pair & odd i=15 9r(i)e2p(e2)=0r(i)e1p(e1)=06210B  i: i=15  r(i)=e1r(i)=e26210B *i: 4i=15 >r(i)e1r(i)e26210B Ri: \4disp12disp226110:not three f)disp1=1disp2=16050 pi=15 ue1=06025 z1disp1=2f(e1)>5r(i)e16210B #p(e1)=3r(i)=e16210B >f(e1)<6p(e1)<3r(i)e1m=1:t(1)=i e2=06045 1disp2=2f(e2)>5r(i)e26210B #p(e2)=3r(i)=e26210B >f(e2)<6p(e2)<3r(i)e2m=1:t(1)=i i:  full house "e1=0e2=03106 i=15 )p(e1)>1p(e2)>16210B 1p(e1)>1p(e2)=0r(i)e26210B 1p(e1)=0p(e2)>1r(i)e16210B i: Hdisp13disp23e1>66150: not four i=15 9r(i)e1disp1=3r(i)e2disp2=36210B i: ]high=2low=3disp1=4e1=7p(7)=03106:no re-roll Bhigh=2p(8)=0m=1:t(1)=5: Alow=2p(9 )=0m=1:t(1)=1: $m=5:i=15 . t(i)=i:i: Bm=m+1:t(m)=i L highlow 2f(8)<4highf(9 )<4low >disp1=2disp2=1(f(8)-high)>3high <disp1=2disp2=1(f(9 )-low)>3low >disp1=1disp2=2(f(8)-high)>3high <disp1=1disp2=2(f(9 )-low)>3low !disp1>highhighdisp1>lowlow (f(e1)-disp1)<4 e2=06350 (f(e2)-disp2)<4 +f(e1)>10 f(8)<10 high e2=06360 +f(e2)>10 f(8)<10 high *f(e1)>10 f(9 )<10 low e2=06370 *f(e2)>10 f(9 )<10 low 4010: #' graphics #(3i=017:6;i,14;" ":i #-<i=017:6;i,15;(144+i):i #2>i=017:2;i,2;z$;i,23;z$:i #<>i=017:4;i,8;z$;i,17;z$:i #P15,31:i=14:216,0:0,16:-216,0:0,16:i:216,0:0,16:-216,0 #Zi=2142:i*8-1,175:0,-143:i:i=17292:i*8-1,175:0,-143:i #_play=19070n# #dKi$="PLAYER ONE":i=413 :1;i,0;i$(i-3):i #iXi$="PLAYER TWO":i=413 :2;i,30;i$(i-3):i:9080x# #nIi$="SPECTRUM":i=411 :1;i,0;i$(i-3):i #sJi$="YOURSELF":i=411 :2;i,30;i$(i-3):i #x^go=115,0;7;0;1;"X";15,30;7;" " #}_go=-115,0;7;" ";15,30;7;0;1;"X" # #instructions #1:6:1:: #"The purpose of this game is to"''"manoeuvre three counters into"''"the red area at your end of the"''"board. Your opponent will, in"''"turn, do likewise. There are 9"'' #"counters, initially placed down"''"the centre of the board, one in"''"each of lanes 1-6, R, H & L. You"''"will normally be able to move 1"''"or 2 counters on each turn. You"''"do this by throwing five dice." # 9300T$ #"After the first roll of the dice"''"you will be able to re-roll as"''"many dice as you wish twice more"''"-you can re-roll a die on your"''"second re-roll that you had kept"'' #"on your first re-roll. You will"''"be aiming for combinations that"''"will move the counters to your"''"advantage - possibly getting"''"counters into your red area or"''"out of your opponent's red area." # 9300T$ #ܬ"Combinations that will move"''"counters are:"''" two or more of the same die"'" (moves lane number of dice"'" value)"''" a run of all five dice"'" (moves 'R' lane)" #'" a high score (moves 'H' lane)"''" a low score (moves 'L' lane)"''"Press any key to see how many"''"squares the counters can move." #10:.25~,3:.15~,0: #17;"A Pair";26;"1"''12 ;"3 of a Kind";26;"2"''9 ;"Four of a Kind";26;"3"''9 ;"Five of a Kind";26;"4"''9 ;"High Run (2-6)";26;"3"'' $10 ;"Low Run (1-5)";26;"2"''8;"High Score(>25)";26;"3"''6;"High Score(23-25)";26;"2"''8;"Low Score (<10)";26;"3"''6;"Low Score (10-12)";26;"2"''"Note that 2 counters can be"'"moved with 2 Pair or Full House." $ 9300T$ $'14;"NOTES";1,14;1;"_____"''"1) You cannot combine moves in"'" the High & Low lanes with"'" moves in the 1-6 lanes."''"2) A counter cannot go beyond"'" the outer red rank - any"' $d" surplus moves are wasted."''"3) A player's turn is shown by ";1;7;0;"X"'' $"X"4) Dice #s are shown in black"'" on green - eg. ";0;4;"5":9300T$ $'"When the board is set up"''"the counters are initially"''"superimposed over the central"''"lane markings, but once one is"''"moved it appears as:"''15;0;6;"\/";1;15;6;"/\" $,"________________________________"''''"If you wish to see these"''"instructions again press ""i"","''"otherwise press any other key.":0:="i"9110# $61:1:6::"If you wish to play the Spectrum"''"enter ""1"", otherwise decide now"''"who is to go first and enter ""2"""''"(blow on the keyboard for luck)." $7"Enter ""1"" or ""2"" ";play $83play=play:play<1play>292717$ $;play=29290J$ $@:"Please note that when the"''"Spectrum has decided which"''"dice to re-roll it will"''"re-arrange the dice in numerical"''"order immediately before"''"starting to re-roll them."''' $EC"If you wish to go first enter"''"""-1"", otherwise enter ""1""." $F"Enter ""-1"" or ""1"" ";go $G8go=go:go=0go>+1go<-19286F$ $JP.25~,3:.15~,0:.15~,0:.25~,3:: $TY#1;"PRESS ANY KEY TO CONTINUE":0:.25~,3:.15~,0:: &HwUDGs AB CD EF GH IJ KL MN OP QR &$i=018*8-1 &a & "a"+i,a &i & &0,8,24,568,120x,88X,88X,24,24,24,24,24,24,126~,126~,0: A&B=1 &0,0,60<,126~,70F,2,6,12 ,12 ,24,24,480,480,126~,126~,0: C&D=2 &0,126~,126~,6,12 ,24,480,96`,124|,126~,6,6,102f,124|,120x,0: E&F=3 &0,6,14,30,546,102f,102f,102f,102f,127,127,6,6,6,6,0: G&H=4 &Ş0,126~,126~,96`,96`,96`,126~,126~,6,6,6,12 ,24,112p,96`,0: I&J=5 &ʞ0,6,12 ,24,24,480,480,120x,108l,108l,102f,102f,546,60<,24,0: K&L=6 &ϣ0,568,124|,102f,102f,108l,108l,120x,112p,120x,108l,108l,102f,102f,102f,0:M&N=R &Ԥ0,102f,102f,102f,102f,102f,102f,126~,126~,102f,102f,102f,102f,102f,102f,0:O&P=H &ٞ0,96`,96`,96`,96`,96`,96`,96`,96`,96`,96`,96`,96`,126~,126~,0: Q&R=L &p20,28,68D,28,116t,28,164,28,212,28:dice plot coords