mirror of
https://github.com/GTNewHorizons/ForestryMC.git
synced 2026-11-26 23:03:18 +00:00
Fix farm reporting wrong location for hasCultivated listeners
This commit is contained in:
1 parent
272152d48e
commit
7dff774368
1 file changed
+3
-3
@@ -224,7 +224,6 @@ public class TileFarmPlain extends TileFarm implements IFarmHousing, ISocketable
|
||||
|
||||
TreeMap<ForgeDirection, List<FarmTarget>> targets = new TreeMap<ForgeDirection, List<FarmTarget>>();
|
||||
|
||||
|
||||
for (ForgeDirection farmSide : CARDINAL_DIRECTIONS) {
|
||||
|
||||
int farmSize;
|
||||
@@ -477,9 +476,10 @@ public class TileFarmPlain extends TileFarm implements IFarmHousing, ISocketable
|
||||
}
|
||||
|
||||
private boolean cultivateTarget(FarmTarget target, IFarmLogic logic) {
|
||||
if (logic.cultivate(target.getStart().x, target.getStart().y + target.getYOffset(), target.getStart().z, target.getDirection(), target.getExtent())) {
|
||||
Vect targetPosition = target.getStart().add(0, target.getYOffset(), 0);
|
||||
if (logic.cultivate(targetPosition.x, targetPosition.y, targetPosition.z, target.getDirection(), target.getExtent())) {
|
||||
for (IFarmListener listener : eventHandlers) {
|
||||
listener.hasCultivated(logic, target.getStart().x, target.getStart().y, target.getStart().z, target.getDirection(), target.getExtent());
|
||||
listener.hasCultivated(logic, targetPosition.x, targetPosition.y, targetPosition.z, target.getDirection(), target.getExtent());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user