Fixed logic IDs not loading / Accelerator animation tweaks
This commit is contained in:
@@ -23,6 +23,7 @@ import static mindustry.Vars.*;
|
||||
public class GlobalVars{
|
||||
public static final int ctrlProcessor = 1, ctrlPlayer = 2, ctrlCommand = 3;
|
||||
public static final ContentType[] lookableContent = {ContentType.block, ContentType.unit, ContentType.item, ContentType.liquid, ContentType.team};
|
||||
public static final ContentType[] writableLookableContent = {ContentType.block, ContentType.unit, ContentType.item, ContentType.liquid};
|
||||
/** Global random state. */
|
||||
public static final Rand rand = new Rand();
|
||||
|
||||
@@ -155,7 +156,7 @@ public class GlobalVars{
|
||||
if(ids.exists()){
|
||||
//read logic ID mapping data (generated in ImagePacker)
|
||||
try(DataInputStream in = new DataInputStream(ids.readByteStream())){
|
||||
for(ContentType ctype : lookableContent){
|
||||
for(ContentType ctype : writableLookableContent){
|
||||
short amount = in.readShort();
|
||||
logicIdToContent[ctype.ordinal()] = new UnlockableContent[amount];
|
||||
contentIdToLogicId[ctype.ordinal()] = new int[Vars.content.getBy(ctype).size];
|
||||
|
||||
Reference in New Issue
Block a user