Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 75 print "do you want to play?"
- 80 input q$
- 85 if q$ = "no" then end
- 100 graphics 0
- 200 graphics pensetup 5,5
- 300 moveto 100,0 : lineto 100,300
- 400 moveto 200,0 : lineto 200,300
- 500 moveto 0,100 : lineto 300,100
- 600 moveto 0,200 : lineto 300,200
- 700 graphics button "O1",0,0,20,20,"MOVETO 50,50 : GRAPHICS CIRCLE 70 : let
- d=1"
- 800 graphics button "X1",20,0,20,20,"MOVETO 25,25 : LINETO 75,75 : MOVETO
- 75,25 : LINETO 25,75 : let d=2"
- 900 graphics button "O2",100,0,20,20,"MOVETO 150,50 : GRAPHICS CIRCLE 70 : let
- g=1"
- 1000 graphics button "X2",120,0,20,20,"MOVETO 125,25 : LINETO 175,75 : graphics
- MOVETO 175,25 : LINETO 125,75 : let g=2"
- 1100 graphics button "O3",200,0,20,20,"MOVETO 250,50 : GRAPHICS CIRCLE 70 :
- let a=1"
- 1200 graphics button "X3",220,0,20,20,"MOVETO 225,25 : LINETO 275,75 :
- GRAPHICS MOVETO 275,25 : LINETO 225,75 : let a=2"
- 1300 graphics button "O4",0,100,20,20,"MOVETO 50,150 : GRAPHICS CIRCLE 70 :
- let e=1"
- 1400 graphics button "X4",20,100,20,20,"MOVETO 25,125 : LINETO 75,175 : graphics
- moveto 75,125 : lineto 25,175 : let e=2"
- 1500 graphics button "O5",100,100,20,20,"MOVETO 150,150 : GRAPHICS CIRCLE
- 70 : let h=1"
- 1600 graphics button "X5",120,100,20,20,"MOVETO 125,125 : LINETO 175,175 :
- MOVETO 175,125 : LINETO 125,175 : let h=2"
- 1700 graphics button "O6",200,100,20,20,"MOVETO 250,150 : GRAPHICS CIRCLE
- 70 : let b=1"
- 1800 graphics button "X6",220,100,20,20,"MOVETO 225,125 : LINETO 275,175 :
- MOVETO 275,125 : LINETO 225,175 : let b=2"
- 1900 graphics button "O7",0,200,20,20,"MOVETO 50,250 : GRAPHICS CIRCLE 70 :
- let f=1"
- 2000 graphics button "X7",20,200,20,20,"MOVETO 25,225 : LINETO 75,275 :
- MOVETO 75,225
- : lineto 25,275 : let f=2"
- 2100 graphics button "O9",100,200,20,20,"MOVETO 150,250 : GRAPHICS CIRCLE
- 70 : let i=1"
- 2200 graphics button "X9",120,200,20,20,"MOVETO 125,225 : LINETO 175,275 :
- MOVETO 175,225 : LINETO 125,275 : let i=2"
- 2300 graphics button "O0",200,200,20,20,"MOVETO 250,250 : GRAPHICS CIRCLE
- 70: LET c=1"
- 2400 graphics button "X0",220,200,20,20,"MOVETO 225,225 : LINETO 275,275 :
- MOVETO 275,225 : LINETO 225,275 : let c=2"
- 2500 if a = 1 and b = 1 and c = 1 then graphics moveto 250,50 : lineto 250,250 : let w$
- = "O"
- 2510 if a = 2 and b = 2 and c = 2 then graphics moveto 250,50 : lineto 250,250 : let w$
- = "X"
- 2520 if d = 1 and e = 1 and f = 1 then graphics moveto 50,50 : lineto 50,250 : let w$
- = "O"
- 2530 if d = 2 and e = 2 and f = 2 then graphics moveto 50,50 : lineto 50,250 : let w$
- = "X"
- 2540 if g = 1 and h = 1 and i = 1 then graphics moveto 150,50 : lineto 150,250 : let w$
- = "O"
- 2550 if g = 2 and h = 2 and i = 2 then graphics moveto 150,50 : lineto 150,250 : let w$
- = "X"
- 2560 if d = 1 and g = 1 and a = 1 then graphics moveto 50,50 : lineto 250,50 : let w$
- = "O"
- 2570 if d = 2 and g = 2 and a = 2 then graphics moveto 50,50 : lineto 250,50 : let w$
- = "X"
- 2580 if e = 1 and h = 1 and b = 1 then graphics moveto 50,150 : lineto 250,150 : let w$
- = "O"
- 2590 if e = 2 and h = 2 and b = 2 then graphics moveto 50,150 : lineto 250,150 : let w$
- = "X"
- 2600 if f = 1 and i = 1 and c = 1 then graphics moveto 50,250 : lineto 250,250 : let w$
- = "O"
- 2610 if f = 2 and i = 2 and c = 2 then graphics moveto 50,250 : lineto 250,250 : let w$
- = "X"
- 2620 if d = 1 and h = 1 and c = 1 then graphics moveto 50,50 : lineto 250,250 : let w$
- = "O"
- 2630 if d = 2 and h = 2 and c = 2 then graphics moveto 50,50 : lineto 250,250 : let w$
- = "X"
- 2640 if a = 1 and h = 1 and f = 1 then graphics moveto 50,250 : lineto 250,50 : let w$
- = "O"
- 2650 if a = 2 and h = 2 and f = 2 then graphics moveto 50,250 : lineto 250,50 : let w$
- = "X"
- 2660 if w$ = "X" or w$ = "O" then 3500
- 2700 print "Type DONE when you are done with your turn and END when you want to
- end"
- 2800 input t$
- 2900 if t$ = "DONE" then 2500
- 3000 if t$ = "END" then end
- 3500 print "The ";w$;"'s Win!"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement