how do i add recoil to ranged items?

Started by Jromo2 on

Topic category: Help with modding (Java Edition)

Last seen on 03:37, 11. Mar 2023
Joined Oct 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
how do i add recoil to ranged items?

How do you add recoil to ranged items when used? I just want the player to be sent in the opposite direction that he's facing. I made an item in my other mod that sends you in the direction the player is facing but I do not know how to make it in the opposite direction.

You could use set movement…
Sat, 01/30/2021 - 09:18

You could use set movement vector or set entity location procedure blocks for this

Last seen on 03:37, 11. Mar 2023
Joined Oct 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Yes but i do not know how to…
Wed, 02/03/2021 - 08:20

Yes but i do not know how to make it relative to the players pitch and yaw. I only know how to set the players velocity to a specific x y or z. I want to make it push you the opposite way you're looking.

Last seen on 19:20, 25. Jun 2023
Joined Mar 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
well than do negative values
Sun, 01/02/2022 - 05:50

well than do negative values