Compare commits

...

10 Commits

Author SHA1 Message Date
Jason Penilla
a523823513 Add ticket on player join
https://github.com/PaperMC/Paper/pull/11398
2024-09-13 16:00:06 -07:00
Jason Penilla
fe7bcfc56a Back to 0.1.0-SNAPSHOT 2024-09-07 18:01:51 -07:00
Jason Penilla
44f8058b09 0.1.0-beta.2 2024-09-07 17:53:22 -07:00
Jason Penilla
d1f8e81913 Update gradle plugins and dependencies 2024-09-07 10:26:08 -07:00
Jason Penilla
dcef1320b2 Switch version back to 0.1.0-SNAPSHOT
We are still in the 0.1.0 beta cycle, bumping to 0.1.1-SNAPSHOT previously was an error
2024-09-07 10:25:17 -07:00
Jason Penilla
179b45cac5 Update lithium config overrides
`mixin.alloc.entity_tracker` does the same thing as useBetterIdentitySet, nothing more or less

closes #17
2024-09-07 10:06:10 -07:00
Jason Penilla
89e9cd52e4 fix(build): mark incompatibility with correct version of starlight 2024-09-03 12:04:19 -07:00
Jason Penilla
38c3f5fd80 0.1.1-SNAPSHOT 2024-09-03 11:58:01 -07:00
Jason Penilla
98e8a08e85 0.1.0-beta.1
this time maybe publishing will work
2024-09-03 11:50:08 -07:00
Jason Penilla
caf2960b6b fix(actions): populate release tag 2024-09-03 11:49:36 -07:00
8 changed files with 45 additions and 12 deletions

View File

@@ -35,7 +35,14 @@ jobs:
run: ./installConcurrentUtil.sh run: ./installConcurrentUtil.sh
- name: "execute gradle build" - name: "execute gradle build"
run: ./gradlew build run: ./gradlew build
- name: Publish (Pre-)Release to Modrinth - name: Determine Snapshot Status
run: |
if [ "$(./gradlew properties | awk '/^version:/ { print $2; }' | grep '\-SNAPSHOT')" ]; then
echo "STATUS=snapshot" >> $GITHUB_ENV
else
echo "STATUS=release" >> $GITHUB_ENV
fi
- name: Publish (Pre-)Release to Modrinth & CurseForge
if: "${{ env.STATUS == 'release' && github.event_name == 'release' }}" if: "${{ env.STATUS == 'release' && github.event_name == 'release' }}"
run: ./gradlew :moonrise-fabric:publishMods :moonrise-neoforge:publishMods run: ./gradlew :moonrise-fabric:publishMods :moonrise-neoforge:publishMods
env: env:

View File

@@ -1,7 +1,7 @@
plugins { plugins {
id("xyz.jpenilla.quiet-architectury-loom") id("xyz.jpenilla.quiet-architectury-loom")
id 'maven-publish' id 'maven-publish'
id 'io.github.goooler.shadow' id 'com.gradleup.shadow'
} }
configurations.create("libs") configurations.create("libs")

View File

@@ -64,7 +64,8 @@
"mixin.entity.collisions.intersection": false, "mixin.entity.collisions.intersection": false,
"mixin.entity.collisions.movement": false, "mixin.entity.collisions.movement": false,
"mixin.entity.collisions.unpushable_cramming": false, "mixin.entity.collisions.unpushable_cramming": false,
"mixin.chunk.entity_class_groups": false "mixin.chunk.entity_class_groups": false,
"mixin.alloc.entity_tracker": false
} }
} }
} }

View File

@@ -4,13 +4,13 @@ org.gradle.daemon=false
# Fabric Properties # Fabric Properties
# check these on https://modmuss50.me/fabric.html # check these on https://modmuss50.me/fabric.html
minecraft_version=1.21.1 minecraft_version=1.21.1
loader_version=0.15.11 loader_version=0.16.5
neoforge_version=21.1.20 neoforge_version=21.1.42
snakeyaml_version=2.2 snakeyaml_version=2.2
concurrentutil_version=0.0.2-SNAPSHOT concurrentutil_version=0.0.2-SNAPSHOT
cloth_version=15.0.128 cloth_version=15.0.128
lithium_version=mc1.21.1-0.13.0 lithium_version=mc1.21.1-0.13.0
# Mod Properties # Mod Properties
mod_version=0.1.0-beta.0 mod_version=0.1.0-SNAPSHOT
maven_group=ca.spottedleaf.moonrise maven_group=ca.spottedleaf.moonrise
archives_base_name=moonrise archives_base_name=moonrise

View File

