mirror of
https://github.com/godotengine/godot-docs.git
synced 2026-01-03 05:48:42 +03:00
Edit the scripting section
Misc grammar fixes, improvements to phrasing, and more. Co-authored-by: balloonpopper <5151242+balloonpopper@users.noreply.github.com>
This commit is contained in:
@@ -1068,10 +1068,10 @@ path. For example, if you name a script file ``character.gd``::
|
||||
Registering named classes
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Instead, you can give your class a name to register it as a new type in Godot's
|
||||
editor. For that, you use the ``class_name`` keyword. You can add an
|
||||
optional comma followed by a path to an image, to use it as an icon. Your class
|
||||
will then appear with its new icon in the editor::
|
||||
You can give your class a name to register it as a new type in Godot's
|
||||
editor. For that, you use the ``class_name`` keyword. You can optionally use
|
||||
the ``@icon`` annotation with a path to an image, to use it as an icon. Your
|
||||
class will then appear with its new icon in the editor::
|
||||
|
||||
# Item.gd
|
||||
|
||||
|
||||
@@ -107,7 +107,7 @@ Currently you can use three types of… types:
|
||||
1. :ref:`Built-in <doc_gdscript_builtin_types>`
|
||||
2. Core classes and nodes (``Object``, ``Node``, ``Area2D``,
|
||||
``Camera2D``, etc.)
|
||||
3. Your own, custom classes. Look at the new :ref:`class_name <doc_gdscript_basics_class_name>`
|
||||
3. Your own custom classes. Look at the new :ref:`class_name <doc_gdscript_basics_class_name>`
|
||||
feature to register types in the editor.
|
||||
|
||||
.. note::
|
||||
|
||||
Reference in New Issue
Block a user