Controlling NPC with Widgets

Is it possible to control an NPC character via a widget? Like, if I made a widget that has the player click on one of four arrow buttons to make the NPC go up, down, left or right?