Ghostbusters (Activision)

developing/porting a new game or gaming framework? post in here!
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Ghostbusters (Activision)

Post by ChrisB »

This is a continuation of the thread here: viewtopic.php?f=67&t=27158

Added street names to the city. This has increased the size to 2167 bytes (from 1744). Given this includes some shared support code (sprite plot and screen line table will used throughout for example) and startup code (screen setup) I'm reasonably happy so far. There's no compression applied to the stored data yet (which would reduce the size by around 256 bytes - but would again include 256 bytes of "shared" decompression code).

With the screen mode defined as it is there's still around 14K of easily (keeping the OS) usable space at the moment.

I have also been looking at one of the PD tunes out there - and that would seem to fit in around 512 bytes (including player) with a little optimisation - possibly less if I get "clever" with the note storage.
gbcity.ssd
(3 KiB) Downloaded 41 times
cityletters.png
cityletters.png (9.74 KiB) Viewed 4917 times
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
Dave_E
Posts: 908
Joined: Fri Jun 16, 2006 1:55 pm
Location: Middlesbrough
Contact:

Re: Ghostbusters (Activision)

Post by Dave_E »

That looks soooooo good!
User avatar
Rob_hawk
Posts: 477
Joined: Mon Jul 12, 2021 6:50 pm
Location: Valmeinier, France
Contact:

Re: Ghostbusters (Activision)

Post by Rob_hawk »

Glad this has become a thing Chris :D =D>
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

This will probably take a while. Still playing around with things to see what works etc. However - here's another brief update. Attached ssd shows some of the map alternate colours (the logic was in the previous version I just didn't use it.)
Also I've added another sprite plot routine - this time for 1 bit sprites - for the ghosts which are single colour in most versions. This means I can use the top 8 colours to be ghost colours which means I can use EOR/OR plotting (not decided which).
gbcity.ssd
(3.5 KiB) Downloaded 38 times
cityghost.png
cityghost.png (10.15 KiB) Viewed 4752 times
I'll probably leave the map screen alone for a while now. The fight screen is going to need some work for taking apart the house graphics. I'm also thinking about revisiting the driving and how to make the tune as small as possible.
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
Dave_E
Posts: 908
Joined: Fri Jun 16, 2006 1:55 pm
Location: Middlesbrough
Contact:

Re: Ghostbusters (Activision)

Post by Dave_E »

Looking great!
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

