godotengine / godotengine/godot-docs

Getting started 2D and 3D tutorials are missing type hints that are automatically generated

Open
#11,037 1 comment 0 reactions 0 assignees View on GitHub
area:getting started bug
Dominant language
reStructuredText
Stars
5.7k
Forks
3.8k
Avg merge
1d 20h
Merged PRs (30d)
25

Description

**Your Godot version:**

4.4.1

**Issue description:**

When working on the tutorial I found that in general all default generated functions contains type hints example:
`func _ready() -> void:`, `func _on_mob_timer_timeout() -> void:`

From my understanding we want to encourage the use of type hints to users. I think the tutorials should at least match what the default generated scripts on the editor are going to be.

The two above examples currently are shown on the tutorial as:
`func _ready():` or `func _on_mob_timer_timeout()` which could even encourage the user to remove the type hints.

I am happy to provide a PR for the getting started first 2d and 3d games adding type hints if you think it would be an improvement.

I see there were discussions on the past about adding type hints to the documentation (https://github.com/godotengine/godot-docs/issues/6295) but I think the getting started guides should at least match what the users are going to find with the autogenerated functions as this is probably the entry point and might be confusing for some.

**URL to the documentation page (if already existing):**

Several pages on the getting started guide.
https://docs.godotengine.org/en/stable/getting_started/first_2d_game/03.coding_the_player.html

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.