modifyVelocity
fun Entity.modifyVelocity(x: Number = 0.0, y: Number = 0.0, z: Number = 0.0, add: Boolean = true)(source)
Changes the velocity of this Entity and calls markVelocityDirty.
Parameters
add
Whether the velocity should be added to the current one or not. Set this to false if you want to overwrite the previous velocity.
Changes the velocity of this Entity using the given mutation logic in block. After that, markVelocityDirty is called.
Sets the Entitys velocity to vec and calls markVelocityDirty.