Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions tutorials/scripting/gdscript/gdscript_basics.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1951,6 +1951,16 @@ If you want to use ``extends`` too, you can keep both on the same line::

class_name MyNode extends Node

Named classes are globally registered, which means they become available to use
in other scripts without the need to ``load`` or ``preload`` them:

.. code-block:: gdscript

var player

func _ready():
player = Character.new()

.. note::

Godot initializes non-static variables every time you create an instance,
Expand Down