How to make ranged item projectiles break through blocks

Started by Kvngsavage118 on

Topic category: Help with Minecraft modding (Java Edition)

Active 8 months ago
Joined Jul 2023
Points:
217

User statistics:

  • Modifications: 0
  • Forum topics: 5
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 15
How to make ranged item projectiles break through blocks
Wed, 08/30/2023 - 20:17 (edited)

So I'm making a mod where I have a ranged weapon that shoots a projectile and said projectile is supposed to break through blocks.  An example of what I am trying to reproduce would be something similar to hollow purple from orca's jujutsucraft mod, where the projectile launches and breaks through all blocks it touches rather than exploding on impact.  I would appreciate if I got some help on how to reproduce this.  I've tried the "remove block" command when projectile touches block procedure in conjunction with "wait x ticks to despawn" block as well.

Edited by Kvngsavage118 on Wed, 08/30/2023 - 20:17
Active 2 weeks ago
Joined May 2024
Points:
137

User statistics:

  • Modifications: 1
  • Forum topics: 6
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 39
@Kvngsavage118 did you…
Tue, 05/28/2024 - 12:32

@Kvngsavage118 did you figure this out? I need the same thing

Active 1 year ago
Joined May 2024
Points:
83

User statistics:

  • Modifications: 0
  • Forum topics: 1
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 3
You can remove blocks in a…
Tue, 05/28/2024 - 13:05

You can remove blocks in a small area around the projectile in the tick update trigger, so as the projectile is moving it will remove any blocks it gets close to

Active 2 weeks ago
Joined May 2024
Points:
137

User statistics:

  • Modifications: 1
  • Forum topics: 6
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 39
Thanks!
Tue, 05/28/2024 - 13:19

Thanks!

Active 2 weeks ago
Joined May 2024
Points:
137

User statistics:

  • Modifications: 1
  • Forum topics: 6
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 39
I think orca uses an entity…
Tue, 05/28/2024 - 13:20

I think orca uses an entity tho, do you know how I could push it forward?

Active 1 year ago
Joined Jun 2024
Points:
72

User statistics:

  • Modifications: 0
  • Forum topics: 0
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 1
I can't find the tick…
Tue, 06/18/2024 - 11:27

I can't find the tick trigger can you please explain more about it ?

Active 8 months ago
Joined Jul 2023
Points:
217

User statistics:

  • Modifications: 0
  • Forum topics: 5
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 15
I figured this out a while…
Sun, 06/23/2024 - 23:08

I figured this out a while ago.  You need to use the "attempt to override motion vector" of entity on its tick update.  You also need to override it based on your x,y, and z angle look vectors.