Trying to have my mob activitly avoid the sun

Started by VideoDrifter on

Topic category: Help with Minecraft modding (Java Edition)

Joined Dec 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Trying to have my mob activitly avoid the sun

So I am trying to make a procedure where my mob hides under a shaded area and avoid the sun, just like the skeleton in default minecraft. I use the "move indoors if possible" in ai and goals which it seems to work, but sometimes the mob forgets its in the sunlight moreover just stand there and die.The mob also try to chase the targeted entity when they are accidently push under the sun, instead of returning back to the shaded area. Does anyone have a better solution to this problem?

Joined Jul 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
have you got the ai in order…
Sun, 12/25/2022 - 09:15

have you got the ai in order so that get indoors is at the top?

 

Joined Dec 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
@ Sayne Yes it at the top,…
Sun, 12/25/2022 - 16:11

@ Sayne Yes it at the top, still the  "vampire" still try to chase me if slightly expose to the sun, as appose of ignoring me and trying to return to the tree.