Hi all, I'm currently working on a SMAPI mod that would result in your pet following you around your farm (and perhaps eventually beyond), however working with movement and animation has been challenging. I've managed to get my cat to walk towards me using the following: Code: if (followingPlayer) { if (farmer.Equals(Utility.isThereAFarmerWithinDistance(pet.getTileLocation(), 10))) { var velocity = Utility.getVelocityTowardPoint(pet.position, farmer.position, 3); pet.xVelocity = velocity.X; pet.yVelocity = velocity.Y * -1; pet.faceGeneralDirection(farmer.position, 0); pet.animateInFacingDirection(Game1.currentGameTime); } } However, I notice that the animation isn't always correct (i.e. standing still animation while moving) and it will rapidly try and face a different direction every few seconds. I'm guessing this is because it's internal update method is trying to do it's own thing. If anyone has any suggestions on how to temporarily override the movement for an NPC, I would appreciate it
Dude, I hope someone helps you with this!! Also, if you could maybe look into having multiple types of the same pet (different breeds tho) in smapi too would be bossss o:
I definitely wouldn't mind looking into it once I've gotten pass some of the initial hurdles of what I'm working on