[SOLVED] Procedure where player looks

Started by Mars33311 on

Topic category: Help with modding (Java Edition)

Last seen on 08:39, 19. Nov 2020
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
[SOLVED] Procedure where player looks
Mon, 08/17/2020 - 10:49 (edited)

In my mod I want stuff like player teleporting where they looks and explosions there they look but don't know how. I have searched on the website about thing like raytrace but I realised if I, say, made the player move 5 blocks in their x raytrace, it means that they would be teleporting backwards or sideways if they are facing like z or away from x. This also means that if the player is looking partially up or down they still will only go in one direction. I am really stumped and don't know how to code. Please help or add a new feature in the procedure maker! 

Edited by Mars33311 on Mon, 08/17/2020 - 10:49
Last seen on 05:29, 31. Jan 2022
Joined Nov 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
when using the raytrace…
Wed, 07/29/2020 - 08:28

when using the raytrace function, use all 3 coordinates together. for example, do something like this: move target entity to (look X position of target entity), (look Y pos...), (look Z pos...). this will move your target entity to where they are looking.

Last seen on 08:39, 19. Nov 2020
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Sorry but I still don't…
Thu, 07/30/2020 - 06:57

Sorry but I still don't understand. Can you show me a picture of what you are trying to say, and I am pretty sure that it only works in one angle.

Last seen on 08:39, 19. Nov 2020
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Does x mean directly in…
Tue, 08/11/2020 - 09:52

Does x mean directly in front of the player, and z the right of the player no matter where they look? Because my understanding of it is that they are more like North and East. If so, I do not know how one can do it.

Last seen on 16:48, 17. Dec 2020
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
X = right, Y = up, Z = front…
Tue, 08/11/2020 - 10:22

X = right, Y = up, Z = front

look X is basically what's to the side of the player's vision, look Y is what's above the player's vision, and Z is what's in front of the player's vision

combining these gets you the coordinate of the block you're looking at

(Teleport target entity to (look X) (look Y) (look Z))

Last seen on 08:39, 19. Nov 2020
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Oh, thank you very much!  
Thu, 08/13/2020 - 06:38

Oh, thank you very much!

 

Last seen on 01:14, 25. Mar 2024
Joined Apr 2015
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Is there a way to set a max…
Tue, 10/27/2020 - 05:20

Is there a way to set a max distance?

Last seen on 08:39, 19. Nov 2020
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
hurn, if say the range if 5,…
Wed, 11/18/2020 - 07:28

hurn, if say the range if 5, I am thinking of checking if the block 5 blocks away from you is air, and if false, then check with the fourth, and so on

Last seen on 23:41, 3. Jun 2021
Joined Dec 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
hey uh how do you MAKE this…
Fri, 12/04/2020 - 19:48

hey uh how do you MAKE this though

Last seen on 16:55, 21. Nov 2023
Joined Aug 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Yeah, I don't really…
Mon, 06/07/2021 - 21:20

Yeah, I don't really understand how to do it either.

Last seen on 15:54, 6. Jun 2023
Joined Dec 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Can u also make it so that a…
Fri, 07/09/2021 - 18:43

Can u also make it so that a procedure gets triggered if you rightclick on one side of a block not the whole block but only a 16x16x8 slab-sized section

Last seen on 09:26, 23. Aug 2021
Joined Jan 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I can't find the "move…
Mon, 07/19/2021 - 17:57

I can't find the "move provided entity" block.

Last seen on 14:01, 28. Jan 2022
Joined Nov 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Ressurection, I hape Strykz…
Thu, 12/09/2021 - 19:38

Ressurection, I hape Strykz problem, i can't find the block