
APT.all-test.MOUTBot.execute-mission.defend.predict-enemy.simulate-move-to-area.soar Maven / Gradle / Ivy
echo "\nLoading execute-mission/defend/predict-enemy/internal-simulation"
#If the last-node's area is not our current area
#then update the current area (as we move through
#the environment).
sp {predict-enemy*apply*goto-next-room*internal-simulation
(state ^name { <> predict-enemy }
^predicting true
^top-state.map
^operator )
( ^type move-to-area)
( ^current-area { <> }
^last-node.area )
-->
(write (crlf) |+++++++++ Moving from | | to | )
( ^current-area -
^current-area )
}
#Every time we move to a node in a new room, increment
#the predicted-distance
#FIXME: Where does this get initialized to zero?
sp {predict-enemy*apply*goto-next-room*internal-simulation*distance
(state ^name { <> predict-enemy }
^predicting true
^operator
^top-state )
( ^predicted-distance
^map )
( ^type move-to-area)
( ^current-area { <> }
^last-node.area )
-->
(write (crlf) |+++++++++ Distance traveled | (+ 1))
( ^predicted-distance -
^predicted-distance (+ 1))
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy