ViaBackwards/common/src/main/java/nl/matsv/viabackwards/protocol/protocol1_12_2to1_13/data/PaintingMapping.java

63 lines
1.9 KiB
Java

/*
* This file is part of ViaBackwards - https://github.com/ViaVersion/ViaBackwards
* Copyright (C) 2016-2021 ViaVersion and contributors
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package nl.matsv.viabackwards.protocol.protocol1_12_2to1_13.data;
import us.myles.viaversion.libs.fastutil.ints.Int2ObjectMap;
import us.myles.viaversion.libs.fastutil.ints.Int2ObjectOpenHashMap;
public class PaintingMapping {
private static final Int2ObjectMap<String> PAINTINGS = new Int2ObjectOpenHashMap<>(26, 1F);
public static void init() {
add("Kebab");
add("Aztec");
add("Alban");
add("Aztec2");
add("Bomb");
add("Plant");
add("Wasteland");
add("Pool");
add("Courbet");
add("Sea");
add("Sunset");
add("Creebet");
add("Wanderer");
add("Graham");
add("Match");
add("Bust");
add("Stage");
add("Void");
add("SkullAndRoses");
add("Wither");
add("Fighters");
add("Pointer");
add("Pigscene");
add("BurningSkull");
add("Skeleton");
add("DonkeyKong");
}
private static void add(String motive) {
PAINTINGS.put(PAINTINGS.size(), motive);
}
public static String getStringId(int id) {
return PAINTINGS.getOrDefault(id, "kebab");
}
}