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

improve movement terminology #654

Merged

Conversation

supersaiyansubtlety
Copy link
Member

rename "movement speed" things -> "acceleration factor"

They're used to calculate the vector added to velocity:

// Entity
public void updateVelocity(float accelerationFactor, Vec3d movementInput) {
    Vec3d lv = movementInputToAcceleration(movementInput, accelerationFactor, this.m_ndosmusf());
    this.setVelocity(this.getVelocity().add(lv));
}

Also, it didn't make sense for higher slipperiness to reduce the result of this method (formerly named getMovementSpeed):

// LivingEntity
private float getAccelerationFactor(float slipperiness) {
    return this.isOnGround() ? this.getBaseAccelerationFactor() * (0.21600002F / (slipperiness * slipperiness * slipperiness)) : this.getAirAccelerationFactor();
}

... but it does make sense for slipperiness to reduce acceleration.

@supersaiyansubtlety supersaiyansubtlety added t: refactor proposes a refactor v: snapshot targets a snapshot version of minecraft reviews needed please review this PR s: tiny PRs with less than 50 lines labels Oct 13, 2024
@supersaiyansubtlety supersaiyansubtlety self-assigned this Oct 13, 2024
@ix0rai ix0rai added the update-base used to notify github actions that the base branch should be updated label Oct 17, 2024
@github-actions github-actions bot changed the base branch from 1.21.2-pre3 to 1.21.2-pre5 October 17, 2024 02:13
Copy link
Contributor

🚀 Target branch has been updated to 1.21.2-pre5

@github-actions github-actions bot removed the update-base used to notify github actions that the base branch should be updated label Oct 17, 2024
@ix0rai ix0rai added the update-base used to notify github actions that the base branch should be updated label Oct 17, 2024
Copy link
Contributor

🚀 Target branch has been updated to 1.21.2-rc1

@github-actions github-actions bot changed the base branch from 1.21.2-pre5 to 1.21.2-rc1 October 17, 2024 16:26
@github-actions github-actions bot removed the update-base used to notify github actions that the base branch should be updated label Oct 17, 2024
Copy link
Member

@ix0rai ix0rai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks great!

@ix0rai ix0rai added the update-base used to notify github actions that the base branch should be updated label Oct 22, 2024
@github-actions github-actions bot changed the base branch from 1.21.2-rc1 to 1.21.2 October 22, 2024 22:48
Copy link
Contributor

🚀 Target branch has been updated to 1.21.2

@github-actions github-actions bot removed the update-base used to notify github actions that the base branch should be updated label Oct 22, 2024
@ix0rai ix0rai added the update-base used to notify github actions that the base branch should be updated label Oct 23, 2024
Copy link
Contributor

🚀 Target branch has been updated to 1.21.3

@github-actions github-actions bot changed the base branch from 1.21.2 to 1.21.3 October 23, 2024 16:18
@github-actions github-actions bot removed the update-base used to notify github actions that the base branch should be updated label Oct 23, 2024
@ix0rai ix0rai added final-comment-period is approved and will soon be merged if no issues are raised and removed reviews needed please review this PR labels Oct 29, 2024
@supersaiyansubtlety supersaiyansubtlety added v: release targets a release version of minecraft and removed v: snapshot targets a snapshot version of minecraft labels Oct 31, 2024
@ix0rai ix0rai merged commit 06e6440 into QuiltMC:1.21.3 Nov 4, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
final-comment-period is approved and will soon be merged if no issues are raised s: tiny PRs with less than 50 lines t: refactor proposes a refactor v: release targets a release version of minecraft
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants