Hiya, I am attempting to use Citizens and our own Vehicle-System (Cars, Helicopters) to create NPCs that can find a car and drive it around. I've created two behavoirs, one for finding a car and a second one for entering and starting the car. I'm spawning the NPC using a simple command and add the goals right afterwards. After spawning, the NPC literally does nothing for some reason. Any help is welcome and appreciated!
Command:
private void spawn(Player p) {
NPC npc = NpcHook.getRegistry().createNPC(EntityType.PLAYER, "Driver");
npc.spawn(p.getLocation());
npc.getDefaultGoalController().addBehavior(Sequence.createSequence(new NpcVehicleFindBehavoir(npc), new NpcVehicleStartBehavoir(npc, NpcVehicleFindBehavoir.getClosestNpcVehicle(npc))),0);
ChatUtils.sendMessage(p, ChatUtils.MessageType.SUCCESS, "Done");
}