Random maze generator ;-)

صفحة 1/3
| 2 | 3

بواسطة Manuel

Ascended (19465)

صورة Manuel

23-08-2019, 00:29

10 SCREEN 1:KEY OFF:Z=RND(-TIME)
20 IF RND(1)>.5 THEN C=203 ELSE C=204
30 PRINTCHR$(C);
40 GOTO 20
Login أوregister لوضع تعليقاتك

بواسطة Grauw

Ascended (10768)

صورة Grauw

23-08-2019, 01:28

Let me just copy/paste (Cmd+V) that into the latest openMSX build… Wink

Looks nice! But use a European MSX Smile.

بواسطة ToriHino

Paladin (855)

صورة ToriHino

23-08-2019, 07:32

Also the favorite test program from this guy :)

بواسطة Manuel

Ascended (19465)

صورة Manuel

23-08-2019, 07:39

Grauw: I used copy to clipboard to be able to paste it here!

بواسطة hamlet

Scribe (4106)

صورة hamlet

23-08-2019, 08:55

I'm sure ya all know the
10 PRINT CHR$(205.5+RND(1)); : GOTO 10
maze. It's Commodore BASIC code, but portable to the MSX (I used 254.5 on an european machine).
Here is a nice book about.

بواسطة Manuel

Ascended (19465)

صورة Manuel

23-08-2019, 23:49

Sure, if you want it shorter:

10 SCREEN 1:KEY OFF:Z=RND(-TIME)
20 PRINTCHR$(203.5+RND(1));:GOTO20

(Although it's longer, I find line 10 worth it.)

بواسطة Louthrax

Prophet (2465)

صورة Louthrax

24-08-2019, 08:06

hamlet wrote:

I'm sure ya all know the
10 PRINT CHR$(205.5+RND(1)); : GOTO 10
maze. It's Commodore BASIC code, but portable to the MSX (I used 254.5 on an european machine).
Here is a nice book about.

OMG, the book is 309 pages, talking only about that 1 line of code :RNFF: Never heard about that one, but it's just hilarious !

بواسطة Manuel

Ascended (19465)

صورة Manuel

24-08-2019, 09:18

I honestly didn't know this trick was so popular, I had never seen it! Well, I guess GMTA....

بواسطة Louthrax

Prophet (2465)

صورة Louthrax

24-08-2019, 09:20

And the book mentionned above is indeed interesting to read Smile

بواسطة NYYRIKKI

Enlighted (6067)

صورة NYYRIKKI

24-08-2019, 10:52

Manuel wrote:

I honestly didn't know this trick was so popular, I had never seen it! Well, I guess GMTA....

Naah... It is just your memory that is failing... Look at your comments here:
https://www.msx.org/news/challenges/en/mrc-tenliner-challenge

... but don't worry... I've done this same mistake: :)
https://msx.org/forum/msx-talk/general-discussion/old-maze-g...

بواسطة Manuel

Ascended (19465)

صورة Manuel

24-08-2019, 11:11

Geez, I must be getting old... Crazy

صفحة 1/3
| 2 | 3