This commit is contained in:
SD 2021-01-25 08:24:24 +05:30
parent edfc9d7b63
commit a7c900f644
No known key found for this signature in database
GPG key ID: E36B57EE08544BC5
21 changed files with 36 additions and 58 deletions

View file

@ -1,5 +1,6 @@
plugins {
id 'fabric-loom' version '0.5-SNAPSHOT'
id 'maven-publish'
}
apply plugin: "java"
@ -20,12 +21,27 @@ repositories {
}
def includeCompile(str) {
def dep
project.dependencies {
modImplementation(str) {
dep = modImplementation(str) {
exclude module: "fabric-api"
}
include(str)
}
project.publishing {
publications {
mavenJava(MavenPublication) {
pom.withXml {
def depsNode = asNode().appendNode("dependencies")
def depNode = depsNode.appendNode("dependency")
depNode.appendNode("groupId", dep.group)
depNode.appendNode("artifactId", dep.name)
depNode.appendNode("version", dep.version)
depNode.appendNode("scope", "compile")
}
}
}
}
}
dependencies {

View file

@ -7,13 +7,12 @@ import org.apache.logging.log4j.Logger;
import org.dimdev.dimdoors.pockets.PocketTemplate;
import org.dimdev.dimdoors.rift.registry.LinkProperties;
import org.dimdev.dimdoors.rift.registry.Rift;
import org.dimdev.dimdoors.rift.registry.RiftRegistry;
import org.dimdev.dimdoors.rift.targets.EntityTarget;
import org.dimdev.dimdoors.rift.targets.MessageTarget;
import org.dimdev.dimdoors.rift.targets.Target;
import org.dimdev.dimdoors.rift.targets.Targets;
import org.dimdev.dimdoors.rift.targets.VirtualTarget;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.EntityUtils;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.util.RGBA;

View file

@ -10,9 +10,8 @@ import org.dimdev.dimdoors.command.arguments.NameArugmentType;
import org.dimdev.dimdoors.pockets.PocketGenerator;
import org.dimdev.dimdoors.pockets.PocketTemplate;
import org.dimdev.dimdoors.pockets.SchematicHandler;
import org.dimdev.dimdoors.rift.registry.RiftRegistry;
import org.dimdev.dimdoors.rift.targets.EntityTarget;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.util.TeleportUtil;
import org.dimdev.dimdoors.world.ModDimensions;

View file

@ -8,7 +8,7 @@ import org.dimdev.dimdoors.DimensionalDoorsInitializer;
import org.dimdev.dimdoors.ModConfig;
import org.dimdev.dimdoors.rift.registry.LinkProperties;
import org.dimdev.dimdoors.rift.targets.VirtualTarget;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.world.ModDimensions;
import org.dimdev.dimdoors.world.pocket.Pocket;
import org.dimdev.dimdoors.world.pocket.VirtualLocation;

View file

@ -3,22 +3,18 @@ package org.dimdev.dimdoors.pockets;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.function.Consumer;
import java.util.function.Supplier;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import net.fabricmc.fabric.api.event.registry.FabricRegistryBuilder;
import org.dimdev.dimdoors.DimensionalDoorsInitializer;
import org.dimdev.dimdoors.block.entity.EntranceRiftBlockEntity;
import org.dimdev.dimdoors.block.entity.ModBlockEntityTypes;
import org.dimdev.dimdoors.block.entity.RiftBlockEntity;
import org.dimdev.dimdoors.block.entity.RiftData;
import org.dimdev.dimdoors.rift.registry.LinkProperties;
import org.dimdev.dimdoors.rift.targets.VirtualTarget;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.util.schematic.Schematic;
import org.dimdev.dimdoors.world.pocket.Pocket;
@ -30,14 +26,7 @@ import net.minecraft.block.entity.DispenserBlockEntity;
import net.minecraft.inventory.Inventory;
import net.minecraft.nbt.CompoundTag;
import net.minecraft.server.world.ServerWorld;
import net.minecraft.util.Identifier;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.registry.Registry;
import net.minecraft.util.registry.RegistryKey;
import net.minecraft.util.registry.SimpleRegistry;
import com.mojang.datafixers.types.Func;
import com.mojang.serialization.Lifecycle;
/**
* @author Robijnvogel

View file

@ -13,11 +13,10 @@ import org.dimdev.dimdoors.block.entity.RiftBlockEntity;
import org.dimdev.dimdoors.entity.ModEntityTypes;
import org.dimdev.dimdoors.entity.MonolithEntity;
import org.dimdev.dimdoors.rift.registry.LinkProperties;
import org.dimdev.dimdoors.rift.registry.RiftRegistry;
import org.dimdev.dimdoors.rift.targets.PocketEntranceMarker;
import org.dimdev.dimdoors.rift.targets.PocketExitMarker;
import org.dimdev.dimdoors.rift.targets.VirtualTarget;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.util.math.MathUtil;
import org.dimdev.dimdoors.util.schematic.v2.Schematic;

View file

@ -5,7 +5,7 @@ import java.util.UUID;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.dimdev.dimdoors.block.entity.RiftBlockEntity;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.Location;
import net.minecraft.nbt.CompoundTag;

View file

@ -11,11 +11,8 @@ import java.util.stream.Collectors;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import dev.onyxstudios.cca.api.v3.component.ComponentV3;
import org.dimdev.dimdoors.DimensionalDoorsComponents;
import org.dimdev.dimdoors.util.GraphUtils;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.util.NbtUtil;
import org.dimdev.dimdoors.world.pocket.Pocket;
import org.dimdev.dimdoors.world.pocket.PocketDirectory;
import org.dimdev.dimdoors.world.pocket.PrivatePocketData;
@ -26,13 +23,7 @@ import net.minecraft.nbt.CompoundTag;
import net.minecraft.nbt.ListTag;
import net.minecraft.nbt.Tag;
import net.minecraft.util.registry.RegistryKey;
import net.minecraft.world.PersistentState;
import net.minecraft.world.World;
import net.minecraft.world.level.LevelProperties;
import static net.minecraft.world.World.OVERWORLD;
import static org.dimdev.dimdoors.DimensionalDoorsInitializer.getServer;
import static org.dimdev.dimdoors.DimensionalDoorsInitializer.getWorld;
public class RiftRegistry {
private static final Logger LOGGER = LogManager.getLogger();

View file

@ -5,8 +5,7 @@ import java.util.UUID;
import com.mojang.serialization.Codec;
import com.mojang.serialization.codecs.RecordCodecBuilder;
import org.dimdev.dimdoors.block.entity.RiftBlockEntity;
import org.dimdev.dimdoors.rift.registry.RiftRegistry;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.util.TeleportUtil;
import org.dimdev.dimdoors.world.ModDimensions;

View file

@ -3,12 +3,10 @@ package org.dimdev.dimdoors.rift.targets;
import java.util.UUID;
import org.dimdev.dimdoors.block.entity.RiftBlockEntity;
import org.dimdev.dimdoors.rift.registry.RiftRegistry;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.EntityUtils;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.util.RGBA;
import org.dimdev.dimdoors.util.TeleportUtil;
import org.dimdev.dimdoors.world.ModDimensions;
import org.dimdev.dimdoors.world.pocket.Pocket;
import org.dimdev.dimdoors.world.pocket.PocketDirectory;

View file

@ -5,8 +5,7 @@ import java.util.UUID;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.dimdev.dimdoors.pockets.PocketGenerator;
import org.dimdev.dimdoors.rift.registry.RiftRegistry;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.EntityUtils;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.util.RGBA;

View file

@ -1,8 +1,7 @@
package org.dimdev.dimdoors.rift.targets;
import org.dimdev.dimdoors.pockets.PocketGenerator;
import org.dimdev.dimdoors.rift.registry.RiftRegistry;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.world.pocket.Pocket;
import org.dimdev.dimdoors.world.pocket.VirtualLocation;

View file

@ -18,8 +18,7 @@ import org.dimdev.dimdoors.block.entity.RiftBlockEntity;
import org.dimdev.dimdoors.pockets.PocketGenerator;
import org.dimdev.dimdoors.rift.registry.LinkProperties;
import org.dimdev.dimdoors.rift.registry.Rift;
import org.dimdev.dimdoors.rift.registry.RiftRegistry;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.util.math.MathUtil;
import org.dimdev.dimdoors.world.pocket.Pocket;

View file

@ -2,8 +2,7 @@ package org.dimdev.dimdoors.rift.targets;
import java.util.Set;
import org.dimdev.dimdoors.rift.registry.RiftRegistry;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.util.RGBA;

View file

@ -1,4 +1,4 @@
package org.dimdev.dimdoors;
package org.dimdev.dimdoors.world.level;
import net.minecraft.util.Identifier;
@ -6,7 +6,6 @@ import dev.onyxstudios.cca.api.v3.component.ComponentKey;
import dev.onyxstudios.cca.api.v3.component.ComponentRegistryV3;
import dev.onyxstudios.cca.api.v3.level.LevelComponentFactoryRegistry;
import dev.onyxstudios.cca.api.v3.level.LevelComponentInitializer;
import org.dimdev.dimdoors.util.DimensionalRegistry;
public class DimensionalDoorsComponents implements LevelComponentInitializer {
public static final ComponentKey<DimensionalRegistry> DIMENSIONAL_REGISTRY_COMPONENT_KEY = ComponentRegistryV3.INSTANCE.getOrCreate(new Identifier("dimdoors:dimensional_registry"), DimensionalRegistry.class);

View file

@ -1,4 +1,4 @@
package org.dimdev.dimdoors.util;
package org.dimdev.dimdoors.world.level;
import java.util.HashMap;
import java.util.Map;
@ -12,7 +12,6 @@ import net.minecraft.world.World;
import net.minecraft.world.level.LevelProperties;
import dev.onyxstudios.cca.api.v3.component.ComponentV3;
import org.dimdev.dimdoors.DimensionalDoorsComponents;
import org.dimdev.dimdoors.rift.registry.RiftRegistry;
import org.dimdev.dimdoors.world.ModDimensions;
import org.dimdev.dimdoors.world.pocket.PocketDirectory;

View file

@ -5,7 +5,7 @@ import java.util.stream.IntStream;
import com.flowpowered.math.vector.Vector3i;
import com.mojang.serialization.Codec;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.EntityUtils;
import net.minecraft.entity.Entity;

View file

@ -4,22 +4,16 @@ import java.util.HashMap;
import java.util.Map;
import java.util.stream.Collectors;
import dev.onyxstudios.cca.api.v3.component.Component;
import org.dimdev.dimdoors.DimensionalDoorsComponents;
import org.dimdev.dimdoors.DimensionalDoorsInitializer;
import org.dimdev.dimdoors.ModConfig;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.util.math.GridUtil;
import org.dimdev.dimdoors.world.ModDimensions;
import net.minecraft.nbt.CompoundTag;
import net.minecraft.server.world.ServerWorld;
import net.minecraft.util.Identifier;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.registry.Registry;
import net.minecraft.util.registry.RegistryKey;
import net.minecraft.world.World;
import net.minecraft.world.level.LevelProperties;
public class PocketDirectory {
int gridSize; // Determines how much pockets in their dimension are spaced
int privatePocketSize;

View file

@ -6,7 +6,7 @@ import java.util.UUID;
import com.google.common.collect.BiMap;
import com.google.common.collect.HashBiMap;
import org.dimdev.dimdoors.DimensionalDoorsInitializer;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import net.minecraft.nbt.CompoundTag;
import net.minecraft.util.Identifier;

View file

@ -5,7 +5,7 @@ import com.mojang.serialization.Codec;
import com.mojang.serialization.codecs.RecordCodecBuilder;
import org.dimdev.dimdoors.DimensionalDoorsInitializer;
import org.dimdev.dimdoors.ModConfig;
import org.dimdev.dimdoors.util.DimensionalRegistry;
import org.dimdev.dimdoors.world.level.DimensionalRegistry;
import org.dimdev.dimdoors.util.Location;
import org.dimdev.dimdoors.world.ModDimensions;

View file

@ -31,7 +31,7 @@
"org.dimdev.dimdoors.client.config.ModMenuImpl"
],
"cardinal-components": [
"org.dimdev.dimdoors.DimensionalDoorsComponents"
"org.dimdev.dimdoors.world.level.DimensionalDoorsComponents"
]
},
"mixins": [