One Spatial Dimension (#4570)
* Ported the "one spatial dimension" concept from pre-1.15 * Apply lighting updates after moving chunks. Mark world data as dirty when changing it. * Consolidated naming of spatial storage world/dimension. Use server light manager to update lighting info in chunk. * Save last transition information, and add ae2 spatial command to interact with spatial storage. * Formatting fixes. * Improved docs for the origin generation. Inverted condition on when the x/z axis are flipped. Also added a helper to map a plot to a region file * Remove TransitionResult since it's only used in lieu of a boolean. Rework transition to make the checks BEFORE allocating a new cell. * Removed unused imports. Co-authored-by: yueh <yueh@users.noreply.github.com>
This commit is contained in:
@@ -0,0 +1,57 @@
|
||||
package appeng.spatial;
|
||||
|
||||
import net.minecraft.util.RegistryKey;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.registry.Registry;
|
||||
import net.minecraft.world.Dimension;
|
||||
import net.minecraft.world.DimensionType;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import appeng.core.AppEng;
|
||||
import appeng.mixins.spatial.DimensionTypeMixin;
|
||||
|
||||
/**
|
||||
* IDs for the spatial storage world related dimension objects.
|
||||
*/
|
||||
public final class SpatialStorageDimensionIds {
|
||||
|
||||
/**
|
||||
* ID of the {@link DimensionType} used for the spatial storage world.
|
||||
* <p>
|
||||
* This is defined in {@link DimensionTypeMixin}.
|
||||
*/
|
||||
public static final RegistryKey<DimensionType> DIMENSION_TYPE_ID = RegistryKey
|
||||
.func_240903_a_(Registry.DIMENSION_TYPE_KEY, AppEng.makeId("spatial_storage"));
|
||||
|
||||
/**
|
||||
* ID of the {@link net.minecraft.world.gen.ChunkGenerator} used for the spatial
|
||||
* storage world.
|
||||
*/
|
||||
public static final ResourceLocation CHUNK_GENERATOR_ID = AppEng.makeId("spatial_storage");
|
||||
|
||||
/**
|
||||
* ID of the {@link net.minecraft.world.biome.Biome} used for the spatial
|
||||
* storage world.
|
||||
*/
|
||||
public static final ResourceLocation BIOME_ID = AppEng.makeId("spatial_storage");
|
||||
|
||||
/**
|
||||
* ID of the {@link Dimension} used for the spatial storage dimension.
|
||||
* <p>
|
||||
* This is defined in
|
||||
* <code>data/minecraft/dimension/appliedenergistics2/spatial_storage.json</code>
|
||||
*/
|
||||
public static final RegistryKey<Dimension> DIMENSION_ID = RegistryKey.func_240903_a_(Registry.DIMENSION_KEY,
|
||||
AppEng.makeId("spatial_storage"));
|
||||
|
||||
/**
|
||||
* ID of the {@link World} that is instantiated from the dimension/dimension
|
||||
* type.
|
||||
*/
|
||||
public static final RegistryKey<World> WORLD_ID = RegistryKey.func_240903_a_(Registry.WORLD_KEY,
|
||||
AppEng.makeId("spatial_storage"));
|
||||
|
||||
private SpatialStorageDimensionIds() {
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user