Use complete Godot version for preprocessing conditionals#1947
Use complete Godot version for preprocessing conditionals#1947Naros wants to merge 1 commit intogodotengine:masterfrom
Conversation
0e97e2b to
8c78f00
Compare
|
I don't think this change makes these When Godot 5 happens, my plan was to reset the GDExtension interface such that all the old numbered functions are removed, and the latest becomes unnumbered. So, for example, If we want to account for Godot 5, I think it would be better to add something like this to a central location: That way when Godot 5 comes out, if folks try to use it with an old godot-cpp, they will get a nice message rather than cryptic errors about functions not existing. (Or, I guess we could add this check in the Python code before we even get to compiling C++?) Of course, we could add |
|
That's fair. Then in that case, it sounds like it might be best to wait until we're at that bridge, and cross it then. Would you agree with that assessment @dsnopek ? |
|
Yes, I think so. If we're going to handle this pre-emptively in any way, it should just be to prevent godot-cpp from building if the major version is greater than 4. Anything else would need to wait until we actually have a Godot 5 to build against. |
This expands on the current conditional logic for Godot versions by using the full Godot version. I suspect that when Godot's next major version happens, godot-cpp will need to continue to maintain compatibility with at least some Godot 4.x versions. This makes that possible.