Posted February 20, 2023 by Yatch
If you like what you see below, please wishlist V-Hunter Puzzler Dx!
Likely the biggest change implemented for this release is a level selection. My original intent was for the Sagas to be recorded as one chunk, and while you could stop mid-way and save progress, you couldn’t jump between levels or change difficulties mid-run.
The more I thought about and played other puzzle games, I realized the overwhelming majority have a level select, and I also thought of edge cases like a player wanting to change difficulty 70% into a saga and getting frustrated that they have to start all over.
So, I took a couple of hours and hashed out a level select system. Luckily, it wasn’t too big of a hassle and I’m glad it’s in.
A neat part of implementing this was creating a dynamic solution to how many buttons there should be AND whether they should be disabled or not.
My solution involved taking in a map with sagas as the key and the number of levels as the value. Then, I could create a button of a predefined size as a child of an h flow container, connect the button pressed signal to a function, and determine if the button should be disabled or not (basically, is the level unlocked).
for level in saga_level_map[saga_selected]:
var level_button: Button = Button.new()
level_button.text = str(level + 1)
level_button.rect_min_size = Vector2(24, 24)
level_button.disabled = false
level_button.connect("pressed", self, "_handle_level_select", [level + 1])
# Ensure first level and all unlocked levels + 1 are enabled
if not _level_unlocked(level):
level_button.disabled = true
h_flow_container.add_child(level_button)
Some nice polish was adding a scene fade in/out to levels loading. It makes it less jarring and I think adds to the professionalism.
I just have to say that SteamAPI made integrating with Steam beyond easy. It took me more time to set up achievement icons than to hook up the plugin and have it communicate with the Steam backend.
If you’re developing in Godot, seriously, check out SteamApi!
This was something I wanted to implement so friends could test the game out on mobile. While mobile is not the ideal platform to play the game, it’s definitely doable and I was happy to tackle the challenge.
The solution wound up being quite straightforward, besides a few edge cases.
I added invisible buttons (buttons with alpha set to zero) in adjacent squares and one where V-Hunter is. I connected those buttons to the player code, and when pressed they will call the move and rest functions, just as if they were keyboard/controller inputs.
The one edge case was how to deal with the revolver shot. It was the only V-Hunter skill that wasn’t handled by movement or rest, so I had to figure it out. Initially, I considered adding an extra shoot
button or making the bullets clickable in the inventory. but I wanted to limit what I added for touch support as it wouldn’t be the main play style for the game.
What I settled on was having V-Hunter shoot if he was pressed down and held for over one second. While this solution is not perfect, it works well enough without impacting the normal play style.
The timer system was a little tricky to implement, but I found a timer to be the cleanest way. The timer starts when the rest button is pressed down. If the timer times out, it will set a bool to true that it should shoot. On rest button up, it’ll check if V-Hunter should shoot or rest. Shoot logic already checks to make sure there is an available bullet.
func _handle_rest_button_down():
rest_btn_timer.start()
is_touch_input_shoot = false
func _handle_rest_button_up():
if _can_take_input():
if is_touch_input_shoot:
_fire_bullet()
else:
_rest()
func _handle_rest_timer_timeout():
is_touch_input_shoot = true
I will continue with marketing, It’s been a real slog gaining wish lists, but I’m gonna keep going with it!
As for features, I’ll be working on adding some unlockables (got some cool alt costumes for V-Hunter) and more polish on menus and UI.
If you like what you’ve read, please wishlist V-Hunter Puzzler Dx and consider following me on any of my socials on my Linktree!