More fixes

This commit is contained in:
Sebastian Hartte
2020-06-29 21:23:50 +02:00
parent 0d63f560d3
commit ca104912d6
121 changed files with 2623 additions and 2563 deletions
@@ -34,15 +34,15 @@ import net.fabricmc.fabric.api.event.EventFactory;
*/
public interface LocatableEventAnnounce {
Event<LocatableEventAnnounce> EVENT = EventFactory.createArrayBacked(LocatableEventAnnounce.class, listeners -> (ILocatable o, LocatableEvent evt) -> {
Event<LocatableEventAnnounce> EVENT = EventFactory.createArrayBacked(LocatableEventAnnounce.class, listeners -> (ILocatable target, LocatableEvent change) -> {
for (LocatableEventAnnounce listener : listeners) {
listener.onLocatableAnnounce(o, evt);
listener.onLocatableAnnounce(target, change);
}
});
void onLocatableAnnounce(final ILocatable o, final LocatableEvent ev);
void onLocatableAnnounce(final ILocatable target, final LocatableEvent change);
public enum LocatableEvent {
enum LocatableEvent {
/**
* Adds the locatable to the registry
*/
@@ -26,6 +26,7 @@ package appeng.api.features;
import javax.annotation.Nonnull;
import javax.annotation.Nullable;
import alexiil.mc.lib.attributes.Attribute;
import net.minecraft.item.ItemStack;
import appeng.api.config.TunnelType;
@@ -47,6 +48,8 @@ public interface IP2PTunnelRegistry {
void addNewAttunement(@Nonnull String ModId, @Nullable TunnelType type);
void addNewAttunement(@Nonnull Attribute<?> attr, @Nullable TunnelType type);
/**
* returns null if no attunement can be found.
*
@@ -23,6 +23,7 @@
package appeng.api.features;
import net.minecraft.server.world.ServerWorld;
import net.minecraft.util.Identifier;
import net.minecraft.world.ServerWorldAccess;
@@ -32,7 +33,7 @@ public interface IWorldGen {
void disableWorldGenForDimension(WorldGenType type, Identifier dimID);
boolean isWorldGenEnabled(WorldGenType type, ServerWorldAccess w);
boolean isWorldGenEnabled(WorldGenType type, ServerWorld w);
enum WorldGenType {
CERTUS_QUARTZ, CHARGED_CERTUS_QUARTZ, METEORITES
@@ -50,11 +50,11 @@ public interface IMovableHandler {
* <pre>
* {
* &#064;code
* Chunk c = world.getChunkAt(x, z);
* Chunk c = world.getChunk(x, z);
* c.setChunkBlockTileEntity(x &amp; 0xF, y + y, z &amp; 0xF, tile);
*
* if (c.isChunkLoaded) {
* world.addTileEntity(tile);
* world.addBlockEntity(tile);
* world.markBlockForUpdate(x, y, z);
* }
* }