mirror of
https://gitlab.com/2009scape/2009scape.git
synced 2026-08-23 19:35:10 -06:00
Critical fix because Devin problems
This commit is contained in:
parent
c96673989c
commit
4eeda96ff2
1 changed files with 7 additions and 8 deletions
|
|
@ -6,13 +6,8 @@ import core.game.node.entity.player.Player;
|
|||
import core.game.node.entity.skill.Skills;
|
||||
import core.game.node.item.Item;
|
||||
import core.game.node.item.GroundItem;
|
||||
import core.game.world.map.Direction;
|
||||
import core.game.world.map.Location;
|
||||
import core.game.world.map.Point;
|
||||
import core.game.world.map.RegionManager;
|
||||
import core.game.world.update.flag.chunk.ItemUpdateFlag;
|
||||
import core.game.world.map.*;
|
||||
import core.tools.Log;
|
||||
import core.tools.SystemLogger;
|
||||
|
||||
import java.util.Deque;
|
||||
import java.util.ArrayDeque;
|
||||
|
|
@ -247,7 +242,9 @@ public final class WalkingQueue {
|
|||
if (last == null) {
|
||||
last = p.getLocation();
|
||||
}
|
||||
if (last.getChunk() != p.getLocation().getChunk()) {
|
||||
int rx = last.getRegionX(), ry = last.getRegionY();
|
||||
int cx = p.getLocation().getRegionX(), cy = p.getLocation().getRegionY();
|
||||
if (Math.abs(rx - cx) >= 4 || Math.abs(ry - cy) >= 4) {
|
||||
p.getPlayerFlags().setUpdateSceneGraph(true);
|
||||
}
|
||||
}
|
||||
|
|
@ -270,7 +267,9 @@ public final class WalkingQueue {
|
|||
if (lastRegion == null) {
|
||||
lastRegion = location;
|
||||
}
|
||||
if (lastRegion.getChunk() != location.getChunk()) {
|
||||
int rx = lastRegion.getRegionX(), ry = lastRegion.getRegionY();
|
||||
int cx = location.getRegionX(), cy = location.getRegionY();
|
||||
if (Math.abs(rx - cx) >= 4 || Math.abs(ry - cy) >= 4) {
|
||||
p.getPlayerFlags().setUpdateSceneGraph(true);
|
||||
}
|
||||
if (move && p.getPlayerFlags().isUpdateSceneGraph()) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue