Trying to figure out enums java
20:41 03 Nov 2026

I am making a game outside my computer science class, currently trying to figure out how to use enum to pass in a position 1D array and output a preset position name (e.g. 1, 4 returns Town). Is there a way to smoothly set these values to my location names?
Ive tried looking on google but it is confusing me as gemini is terrible at explaining code.
This is currently a part of how im doing it. Ignore template as it is part of a map system that is in progress.

public static String check(int x, int y){
        if (x == 0 && y == 0){         //1,1
            template[x][y] = 'H';
            return "Home";
        }
        else if ((x == 1 && y == 1) || //2,2
                 (x == 0 && y == 5) || //1,6
                 (x == 5 && y == 6)){  //6,7
            template[x][y] = '\u03B3';
            return "Lake";
        }
        else if ((x == 4 && y == 0) || //5,1
                 (x == 5 && y == 1) || //6,2
                 (x == 6 && y == 2) || //7,3
                 (x == 7 && y == 2)){  //8,3
            template[x][y] = '\uFE4F';
            return "River";
        }
        else if ((x == 3 && y == 0) || //4,1
                 (x == 4 && y == 1) || //5,2
                 (x == 6 && y == 1) || //7,2
                 (x == 7 && y == 1)){  //8,2
            template[x][y] = '\u2056';
            return "Fen";
        }
java game-development