Class MobileTreasureHider
- java.lang.Object
-
- com.treasure.hunt.strategy.hider.impl.StatisticalHider
-
- com.treasure.hunt.strategy.hider.impl.MobileTreasureHider
-
- All Implemented Interfaces:
HideAndSeekHider<AngleHint>
,Hider<AngleHint>
public class MobileTreasureHider extends StatisticalHider implements HideAndSeekHider<AngleHint>
A Strategy using theStatisticalHider
as Base Implementation, but being able to move the treasure while the game is running and therefore implementing to theHideAndSeekHider
interfaceThe strategy uses the
GameField
to maintain its state
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
mindTreasureRelocationDistance_Preference
static java.lang.String
treasureBeforeHintFirst_Preference
static java.lang.String
walkedPathLengthForTreasureRelocation_Preference
-
Fields inherited from class com.treasure.hunt.strategy.hider.impl.StatisticalHider
absoluteAreaCutoff, badHintWeight_Preference, centroidDistanceToTreasure, counterStrategyGeometryCutoff, currentPossibleArea, DistanceFromNormalAngleLineToTreasureWeight_Preference, distanceFromNormalAngleRay, DistanceFromResultingCentroidToTreasureWeight_Preference, gameField, gf, preferredHintSize, relativeAreaCutoff, relativeAreaCutoffWeight_Preference, startingPoint, treasure
-
-
Constructor Summary
Constructors Constructor Description MobileTreasureHider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AngleHint
move(SearchPath searchPath)
protected double
rateHint(AngleHintStatistic ahs)
Rates the Given Hint with a custom function, saves the result in the AngleHintStatistic - Wrapper and returns the result-
Methods inherited from class com.treasure.hunt.strategy.hider.impl.StatisticalHider
eval, fillDistanceToCentroid, fillDistanceToNormalLine, filterForValidHints, generateHints, getTreasureLocation, init
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.treasure.hunt.strategy.hider.Hider
getTreasureLocation, init
-
-
-
-
Field Detail
-
treasureBeforeHintFirst_Preference
public static final java.lang.String treasureBeforeHintFirst_Preference
- See Also:
- Constant Field Values
-
walkedPathLengthForTreasureRelocation_Preference
public static final java.lang.String walkedPathLengthForTreasureRelocation_Preference
- See Also:
- Constant Field Values
-
mindTreasureRelocationDistance_Preference
public static final java.lang.String mindTreasureRelocationDistance_Preference
- See Also:
- Constant Field Values
-
-
Method Detail
-
move
public AngleHint move(SearchPath searchPath)
- Specified by:
move
in interfaceHider<AngleHint>
- Overrides:
move
in classStatisticalHider
- Parameters:
searchPath
- theSearchPath
, theSearcher
did last- Returns:
- T a (new) hint.
-
rateHint
protected double rateHint(AngleHintStatistic ahs)
Description copied from class:StatisticalHider
Rates the Given Hint with a custom function, saves the result in the AngleHintStatistic - Wrapper and returns the result- Specified by:
rateHint
in classStatisticalHider
- Parameters:
ahs
- The AngleHint - Wrapper , in which the result is saved- Returns:
- the rating of the hint
-
-