@Retrochallenge – 28 Years Later

Yahtzee Listing

Remember those halcyon days when you used to cycle excitedly to the local newsagent for the latest copy of your favourite computer magazine, rush home and spend three hours typing in a BASIC listing, fail to save it and then watch as your computer crashed due to an errant semi colon.

It's Been 28 Years

It’s Been 28 Years

Well I remember it especially vividly given that yesterday I spent an hour or so typing Yahtzee into my BBC Master.  That’s right, I took one for the team.  Unable to successfully transfer the code I’d worked on whilst waiting for the Master to arrive I opted for the manual option.

Jokes aside it was actually quite a pleasant experience.  The BBC keyboard is very responsive and the screen was actually pretty easy on my eyes (remembers hours playing M.U.D. on a C64 hooked up to a TV and the subsequent migraines.)

Of course editing the code is a tad more laborious on the BBC than with a modern editor but nevertheless I’ve continued to make improvements, mostly aesthetic.  I’ve banished the garish red dice and gone for more subtle black and white in a slightly less in your face graphics mode so everything’s a bit smaller.

Scores At Last

Scores At Last

I’ve also numbered the dice so it’s more obvious which ones you’re holding, realigned some of the text and cleared out a few other redundant lines of code.

I’ve also been looking at the possibility of using the Mode 7 – Teletext mode to render the dice.  I found a good resource here that covers Mode 7 and the Sixel graphical elements.  Incidentally Ceefax, the BBC’s text information service, introduced in 1974 was finally retired on the 23rd of October 2012 when the last remaining analogue TV symbol in the UK was switched off in Northern Ireland in favour of digital broadcasts.

Old & New

Old & New

When running Yahtzee on the actual Beeb rather than the emulator the previously reported issue with the lack of randomness of the dice throws has resolved itself.

Presumably the random number generator is now being correctly seeded and is as random as such computer generated things can be.

5 thoughts on “@Retrochallenge – 28 Years Later

  1. Good job! Better typing a listing into a BBC than a ZX81 or ZX Spectrum!
    Normally pseudo-random number generators are seeded from the timestamp stored in the internal clock, but I’m not sure a BBC has any concept of time?
    Anyway, it’s nice to see it on a ‘proper’ monitor – gotta love that overglow!

    Like

  2. That’s awesome! Good job on getting the Yahtzee program running on the BBC system. I love the glow of the CRT on the graphics and text.

    Like

  3. Cheers guys. Good point about the ZX81 and Spectrum! And yes it’s great using a CRT again I also love the glow, although photographing it is quite a challenge. I did attempt a video but the reflections were a nightmare and I couldn’t overcome the flickering.

    Like

  4. That would a be good approach Brendan. I know it’s also common to seed the generator using the system time but your method would be better, although I’m not sure I could pull it off with my limited abilities. I’m using IF RND(-TIME) with the emulator and it seems to be working (Urbancamo suggested that one,) haven’t tried it on the physical machine yet though.

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s