mirror of
https://github.com/webbukkit/dynmap.git
synced 2024-11-24 03:05:28 +01:00
Maintain order on mod support API
This commit is contained in:
parent
cbfbfb4d58
commit
7f719bcead
@ -2,7 +2,7 @@ package org.dynmap.modsupport;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.util.HashMap;
|
||||
import java.util.LinkedHashMap;
|
||||
|
||||
import org.dynmap.Log;
|
||||
import org.dynmap.modsupport.impl.ModModelDefinitionImpl;
|
||||
@ -12,7 +12,7 @@ import org.dynmap.modsupport.impl.ModTextureDefinitionImpl;
|
||||
* Implementation of ModSupportAPI
|
||||
*/
|
||||
public class ModSupportImpl extends ModSupportAPI {
|
||||
private HashMap<String, ModTextureDefinitionImpl> txtDefsByModID = new HashMap<String, ModTextureDefinitionImpl>();
|
||||
private LinkedHashMap<String, ModTextureDefinitionImpl> txtDefsByModID = new LinkedHashMap<String, ModTextureDefinitionImpl>();
|
||||
|
||||
/**
|
||||
* Initialize mod support API
|
||||
|
@ -4,7 +4,7 @@ import java.io.File;
|
||||
import java.io.FileWriter;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.Locale;
|
||||
|
||||
import org.dynmap.hdmap.HDBlockModels;
|
||||
@ -29,7 +29,7 @@ public class ModModelDefinitionImpl implements ModModelDefinition {
|
||||
private boolean published = false;
|
||||
private ArrayList<BlockModelImpl> blkModel = new ArrayList<BlockModelImpl>();
|
||||
private ArrayList<PatchDefinition> blkPatch = new ArrayList<PatchDefinition>();
|
||||
private HashMap<String, PatchDefinition> blkPatchMap = new HashMap<String, PatchDefinition>();
|
||||
private LinkedHashMap<String, PatchDefinition> blkPatchMap = new LinkedHashMap<String, PatchDefinition>();
|
||||
private PatchDefinitionFactory pdf;
|
||||
|
||||
public ModModelDefinitionImpl(ModTextureDefinitionImpl txtDef) {
|
||||
|
@ -4,7 +4,7 @@ import java.io.File;
|
||||
import java.io.FileWriter;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.LinkedHashMap;
|
||||
|
||||
import org.dynmap.modsupport.BigChestTextureFile;
|
||||
import org.dynmap.modsupport.BiomeTextureFile;
|
||||
@ -27,7 +27,7 @@ public class ModTextureDefinitionImpl implements ModTextureDefinition {
|
||||
private final String modver;
|
||||
private ModModelDefinitionImpl modDef = null;
|
||||
private String texturePath;
|
||||
private HashMap<String, TextureFileImpl> txtFileByID = new HashMap<String, TextureFileImpl>();
|
||||
private LinkedHashMap<String, TextureFileImpl> txtFileByID = new LinkedHashMap<String, TextureFileImpl>();
|
||||
private ArrayList<BlockTextureRecordImpl> blkTextureRec = new ArrayList<BlockTextureRecordImpl>();
|
||||
private ArrayList<CopyBlockTextureRecordImpl> blkCopyTextureRec = new ArrayList<CopyBlockTextureRecordImpl>();
|
||||
private boolean published = false;
|
||||
@ -272,7 +272,8 @@ public class ModTextureDefinitionImpl implements ModTextureDefinition {
|
||||
String s = "modname:" + this.modid;
|
||||
fw.write(s + "\n\n");
|
||||
// Loop through textures
|
||||
for (TextureFileImpl tfi : txtFileByID.values()) {
|
||||
for (String tid : txtFileByID.keySet()) {
|
||||
TextureFileImpl tfi = txtFileByID.get(tid);
|
||||
String line = tfi.getLine();
|
||||
if (line != null) {
|
||||
fw.write(line + "\n");
|
||||
|
Loading…
Reference in New Issue
Block a user