How do I modify Vanilla Zombies? + How does one Quilt?

Started by MinerB4Gaming on

Topic category: Help with modding (Java Edition)

Last seen on 07:39, 5. Dec 2023
Joined Mar 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How do I modify Vanilla Zombies? + How does one Quilt?
Mon, 12/04/2023 - 05:08 (edited)

"I got two problems, and writing about them ain't one."

I'm trying to make a zombie poison feature in my mod, unfortunately I have no idea how to check when a player gets hit by a certain mob (mob is vanilla).
I looked for the answer but all I got were incomprehensible feelings and a stupid mask guides on how to apply said features to entities made by the mod, that and some outdated topic that doesn't work, wouldn't even have worked for me, and then spiraled into madness.
I found this code from a post, which I kinda understood... but I don't know what to do with it.

Don't care, too long: Problem is I want to make sure the attacker is a #minecraft:zombie, they melee the player, and the player is given an effect.
 


Another thing is that I looked for a Quilt Generator, but couldn't find one... does Fabric work fine?

Edited by MinerB4Gaming on Mon, 12/04/2023 - 05:08
Last seen on 17:28, 24. Jul 2024
Joined Oct 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Make a procedure that checks…
Mon, 12/04/2023 - 07:30

Make a procedure that checks when an entity attacks. If it is your zombie, give the entity the closest poison. 

Last seen on 07:39, 5. Dec 2023
Joined Mar 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I'll try that
Tue, 12/05/2023 - 03:20

I'll try that

Last seen on 07:39, 5. Dec 2023
Joined Mar 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
It kind of worked, thanks!…
Tue, 12/05/2023 - 04:02

It kind of worked, thanks! Entity attacked provides a "sourceentity" along with a "entity" dependency which helps it be more precise on who to attack.