Skip to content

Conversation

kan6868
Copy link
Contributor

@kan6868 kan6868 commented Nov 10, 2023

I'm doing some projects using Box2D and really need some methods inside Box2D that Solar2D doesn't provide yet.

Some previous requests also existed on the forum:

https://forums.solar2d.com/t/possible-physics-additions-feature-request/342254

--

  • body:getWorldVector(x, y) --Get the world coordinates of a vector given the local coordinates.

  • body:getInertia() -- Get the rotational inertia of the body about the local origin.

  • body:getLinearVelocityFromWorldPoint(worldX, worldY) -- Get the world linear velocity of a world point attached to this body.

  • body:getLinearVelocityFromLocalPoint(localX, localY) -- Get the world velocity of a local point.

- body:getWorldVector(x, y) --Get the world coordinates of a vector given the local coordinates.

- body:getInertia() -- Get the rotational inertia of the body about the local origin.

- body:getLinearVelocityFromWorldPoint(worldX, worldY) -- Get the world linear velocity of a world point attached to this body.

- body:getLinearVelocityFromLocalPoint(localX, localY) -- Get the world velocity of a local point.
@kan6868 kan6868 requested a review from Shchvova as a code owner November 10, 2023 06:06
@CLAassistant
Copy link

CLAassistant commented Nov 10, 2023

CLA assistant check
All committers have signed the CLA.

@kan6868
Copy link
Contributor Author

kan6868 commented Nov 16, 2023

I don't know why these methods only exist on the simulator, not in the build. I will reopen once I get it resolved.

@kan6868 kan6868 closed this Nov 16, 2023
@kan6868 kan6868 reopened this Nov 17, 2023
@Shchvova
Copy link
Contributor

To get methods into the build you have to build templates for specified platforms. There are some issues with the PR, I will fill them UP and merge it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants