Commit Graph

103 Commits

Author SHA1 Message Date
Micky 59e11934d8 Rename `str2var` to `str_to_var` and similar
Affects the Math class, a good chunk of the audio code, and a lot of other miscellaneous classes, too.

- `var2str` -> `var_to_str`
- `str2var` -> `str_to_var`
- `bytes2var` -> `bytes_to_var`
- `bytes2var_with_objects` -> `bytes_to_var_with_objects`
- `var2bytes` -> `var_to_bytes`
- `var2bytes_with_objects` -> `var_to_bytes_with_objects`
- `linear2db` -> `linear_to_db`
- `db2linear` -> `db_to_linear`
- `deg2rad` -> `deg_to_rad`
- `rad2deg` -> `rad_to_deg`

- `dict2inst` -> `dict_to_inst`
- `inst2dict` -> `inst_to_dict`
2022-08-26 14:58:22 +02:00
Silc Renew dded7c72c1 Make `cubic_interpolate()` consider key time in animation 2022-08-19 14:48:37 +09:00
Andy Maloney 5361585832 [doc] Use "param" instead of "code" to refer to parameters
Co-authored-by: Yuri Sizov <11782833+YuriSizov@users.noreply.github.com>
2022-08-09 10:09:07 -04:00
Yuri Sizov c5d7115038 Rename the argument tag to param in XML documentation 2022-08-08 22:34:31 +03:00
Hendrik Brucker 99ce0df3b1 Refactor bezier interpolation functions 2022-06-27 19:42:43 +02:00
Rémi Verschelde e7a58a7eb6 Core: Rename math 'phi' arguments to 'angle' 2022-05-05 14:17:39 +02:00
Yuri Roubinsky 32f2c47356 Remove generating of null comparison operators from documentation 2022-03-14 22:35:23 +03:00
Hugo Locurcio b68dd2e189
Add an XML schema for documentation
This makes it easier to spot syntax errors when editing the
class reference. The schema is referenced locally so validation
can still work offline.

Each class XML's schema conformance is also checked on GitHub Actions.
2022-02-15 00:03:31 +01:00
Haoyu Qiu d54586a8e6 Explain what 2D cross product means 2022-01-11 11:48:45 +08:00
Rémi Verschelde 50225a0f32
i18n: Sync classref translations with current 3.x codebase
(cherry picked from commit defb801120)
2022-01-07 13:39:06 +01:00
Aaron Franke 064036d786
Allow Vector2/3 slerp values to have any length 2022-01-06 11:12:59 -08:00
Haoyu Qiu 3d08becd06 Unify similar method descriptions
Notably:

* `Packed*Array.size()` and `Array.size()`.
* Shared methods of `Transform2D` and `Transform3D`.
* Shared methods of `Vector2`, `Vector3`, and `Vector2i`.

This reduces the Deja Vu when translating the class reference :)
2022-01-06 19:50:57 +08:00
Max Hilbrunner 937fb63a23
Merge pull request #53020 from Lertsenem/doc/fix_vector2_reflect
Fix error in Vector2.reflect() description
2022-01-02 14:28:46 +01:00
Max Hilbrunner 78fd56a596
Merge pull request #55500 from KoBeWi/just_doc_things
Misc improvements to various docs
2021-12-06 15:34:21 +01:00
Aaron Franke 24f57886d0
Expose max_axis_index and max_axis_index for Vector2(i)
Some cleanup with Vector3(i)'s methods so that it is consistent with Vector2, for example it returns enums internally (GDScript still gets ints).
2021-12-02 23:45:41 -06:00
Raul Santos a367378f9e Rename Vector parameters to be consistent
Renames parameters that were named differently across different
scripting languages or their documentation to use the same name
everywhere.
2021-12-01 21:14:46 +01:00
kobewi 244c5ecc64 Misc improvements to various docs 2021-11-30 23:53:58 +01:00
Marcel Admiraal 272b3c3728 Enable sorting of operator methods in class documentation. 2021-11-29 14:51:44 +00:00
Rémi Verschelde 471e7cbfc7
Merge pull request #54581 from aaronfranke/operator-docs 2021-11-16 14:10:09 +01:00
Rémi Verschelde 6c1bd4d227
Replace Godot docs URL with `$DOCS_URL` in XML class reference 2021-11-15 13:02:21 +01:00
Tomasz Chabora 606cfa9a47 Fix Vector2.angle_to_point() being reversed 2021-11-09 16:59:58 +01:00
Aaron Franke 813466b3c8
Add documentation to operators for math types
Co-authored-by: Raul Santos <raulsntos@gmail.com>
2021-11-04 14:44:55 -05:00
Aaron Franke 6772ebcea0
Move the docs for constructors and operators out of methods section 2021-10-29 12:34:57 -05:00
Rémi Verschelde 862994a8ef
doc: Update links to latest documentation after content reorganization 2021-10-06 13:48:48 +02:00
Lertsenem e1bf428cdc Fix error in Vector2.reflect() description
The description was probably copied from Vector3.reflect(), and
unfortunately did not match the 2D behaviour (where n is apparently the
direction vector of the symmetry line, not the normal).
2021-09-24 18:41:06 +02:00
George Marques 455e142d37
Allow comparing equality between builtin types and null 2021-09-17 12:33:52 -03:00
Max Hilbrunner d69f4999fb
Merge pull request #52628 from mechPenSketch/imgages_in_docs
Add Graph Illustrations to Doc
2021-09-15 23:18:25 +02:00
mechPenSketch 9ea619c486 Add Graph Illustrations to Doc 2021-09-13 21:04:29 +08:00
kobewi 3f3739ccb5 Add Vector2.from_angle() method 2021-08-31 01:53:58 +02:00
Rémi Verschelde 7adf4cc9b5
doc: Use self-closing tags for `return` and `argument`
For the time being we don't support writing a description for those, preferring
having all details in the method's description.

