Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FakeWall hides TalkComponentUI #759

Open
LozenChen opened this issue Apr 7, 2024 · 0 comments
Open

FakeWall hides TalkComponentUI #759

LozenChen opened this issue Apr 7, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@LozenChen
Copy link
Contributor

My mods and Everest install are up to date

Yes

I have recreated the bug with only Everest OR a minimum number of mods enabled

Yes

Describe the bug

Bug description
If we have a NPC (which holds a TalkComponentUI), standing exactly on a FakeWall, and if the FakeWall is not uncovered, then the talk bubble will not show up
celeste

Steps to reproduce

Why we have this bug
TalkComponentUI.Update will check if its Handler.Entity.Position (Position of NPC in this case) is covered by a FakeWall. If is, then its alpha will always be 0.
if (alpha < 1f && Handler.Entity != null && !base.Scene.CollideCheck<FakeWall>(Handler.Entity.Position)){ alpha = Calc.Approach(alpha, 1f, 2f * Engine.DeltaTime); }
Due to the minor differences between Hitbox.Collide(Vector2 point) vs Hitbox.Collide(Hitbox hitbox),
Scene.CollideCheck<FakeWall>(Handler.Entity.Position) will return true here.

How to patch this
maybe just change it to
Scene.CollideCheck<FakeWall>(Handler.Entity.Position - Vector2.UnitY)
in TalkComponentUI.Awake/Update

Why we should patch this
Coz such kind of structure is not uncommon in mod maps

Expected behavior

celeste2

Operating System

Win 10

Everest Version

4713

Mods required to reproduce

No

Additional context

No response

@LozenChen LozenChen added the bug Something isn't working label Apr 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant