• Register
Post feature RSS How to Control a Cat

Hey there, fellow catz! Today I want to talk about the input system in our upcoming game ZpellCatz. Being able to smoothly control your character (or cat) is important for non turn-based games. Lets have a look of what to expect in ZpellCatz.

Posted by on

Hey there, fellow catz! Today I want to talk about the input system in our upcoming game ZpellCatz. Being able to smoothly control your character (or cat) is important for non turn-based games. Lets have a look of what to expect in ZpellCatz.

I talked a lot about the "Randomization vs. Reliability" design pillar in the last article about the itemization in ZpellCatz. The input system is a quite technical feature but we can still satisfy two of ZpellCatz' design pillars here: "Comfortable to Play" and "Clean & Minimalist".

Keyboard and Mouse

Since ZpellCatz is a PC game, we can assume that every player has access to a keyboard and a mouse. Menu screens are controlled by mouse only, like in every other ARPG out there.

For ingame movement controls, players can choose to move their cat hero directly by keyboard buttons (arrow keys or WASD for example) or indirectly by pressing the left mouse button. So they have the choice between action adventure default controls or action RPG default controls. Both movement options are active at the same time, so players can toy around with them and find the preferred one easily.

keyboard input QWER

Casting spells and driking potions is realized via hotkeys, like most modern ARPGs do. Since ZpellCatz should be "Comfortable to Play" (design pillar), there is no button mashing or rapid left clicking to attack enemies. Every spell has a cooldown and if you keep the hotkey pressed, the spell will automatically be cast again when it is ready. So do you have to run around and wait for cooldowns to finish? Not really. Every hero class has one "default attack" like offensive skill that has a rather short cooldown - about 1 second or so.

mage fireball

Gamepad and Joystick

Over the last few years, more and more players started using their gamepad for PC gaming. In February 2021, Steam wrote that about 10% of all gaming sessions are played with one (source).

In my opinion, full controller support is a must have for action games today. To clarify the term "full controller support": It means that the whole game from start to finish, ingame and menues are playable with a controller. It does not mean that every gamepad / joystick / input device of the world is supported by the game on every OS - that would be a rather impossible task.

gamepad ingame controls

ZpellCatz is developed using the Unity3D game engine. The engine has a quite new "Input System" package that classifies input devices in multiple categories. Every device that is classified "Gamepad" or "Joystick" is supported in ZpellCatz. A "Gamepad" is a typical modern controller with 2 analog sticks - XBox / PS / Switch for example. A "Joystick" is an input device that has some kind of directional input (e.g. an analog stick or a dpad) and at least one button. It might be very hard to play ZpellCatz with just one button, but maybe it's possible. The reason to support the "Joystick" classification is that older gamepads (without analog stick) are classified as "Joystick" although they have multile buttons (for example an SNES controller or an original PS1 controller).

Designing menu controls for gamepads is no easy task. Navigating menus on PC with a mouse feels really natural. But playing some ARPG console port, it sometimes feels weird to just equip an item with a controller...

When I first played one of my favorite indie ARPGs on PC with a gamepad, I noticed that they had a different solution to this problem: They simply let you navigate your mouse with the controller and let you "click" with one of the buttons. This felt really good! No circle menues controlled by analog sticks that are impossible to control - just the same old menu UI you already know from playing with keyboard and mouse.

gamepad menu controls

Since this is by far the best option to navigate menues with a gamepad (in my opinion), I had to go the same route for ZpellCatz.

Hot Swapping Controls

To really satisfy the "Comfortable to Play" game design pillar, supporting all different kinds of input devices alone is not enough. We need to be able to easily change our control scheme.

I implemented hot swapping for input controls. For the moment, this applies to single player only since I'm not sure how to handle this for local multiplayer yet. So, whenever you use a connected input device, the game will automatically adjust to the last used one.

hot swapping keyboard and gamepad


Input Rebinding

Input rebinding is super important. In the options menu, players are able to rebind their keyboard, "Gamepad" or "Joystick" devices. Looking at the menu screen, you certainly noticed that the game design pillar "Clean & Minimalist" is at work here.

keyboard rebinding

When rebinding your gamepad, you can even choose a gamepad button layout. To avoid any trademark issues, I decided to replace all brand icons with numbers / characters. Movement (ingame as well as menu mouse pointer) is always bound to left stick and dpad and can't be remapped at the moment. (The colors on the gif below seem to be a little bit off - they are better ingame ^^ )

gamepad button layouts

Sadly, we can't add these nice features if the input device is classified as "Joystick". We know the amount of buttons available for the controller, but we don't know how they are labeled or where they are physically positioned on the device. That's why we have stick / dpad for movement and numbered buttons for other input. I highly recommend remapping controllers that are classified as joysticks.

joystick without button layout

So, I hope you got a good idea of the input system in ZpellCatz. Do you like it? Is there any feature missing that you find important? Lets hear your thoughts in the comments section below or by joining the ZpellCatz chat in our discord: Discord.gg

Note: All info here is in development content and subject to change.

Post a comment
Sign in or join with:

Only registered members can share their thoughts. So come on! Join the community today (totally free - or sign in with your social account on the right) and join in the conversation.