public void setTransient(Registry rg, AI a) {
        registry = rg;
        ai = a;
        for(int i = 0; i < subGoals.size(); i++) {
            subGoals.get(i).setTransient(rg, a);
        }
    }