SamuKata
sgthale
sgthale

patreon


Handhold improvements

I extended the behavior for handholding. Instead of solely being about pulling her around to places, Shinobu will now match your speed and walk along side you when you walk slow.

The implementation was mostly about prediction because it is sometimes difficult to tell when the player wants to either pull her or have her walk alongside. The solution for now is just to activate the "match player speed" after a second of slow walking. Demonstration:

The next part was solving the constraints to stick with the player. Depending on which hand is being held, Shinobu should either follow the player's left or right side. However, if the player changes movement directions quickly, that target side position can suddenly flip to the opposite side, meaning Shinobu would have to travel all the way over, and that's no good. To solve this I constrained that target follow position to a half circle:

Green is the constrained area and blue is the player walking forward. After this I interpolated several variables to smooth out the sudden flip from one side to the other side transition and arrived at the following gif:

The little ball is to visualize the half circle. Notice how she remains in the half circle regardless of my movement direction. After feeling satisfied with this, I baked out some HoldForms which are custom classes that store hand poses and finger information. These were used to make Shinobu and the player hold hands tightly like so:

They were then wired up to the handholding logic extension. This kind of handholding  behavior stops automatically if the player stops walking. Like so:

And then resumes the regular pull soft/hard logic.

These are the kinds of "polishes" I will be continuing up to the release of v0.3. I am excited for the release.


Happy New Year!

Handhold improvements

More Creators