Skip to content

Commit

Permalink
Merge pull request #1 from KevinSenez/alkharid
Browse files Browse the repository at this point in the history
fix: Proper npc direction
  • Loading branch information
KevinSenez authored Feb 24, 2023
2 parents dc1f33e + 4a01d48 commit ceca561
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions game/src/main/kotlin/gg/rsmod/game/model/Direction.kt
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,21 @@ enum class Direction(val orientationValue: Int, val walkValue: Int) {

NONE(orientationValue = -1, walkValue = -1),

NORTH_WEST(orientationValue = 0, walkValue = 5),
NORTH_WEST(orientationValue = 0, walkValue = 4),

NORTH(orientationValue = 1, walkValue = 6),
NORTH(orientationValue = 1, walkValue = 5),

NORTH_EAST(orientationValue = 2, walkValue = 7),
NORTH_EAST(orientationValue = 2, walkValue = 6),

WEST(orientationValue = 3, walkValue = 3),

EAST(orientationValue = 4, walkValue = 4),
EAST(orientationValue = 4, walkValue = 7),

SOUTH_WEST(orientationValue = 5, walkValue = 0),
SOUTH_WEST(orientationValue = 5, walkValue = 2),

SOUTH(orientationValue = 6, walkValue = 1),

SOUTH_EAST(orientationValue = 7, walkValue = 2);
SOUTH_EAST(orientationValue = 7, walkValue = 0);

fun isDiagonal(): Boolean = this == SOUTH_EAST || this == SOUTH_WEST || this == NORTH_EAST || this == NORTH_WEST

Expand Down

0 comments on commit ceca561

Please sign in to comment.