How to check if riding my custom entity?

Started by Levi Kornelsen on

Topic category: Help with modding (Java Edition)

Last seen on 16:38, 8. Sep 2022
Joined Mar 2016
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How to check if riding my custom entity?

I've got a custom vehicle mount and have sorted out controls for it that run off keybinds - you hit jump while riding, it jumps, all that.

What I'm having trouble with is how to check that the player is riding the RIGHT entity.  It's feels like it should be just a set of code blocks that go "if [get entity player is riding] = [this entity] then do [that bit]," but while I've found most of the theoretical parts of that, I can't actually find the [this entity] piece or find another way to get the "check that this is the right mount" to assemble into a set of blocks that actually click together.

I suspect this is dead simple and I'm missing something.  Anyone?

Last seen on 16:38, 8. Sep 2022
Joined Mar 2016
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
(Oh, bloody hell, found theā€¦
Mon, 08/15/2022 - 03:35

(Oh, bloody hell, found the bit I need right at the bottom of the "Logic" section.)