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

% uses NodePath color even when not part of NodePath #61646

Closed
KoBeWi opened this issue Jun 2, 2022 · 3 comments · Fixed by #63326
Closed

% uses NodePath color even when not part of NodePath #61646

KoBeWi opened this issue Jun 2, 2022 · 3 comments · Fixed by #63326

Comments

@KoBeWi
Copy link
Member

KoBeWi commented Jun 2, 2022

Godot version

1baee21

System information

Windows 10 x64

Issue description

Minor regression from #61440 (I assume at least)
image
It shouldn't be green.

Steps to reproduce

  1. Use % as modulo operator
  2. Notice it's colored like NodePath instead of operator

Minimal reproduction project

No response

@MewPurPur
Copy link
Contributor

%'s coloring behavior is consistent with that of $ now. So I honestly think %Node is just not fit as a replacement for get_node("%Node") and it should require a fuller $%

@KoBeWi
Copy link
Member Author

KoBeWi commented Jun 3, 2022

Nah, %Node is fine, just % shouldn't use NodePath coloring when used alone.

@MewPurPur
Copy link
Contributor

MewPurPur commented Jun 3, 2022

Not just standalone - things like 19%3 and "I am %s the Espeon"%"Mew Pur Pur" also trigger the color change. I suppose it requires knowledge of whether its current context is as a binary or a unary operator, which is currently not done by other operators.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants