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

Issues With C# Preprocessor Defines #9230

Open
Joy-less opened this issue Apr 14, 2024 · 0 comments
Open

Issues With C# Preprocessor Defines #9230

Joy-less opened this issue Apr 14, 2024 · 0 comments
Labels
area:manual Issues and PRs related to the Manual/Tutorials section of the documentation bug topic:dotnet

Comments

@Joy-less
Copy link

Your Godot version:
4.2

Issue description:
The wiki page on conditional compilation for C# has a number of issues:

  • It says GODOT_SERVER is defined for dedicated server exports, but it's never defined.
  • It says GODOT_64 or GODOT_32 is defined in the editor and exports, but they're never defined.
  • It says GODOT_PC is defined only when exporting, but it's also defined in the editor.
  • It says the platform defines are "created from the get_name() method of the OS singleton" which is not true, as get_name() values have different casing, separate Linux and BSD, and uses "Web" rather than HTML5.

Additionally, there are some design problems:

  • No guarantee that the names won't change in the future.
  • Duplicate definitions such as GODOT_MACOS/GODOT_OSX, GODOT_WEB/GODOT_HTML5.
  • GODOT_32 and GODOT_64 are ambiguous between the OS architecture and the floating point accuracy.

There's no clear consensus on determining which export the game is running on, so I suggest a dedicated wiki page is created for this purpose.

URL to the documentation page:
https://docs.godotengine.org/en/stable/tutorials/scripting/c_sharp/c_sharp_features.html

@Joy-less Joy-less added the bug label Apr 14, 2024
@skyace65 skyace65 added topic:dotnet area:manual Issues and PRs related to the Manual/Tutorials section of the documentation labels Apr 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:manual Issues and PRs related to the Manual/Tutorials section of the documentation bug topic:dotnet
Projects
None yet
Development

No branches or pull requests

2 participants