Robots and Finite-State Machines
By Everett F. Carter, Jr.
Dr. Dobb's Journal February 1997
: ARBITRATE ( this sequence gives a subsumption behaviour to the system ) CONTACT_VEC @ DUP IF EXECUTE EXIT ELSE DROP THEN PROXIMITY_VEC @ DUP IF EXECUTE EXIT ELSE DROP THEN EXPLORE_VEC @ DUP IF EXECUTE EXIT ELSE DROP THEN WALK_VEC @ DUP IF EXECUTE EXIT ELSE DROP THEN ;
Example 2: The arbitrator.
Copyright © 1997, Dr. Dobb's Journal