- Changed the grammatical number of all enum names to be singular.
- Removed the enum names from their members, (e.g.: Tile.TILE_BRICK -> Tile.BRICK).
- Added a suggestion for the reader to use singular case for enum names.
- Change all links to '_doc' anchors instead of 'toc's.
- Move 'doc_c_sharp' and 'doc_gdscript' to the index pages.
- Add 'doc_gdscript_reference' anchor.
- Update all existing links to point to the right place,
updating grammar if needed.
* Update code order with static annotation on gdscript_styleguide.rst
Update code order on gdscript_styleguide.rst
by inserting static variables and methods on the code order as a proposal
- Recommend writing each enum item on its own line, similar to C++.
- Recommend using spaces around inline dictionary declarations
to make them easier to distinguish from arrays (due to similar-looking
`[]` and `{}` characters in most fonts). This is commonly found
in Python or JavaScript style guides.
* Update gdscript_styleguide.rst - clarified sentence and grammar
- Clarified the statement on "One statement per line"
- Removed unclear sentence with incorrect grammar
---------
Co-authored-by: A Thousand Ships <96648715+AThousandShips@users.noreply.github.com>
* Add bang operator to operators table
* Add symbolic aliases for `and` & `or`
* Remove comma from operators table
* Add bang to the aliases list
---------
Co-authored-by: Max Hilbrunner <mhilbrunner@users.noreply.github.com>
Adds two changes:
- makes it clear where subclasses should go (at the bottom of the script)
- put the `_enter_tree()` method before `_ready()` but after `_init()` since that's the order in which the methods are executed
In the current style guide, the example for ternary operators includes a "not" in the conditional which is the same text color as the preceding "if" giving the impression that the format for a ternary operation is "[some_value] if not [condition] else [other_value]" which is incorrect, and may be confusing to figure out. I'm new to Godot and I've never used python (which I understand GDScript is based on). My only experience is with c# which I don't believe has a "not" keyword so I was quite confused by this.
This change would remove "not" from the condition to eliminate confusion, and rearrange the values to keep the meaning of the example code the same. Any alternative that removes the "not" would also work.