package chess.view.DDDrender; import org.joml.Vector2f; import chess.model.Coordinate; class DDDPlacement { static public Vector2f coordinates_to_vector(Coordinate coo) { // float newX = switch (x) { // case 0 -> -1 + 0.125f; // case 1 -> -1 + 0.375f; // case 2 -> -1 + 0.625f; // case 3 -> -1 + 0.875f; // default -> 0; // }; return new Vector2f(-1.0f + 0.125f + coo.getX() * 0.250f, -1.0f + 0.125f + coo.getY() * 0.250f); } }