E.g. execute shouldn't be called from the executor and passed in an automaton, it should be a function on the automaton's prototype. getCentroid() should be part of the regions's prototype (and possibly stored in the returned region object somewhere too). etc.
E.g. execute shouldn't be called from the executor and passed in an automaton, it should be a function on the automaton's prototype.
getCentroid()should be part of the regions's prototype (and possibly stored in the returned region object somewhere too). etc.