How do you make an NPC chase and attack you in a Piggy type game?

Hi fellow developers! I have been having an issue with my piggy type/based game. I can not figure out how to make it chase you and attack you. This is the main part of piggy based games and I really need help! I am willing to hire someone, or if some really nice people are there in the comments, go ahead and paste it in there!

2 Likes

Humanoid:MoveTo()

Find the nearest player and move to the player

Thanks man! Imma see if it works. Before I try, does the character have to be R6 or R15?

No problem, both R6 and R15 characters should work

Does the character attack you, Like in piggy?

You have to use BasePart.Touched and detect when a player touches the character and damage them. You can always look at free model zombies for reference.

Thank you. Have a nice day! (I love your description) :joy:

1 Like