Confused a little bit on this issue, NPC size reading doesnt work as if its bigger then 1x1 it will noclip through walls, but anything 1x1 doesnt.
Code:
public int getNextWalkingDirection() {
currentTile = new Tile(absX + moveX, absY + moveY, heightLevel);
if(!WalkingCheck.tiles.containsKey(currentTile.getH() << 28 | currentTile.getX() << 14 | currentTile.getY())){
int dir;
dir = misc.direction(absX, absY, (absX + moveX), (absY + moveY));
if (dir == -1)
return -1;
dir >>= 1;
absX += moveX;
absY += moveY;
return dir;
} else if(WalkingCheck.tiles.get(currentTile.getH() << 28 | currentTile.getX() << 14 | currentTile.getY()) == true) {
return -1;
} else {
return -1;
}
}
what shall be done?