mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-01-25 10:32:49 +00:00
Add explicit "public" to interfaces
This commit is contained in:
parent
e59f8b441d
commit
f1184f8731
@ -3,17 +3,17 @@ package com.hbm.handler.ability;
|
||||
import net.minecraft.client.resources.I18n;
|
||||
|
||||
public interface IBaseAbility {
|
||||
String getName();
|
||||
public String getName();
|
||||
|
||||
default String getExtension(int level) {
|
||||
public default String getExtension(int level) {
|
||||
return "";
|
||||
}
|
||||
|
||||
default String getFullName(int level) {
|
||||
public default String getFullName(int level) {
|
||||
return I18n.format(getName()) + getExtension(level);
|
||||
}
|
||||
|
||||
default boolean isAllowed() {
|
||||
public default boolean isAllowed() {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@ -27,7 +27,7 @@ public interface IToolAreaAbility extends IBaseAbility {
|
||||
// The initial block is always implicitly broken and shouldn't be included.
|
||||
// If true is returned, no block breaking is handled by the tool
|
||||
// (neither for the original block nor for the extras)
|
||||
boolean onDig(int level, World world, int x, int y, int z, EntityPlayer player, IItemWithAbility tool);
|
||||
public boolean onDig(int level, World world, int x, int y, int z, EntityPlayer player, IItemWithAbility tool);
|
||||
|
||||
// region handlers
|
||||
public static final IToolAreaAbility NONE = new IToolAreaAbility() {
|
||||
|
||||
@ -23,14 +23,14 @@ import net.minecraft.item.crafting.FurnaceRecipes;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public interface IToolHarvestAbility extends IBaseAbility {
|
||||
default void preHarvestAll(int level, World world, EntityPlayer player) {}
|
||||
public default void preHarvestAll(int level, World world, EntityPlayer player) {}
|
||||
|
||||
default void postHarvestAll(int level, World world, EntityPlayer player) {}
|
||||
public default void postHarvestAll(int level, World world, EntityPlayer player) {}
|
||||
|
||||
boolean skipDefaultDrops(int level);
|
||||
public boolean skipDefaultDrops(int level);
|
||||
|
||||
// Call IToolHarvestAbility.super.onHarvestBlock to emulate the actual block breaking
|
||||
default void onHarvestBlock(int level, World world, int x, int y, int z, EntityPlayer player, Block block, int meta) {
|
||||
public default void onHarvestBlock(int level, World world, int x, int y, int z, EntityPlayer player, Block block, int meta) {
|
||||
if (skipDefaultDrops(level)) {
|
||||
// Emulate the block breaking without drops
|
||||
world.setBlockToAir(x, y, z);
|
||||
|
||||
@ -35,7 +35,7 @@ import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public interface IWeaponAbility extends IBaseAbility {
|
||||
void onHit(int level, World world, EntityPlayer player, Entity victim, IItemWithAbility tool);
|
||||
public void onHit(int level, World world, EntityPlayer player, Entity victim, IItemWithAbility tool);
|
||||
|
||||
// region handlers
|
||||
public static final IWeaponAbility NONE = new IWeaponAbility() {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user