mirror of
https://github.com/GTNewHorizons/Binnie.git
synced 2026-11-22 21:19:56 +00:00
Some reformat code for 1.11.2 source (#84)
* Optimized imports * Some code reformat * Some refactoring and code reformat * Some code reformat
This commit is contained in:
1 parent
886c36a308
commit
c3809fbc27
508 files changed
+6677
-6238
No files matched your search
@@ -16,10 +16,16 @@ import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
import java.util.*;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
public class WoodManager {
|
||||
public static Map<IPlankType, ItemStack> PLANKS;
|
||||
|
||||
public static String getDisplayName(IWoodTyped wood, IWoodType woodType) {
|
||||
WoodBlockKind blockKind = wood.getBlockKind();
|
||||
|
||||
@@ -133,18 +139,18 @@ public class WoodManager {
|
||||
Collections.addAll(list, PlankType.VanillaPlanks.values());
|
||||
return list;
|
||||
}
|
||||
|
||||
public static Map<IPlankType, ItemStack> getAllPlankStacks(){
|
||||
if(PLANKS == null){
|
||||
|
||||
public static Map<IPlankType, ItemStack> getAllPlankStacks() {
|
||||
if (PLANKS == null) {
|
||||
PLANKS = new HashMap<>();
|
||||
for(IPlankType type : getAllPlankTypes()){
|
||||
for (IPlankType type : getAllPlankTypes()) {
|
||||
PLANKS.put(type, type.getStack(false));
|
||||
}
|
||||
}
|
||||
return PLANKS;
|
||||
}
|
||||
|
||||
public static Collection<ItemStack> getAllPlankStacks(IPlankType type){
|
||||
|
||||
public static Collection<ItemStack> getAllPlankStacks(IPlankType type) {
|
||||
Map<IPlankType, ItemStack> planks = new HashMap<>(getAllPlankStacks());
|
||||
planks.remove(type);
|
||||
return planks.values();
|
||||
|
||||
Reference in new issue
Block a user