Started by
Mopru
on
Topic category: Help with Minecraft modding (Java Edition)
Kind of confused with this one. when I use "Attempt to override motion vector of entity" i can only make it go in a direction based on coordinates, so how do I instead launch an entity through directions through pitch (horizontal direction) and maybe even yaw and roll
There's a seperate function to manage yaw and pitch; the x/y/z Override Motion Vector does not ask for coordinates, but rather for x/y/z velocities. (How much to add to the player's current velocity in each axis. I think they renamed it 'motion delta' in the latest version, but it's essentially velocity.) As such, if you want to update the player's current velocity, you would override the entity's motion vector to their current x/y/z velocities, plus a certain amount, or multiplied by a certain amount, etc. You can also use the look angle vector of the current entity as velocities and multiply them by a desired value to move an entity in the direction it's currently looking at. For more complex velocity changes, you'll need some basic trig, but for basic stuff it's usually not necessary.