how do i add recoil to ranged items?

Started by Jromo2 on Sat, 01/30/2021 - 06:55

Topic category: Help with modding (Java Edition)

Last seen on 04:19, 19. Nov 2021
Joined Oct 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
how do i add recoil to ranged items?
Sat, 01/30/2021 - 06:55

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 04:19, 19. Nov 2021
Joined Oct 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • 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 04:00, 9. Apr 2022
Joined Mar 2020
Points:

User statistics:

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

well than do negative values