Skip to content

Rework and document CharacterSight and PlayerInteraction#2078

Merged
manuq merged 4 commits intomainfrom
rework-player-interaction
Mar 24, 2026
Merged

Rework and document CharacterSight and PlayerInteraction#2078
manuq merged 4 commits intomainfrom
rework-player-interaction

Conversation

@manuq
Copy link
Collaborator

@manuq manuq commented Mar 24, 2026

Use body_entered and body_exited signals for obtaining the best area, instead of doing it in the process loop.

Rename the node InteractZone in player to CharacterSight and give it a class name, moving it to game_elements.

champ & after_the_tremor StoryQuests: Adapt to the recent changes in player.

manuq added 4 commits March 24, 2026 08:53
Use body_entered and body_exited signals for obtaining the best area,
instead of doing it in the process loop.

Rename the node InteractZone in player to CharacterSight and give it
a class name, moving it to game_elements.
Adapt to the recent changes in player.
@manuq manuq requested review from a team as code owners March 24, 2026 12:03
@manuq
Copy link
Collaborator Author

manuq commented Mar 24, 2026

This is extracted from #2073, in which I'm trying to highlight the object that can be interacted. That is the object currently being observed by the player (the one showing the interact label).

@github-actions
Copy link

Play this branch at https://play.threadbare.game/branches/endlessm/rework-player-interaction/.

(This launches the game from the start, not directly at the change(s) in this pull request.)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's a bit weird for this to live in props rather than player.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, I did it to match interact_area. But also this can potentially be attached to a CharacterBody2D NPC.
Maybe I move it to scenes/game_logic/ ?

Copy link
Member

@wjt wjt Mar 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could work. Honestly I think it's also quite strange that this script (not a scene) lives in scenes/, like many many others (e.g. area_filler.gd) but I can't bring myself to propose rearranging all the folders in the project again :)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't feel the need to address this now, it's just a path, we can change it later. I was just observing that it seems a bit strange

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes the whole structure is strange to me as well!

@manuq manuq merged commit 36082b4 into main Mar 24, 2026
6 checks passed
@manuq manuq deleted the rework-player-interaction branch March 24, 2026 12:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants