Repository navigation
Add Godot 4 GDScript 2.0 instructions - #5151
Conversation
🚦 Submission status: ⏳ Awaiting automationRisk tier: Why this tier
Automated checks
Action needed
Review
Commands
Updated for |
aaronpowell
left a comment
There was a problem hiding this comment.
Thanks, this is a tight, useful file — the Godot 3 → 4 mapping table covers exactly what Copilot gets wrong from older tutorials.
|
/rerun-checks |
|
🔁 No failed or incomplete checks to re-run.
The status comment updates when the checks finish. |
🔒 PR Risk Scan ResultsScanned 1 changed file(s).
✅ No matching risk patterns were detected in changed files.
|
|
🟡 Contributor Reputation Check: MEDIUM risk
Maintainers: please review this contributor before merging. |
Pull Request Checklist
npm startand verified thatREADME.mdis up to date.mainbranch for this pull request.Description
Adds
instructions/godot-4-gdscript.instructions.md(applyTo: "**/*.gd").Copilot often writes Godot 3 GDScript inside Godot 4 projects, because most tutorials online still use the old syntax. That code doesn't parse in Godot 4. This file gives the Godot 3 -> Godot 4 mapping for the usual offenders:
yield(...)->awaitexport/onready/tool->@export/@onready/@toolsetget-> inlineset(value):/get:blockspuppet/remote/remotesync/puppetsync/master->@rpc(...)connect("signal", self, "method")->signal.connect(callable),emit_signal()->signal.emit()funcref->Callable,Pool*Array->Packed*ArrayIt also covers static typing,
super()in lifecycle overrides, andStringName/NodePathliterals. I checked the mappings against Godot's "Upgrading from Godot 3 to Godot 4" guide and the engine'srenames_map_3_to_4.cpp. No existing instruction file covers Godot or GDScript.docs/README.instructions.mdwas regenerated withnpm start.Type of Contribution
Additional Notes
The content is adapted from the MIT-licensed rules I maintain at https://github.com/otctrading101/shiprules-free. The file itself has no links, and it doesn't depend on any paid service.
By submitting this pull request, I confirm that my contribution abides by the Code of Conduct and will be licensed under the MIT License.