Skip to content

Commit

Permalink
Remove most code in favor of Server Sided Portals dependency and thus…
Browse files Browse the repository at this point in the history
… implement (#11).
  • Loading branch information
Crystal-Spider committed Sep 15, 2024
1 parent f0fcad9 commit 8ab9992
Show file tree
Hide file tree
Showing 31 changed files with 41 additions and 968 deletions.
19 changes: 14 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,23 @@ It's a perfect choice for both multiplayer servers who need the nighttime but ca
- Enter the Nightworld by creating a portal with crying obsidian.
- Similarly to Nether portals spawning zombified piglins, Nightworld portals can spawn zombies and skeletons!
- Respawn anchors work just fine!
- The frame block can be changed with a simple datapack!

## **Dependencies**

| Mod | Loader | Requirement |
|:----------------------------------------------------------------------|:------:|:-----------:|
| [Cobweb](https://modrinth.com/mod/cobweb) | All | Required |
| [Server Sided Portals](https://modrinth.com/mod/server-sided-portals) | All | Required |

## **Compatibilities**

| Mod | Loader | Compatibility |
|:---------------------------------------------------------------|:------:|:-----------------------------------------:|
| [Crying Portals](https://modrinth.com/mod/crying-portals) | All | Incompatible |
| [Immersive Portals](https://modrinth.com/mod/immersiveportals) | All | Incompatible |
| [Very Many Players](https://modrinth.com/mod/vmp-fabric) | Fabric | Compatible with `use_async_portals=false` |
| Mod | Loader | Compatibility |
|:---------------------------------------------------------------|:------:|:------------------------------------------------------------------------------------------------------------------------------:|
| [Crying Portals](https://modrinth.com/mod/crying-portals) | All | Incompatible |
| [Immersive Portals](https://modrinth.com/mod/immersiveportals) | All | Incompatible |
| [Very Many Players](https://modrinth.com/mod/vmp-fabric) | Fabric | Compatible with `use_async_portals=false` |
| [Canary](https://modrinth.com/mod/canary) | Forge | Compatible with [fast portals](https://github.com/AbdElAziz333/Canary/wiki/Configuration-File#mixinaipoifast_portals) disabled |

## **License and right of use**

Expand Down
1 change: 1 addition & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ subprojects { subproject ->
"forge_version" : forge_version,
"forge_loader_version_range" : forge_loader_version_range,
"cobweb_version" : cobweb_version,
"server_sided_portals_version" : server_sided_portals_version
]

filesMatching(["pack.mcmeta", "fabric.mod.json", "META-INF/mods.toml", "*.mixins.json"]) {
Expand Down
1 change: 1 addition & 0 deletions common/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ dependencies {
compileOnly group: "org.spongepowered", name: "mixin", version: "0.8.5"
compileOnly group: "io.github.llamalad7", name: "mixinextras-common", version: "0.3.6"
implementation "it.crystalnest:cobweb-common:${minecraft_version}-${cobweb_version}"
implementation "it.crystalnest:server-sided-portals-common:${minecraft_version}-${server_sided_portals_version}"
}

// Disable publishing tasks where common is not published
Expand Down
15 changes: 2 additions & 13 deletions common/src/main/java/it/crystalnest/nightworld/Constants.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import net.minecraft.resources.ResourceKey;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.world.level.Level;
import net.minecraft.world.level.dimension.DimensionType;
import org.jetbrains.annotations.ApiStatus;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
Expand All @@ -15,24 +14,14 @@
@ApiStatus.Internal
public final class Constants {
/**
* {@link ThreadLocal} to keep track of a player's origin dimension when teleporting through a Nether/Nightworld portal.
*/
public static final ThreadLocal<Boolean> NIGHTWORLD_ORIGIN_THREAD = ThreadLocal.withInitial(() -> false);

/**
* Mod id.
* Mod ID.
*/
public static final String MOD_ID = "nightworld";

/**
* {@link ResourceKey} for the dimension.
*/
public static final ResourceKey<Level> NIGHTWORLD = ResourceKey.create(Registries.DIMENSION, new ResourceLocation(MOD_ID, "nightworld"));

/**
* {@link ResourceKey} for the dimension type.
*/
public static final ResourceKey<DimensionType> NIGHTWORLD_TYPE = ResourceKey.create(Registries.DIMENSION_TYPE, NIGHTWORLD.location());
public static final ResourceKey<Level> NIGHTWORLD = ResourceKey.create(Registries.DIMENSION, new ResourceLocation("server_sided_portals", "nightworld"));

/**
* Mod logger.
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Loading

0 comments on commit 8ab9992

Please sign in to comment.