Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @Override
- public int hashCode() {
- final int prime = 31;
- int result = 1;
- result = prime * result + Float.floatToIntBits(depth);
- result = prime * result + (generate ? 1231 : 1237);
- result = prime * result + Float.floatToIntBits(hardness);
- result = prime * result + nodes;
- result = prime * result + Float.floatToIntBits(rarity);
- result = prime * result + Float.floatToIntBits(resistance);
- result = prime * result + size;
- result = prime * result + Float.floatToIntBits(spread);
- return result;
- }
- @Override
- public boolean equals(Object obj) {
- if (this == obj)
- return true;
- if (obj == null)
- return false;
- if (getClass() != obj.getClass())
- return false;
- Settings other = (Settings) obj;
- if (Float.floatToIntBits(depth) != Float.floatToIntBits(other.depth))
- return false;
- if (generate != other.generate)
- return false;
- if (Float.floatToIntBits(hardness) != Float.floatToIntBits(other.hardness))
- return false;
- if (nodes != other.nodes)
- return false;
- if (Float.floatToIntBits(rarity) != Float.floatToIntBits(other.rarity))
- return false;
- if (Float.floatToIntBits(resistance) != Float.floatToIntBits(other.resistance))
- return false;
- if (size != other.size)
- return false;
- if (Float.floatToIntBits(spread) != Float.floatToIntBits(other.spread))
- return false;
- return true;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement