Commit 83672616 authored by Matthew Hausknecht's avatar Matthew Hausknecht Committed by GitHub

Merge pull request #70 from CoolPhilChen/master

Thanks for the bugfix!
parents 269c6b69 3b2966b9
......@@ -29,8 +29,8 @@ FeatureExtractor::FeatureExtractor(int num_teammates,
penaltyAreaWidth = SP.penaltyAreaWidth();
// Maximum possible radius in HFO
maxHFORadius = sqrtf(pitchHalfLength * pitchHalfLength +
pitchHalfWidth * pitchHalfWidth);
maxHFODist = sqrtf(pitchHalfLength * pitchHalfLength +
pitchWidth * pitchWidth);
}
FeatureExtractor::~FeatureExtractor() {}
......@@ -68,7 +68,7 @@ void FeatureExtractor::addLandmarkFeatures(const rcsc::Vector2D& landmark,
} else {
Vector2D vec_to_landmark = landmark - self_pos;
addAngFeature(vec_to_landmark.th() - self_ang);
addDistFeature(vec_to_landmark.r(), maxHFORadius);
addDistFeature(vec_to_landmark.r(), maxHFODist);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment