Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

Interactions: A Small But Substantial Start

Today I began diving back into adding interactable objects to the game. Previously I had some conversations with Gemini about how I expected this system to work. Of course, that was with the old chat instance I had to abandon. So I fought with it a bit to see what information I could get out. Unfortunately, "Something went wrong" repeatedly. And when I finally got some information out, it was completely wrong and not at all what we discussed. 

So, I started over a bit. I described how I wanted the system to work and had a discussion with Gemini to iron out any wrinkles it could find. I'm still not completely certain of everything, but for now I have something to work on. The interaction system will be split in half between the player and the interactable object. They both have colliders. When the player's character detects a collision with an interactable object it will do a raycast to make sure there's nothing in the way. If it's all good, the object notifies the player it can be interacted with.

There's going to be a whole targeting system, sort of, although I'm not so certain it's important anymore. The idea was any time an object came in range it was added to a list and when it left range it is removed. But there were potential edge cases I was worried about. But I can't remember the specifics, I think I was just worried about trying to deal with an object in the list that isn't actually in range. . . 

But anyway, I've got a plan of attack, and as part of working on this, I also figured out something I needed. I hadn't actually gotten my tilemap collision with the player working, but that's a thing of the past! The player can now successfully bounce off the walls. This should also deal with my raycasting.

But that's all for today. Next time I'll continue working on this and really have something!

Support this post

Did you like this post? Tell us

Leave a comment

Log in with your itch.io account to leave a comment.