Jos : Special delivery

Discussions related to graphics (2D and 3D), animation and games programming
jgroenendaal
Posts: 28
Joined: Fri 15 Nov 2024, 14:40

Jos : Special delivery

Post by jgroenendaal »

Hello everyone,

I’ve decided to dive back into game dev with BBC BASIC! Last year, I attempted a few other projects that didn't quite take off, so now I want to start with something simpler but hopefully fun.

The idea is a prequel to one of my previous games, Joop. This time, you play as a postman being hunted by a giant pig. Since it's a prequel, I’m going for a retro aesthetic: low resolution and a 4-colour palette (MODE 1), just like a classic BBC Micro platformer.

I originally came up with this idea when I was a kid learning BASIC on my Electron and BBC Master, but I didn't have the coding knowledge to pull it off back then.

My additional plan is to make it compatible with the A3000. I remember Joop ran at around 12fps on that machine, but I think I can get this one running at a smooth 25-50fps on an ARM2 Acorn. For now, though, I am doing the main development using BBCSDL.

Image
Ric
Posts: 262
Joined: Tue 17 Apr 2018, 21:03

Re: Jos : Special delivery

Post by Ric »

Have you got any links to YouTube videos or any way of showing the game in its current form?
Kind Regards Ric.

6502 back in the day, BB4W 2017 onwards, BBCSDL from 2023
jgroenendaal
Posts: 28
Joined: Fri 15 Nov 2024, 14:40

Re: Jos : Special delivery

Post by jgroenendaal »

Hey Ric,

Actually I never done that before.
https://www.youtube.com/watch?v=JC5I7qQJXkI
It's a very early version, so I'm still struggling a bit with the playability. It aims to play closely to Chuckie Egg and Magic Mushrooms, if you are familiar with those classic BBC Micro games.

I used a tool called ScreenRec to capture this footage, but the compression is terrible. I'm sure there are better tools out there for recording YouTube videos, so I'll have to look into that.
jgroenendaal
Posts: 28
Joined: Fri 15 Nov 2024, 14:40

Re: Jos : Special delivery

Post by jgroenendaal »

Hello,

I’m writing to share an update on my current project. After reviewing the progress, I’ve decided to either pause development, abandon or pursue a complete restart.

While the concept was exciting, the execution hasn't quite reached the standard I anticipated. You can test the online build via the link below to see the current state for yourself.

Controls & Gameplay:
  • Navigation: Use the Spacebar for menus and instructions.
  • Gameplay: Use Z, X, *, /, and Enter.
Currently, the instructions include only the full storyline, which I feel is the strongest part of the project. While the 4-color, low-resolution (8x8/8x16) aesthetic was intentional, I’m not satisfied with the final look. There are some collision detection glitches, but the first four levels are playable. Level 4 introduces the first of four moving monsters; however, the "Giant Pig" boss in Level 5 is not yet implemented.

I did successfully port the game to BBC Basic on RISC OS. It runs smoothly on ARM2 hardware with up to five monsters on a level, though performance may dip once the final bugs are fixed and ENVELOPE sound effects are added some way.

I suspect switching to MODE 9 ( 320 x 256 and 16 colours) with larger graphics might improve performance by allowing me to limit active monster calculations. I am currently weighing whether to continue with these constraints or restart the project without the BBC Micro limitations to allow for more colors and higher-resolution assets.

You can try it here.
https://wasm.bbcbasic.net/bbcsdl.html?a ... g2/jos.bbb

-
Jeroen
Richard Russell
Posts: 582
Joined: Tue 18 Jun 2024, 09:32

Re: Jos : Special delivery

Post by Richard Russell »

jgroenendaal wrote: Tue 03 Feb 2026, 18:02 I’ve decided to either pause development, abandon or pursue a complete restart.
I'm sorry to hear that. However I haven't properly understood what the problem actually is. Is it speed? When running in a browser, performance is inevitably poorer than using the native CPU because there are two levels of translation happening: firstly BBCSDL is interpreting your BASIC source code as Web Assembly instructions, and then your browser is interpreting the Web Assembly code as native CPU instructions.

One particular thing which concerns me is your reference to running your program in BBC Basic on RISC OS. BBC BASIC's native graphics are never going to be fast enough for a high-performance game, you really must use an optimised game library such as David Williams's GFXLIB2 for BBC BASIC for Windows or gfxlib.bbc for BBC BASIC for SDL 2.0.

Those two libraries offer a similarly large performance boost compared with native BBC BASIC graphics, which is precisely why they were written.
The gfxlib documentation contains quite a lot of information on how to optimise your code for the best speed, particularly in Section 4: Performance tuning. As far as I know there is not a comparable library available for RISC OS.

So my recommendation would be either to abandon RISC OS as a target platform, or to limit your expectations if you must support it and are therefore limited to BBC BASIC's native graphics. Acorn's VDU stream approach to graphics is ingenious and flexible, but forcing everything into such a narrow 'byte-wide pipe' is never going to give good performance.
jgroenendaal
Posts: 28
Joined: Fri 15 Nov 2024, 14:40

Re: Jos : Special delivery

Post by jgroenendaal »

Richard,

Thank you for your comments.

I use the gfxlib on the SDL version, while the RISCOS version uses the regular Acorn sprite format.
I only used the same way to do the game play calculations and reading the levels and other data.

However, I could win performance on an old RISCOS computer if the game play calculations where based on the RISCOS coordinates, rather than the more logic SDL gfxlib coordinates as a base, but for my test I was happy enough to see the performance.

The problem is not based on the performance, it's based by the fact the game itself is not playing as satisfied as what I had in mind.
jgroenendaal
Posts: 28
Joined: Fri 15 Nov 2024, 14:40

Re: Jos : Special delivery

Post by jgroenendaal »

Ok, I decided that I will do another approach with more resolution graphics.
It will technically be on the same level as the original Joop. Holding 16 colours and a resolution of 320x256. The tiles will be 24x24 and the character will be 24x36.

I hope it's is a bit better than my previous attempt with the 8x8 tiles ( and 8x16 for the character )
The preview images are unscaled:

New title screen vs previous one.
Image

GIF of the running cycle of Jos.
Image

Demo screenshot taken from the new level editor.
Image

Anyway, the game probably gets more graphics, and I had in plan. I am also 'inviting' a way to make the game more precisely than my previous tiled platform games like Joop, Emotions and Vapiki while it takes less calculations during gameplay. I will show next time what this approach would be ( and if it works )