Skip to content

Commit

Permalink
[Omnibus] Several PRs at once. (ldtteam#5326)
Browse files Browse the repository at this point in the history
  • Loading branch information
marchermans authored Jul 2, 2020
1 parent 6ccb5d7 commit d1ebb34
Show file tree
Hide file tree
Showing 6,970 changed files with 232,401 additions and 45,563 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
Empty file modified .github/CONTRIBUTING
100644 → 100755
Empty file.
Empty file modified .github/FUNDING.yml
100644 → 100755
Empty file.
Empty file modified .github/ISSUE_TEMPLATE.md
100644 → 100755
Empty file.
Empty file modified .github/PULL_REQUEST_TEMPLATE
100644 → 100755
Empty file.
Empty file modified .github/workflows/translation.yml
100644 → 100755
Empty file.
Empty file modified .gitignore
100644 → 100755
Empty file.
Empty file modified .phraseapp.yml
100644 → 100755
Empty file.
Empty file modified .pullapprove.yml
100644 → 100755
Empty file.
Empty file modified .travis.yml
100644 → 100755
Empty file.
Empty file modified ABOUT.md
100644 → 100755
Empty file.
Empty file modified CODE_OF_CONDUCT.md
100644 → 100755
Empty file.
Empty file modified LICENSE
100644 → 100755
Empty file.
Empty file modified README.md
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion build.gradle
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ minecraft {
workingDirectory project.file('runClient')

// Recommended logging data for a userdev environment
//property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'
property 'forge.logging.markers', 'SCAN'

// Recommended logging level for the console
property 'forge.logging.console.level', 'info'
Expand Down
Empty file modified build.properties
100644 → 100755
Empty file.
Empty file modified config/PMD/pmd.xml
100644 → 100755
Empty file.
Empty file modified config/checkstyle/checkstyle-noframes-sorted.xsl
100644 → 100755
Empty file.
Empty file modified config/checkstyle/checkstyle.xml
100644 → 100755
Empty file.
Empty file modified crowdin.yml
100644 → 100755
Empty file.
Empty file modified documentation/eclipse/checkstyle.MD
100644 → 100755
Empty file.
Empty file modified documentation/eclipse/log4j2.xml
100644 → 100755
Empty file.
Empty file modified documentation/eclipse/logging.MD
100644 → 100755
Empty file.
Empty file modified documentation/eclipse/setup.MD
100644 → 100755
Empty file.
Empty file modified documentation/formatter/intellij/Minecolonies.xml
100644 → 100755
Empty file.
Empty file modified documentation/inspections/Minecolonies.xml
100644 → 100755
Empty file.
Empty file modified documentation/sonar/suppressing.MD
100644 → 100755
Empty file.
Empty file modified gradle.properties
100644 → 100755
Empty file.
Empty file modified gradle/wrapper/gradle-wrapper.jar
100644 → 100755
Empty file.
Empty file modified gradle/wrapper/gradle-wrapper.properties
100644 → 100755
Empty file.
Empty file modified gradlew.bat
100644 → 100755
Empty file.
Empty file modified resources/minecolonies.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified runData/config/fml.toml
100644 → 100755
Empty file.
Empty file modified scripts/server.properties
100644 → 100755
Empty file.
Empty file modified scripts/users.json
100644 → 100755
Empty file.
Empty file modified settings.gradle
100644 → 100755
Empty file.
Empty file modified sonar.json
100644 → 100755
Empty file.
3 changes: 2 additions & 1 deletion src/api/java/com/minecolonies/api/IMinecoloniesAPI.java
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@
public interface IMinecoloniesAPI
{

static IMinecoloniesAPI getInstance() {
static IMinecoloniesAPI getInstance()
{
return MinecoloniesAPIProxy.getInstance();
}

Expand Down
Empty file modified src/api/java/com/minecolonies/api/MinecoloniesAPIProxy.java
100644 → 100755
Empty file.
4 changes: 2 additions & 2 deletions src/api/java/com/minecolonies/api/advancements/AbstractCriterionTrigger.java
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@

public abstract class AbstractCriterionTrigger<T extends CriterionListeners<U>, U extends ICriterionInstance> implements ICriterionTrigger<U>
{
private final ResourceLocation id;
private final ResourceLocation id;
private final Function<PlayerAdvancements, T> createNew;
private final Map<PlayerAdvancements, T> listeners = Maps.newHashMap();
private final Map<PlayerAdvancements, T> listeners = Maps.newHashMap();

protected AbstractCriterionTrigger(ResourceLocation id, Function<PlayerAdvancements, T> createNew)
{
Expand Down
17 changes: 8 additions & 9 deletions src/api/java/com/minecolonies/api/advancements/AdvancementTriggers.java
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@

public class AdvancementTriggers
{
public static final PlaceSupplyTrigger PLACE_SUPPLY = new PlaceSupplyTrigger();
public static final PlaceStructureTrigger PLACE_STRUCTURE = new PlaceStructureTrigger();
public static final CreateBuildRequestTrigger CREATE_BUILD_REQUEST = new CreateBuildRequestTrigger();
public static final OpenGuiWindowTrigger OPEN_GUI_WINDOW = new OpenGuiWindowTrigger();
public static final ClickGuiButtonTrigger CLICK_GUI_BUTTON = new ClickGuiButtonTrigger();
public static final CitizenEatFoodTrigger CITIZEN_EAT_FOOD = new CitizenEatFoodTrigger();
public static final BuildingAddRecipeTrigger BUILDING_ADD_RECIPE = new BuildingAddRecipeTrigger();
public static final PlaceSupplyTrigger PLACE_SUPPLY = new PlaceSupplyTrigger();
public static final PlaceStructureTrigger PLACE_STRUCTURE = new PlaceStructureTrigger();
public static final CreateBuildRequestTrigger CREATE_BUILD_REQUEST = new CreateBuildRequestTrigger();
public static final OpenGuiWindowTrigger OPEN_GUI_WINDOW = new OpenGuiWindowTrigger();
public static final ClickGuiButtonTrigger CLICK_GUI_BUTTON = new ClickGuiButtonTrigger();
public static final CitizenEatFoodTrigger CITIZEN_EAT_FOOD = new CitizenEatFoodTrigger();
public static final BuildingAddRecipeTrigger BUILDING_ADD_RECIPE = new BuildingAddRecipeTrigger();
public static final CompleteBuildRequestTrigger COMPLETE_BUILD_REQUEST = new CompleteBuildRequestTrigger();
public static final ColonyPopulationTrigger COLONY_POPULATION = new ColonyPopulationTrigger();
public static final ColonyPopulationTrigger COLONY_POPULATION = new ColonyPopulationTrigger();

public static void preInit()
{
Expand All @@ -35,5 +35,4 @@ public static void preInit()
CriteriaTriggers.register(COMPLETE_BUILD_REQUEST);
CriteriaTriggers.register(COLONY_POPULATION);
}

}
2 changes: 1 addition & 1 deletion src/api/java/com/minecolonies/api/advancements/CriterionListeners.java
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

public class CriterionListeners<T extends ICriterionInstance>
{
private final PlayerAdvancements playerAdvancements;
private final PlayerAdvancements playerAdvancements;
private final Set<ICriterionTrigger.Listener<T>> listeners = Sets.newHashSet();

public CriterionListeners(PlayerAdvancements playerAdvancements)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
public class BuildingAddRecipeCriterionInstance extends CriterionInstance
{
private ItemPredicate[] outputItemPredicates;
private int craftingSize = -1;
private int craftingSize = -1;

public BuildingAddRecipeCriterionInstance()
{
Expand Down
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
import net.minecraft.util.ResourceLocation;
import org.jetbrains.annotations.NotNull;


public class BuildingAddRecipeTrigger extends AbstractCriterionTrigger<BuildingAddRecipeListeners, BuildingAddRecipeCriterionInstance>
{
public BuildingAddRecipeTrigger()
Expand Down
Empty file.
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
import net.minecraft.util.ResourceLocation;
import org.jetbrains.annotations.NotNull;


public class CitizenEatFoodTrigger extends AbstractCriterionTrigger<CitizenEatFoodListeners, CitizenEatFoodCriterionInstance>
{
public CitizenEatFoodTrigger()
Expand Down
Empty file.
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
import net.minecraft.util.ResourceLocation;
import org.jetbrains.annotations.NotNull;


public class ClickGuiButtonTrigger extends AbstractCriterionTrigger<ClickGuiButtonListeners, ClickGuiButtonCriterionInstance>
{
public ClickGuiButtonTrigger()
Expand Down
Empty file.
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
import net.minecraft.util.ResourceLocation;
import org.jetbrains.annotations.NotNull;


public class ColonyPopulationTrigger extends AbstractCriterionTrigger<ColonyPopulationListeners, ColonyPopulationCriterionInstance>
{
public ColonyPopulationTrigger()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@

public class CompleteBuildRequestCriterionInstance extends CriterionInstance
{
private String hutName;
private String hutName;
private StructureName structureName;
private int level = -1;
private int level = -1;

public CompleteBuildRequestCriterionInstance()
{
Expand Down
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
import net.minecraft.util.ResourceLocation;
import org.jetbrains.annotations.NotNull;


public class CompleteBuildRequestTrigger extends AbstractCriterionTrigger<CompleteBuildRequestListeners, CompleteBuildRequestCriterionInstance>
{
public CompleteBuildRequestTrigger()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@

public class CreateBuildRequestCriterionInstance extends CriterionInstance
{
private String hutName;
private String hutName;
private StructureName structureName;
private int level = -1;
private int level = -1;

public CreateBuildRequestCriterionInstance()
{
Expand Down
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
import net.minecraft.util.ResourceLocation;
import org.jetbrains.annotations.NotNull;


public class CreateBuildRequestTrigger extends AbstractCriterionTrigger<CreateBuildRequestListeners, CreateBuildRequestCriterionInstance>
{
public CreateBuildRequestTrigger()
Expand Down
Empty file.
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
import net.minecraft.util.ResourceLocation;
import org.jetbrains.annotations.NotNull;


public class OpenGuiWindowTrigger extends AbstractCriterionTrigger<OpenGuiWindowListeners, OpenGuiWindowCriterionInstance>
{
public OpenGuiWindowTrigger()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

public class PlaceStructureCriterionInstance extends CriterionInstance
{
private String hutName;
private String hutName;
private StructureName structureName;

public PlaceStructureCriterionInstance()
Expand Down
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
import net.minecraft.util.ResourceLocation;
import org.jetbrains.annotations.NotNull;


public class PlaceStructureTrigger extends AbstractCriterionTrigger<PlaceStructureListeners, PlaceStructureCriterionInstance>
{
public PlaceStructureTrigger()
Expand Down
Empty file.
Empty file.
1 change: 0 additions & 1 deletion src/api/java/com/minecolonies/api/advancements/place_supply/PlaceSupplyTrigger.java
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import net.minecraft.util.ResourceLocation;
import org.jetbrains.annotations.NotNull;


public class PlaceSupplyTrigger extends AbstractCriterionTrigger<PlaceSupplyListeners, PlaceSupplyCriterionInstance>
{
public PlaceSupplyTrigger()
Expand Down
8 changes: 4 additions & 4 deletions src/api/java/com/minecolonies/api/blocks/AbstractBlockBarrel.java
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public abstract class AbstractBlockBarrel<B extends AbstractBlockBarrel<B>> exte
/**
* The position it faces.
*/
public static final DirectionProperty FACING = HorizontalBlock.HORIZONTAL_FACING;
public static final DirectionProperty FACING = HorizontalBlock.HORIZONTAL_FACING;

public AbstractBlockBarrel(final Properties properties)
{
Expand All @@ -28,23 +28,23 @@ public static BlockState changeStateOverFullness(@NotNull final AbstractTileEnti
* 12.8 -> the number of items needed to go up on a state (having 6 filling states)
* So items/12.8 -> meta of the state we should get
*/
BarrelType type = BarrelType.byMetadata((int) Math.round(te.getItems()/12.8));
BarrelType type = BarrelType.byMetadata((int) Math.round(te.getItems() / 12.8));

/*
* We check if the barrel is marked as empty but it have items inside. If so, means that it
* does not have all the items needed to go on TWENTY state, but we need to mark it so the player
* knows it have some items inside
*/

if(type.equals(BarrelType.ZERO) && te.getItems() > 0)
if (type.equals(BarrelType.ZERO) && te.getItems() > 0)
{
type = BarrelType.TWENTY;
}
else if (te.getItems() == AbstractTileEntityBarrel.MAX_ITEMS)
{
type = BarrelType.WORKING;
}
if(te.isDone())
if (te.isDone())
{
type = BarrelType.DONE;
}
Expand Down
6 changes: 3 additions & 3 deletions src/api/java/com/minecolonies/api/blocks/AbstractBlockHut.java
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -221,11 +221,11 @@ public void onBlockPlacedBy(@NotNull final World worldIn, @NotNull final BlockPo
final TileEntity tileEntity = worldIn.getTileEntity(pos);
if (tileEntity instanceof TileEntityColonyBuilding)
{
if (((TileEntityColonyBuilding) tileEntity).getBuildingName() != getBuildingEntry().getRegistryName())
@NotNull final TileEntityColonyBuilding hut = (TileEntityColonyBuilding) tileEntity;
if (hut.getBuildingName() != getBuildingEntry().getRegistryName())
{
((TileEntityColonyBuilding) tileEntity).registryName = getBuildingEntry().getRegistryName();
hut.registryName = getBuildingEntry().getRegistryName();
}
@NotNull final AbstractTileEntityColonyBuilding hut = (AbstractTileEntityColonyBuilding) tileEntity;
@Nullable final IColony colony = IColonyManager.getInstance().getColonyByPosFromWorld(worldIn, hut.getPosition());

if (colony != null)
Expand Down
1 change: 1 addition & 0 deletions src/api/java/com/minecolonies/api/blocks/AbstractBlockMinecolonies.java
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ public B registerBlock(final IForgeRegistry<Block> registry)
registry.register(this);
return (B) this;
}

/**
* Registery block at gameregistry.
*
Expand Down
Empty file.
4 changes: 3 additions & 1 deletion src/api/java/com/minecolonies/api/blocks/AbstractBlockMinecoloniesFalling.java
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@

import com.minecolonies.api.blocks.interfaces.IBlockMinecolonies;
import com.minecolonies.api.util.constant.Suppression;
import net.minecraft.block.*;
import net.minecraft.block.Block;
import net.minecraft.block.FallingBlock;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraftforge.registries.IForgeRegistry;
Expand All @@ -27,6 +28,7 @@ public B registerBlock(final IForgeRegistry<Block> registry)
registry.register(this);
return (B) this;
}

/**
* Registery block at gameregistry.
*
Expand Down
Empty file.
Empty file.
20 changes: 10 additions & 10 deletions src/api/java/com/minecolonies/api/blocks/ModBlocks.java
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@
import org.jetbrains.annotations.NotNull;

/**
* Class to create the modBlocks.
* References to the blocks can be made here
* Class to create the modBlocks. References to the blocks can be made here
* <p>
* We disabled the following finals since we are neither able to mark the items as final, nor do we want to provide public accessors.
*/
Expand Down Expand Up @@ -67,13 +66,13 @@ public final class ModBlocks
* Utility blocks.
*/
public static AbstractBlockMinecoloniesConstructionTape<? extends AbstractBlockMinecoloniesConstructionTape<?>> blockConstructionTape;
public static AbstractBlockMinecoloniesRack<? extends AbstractBlockMinecoloniesRack<?>> blockRack;
public static AbstractBlockMinecolonies<? extends AbstractBlockMinecolonies<?>> blockWayPoint;
public static AbstractBlockBarrel<? extends AbstractBlockBarrel<?>> blockBarrel;
public static AbstractBlockMinecoloniesHorizontal<? extends AbstractBlockMinecoloniesHorizontal<?>> blockDecorationPlaceholder;
public static AbstractBlockMinecoloniesDefault<? extends AbstractBlockMinecoloniesDefault<?>> blockScarecrow;
public static AbstractBlockMinecolonies<? extends AbstractBlockMinecolonies<?>> blockBarracksTowerSubstitution;
public static AbstractBlockMinecolonies<? extends AbstractBlockMinecolonies<?>> blockCompostedDirt;
public static AbstractBlockMinecoloniesRack<? extends AbstractBlockMinecoloniesRack<?>> blockRack;
public static AbstractBlockMinecolonies<? extends AbstractBlockMinecolonies<?>> blockWayPoint;
public static AbstractBlockBarrel<? extends AbstractBlockBarrel<?>> blockBarrel;
public static AbstractBlockMinecoloniesHorizontal<? extends AbstractBlockMinecoloniesHorizontal<?>> blockDecorationPlaceholder;
public static AbstractBlockMinecoloniesDefault<? extends AbstractBlockMinecoloniesDefault<?>> blockScarecrow;
public static AbstractBlockMinecolonies<? extends AbstractBlockMinecolonies<?>> blockBarracksTowerSubstitution;
public static AbstractBlockMinecolonies<? extends AbstractBlockMinecolonies<?>> blockCompostedDirt;

/**
* Private constructor to hide the implicit public one.
Expand Down Expand Up @@ -127,6 +126,7 @@ public static AbstractBlockHut<?>[] getHuts()
blockHutTavern,
blockHutRabbitHutch,
blockHutConcreteMixer,
blockHutBeekeeper};
blockHutBeekeeper,
blockHutFlorist};
}
}
Loading

0 comments on commit d1ebb34

Please sign in to comment.