Background collision bugs fixed, flower stages also added, yay!

Well, that sorted itself out quicker than I thought it would, did a lil stream for 90mins over at with the aim to just get background collisions less buggy and, here we are!

Using RAM along with some reference arrays in ROM made life so much easier here, it should be nice and easy to get the following bits of gameplay code implemented pretty soon I reckon.

What are they? Well, there’s quite a list!

  • Limited pollen carrying & depositing at the hive.
  • Scoring
  • Sorting those birds out
  • A handy dandy level editor
  • Maybe making the spiders / crabs a bit less central in the screen
  • Player 2!
  • Possibly cut scenes?
  • Sound Effects
  • BGM
  • Passwords
  • VS Mode
  • Ending Sequence…s
  • Tidying up that intro and other bits.

Background Collisions working all the time 90% of the time

So, after a terrible incdent at the start of the bank holiday weekend, I pulled myself together today and spent a lovely day with the kids then, coded up some more bits for Bee Happy tonight. So, teh slowdown effect is now working when the player is over the hedge tiles which is all good and…most of the time… the flowers are removed correctly, but sometimes and I’m not sure exactly why, the offset changes by 1 frame in any direction.

I’m guessing something’s up with my timings in edge cases which is annoying but really, it’s just one more piece of the puzzle i need to fix before I move onto the next one.

I’ve got to be selective with how many tiles i can write during each VBlank period still, particularly with 2 players involved. I may have to resort to a priority system or just an every other frame depending on how close things get.

Either way, some progress is still progress, so that’s good.

Hives and Hedges

I set myself the target to get more level features into Bee Happy tonight and after some prototyping in photoshop this morning I ended up with this lil image to work towards.

This meant changing how level data was constructed and read from, keeping within my limits of not just lazily turning the rendering off for a few frames. Initally everything went well, adding the hedges seemed to cause no problems until I added the code for the Hive placement which proved to be a little too much for the PPU to handle inside 1 frame.

The problem was that I knew I was close but there were a few cycles I could spare and, with a few minutes of tinkering about with my level loading code I was able to optimize it down to run, what seems to be, safely within the NMI CPU time.

Figured I’d best post a lil video to go with it, the only real difference is that the hive outline isn’t black but that’s something I can live with.

Next up I think I need to handle background collisions in a smart fashion, ideally pre-calculating which tile each player is over before deciding what to do with that information in the NMI window.

Wish me luck, as I think I’m going to need it!