SEAR DevBlog, week of 9/21: What's in a Reswave, part 2


First, the updates: The new laser fire mechanic is functional and will be in for the playtest. Now we’re just working on polishing it up. We can now make any object in the world targetable by the laser fire, and when an object is destroyed, it drops a turbo pickup. This completely transforms the mechanic. Before it felt very workaday, ho-hum, hit the button, vaporize a car. Now, particularly in phase 3, the world is littered with targetable rocks, enough that you pretty much always have a target. But knowing that a turbo drops after you destroy the rock means that you want to catch the laserfire reswave (music-synched) and ALSO line up to grab the turbo that will drop (a decision fully asynchronous to the music). You also need to feel the music tempo and decide on the fly - will it line up in time for me to destroy that rock so I don’t have to change course? Or will that part of the song hit too late, and I should look for a different target now? It’s the same kind of sync/async combined mechanic as the beat drift boost, and I think it’s when SEAR is strongest. So calling that done. It will need some more tweaking for online…. But that’s later.
Elsewhere we continued progress on the new levels, and my work on the NPC AI rewrite also continued… though I’ll be honest, I’m beginning to have doubts about the approach. I’m not sure it will be ready for the playtest, but if not, it just means the old/current AI will need to stay in for now.
The team members that were traveling just got back, so that’s mostly it for this week.
Picking up from last week, I was talking about reswaves. The issue was that the mechanic is tied to the music and has to happen RIGHT at a particular time, but is also dependent on player input to execute. If a player waits to hit the input right on the beat - which they’re not forced to do but they really want to do because this is a music-based game - odds are good they’ll be late by a fraction of a second and the event never fires, because when the music was at the right part they hadn’t hit the button yet.
The solution I hit on was to start the event resolution right on the beat no matter what. For a speed boost, the boost curve starts. For a light event, the light starts shining. For the laser fire, the laser appears but doesn’t immediately resolve. This keeps everything feeling synched. Then the engine can wait just a moment - a grace period for input, the exact duration depends on the actual reswave in question - and then check to see if the player hit the button. If they have, the effect that already started continues and fully resolves. If they haven’t, it rolls back or aborts.
In practice, this means that timeline-based effects reverse. Speed and light quickly revert to their pre-effect status, while the laser fire just misses. So as a player you see the effect begin and abort. If you already know the level and know the reswaves, the effect is pretty strong. It still happens to me on occasion and every time I’m like “aaagh I can’t believe I missed that” because I know how wide the window is and how badly I needed the effect.
Net effect is a forgiving input window with a grace period both before and after the moment of truth, and a mechanic that always executes right on the beat. There are limitations to how far that grace can extend after the beat hits, but even a narrow .2 second extension makes a lot of difference.
The other piece of that is the confirmation sound effect, which is another interesting conundrum.
If the player catches the reswave, they want to hear some kind of independent confirmation of it. But here the grace window approach doesn’t work. You can’t do the confirmation tone right on the beat if the player hasn’t hit the button yet. And if they hit the button within the late grace window and you play the tone then, it will sound off-beat or late.
Where I landed on this was that that is okay. In fact, it is the one place where SEAR punishes you for not hitting the SEAR button right on the beat: it sounds off. You can mash the button to catch a reswave, you can press it early or late, but the only way to make it sound just right is to catch it on the beat. This feels like a perfect compromise to me.



Comments