Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement missing Basis and Transform methods #290

Closed
ghost opened this issue Feb 7, 2020 · 8 comments · Fixed by #791 or #898
Closed

Implement missing Basis and Transform methods #290

ghost opened this issue Feb 7, 2020 · 8 comments · Fixed by #791 or #898
Labels
c: core Component: core (mod core_types, object, log, init, ...) feature Adds functionality to the library good first issue
Milestone

Comments

@ghost
Copy link

ghost commented Feb 7, 2020

The interfaces of Basis and Transform aren't on par with GDScript's yet. A list of methods available in GDScript on those types can be found at their respective doc pages:

Additionally, methods available to the engine but not exposed to GDScript can be implemented if desirable:

If any of the methods need to be manually implemented, sanity tests should be added to make sure their output match Godot's.

@ghost ghost added feature Adds functionality to the library c: core Component: core (mod core_types, object, log, init, ...) good first issue labels Feb 7, 2020
@ghost ghost mentioned this issue Feb 7, 2020
halzy added a commit to halzy/godot-rust that referenced this issue May 26, 2020
halzy added a commit to halzy/godot-rust that referenced this issue May 26, 2020
halzy added a commit to halzy/godot-rust that referenced this issue May 27, 2020
halzy added a commit to halzy/godot-rust that referenced this issue May 28, 2020
halzy added a commit to halzy/godot-rust that referenced this issue May 29, 2020
ghost pushed a commit that referenced this issue May 29, 2020
@ghost
Copy link
Author

ghost commented May 29, 2020

Basis methods added in #373.

@denismaxim0v
Copy link

shouldn't this be closed?

@ghost
Copy link
Author

ghost commented Feb 5, 2021

Transform still has little mathematical methods ported.

@bluenote10
Copy link
Contributor

Note that GDScript's Transform members have some ugly semantic inconsistencies, see godotengine/godot-proposals#1336. Perhaps it even would make sense to anticipate that change.

@ghost
Copy link
Author

ghost commented Feb 5, 2021

Note that GDScript's Transform members have some ugly semantic inconsistencies, see godotengine/godot-proposals#1336. Perhaps it even would make sense to anticipate that change.

The point of implementing them is to make porting easier, so for this issue we care more about what the methods are, not what they should be.

@Bromeon
Copy link
Member

Bromeon commented Oct 30, 2021

Actually the missing methods were implemented for Transform2D; Transform still needs doing.

@Bromeon Bromeon reopened this Oct 30, 2021
@Bromeon Bromeon added this to the v0.10.1 milestone Nov 1, 2021
@Hexorg
Copy link
Contributor

Hexorg commented Jun 13, 2022

I'm taking a stab at this (Hi all). The Godot implementation seems to be inconsistent - some of the in-place methods call copy methods and then assign the result to self. Do you want to reproduce the same behavior in godot-rust, or can I have some freedom to fix those as I implement them?

@Bromeon
Copy link
Member

Bromeon commented Jun 13, 2022

@Hexorg Thank you! I would only provide immutable methods for now (i.e. those returning a new object, not those modifying the existing one).

Feel free to improve on the Godot implementation where needed!

Would be great to add some tests with hardcoded values (ideally obtained by GDScript), like we did for Quat or Basis.

@Bromeon Bromeon linked a pull request Jun 14, 2022 that will close this issue
@Bromeon Bromeon modified the milestones: v0.10.1, v0.10.2 Sep 3, 2022
@Bromeon Bromeon modified the milestones: v0.10.2, v0.11.x Oct 1, 2022
@bors bors bot closed this as completed in #898 Oct 18, 2022
@chitoyuu chitoyuu modified the milestones: v0.11.x, v0.11.1 Dec 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: core Component: core (mod core_types, object, log, init, ...) feature Adds functionality to the library good first issue
Projects
None yet
5 participants