Jump to content
TrinityCore

Script c++ make a npc reset if he can't reach the player


sun864
 Share

Recommended Posts

Hello, I would like to add to my scripts a function (that will be called in UpdateAI()), this function would make the npc reset if he didn't hit the player for the last X second (and of course the timer begins when he doesn't move).

This function would prevent player to "cheat", like if the player is flying in the air and the npc can't hit the player, the npc would reset. I think I already saw a function that work like this but I couldn't find it,

so I was wondering if someone could help me to figure it out.

Thanks for your help.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...