Fixed crash in storage cache, fixes #1033

This commit is contained in:
raoulvdberge
2017-03-04 20:51:35 +01:00
parent 2143db8b9d
commit 9308e0921b
3 changed files with 5 additions and 2 deletions

View File

@@ -5,6 +5,7 @@
- Fixed a crash with the Constructor (raoulvdberge)
- Fixed Crafting Pattern model (pauljoda)
- Fixed Quartz Enriched Iron and the block form of it not having an oredictionary entry (raoulvdberge)
- Fixed crash in storage cache (raoulvdberge)
### 1.4.1
- Added Storage Monitor (raoulvdberge)

View File

@@ -11,11 +11,12 @@ import net.minecraftforge.fluids.FluidStack;
import javax.annotation.Nonnull;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
public class StorageCacheFluid implements IStorageCache<FluidStack> {
private INetworkMaster network;
private List<IStorage<FluidStack>> storages = new ArrayList<>();
private List<IStorage<FluidStack>> storages = Collections.synchronizedList(new ArrayList<>());
private IStackList<FluidStack> list = API.instance().createFluidStackList();
public StorageCacheFluid(INetworkMaster network) {

View File

@@ -11,11 +11,12 @@ import net.minecraft.item.ItemStack;
import javax.annotation.Nonnull;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
public class StorageCacheItem implements IStorageCache<ItemStack> {
private INetworkMaster network;
private List<IStorage<ItemStack>> storages = new ArrayList<>();
private List<IStorage<ItemStack>> storages = Collections.synchronizedList(new ArrayList<>());
private IStackList<ItemStack> list = API.instance().createItemStackList();
public StorageCacheItem(INetworkMaster network) {