• Breakout Game

    From Francois LE COAT@21:1/5 to All on Fri May 1 23:22:02 2020
    Hi,

    Here is the first Breakout Game I typed with a friend, on the ZX81 ...

    <http://eureka.atari.org/OrdinateurIndividuel38.pdf>

    Does somebody have the experience of typing such a program with
    `ZEsarUX.app` 8.0 I have on the Macintosh ? Will I have to type
    it, or somebody else already typed it ? I know this program
    works, because I played it, about 40 years ago =)

    Thanks by advance for any help.

    Best regards,

    --
    François LE COAT
    Author of Eureka 2.12 (2D Graph Describer, 3D Modeller) http://eureka.atari.org/

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Duncan Snowden@21:1/5 to Francois LE COAT on Sat May 2 17:53:29 2020
    On Fri, 1 May 2020 23:22:02 +0200
    Francois LE COAT <lecoat@atari.org> wrote:

    Here is the first Breakout Game I typed with a friend, on the ZX81 ...

    I managed to OCR your PDF, tidy it up, and with the help of
    ZXText2P[1], get it into an emulator. Unfortunately, I think there
    might still be a typo in the machine code. I certainly missed a couple
    in the BASIC at first. It doesn't crash the machine, surprisingly, but
    it's definitely not working properly.

    In days gone by, I'd probably have been flamed for posting an entire
    listing, but there's hardly anyone around here any more, and it's not
    very long, so screw it. I had to change the graphics characters to hash
    signs (which ZXText2P turns into pound symbols, for some reason) but
    they're easy enough to change back in the emulator.

    1 REM AUTEUR REMY HEAULME
    2 REM ******MUR******
    5 FAST
    10 LET DFILE=PEEK 16396+2S6*PEEK 16397
    20 LET R=3E4
    30 LET C$="2A206E3A336EBC300A3A326EBD3004010100C916001E002A226EAFBE28051601CD4A762A246EBE28051E01CD4A76BA2011BB200EED4B266E094E282D16015ACD4A76BA280F3A266EED4432266E3A276E2F32276EAFBB280F3A286EED4432286E3A296E2F32296E18112A266EED4B286E09ED4B206EC50922206E2A266EE
    D4B206E0922226E2A286E0922246E7A8357AFBA2007E13600606936800E0A06000420FD0D20F83A316E47AFB83804010000C93A2540473EF7B820041EFD18073EEFB8204E1E033A2A6EF58306FEB820023E01061FB820023E1C211111222540C148F506002A2B6EE50970237023702A2D6EE5097023702370E1D1F1D54F322A
    6E1680097223722372E1097223722372C330753EFDB8C23075010100C93E08BE2006360021316E35AFC9"
    49 FOR X=1 TO LEN C$-1 STEP 2 50 POKE R+INT ((X-1)/2), (CODE C$(X) -28) *16+CODE C$ (X+1) -28 60 NEXT X
    70 LET N=0
    71 CLS
    75 PRINT "QUEL NIVEAU ?","1 TRES BON",,"2 BON",,"3 MOYEN",,"4 DEBUTANT"
    80 PAUSE 4E4
    85 LET Z=(CODE INKEY$-28) *3+8
    90 POKE 30155,Z
    100 CLS
    110 LET a=28192
    120 LET B=INT (RND*30) +2+DFILE+.33*6
    130 POKE A,B-256*INT (B/256)
    135 POKE a+1,INT (B/256)
    140 POKE A+2,B+1-256*INT ((B+1)/256)
    145 POKE A+3,INT ((B+1) /256)
    150 POKE A+4,B+33-256*INT ((B+33) /256)
    155 POKE A+5,INT ((B+33) /256)
    160 POKE A+6,1
    165 POKE A+7,0
    170 POKE A+8,33
    175 POKE A+9,0
    185 POKE A+10,16
    190 LET B=DFILE+33*21+1
    195 POKE A+11,B-256*INT (B/256)
    200 POKE A+12, INT (B/256)
    205 LET B=DFILE+33*14+1
    210 POKE A+13,B-256*INT (B/256)
    215 POKE A+14, INT (B/256)
    220 POKE A+17,90
    225 LET B=DFILE+33*14+3
    230 POKE A+18,B-256*INT (B/256)
    235 POKE A+19, INT (B/256)
    240 SLOW
    250 REM DESSIN DE L ECRAN
    260 PRINT "################################"
    280 FOR X=0 TO 21
    290 PRINT AT X,0;"#""; TAB 31;"#"
    300 NEXT X
    310 FOR Y=5 TO 7
    340 PRINT AT Y,1;"##############################"
    350 NEXT Y
    360 PRINT AT 14,16;"###";AT 21,16;"###"
    370 REM DEBUT DU PROGRAMME DE CALCUL
    400 LET A=USR 30000
    410 IF A THEN GOTO 500
    420 LET N=N+1
    430 GOTO 100
    500 LET P=N*90+90-PEEK 28209
    510 PRINT AT 10,0;"VOUS AVEZ ";P;" POINT";
    520 IF P>1 THEN PRINT "S"
    530 PRINT AT 12,0;"AU NIVEAU ";(Z-8) /3
    540 PRINT AT 20,0; "APPUYEZ POUR UN AUTRE ESSAI"
    550 PAUSE 4E4
    560 GOTO 70

    [1] http://freestuff.grok.co.uk/zxtext2p/index.html

    --
    Duncan Snowden.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Francois LE COAT@21:1/5 to Duncan Snowden on Sat May 2 21:01:40 2020
    Hi,

    This is really kind of you to have prepared all this work for me.
    I will manage to make it work. I know I can, because it already worked.

    Bye for now,

    Duncan Snowden writes:
    Francois LE COAT wrote:
    Here is the first Breakout Game I typed with a friend, on the ZX81 ...

    I managed to OCR your PDF, tidy it up, and with the help of
    ZXText2P[1], get it into an emulator. Unfortunately, I think there
    might still be a typo in the machine code. I certainly missed a couple
    in the BASIC at first. It doesn't crash the machine, surprisingly, but
    it's definitely not working properly.

    In days gone by, I'd probably have been flamed for posting an entire
    listing, but there's hardly anyone around here any more, and it's not
    very long, so screw it. I had to change the graphics characters to hash
    signs (which ZXText2P turns into pound symbols, for some reason) but
    they're easy enough to change back in the emulator.

    1 REM AUTEUR REMY HEAULME
    2 REM ******MUR******
    5 FAST
    10 LET DFILE=PEEK 16396+2S6*PEEK 16397
    20 LET R=3E4
    30 LET C$="2A206E3A336EBC300A3A326EBD3004010100C916001E002A226EAFBE28051601CD4A762A246EBE28051E01CD4A76BA2011BB200EED4B266E094E282D16015ACD4A76BA280F3A266EED4432266E3A276E2F32276EAFBB280F3A286EED4432286E3A296E2F32296E18112A266EED4B286E09ED4B206EC50922206E2A266
    EED4B206E0922226E2A286E0922246E7A8357AFBA2007E13600606936800E0A06000420FD0D20F83A316E47AFB83804010000C93A2540473EF7B820041EFD18073EEFB8204E1E033A2A6EF58306FEB820023E01061FB820023E1C211111222540C148F506002A2B6EE50970237023702A2D6EE5097023702370E1D1F1D54F32
    2A6E1680097223722372E1097223722372C330753EFDB8C23075010100C93E08BE2006360021316E35AFC9"
    49 FOR X=1 TO LEN C$-1 STEP 2 50 POKE R+INT ((X-1)/2), (CODE C$(X) -28) *16+CODE C$ (X+1) -28 60 NEXT X
    70 LET N=0
    71 CLS
    75 PRINT "QUEL NIVEAU ?","1 TRES BON",,"2 BON",,"3 MOYEN",,"4 DEBUTANT"
    80 PAUSE 4E4
    85 LET Z=(CODE INKEY$-28) *3+8
    90 POKE 30155,Z
    100 CLS
    110 LET a=28192
    120 LET B=INT (RND*30) +2+DFILE+.33*6
    130 POKE A,B-256*INT (B/256)
    135 POKE a+1,INT (B/256)
    140 POKE A+2,B+1-256*INT ((B+1)/256)
    145 POKE A+3,INT ((B+1) /256)
    150 POKE A+4,B+33-256*INT ((B+33) /256)
    155 POKE A+5,INT ((B+33) /256)
    160 POKE A+6,1
    165 POKE A+7,0
    170 POKE A+8,33
    175 POKE A+9,0
    185 POKE A+10,16
    190 LET B=DFILE+33*21+1
    195 POKE A+11,B-256*INT (B/256)
    200 POKE A+12, INT (B/256)
    205 LET B=DFILE+33*14+1
    210 POKE A+13,B-256*INT (B/256)
    215 POKE A+14, INT (B/256)
    220 POKE A+17,90
    225 LET B=DFILE+33*14+3
    230 POKE A+18,B-256*INT (B/256)
    235 POKE A+19, INT (B/256)
    240 SLOW
    250 REM DESSIN DE L ECRAN
    260 PRINT "################################"
    280 FOR X=0 TO 21
    290 PRINT AT X,0;"#""; TAB 31;"#"
    300 NEXT X
    310 FOR Y=5 TO 7
    340 PRINT AT Y,1;"##############################"
    350 NEXT Y
    360 PRINT AT 14,16;"###";AT 21,16;"###"
    370 REM DEBUT DU PROGRAMME DE CALCUL
    400 LET A=USR 30000
    410 IF A THEN GOTO 500
    420 LET N=N+1
    430 GOTO 100
    500 LET P=N*90+90-PEEK 28209
    510 PRINT AT 10,0;"VOUS AVEZ ";P;" POINT";
    520 IF P>1 THEN PRINT "S"
    530 PRINT AT 12,0;"AU NIVEAU ";(Z-8) /3
    540 PRINT AT 20,0; "APPUYEZ POUR UN AUTRE ESSAI"
    550 PAUSE 4E4
    560 GOTO 70

    [1] http://freestuff.grok.co.uk/zxtext2p/index.html

    Best regards,

    --
    François LE COAT
    Author of Eureka 2.12 (2D Graph Describer, 3D Modeller) http://eureka.atari.org/

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Duncan Snowden@21:1/5 to Francois LE COAT on Sat May 2 22:49:07 2020
    On Sat, 2 May 2020 21:01:40 +0200
    Francois LE COAT <lecoat@atari.org> wrote:

    This is really kind of you to have prepared all this work for me.
    I will manage to make it work. I know I can, because it already
    worked.

    Not a problem. It's been a long time since I did anything on the ZX81,
    so I quite enjoyed the nostalgia. :) (And don't worry; it didn't take
    as long as you might think. Maybe a couple of hours in total. The OCR
    was surprisingly good.)

    I think I felt a certain affinity with your problem, because I've
    lost the first game I ever wrote. It *might* still be hanging around on
    a cassette somewhere, but I haven't been able to find it.

    Good luck! Let us all know how you get on.

    --
    Duncan Snowden.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Francois LE COAT@21:1/5 to Duncan Snowden on Tue May 5 00:10:27 2020
    Hi,

    Duncan Snowden writes:
    Francois LE COAT wrote:
    This is really kind of you to have prepared all this work for me.
    I will manage to make it work. I know I can, because it already
    worked.

    Not a problem. It's been a long time since I did anything on the ZX81,
    so I quite enjoyed the nostalgia. :) (And don't worry; it didn't take
    as long as you might think. Maybe a couple of hours in total. The OCR
    was surprisingly good.)

    I think I felt a certain affinity with your problem, because I've
    lost the first game I ever wrote. It *might* still be hanging around on
    a cassette somewhere, but I haven't been able to find it.

    Good luck! Let us all know how you get on.

    I've made good progress ...

    I translated "breakout.txt" sources that you gave, into "breakout.p".
    For that, I used <http://freestuff.grok.co.uk/zxtext2p/> and obtained :

    <http://eureka.atari.org/breakout.p>

    I corrected the sources, loading the ZX81 program with the emulator.
    The actual problem is the game can't be played. The breakout graphics
    are drawn, but the ball is not displayed. Nothing happens. The emulator
    is not crashed, but it is simply not happening anything ...

    I'm wondering whether the breakout game that we are speaking about, is
    a very special program. In facts, it includes "machine language" within.
    Maybe, that's just an hypothesis, the `ZEsarUX.app` 8.1.1 emulator that
    I'm using on the Macintosh, doesn't support "machine language" ...

    This breakout game was running perfectly on my ZX81, in 1982. But it
    doesn't seem to run on the emulator, about 40 years later. I don't
    understand, because I verified the sources several times, cautiously.

    Do you have a similar experience ?

    Thanks a lot for your kind helping.

    Best regards,

    --
    François LE COAT
    Author of Eureka 2.12 (2D Graph Describer, 3D Modeller) http://eureka.atari.org/

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Adam Sampson@21:1/5 to Francois LE COAT on Tue May 5 00:54:03 2020
    Francois LE COAT <lecoat@atari.org> writes:

    I corrected the sources, loading the ZX81 program with the emulator.
    The actual problem is the game can't be played. The breakout graphics
    are drawn, but the ball is not displayed. Nothing happens.

    One more typo: on line 10, 2S6 should be 256 (digit 5 not letter S). If
    I load your breakout.p and fix that line, it works!

    --
    Adam Sampson <ats@offog.org> <http://offog.org/>

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Francois LE COAT@21:1/5 to Adam Sampson on Tue May 5 11:33:35 2020
    Hi,

    Adam Sampson writes:
    Francois LE COAT writes:
    I corrected the sources, loading the ZX81 program with the emulator.
    The actual problem is the game can't be played. The breakout graphics
    are drawn, but the ball is not displayed. Nothing happens.

    One more typo: on line 10, 2S6 should be 256 (digit 5 not letter S). If
    I load your breakout.p and fix that line, it works!

    That's brilliant !

    I corrected the 'S' in '5' at line 10, and now Breakout Game runs :-)

    So, in 1982 I bought a magazine "L'Ordinateur Individuel" and a ZX81 ...

    <http://eureka.atari.org/OrdinateurIndividuel38.pdf>

    I typed the Breakout Game with a friend (he had a TV set) and it worked.

    <http://eureka.atari.org/breakout.p>

    This Breakout program learned me a lot, because the ZX81 manual is
    telling a very few about "machine language" ... I learned the Z80
    assembly language, and had a lot of fun with my Sinclair computer.

    Many thanks for your kind helping.

    Best regards,

    --
    François LE COAT
    Author of Eureka 2.12 (2D Graph Describer, 3D Modeller) http://eureka.atari.org/

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Duncan Snowden@21:1/5 to Adam Sampson on Wed May 6 01:12:00 2020
    On Tue, 05 May 2020 00:54:03 +0100
    Adam Sampson <ats@offog.org> wrote:

    Francois LE COAT <lecoat@atari.org> writes:

    I corrected the sources, loading the ZX81 program with the emulator.
    The actual problem is the game can't be played. The breakout
    graphics are drawn, but the ball is not displayed. Nothing happens.


    One more typo: on line 10, 2S6 should be 256 (digit 5 not letter S).
    If I load your breakout.p and fix that line, it works!

    Aha! I thought I'd caught all of those. And, now I see it, I think I
    know what happened: I was so worried about making sure the machine code
    was right, I probably just skimmed past everything before it.

    I couldn't understand why it *almost* worked. Usually when you get a
    typo in a hex listing like that, it crashes spectacularly. But it makes
    sense now.

    Great teamwork, folks! :)

    --
    Duncan Snowden.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Francois LE COAT@21:1/5 to Duncan Snowden on Wed May 6 17:40:29 2020
    Hi,

    Duncan Snowden writes:
    Adam Sampson wrote:
    Francois LE COAT writes:
    I corrected the sources, loading the ZX81 program with the emulator.
    The actual problem is the game can't be played. The breakout
    graphics are drawn, but the ball is not displayed. Nothing happens.

    One more typo: on line 10, 2S6 should be 256 (digit 5 not letter S).
    If I load your breakout.p and fix that line, it works!

    Aha! I thought I'd caught all of those. And, now I see it, I think I
    know what happened: I was so worried about making sure the machine code
    was right, I probably just skimmed past everything before it.

    I couldn't understand why it *almost* worked. Usually when you get a
    typo in a hex listing like that, it crashes spectacularly. But it makes
    sense now.

    Great teamwork, folks! :)

    I produced a video to show the work that have been done on Breakout Game

    <https://www.youtube.com/watch?v=N_Qi22JvcOU>

    In the comment I put the paper that is the sources of the game, that
    means "l'Ordinateur Individuel" #38 from June-July 1982, with the
    credit from its author. I also indicate the file "breakout.p" if
    somebody wants to play it, not being constrained to perform all the
    work again. In facts the Breakout is very funny, and has been designed originally by Steve Jobs and Steve Wozniak at ATARI, when it was
    directed by Nolan Bushnell, assembling electronics chips ...

    That game, fully playable, reminds me a lot, when I was a teenager =)

    Many thanks for your kind helping.

    Best regards,

    --
    François LE COAT
    Author of Eureka 2.12 (2D Graph Describer, 3D Modeller) http://eureka.atari.org/

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)