@@ -3,7 +3,7 @@ import net.fabricmc.loom.util.aw2at.Aw2At
plugins { plugins {
id("xyz.jpenilla.quiet-architectury-loom") id("xyz.jpenilla.quiet-architectury-loom")
id 'maven-publish' id 'maven-publish'
id 'io.github.goooler.shadow' id 'com.gradleup.shadow'
} }
repositories { repositories {
@@ -53,7 +53,7 @@ publishMods {
modrinth { modrinth {
incompatible( incompatible(
"notenoughcrashes", "notenoughcrashes",
"starlight-forge", "starlight-neoforge",
"canary", "canary",
"radium" "radium"
) )
@@ -61,7 +61,7 @@ publishMods {
curseforge { curseforge {
incompatible( incompatible(
"not-enough-crashes-forge", "not-enough-crashes-forge",
"starlight-forge", "starlight-neoforge",
"canary", "canary",
"radium-reforged" "radium-reforged"
) )

View File

@@ -24,8 +24,8 @@ pluginManagement {
plugins { plugins {
id("org.gradle.toolchains.foojay-resolver-convention") version "0.8.0" id("org.gradle.toolchains.foojay-resolver-convention") version "0.8.0"
id("xyz.jpenilla.quiet-architectury-loom") version "1.7.294" apply false id("xyz.jpenilla.quiet-architectury-loom") version "1.7.295" apply false
id 'io.github.goooler.shadow' version '8.1.8' apply false id 'com.gradleup.shadow' version '8.3.0' apply false
} }
dependencyResolutionManagement { dependencyResolutionManagement {
@@ -37,7 +37,7 @@ dependencyResolutionManagement {
} }
versionCatalogs { versionCatalogs {
create("fabricApiLibs") { create("fabricApiLibs") {
from("net.fabricmc.fabric-api:fabric-api-catalog:0.102.0+1.21.1") from("net.fabricmc.fabric-api:fabric-api-catalog:0.103.0+1.21.1")
} }
} }
} }

View File

@@ -1,11 +1,14 @@
package ca.spottedleaf.moonrise.mixin.chunk_system; package ca.spottedleaf.moonrise.mixin.chunk_system;
import ca.spottedleaf.moonrise.patches.chunk_system.level.ChunkSystemServerLevel;
import ca.spottedleaf.moonrise.patches.chunk_system.player.ChunkSystemServerPlayer; import ca.spottedleaf.moonrise.patches.chunk_system.player.ChunkSystemServerPlayer;
import ca.spottedleaf.moonrise.patches.chunk_system.player.RegionizedPlayerChunkLoader;
import net.minecraft.network.Connection; import net.minecraft.network.Connection;
import net.minecraft.network.protocol.Packet; import net.minecraft.network.protocol.Packet;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.server.network.CommonListenerCookie; import net.minecraft.server.network.CommonListenerCookie;
import net.minecraft.server.players.PlayerList; import net.minecraft.server.players.PlayerList;
import net.minecraft.util.Unit;
import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At; import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Inject; import org.spongepowered.asm.mixin.injection.Inject;
@@ -30,6 +33,26 @@ abstract class PlayerListMixin {
((ChunkSystemServerPlayer)serverPlayer).moonrise$setRealPlayer(true); ((ChunkSystemServerPlayer)serverPlayer).moonrise$setRealPlayer(true);
} }
/**
* @reason prevent chunk load cycling on join
* @author jpenilla
*/
@Inject(
method = "placeNewPlayer",
at = @At(
target = "Lnet/minecraft/server/level/ServerLevel;addNewPlayer(Lnet/minecraft/server/level/ServerPlayer;)V",
value = "INVOKE"
)
)
private void addJoinTicket(final Connection connection, final ServerPlayer serverPlayer,
final CommonListenerCookie commonListenerCookie, final CallbackInfo ci) {
((ChunkSystemServerLevel) serverPlayer.serverLevel()).moonrise$getChunkTaskScheduler().chunkHolderManager.addTicketAtLevel(
RegionizedPlayerChunkLoader.PLAYER_JOIN,
serverPlayer.chunkPosition(),
RegionizedPlayerChunkLoader.TICK_TICKET_LEVEL,
Unit.INSTANCE);
}
/** /**
* @reason The RegionizedPlayerChunkLoader will handle the VD packet * @reason The RegionizedPlayerChunkLoader will handle the VD packet
* @author Spottedleaf * @author Spottedleaf

View File

@@ -34,6 +34,7 @@ import net.minecraft.server.level.ServerLevel;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.server.level.TicketType; import net.minecraft.server.level.TicketType;
import net.minecraft.server.network.PlayerChunkSender; import net.minecraft.server.network.PlayerChunkSender;
import net.minecraft.util.Unit;
import net.minecraft.world.level.ChunkPos; import net.minecraft.world.level.ChunkPos;
import net.minecraft.world.level.GameRules; import net.minecraft.world.level.GameRules;
import net.minecraft.world.level.chunk.ChunkAccess; import net.minecraft.world.level.chunk.ChunkAccess;
@@ -52,6 +53,7 @@ public final class RegionizedPlayerChunkLoader {
public static final TicketType<Long> PLAYER_TICKET = TicketType.create("chunk_system:player_ticket", Long::compareTo); public static final TicketType<Long> PLAYER_TICKET = TicketType.create("chunk_system:player_ticket", Long::compareTo);
public static final TicketType<Long> PLAYER_TICKET_DELAYED = TicketType.create("chunk_system:player_ticket_delayed", Long::compareTo, 5 * 20); public static final TicketType<Long> PLAYER_TICKET_DELAYED = TicketType.create("chunk_system:player_ticket_delayed", Long::compareTo, 5 * 20);
public static final TicketType<Unit> PLAYER_JOIN = TicketType.create("chunk_system:player_join", (a, b) -> 0, 5 * 20);
public static final int MIN_VIEW_DISTANCE = 2; public static final int MIN_VIEW_DISTANCE = 2;
public static final int MAX_VIEW_DISTANCE = 32; public static final int MAX_VIEW_DISTANCE = 32;