Using self-closing tags saves half the lines, and prevents contributors from
thinking that they should write the argument or return documentation there.
2021-07-30 15:29:52 +02:00
reduz b1d15c51bc Implement native extension system
* Deprecates GDNative in favor of a simpler, lower level interface.
* New extension system allows registering core engine classes.
* Simple header interface in gdnative_interace.h
2021-06-25 17:32:45 -03:00
Michael Alexsander Silva Dias 0ff4095b36 Better format arguments in variant parser 2021-06-18 00:06:40 -03:00
Aaron Franke 2e13e3ed4a
Allow clamping vectors and colors 2021-06-03 12:05:20 -04:00
Aaron Franke 94bc0bd919
Rename Vector2 clamped to limit_length and add limit_length to Vector3 2021-06-03 12:04:57 -04:00
kleonc d13cfc8d62 Docs: Minor argument names fix 2021-04-23 15:46:51 +02:00
Rémi Verschelde 4ca1e73ff9
doc: Sync classref with current source
And move GLTF docs to its module folder.
2021-03-18 16:37:43 +01:00
Rémi Verschelde 215d18814e
doc: Sync classref with current source 2021-01-04 14:33:44 +01:00
Rémi Verschelde 6cebb8c117
Merge pull request #44586 from madmiraal/rename-stepify
Rename Math::stepify to snapped
2020-12-28 21:46:43 +01:00
Rémi Verschelde 058f3fe069
Merge pull request #44149 from madmiraal/rename-tangent-orthogonal
Rename Vector2.tangent() to Vector2.orthogonal()
2020-12-28 16:00:12 +01:00
Marcel Admiraal b743a2ef3c Rename Math::stepify to snapped 2020-12-28 13:01:30 +00:00
Yuri Roubinsky fa0683ed30 Added a note describing a code behind Vector2/3.direction_to 2020-12-15 22:36:26 +03:00
Aaron Franke 5465e604bb
Improve argument names for core types 2020-12-07 05:01:33 -05:00
Marcel Admiraal a24c38d1a8 Rename Vector2.tangent() to Vector2.orthogonal() 2020-12-06 18:16:06 +00:00
Rémi Verschelde 64e893deac
doc: Sync classref to add operators after #43419 2020-11-10 15:00:50 +01:00
Rémi Verschelde 0f249f5c0a
Variant: Sync docs with new constructors, fixups after #43403
Change DocData comparators for MethodDoc and ArgumentDoc to get a better
ordering of constructors.
2020-11-09 23:39:53 +01:00
Rémi Verschelde 424cd00f8b
doc: Sync classref with current source + fixup some bindings
Includes various changes triggered by the refactoring of method bindings.
2020-11-04 15:38:26 +01:00
Aaron Franke 439be614f4
Link to demos from within the class reference 2020-10-01 23:57:21 -04:00
Haoyu Qiu aa7ce12bee Surrounds boolean false with code tag 2020-09-25 00:00:22 +08:00
Hugo Locurcio c4903a603b
Add link titles for all links in the class reference
This makes them display in a nicer way in the editor help.
(The title will display instead of the full URL.)
2020-08-31 14:22:07 +02:00
Tomasz Chabora a09078e64b Improve Vector2.angle() description 2020-08-05 00:18:19 +02:00