How can i make the projectile spawn in front of the player

Started by Nepzera on

Topic category: Help with MCreator software

Joined Dec 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How can i make the projectile spawn in front of the player
Fri, 12/20/2024 - 22:37 (edited)

https://prnt.sc/e66uF0JwCkgf

 

I created a keybind script to shoot a projectile the problem is that i want to make the projectile spawn like 2-4 blocks ahead of where the player is looking, do any of u guys know how can i fix that?

Edited by Nepzera on Fri, 12/20/2024 - 22:37
Joined Apr 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
In the procedure, look for…
Fri, 12/20/2024 - 23:25

In the procedure, look for the part which has the x, y and z factors. Go into the math tab and grab a math block (The one which has the plus sign, minus etc icons) and place it into the workspace. You need it to spawn in front so take the Z facter out of the block and add it into the first slot of the math block. Then in the second slot add a number block which is also found in the math tab and change the number from 0 to whatever number you want. Hope this helps!