edu.udo.cs.ie.cowbots.internalActions.experimental2
Class exRandomScoutPosition

Package class diagram package exRandomScoutPosition
java.lang.Object
  extended by DefaultInternalAction
      extended by edu.udo.cs.ie.cowbots.internalActions.experimental2.exRandomScoutPosition

public class exRandomScoutPosition
extends DefaultInternalAction


Constructor Summary
exRandomScoutPosition()
           
 
Method Summary
private  java.awt.Point calculateRandomTarget(GridMap map, int i)
          Utility function for calculating a random target in the world, which is not a switch or an obstacle
 java.lang.Object execute(TransitionSystem ts, Unifier un, Term[] args)
          Modified scout destination finder.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

exRandomScoutPosition

public exRandomScoutPosition()
Method Detail

execute

public java.lang.Object execute(TransitionSystem ts,
                                Unifier un,
                                Term[] args)
                         throws java.lang.Exception
Modified scout destination finder. Returns a new scout position, tries to find a position which is unexplored. Will not return a positon on an obstacle or in own corral.

Throws:
java.lang.Exception

calculateRandomTarget

private java.awt.Point calculateRandomTarget(GridMap map,
                                             int i)
Utility function for calculating a random target in the world, which is not a switch or an obstacle

Returns:
Point encoding the coordinates