How can an existing mob be made peaceful under conditions?

Started by 8Vulcannus8 on

Topic category: Help with modding (Java Edition)

Last seen on 15:52, 22. Apr 2022
Joined Aug 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How can an existing mob be made peaceful under conditions?

I want to make a withers skeleton peaceful and follow a player if he has a sword in his inventory (The Player). I don't know how to do this so please help me. I'm in 1.12.2. By the way: sorry for the bad english

Last seen on 22:15, 1. Mar 2024
Joined Jul 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I'm not sure if this works…
Sun, 08/22/2021 - 23:21

I'm not sure if this works with 1.12.2, but if the conditions are true, replace the entity with a different but identical peaceful entity and set health to the existing health of the original one.

Last seen on 15:52, 22. Apr 2022
Joined Aug 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I want to make the…
Sat, 08/28/2021 - 18:48

I want to make the witherskeleton attack players that dont have the sword and it has to be the original minecraft witherskeleton

Last seen on 22:15, 1. Mar 2024
Joined Jul 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Make a completely separate…
Sun, 08/29/2021 - 16:56

Make a completely separate mob with the same model and texture of a wither skeleton. Then, make an on-player-update-tick procedure checking if the sword is in hand and if there's a wither skeleton nearby. When those are true, make it spawn and tame the new mob and despawn the old one. Ask if you have any questions.

Last seen on 22:15, 1. Mar 2024
Joined Jul 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
The only trouble I see is…
Sun, 08/29/2021 - 16:58

The only trouble I see is actually getting the wither skeleton model, but I'm sure you can find it somewhere. Make sure it's ".java" I think

Last seen on 15:52, 22. Apr 2022
Joined Aug 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Finding the model is easy…
Mon, 08/30/2021 - 20:15

Finding the model is easy bcs i have an aplication. but the problem is the nether. thats why i want to make it real witherskeletons 

and not costum. the real ones would still attack the player.

Last seen on 15:52, 22. Apr 2022
Joined Aug 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
sorry i haven't read your…
Mon, 08/30/2021 - 20:20
sorry i haven't read your post in full (now i did) but how do i check if a mob is nearby and make that it only attacks players without the sword
Last seen on 15:52, 22. Apr 2022
Joined Aug 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
sorry i haven't read your…
Fri, 09/03/2021 - 17:42

sorry i haven't read your post in full (now i did) but
how do i check if a mob is
nearby and make that it only attacks players
without the sword