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

Migrate to godot 4 #18

Merged
merged 47 commits into from
Mar 6, 2023
Merged

Migrate to godot 4 #18

merged 47 commits into from
Mar 6, 2023

Conversation

Kvel2D
Copy link
Collaborator

@Kvel2D Kvel2D commented Mar 4, 2023

Unresolved issues:

Useful link listing all of the things that converter does incorrectly:
godotengine/godot#73960

@Praytic
Copy link
Owner

Praytic commented Mar 4, 2023

_ready() doesn't implicitly call parent version anymore, had to add explicit calls to super() or rework initialization in case of items and towers.

Answer:

This is intentional, and fixed an inconsistency in the OOP behavior of Godot 3.

If you want to call the parent method, you should use super() in the method that overrides it.

godotengine/godot#73377

Kvel2D added 20 commits March 5, 2023 07:28
New directory in godot 4
Add new font import
This was done by opening upgraded project in editor for the first time
Editor said that scene is "broken" when opening it for the first time
Had to remake by hand
By opening them in editor for the first time
String ctor with int parameter was removed in godot 4
Those are built-in functions so rename our functions to avoid
\ overriding them
Add calls to super()
Add spaces between parameters
Fix later
Remove tween nodes
Reconnect element_changed signal
Fix mixed tab/spaces
Zoom values were inverted in godot 4
In godot 3, parent class _ready() was implicitly called
This is not the case for godot 4 anymore
Add explicit calls to _ready()
For towers and items, add separate init functions to avoid mistakes
\ around forgetting super() calls in tower/item scripts
@Praytic
Copy link
Owner

Praytic commented Mar 5, 2023

Tilemap is broken

Autotiles cannot be converted automatically: godotengine/godot#64006

Kvel2D and others added 9 commits March 5, 2023 20:10
Don't need to call randomize()
randi_range() was added to godot 4
Restore original animation speed
Scale down pulse texture
Fix tower preview modulate applying to range indicator as well,
\ apply it only to tower visual
YSort was removed in godot 4
Turn on y_sort_enabled for MobYSort node to approximate old effect
@Kvel2D Kvel2D marked this pull request as ready for review March 6, 2023 18:50
@Kvel2D Kvel2D merged commit 2547641 into main Mar 6, 2023
@Kvel2D Kvel2D deleted the migrate-to-godot-4 branch March 7, 2023 07:11
Praytic pushed a commit that referenced this pull request Mar 27, 2023
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