I found a version of the theme tune on a PD disc (http://8bs.com/catalogue/bbc.htm disk 18). Most of the versions appear to be copies of each other with various images added.

I've converted this to assembler and attached it here. The original basic code is also on the disk (filename ghosts).

The original is just over 2K (even without some calls to one of the speech roms that are skipped and the Envelopes could easily be set up in a loader program). I wanted to reduce this for inclusion and this version is 887 bytes including code and data (but again excluding the envelope definitions). There's more that could be done but this is probably small enough - it will fit quite nicely in the language pages (&400-&7ff) with some space left over for the other interrupt processing I'm intending to do.

The BASIC code uses a number of data statements as up to 16 byte tune segments in groups of three for each of the channels. (Channel 0 is used in combination with channel 1to provide the lower bass notes). Obviously there is a lot of repetition here so I filtered these to only one instance of each line and produced a list of phrase numbers. To make indexing simpler I padded all the phrases to 16 characters. Even with this extra data only using the phrases reduced the size considerably.

I then looked at the data splitting the data up into smaller sections of 8, and then 4 notes. This increased the list size but reduced the overall number of phrases with 4 being the sweet spot (2 note phrases produces a larger overall size).

Lastly I needed to slightly reorganise the code to allow it to be called periodically so it needs to remember where in the loops it is between calls. The demonstration code attached calls the main routine after a *fx19 and then reads out where in the tune it is to provide a display but the code does work if you hang it off an event.
gbtune.ssd
(4.5 KiB) Downloaded 34 times
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
Rob_hawk
Posts: 477
Joined: Mon Jul 12, 2021 6:50 pm
Location: Valmeinier, France
Contact:

Re: Ghostbusters (Activision)

Post by Rob_hawk »

Love the tune Chris - great work :D
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

I've been looking at the "capture" screen and I've put together some programs to extract what I believe are the tiles that are used to build them. These have been reduced to 2 bits per pixel (like the city tiles) and similar and mirrored tiles removed. There are a (slightly scary) 112 tiles after this process which take up 1792 bytes. Now to work out how to organise these into houses...
tiles.png
tiles.png (7.97 KiB) Viewed 4433 times
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
fizgog
Posts: 618
Joined: Thu Jun 17, 2021 3:18 pm
Location: Nottinghamshire
Contact:

Re: Ghostbusters (Activision)

Post by fizgog »

Looking good as usual =D>

That's a lot of tiles to store, looks like you could use 1bit for some tiles that only use 2 colours to save on space.

I took a break from coding and disassembling

Wasn't sure what mode you are using for the capture screen, but I managed to get it down to 82 tiles using the Amstrad Version (could probably tweak it further to reduce the tile set)

Screenshot 2023-07-26 at 22.41.58.png
Pitfall, Gridrunner, Matrix: Gridrunner 2, LaserZone, AcornViewer, AcornPad
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

I'm basing on the C64 screens mostly - they seem slightly more detailed for some reason. The 112 tiles are (theoretically) all possible houses including GBHQ - but not the final Zuul building as yet.

The idea behind 2 bit is that each tile has 4 possible colours - but you can specify these as they are plotted onto a mode 2 screen. The same code plot code draws city blocks, and will at some point do the cars as well. This will allow houses to have more than 4 colours in total - see below.

I could go 1 bit for some tiles but then there's more decode and plot logic and my eventual intention is to compress the tiles as a block (where they go down to only 728 bytes) and decompress them into the "pavement" area on the screen and build from there.

As you can probably tell I'm not quite sure how this is going to fit together yet - there will need to be some other data associated with the blocks and I'm not quite sure what that will look like. And yes - that bottom stats bar would require a split mode...
examplehouse.png
examplehouse.png (5.46 KiB) Viewed 4393 times
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

Attached is a demo of some house drawing code. This can draw most of the house variants in the c64 game that I can see. The code and data combined is 4895 bytes but there are several optimisations that I can (and will) perform on this. Most notably none of the tile or car data is stored compressed. This is next on the list to do. There are also optimisations around the storage of the colour mapping palettes.

There is a small wrapper with instructions that allows you to play around with the combinations.
gbhouse.ssd
(6 KiB) Downloaded 29 times
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
Dave_E
Posts: 908
Joined: Fri Jun 16, 2006 1:55 pm
Location: Middlesbrough
Contact:

Re: Ghostbusters (Activision)

Post by Dave_E »

I actually thought a version of Ghostbusters for the BBC would never arrive... but seeing it actually being created in real time is somehow even better. I am so excited by the arrival of this game, I really think I need to think about getting myself some professional help.
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

Long way to go yet.... Initial addition of the compression routines brings the size down by over 1000 bytes. Next to redo the car in mode 2.
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
Dave_E
Posts: 908
Joined: Fri Jun 16, 2006 1:55 pm
Location: Middlesbrough
Contact:

Re: Ghostbusters (Activision)

Post by Dave_E »

Just as an aside, and completely by chance, I just found a link to the original Ghostbusters leaflet that spoke about versions for the BBC and Acorn back in the day...

http://www.digitpress.com/library/newsl ... nter84.pdf

Activision Fun Club Winter 84/5

This was the very 'magazine' that seven year old me had at school back in the day and I've never seen it since until today. ;-)
User avatar
Cybershark
Posts: 736
Joined: Wed Jun 14, 2006 11:16 pm
Contact:

Re: Ghostbusters (Activision)

Post by Cybershark »

'Ghostbusters - the computer game - follows the film closely'
Funny, I don't recall seeing Dana, Louis, or Walter Peck show up at any point :lol:
Dave_E wrote: Sun Aug 20, 2023 7:51 pm Just as an aside, and completely by chance, I just found a link to the original Ghostbusters leaflet that spoke about versions for the BBC and Acorn back in the day...
Fascinating to hear. Think we probably got a better deal, with Chris now taking the wheel - even if we did have to wait 40 years for it!
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

Think we probably got a better deal, with Chris now taking the wheel
:oops:

Anyhow - after an aborted attempt at the car screen (possibly overcomplicating things) I tried a different approach and have a car in mode 2 for the driving section using the palette. Not quite sure how I'm going to handle the ghosts as I've previously earmarked the palette for that job. One to investigate later. The vsync isn't really in place so there's some tearing but the principle is there.

However I've pulled together the three screens that I've got so far and added a compression routine. This is just to look at the kind of size that we're looking at and as such isn't polished. For example I've not blanked the screen when I do the redraw so you can see the screen being built up. The code and data now take up just under 7K (excluding the intro text) which is about half of the space I have easily available. Given I have the city map, 4 cars and the houses I'm reasonably pleased with this. There are all the sprites - and of course the game logic to add so we're in no way home free as yet - but it looks promising.

Press Escape to change between screens - changing the car (V to change the vehicle) on the capture screen also changes the car that you drive.
gbdemo.ssd
(8 KiB) Downloaded 36 times
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
bob147
Posts: 340
Joined: Thu May 02, 2019 10:02 pm
Contact:

Re: Ghostbusters (Activision)

Post by bob147 »

Looking good so far! I love it when an oldie gets a modern BBC conversion, I had the master system version of this so looking forward to seeing how the mighty beeb compares.
User avatar
Dave_E
Posts: 908
Joined: Fri Jun 16, 2006 1:55 pm
Location: Middlesbrough
Contact:

Re: Ghostbusters (Activision)

Post by Dave_E »

The demo is really good and really looks like what I would imagine a BBC version of the game *to* look like.
User avatar
Rob_hawk
Posts: 477
Joined: Mon Jul 12, 2021 6:50 pm
Location: Valmeinier, France
Contact:

Re: Ghostbusters (Activision)

Post by Rob_hawk »

Looking great Chris! Can't wait to see the next update.... Was sure I'd never see this on the BBC but here we are :D
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

A brief update. I've started to bring this together into more of a game like structure. This version contains the three screens as before but adds a loader screen/routine to move the code down to &E00, some interrupt code to provide mixed screen mode and the tune. The bottom of the city and house screens is placeholder text only. Currently around 8K free.

The car screen uses hardware scrolling so if I'm going to use the text there it will need to be redrawn every time the card move left or right which may make that movement jerky so for now I'm intending to not have text there.
gb.ssd
(11 KiB) Downloaded 30 times
I've had some ideas for the ghost on the car screen so I'm probably going to look at that next.
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
tricky
Posts: 7698
Joined: Tue Jun 21, 2011 9:25 am
Contact:

Re: Ghostbusters (Activision)

Post by tricky »

I don't really remember the game, but would vertical rupture help with the text or are you already doing that?
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

Can rupture do a stationary bottom section and moving top section? The examples I have seen have been the other way round.
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
RobC
Posts: 3816
Joined: Sat Sep 01, 2007 10:41 pm
Contact:

Re: Ghostbusters (Activision)

Post by RobC »

ChrisB wrote: Wed Aug 30, 2023 12:53 pm Can rupture do a stationary bottom section and moving top section? The examples I have seen have been the other way round.
Yes - the idea with rupture is that each portion of the screen gets its own screen start address which can be moved (or not) as you want.

You may waste some screen memory if the scrolling part of the screen doesn't fit neatly into one of the wraparound sizes.
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

I'll keep rupture in mind. Not sure we loose that much with it not visible on the car screen. Speaking of which I've been experimenting with the ghost on that screen.
gbdrive.png
gbdrive.png (4.58 KiB) Viewed 3444 times
gbdrive2.png
gbdrive2.png (4.25 KiB) Viewed 3444 times
I've redefined the palette to speed up the plotting but have "run out" of colours for both the lines and the ghost. So for the ghost I've compromised where it maintains it's colours apart from when it's over black lines when they will appear red (and vice versa - there will be a ghostbusters logo on the car later...). To my mind this looks pretty good - especially when it's in motion.
The palette is therefore:

Code: Select all

0   1   2   3   4   5   6   7
blu wht car car wht wht blk blk
yel yel yel yel yel yel red red
8   9   10  11  12  13  14  15
Where car is the "special" colour that varies per car (cyan or magenta in the above images). The lines are therefore plotted by setting the bottom bits of the byte and the ghost with the top bits.
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

For this update I've added the remaining sprites (that I can see are required). This has meant refactoring one of the plot routines (and the data storage structure) but this means it is more general purpose. Still needs a slight change the the vertical position code and some work to allow unplotting of a sprite - this is probably next - which will then allow me to implement moving around the map.

However for this update this has allowed me to add some gadgets to the cars (fixed types and positions at the moment) and a ghostbuster logo. Due to the previously mentioned colours this will flash when the ghost is not on the screen - and turn yellow when it is. Thoughts welcome here and on the ghost colour clash.

Again no real attention has been paid to the vsync so there is flickering on the sprite plot. Around 7K free - but I've got my eye on 256 bytes of that!
gb.ssd
(12.25 KiB) Downloaded 22 times
gbdrive.png
gbdrive.png (4.46 KiB) Viewed 3358 times
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

And suddenly there's a lot less space free :(

This time I have mostly reordered the code to be more of a game framework rather than some screens stuck together. I've split the scenes into two parts - one that draws the initial scene, and one that "plays" the scene. I've also added a main loop that gets the keys and polls the scenes as appropriate. This will also eventually update the game status (increase PK energy etc.) Previously each scene was it's own thing including key handling etc.

This has allowed me to implement a scroll for the status text as appropriate (along with my own print routines). Press space to display a (static) message on the house and map screens.

As part of this I've brought in the text messages from the C64 version - turns out the game messages are about 2.25K (without any lyrics) so these have needed to be compressed which means I'm now at about 5K of space free without getting too creative. Latest demo attached - use the direction keys to change parameters on the main screen.

Next time really is going to be about moving round the map...
gb.ssd
(14 KiB) Downloaded 17 times
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

Added movement around the map. Not quite happy with this as yet. Horizontal movement is too fast. I may need to add a smaller pixel movement for the sprites. It is also too hard to line up with the vertical streets.
gbmap.png
gbmap.png (10.38 KiB) Viewed 3152 times
gb.ssd
(14.5 KiB) Downloaded 23 times
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
RobC
Posts: 3816
Joined: Sat Sep 01, 2007 10:41 pm
Contact:

Re: Ghostbusters (Activision)

Post by RobC »

This is looking really good - I love the split mode scrolling text =D>

Thinking back, I think Ghostbusters not coming out on the Beeb was when I started to realise that the big games companies were starting to focus on other platforms.

It's great to finally see it looking so good on the Beeb :D
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

Starting to get systems into the game. Ghosts now appear and move over the map adding to PK when they get to the ZUUL building which will wrap eventually. ZUUL and GHQ are now labelled as well. Ghosts are all the same way round for now - I need a reversed plot routine for the 1 bit sprites. Still wondering if I need to change one or both of my sprite routines to be single pixel movement.
gbmap.png
gbmap.png (10.71 KiB) Viewed 3028 times
gb.ssd
(14.25 KiB) Downloaded 31 times
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
User avatar
ChrisB
Posts: 548
Joined: Wed Oct 05, 2011 10:37 pm
Location: Surrey
Contact:

Re: Ghostbusters (Activision)

Post by ChrisB »

Starting to experiment with the capture screen. Looking at the ghost and player movement. I think I need to reorganise the palette for this screen (in a similar way to the car screen) but in the mean time here's how it might look.
gbcap.png
gbcap.png (6.5 KiB) Viewed 2922 times
And - yes in the C64 version the ghosts are cyan but to my mind they look like slimer who was green.
Castle Defender, Untitled Dungeon Game, Night Ninja, Wordle, Waffle, Acorn Island, Beebchase, Ghostbusters
Post Reply

Return to “new projects in development: games”