Changed hashCode() in Blox to take the world into account
This commit is contained in:
parent
eef287f526
commit
2860b13412
@ -105,11 +105,12 @@ public class Blox {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int hashCode() {
|
public int hashCode() {
|
||||||
int result = 0;
|
int result = 18;
|
||||||
|
|
||||||
result += x * 92821;
|
result = result * 27 + x;
|
||||||
result += y * 92821;
|
result = result * 27 + y;
|
||||||
result += z * 92821;
|
result = result * 27 + z;
|
||||||
|
result = result * 27 + world.hashCode();
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user