Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: v5.3 #54

Merged
merged 49 commits into from
Feb 25, 2024
Merged
Changes from 1 commit
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
cdf7fa4
chore: Remove support for MC1.19.3 - MC1.19.4
null2264 Nov 30, 2023
e65781e
chore: Bumps version to v5.3.0
null2264 Nov 30, 2023
0c3aa8e
chore: Maven migration (again)
null2264 Nov 30, 2023
f16a09a
Merge branch '1.18+' into dev/1.18+/5.3
null2264 Dec 3, 2023
4502ecf
chore: Drop support for Forge (1.20.2)
null2264 Dec 4, 2023
d1419d7
refactor: Move FluidInteractionHelper out of data/ directory
null2264 Dec 5, 2023
2ddb157
chore: Optimize import
null2264 Dec 5, 2023
daddcd5
feat: Added check function for plugins
null2264 Dec 5, 2023
879f32f
chore: Comment
null2264 Dec 5, 2023
9016a6e
refactor: Custom class for ID and modifier
null2264 Dec 6, 2023
28bfd9a
feat: Serializer and Deserializer
null2264 Dec 6, 2023
1c586bc
feat: Create configs
null2264 Dec 6, 2023
ba3ed2f
chore: Annotate `handleReaction`
null2264 Dec 6, 2023
051d423
refactor: Use CGIdentifier in config
null2264 Dec 6, 2023
7772e0d
chore: Update neoforge to stable release
null2264 Dec 6, 2023
03abd5c
chore: Disable recipe viewer in dev environment
null2264 Dec 7, 2023
9d26453
fix: Recipe Viewer
null2264 Dec 7, 2023
9ddb6a3
docs: Add @since to shouldLoad javaDoc
null2264 Dec 7, 2023
650edc0
feat: ByteBuf read and write
null2264 Dec 7, 2023
9d1a291
refactor: Use CGIdentifier
null2264 Dec 7, 2023
f2a3ab8
refactor: Preparing configuration phase usage
null2264 Dec 7, 2023
b09ae8e
fix: Wildcard shouldn't return `*`
null2264 Dec 7, 2023
4b1382f
fix: Ambiguous mixin ref
null2264 Dec 7, 2023
f9d79d1
feat: Use configuration phase
null2264 Dec 7, 2023
c20c7ba
fix: Don't use gson
null2264 Dec 7, 2023
53ce249
chore: Update jankson to v1.2.3
null2264 Dec 7, 2023
5022090
fix: Config serializer
null2264 Dec 8, 2023
a1d73bd
chore: Add formatVersion to config
null2264 Dec 8, 2023
b262677
ci: Update action/checkout to v4
null2264 Dec 8, 2023
2a404c2
ci: Revert setup java
null2264 Dec 8, 2023
66e20a3
chore: Update 1.20.2+ release supported versions
null2264 Dec 8, 2023
d2e22b2
refactor: Improve serializer
null2264 Dec 9, 2023
ddba7cd
refactor: Move `config/` into `data/`
null2264 Dec 9, 2023
ab9e619
refactor: Add GeneratorMap
null2264 Dec 9, 2023
3a0dcc1
refactor: Replace the rest of config data with its own class
null2264 Dec 10, 2023
4d54464
chore: Override hashCode and equals
null2264 Dec 10, 2023
54800c4
fix: Only accept 4 modifiers
null2264 Dec 10, 2023
0ab4c49
fix: Merge conflict
null2264 Feb 25, 2024
0f331c0
fix: Don't use record in 1.16.5
null2264 Feb 25, 2024
e2b27e5
fix: Don't use pattern matching
null2264 Feb 25, 2024
e3b92e2
fix: More pattern matching removal
null2264 Feb 25, 2024
2d358cb
chore: Add 1.20.5
null2264 Feb 25, 2024
31f5a9e
fix: Wrong type idiot
null2264 Feb 25, 2024
5852bf2
fix: Leftover lombok junk
null2264 Feb 25, 2024
d6ff0f0
fix: Networking Doomsday
null2264 Feb 25, 2024
d4aee50
fix: Java 8 incompat
null2264 Feb 25, 2024
bbf1eb9
chore: Remove duplicate codec
null2264 Feb 25, 2024
c0cb423
fix: Support snapshots
null2264 Feb 25, 2024
cba91ba
fix: Don't add - for lesser than
null2264 Feb 25, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix: Leftover lombok junk
null2264 committed Feb 25, 2024
commit 5852bf2c1619af9cea972b02e3de5e0a16235336
Original file line number Diff line number Diff line change
@@ -1,17 +1,11 @@
package io.github.null2264.cobblegen.data.config;

import blue.endless.jankson.*;
import blue.endless.jankson.JsonElement;
import blue.endless.jankson.JsonObject;
import blue.endless.jankson.JsonPrimitive;
import blue.endless.jankson.annotation.Deserializer;
import blue.endless.jankson.annotation.Serializer;
import io.github.null2264.cobblegen.data.CGIdentifier;
import io.github.null2264.cobblegen.data.JanksonSerializable;
import lombok.val;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import static io.github.null2264.cobblegen.util.Constants.JANKSON;

public class AdvancedGen implements JanksonSerializable
{
@@ -39,7 +33,7 @@ public AdvancedGen(
@Override
@Serializer
public JsonElement toJson() {
val json = new JsonObject();
JsonObject json = new JsonObject();
json.put("silent", JsonPrimitive.of(silent));
json.put("results", results.toJson());
json.put("resultsFromTop", resultsFromTop.toJson());
@@ -49,10 +43,10 @@ public JsonElement toJson() {

@Deserializer
public static AdvancedGen fromJson(JsonObject json) {
val silent = json.getBoolean("silent", false);
val results = GeneratorMap.fromJson(json.getObject("results"));
val resultsFromTop = GeneratorMap.fromJson(json.getObject("resultsFromTop"));
val obsidian = GeneratorMap.fromJson(json.getObject("obsidian"));
Boolean silent = json.getBoolean("silent", false);
GeneratorMap results = GeneratorMap.fromJson(json.getObject("results"));
GeneratorMap resultsFromTop = GeneratorMap.fromJson(json.getObject("resultsFromTop"));
GeneratorMap obsidian = GeneratorMap.fromJson(json.getObject("obsidian"));
return new AdvancedGen(silent, results, resultsFromTop, obsidian);
}
}
Original file line number Diff line number Diff line change
@@ -3,7 +3,6 @@
//$$
//$$ import io.github.null2264.cobblegen.network.payload.CGPingS2CPayload;
//$$ import io.netty.buffer.Unpooled;
//$$ import lombok.val;
//$$ import net.minecraft.network.FriendlyByteBuf;
//$$ import net.minecraft.network.protocol.common.ClientboundCustomPayloadPacket;
//$$ import net.minecraft.server.network.ServerConfigurationPacketListenerImpl;
@@ -18,7 +17,7 @@
//$$ public abstract class ServerConfigurationPacketListenerMixin {
//$$ @Inject(method = "startConfiguration", at = @At("HEAD"))
//$$ private void syncCG(CallbackInfo ci) {
//$$ val buf = new FriendlyByteBuf(Unpooled.buffer());
//$$ FriendlyByteBuf buf = new FriendlyByteBuf(Unpooled.buffer());
//$$ buf.writeResourceLocation(CG_PING.toMC());
//$$ ((ServerConfigurationPacketListenerImpl) (Object) this).send(
//$$ new ClientboundCustomPayloadPacket(new CGPingS2CPayload(false))
Original file line number Diff line number Diff line change
@@ -4,8 +4,8 @@
//#if MC<1.20.2
import net.minecraft.network.protocol.game.ServerboundCustomPayloadPacket;
//#else
//$$ import lombok.val;
//$$ import io.github.null2264.cobblegen.data.CGIdentifier;
//$$ import io.github.null2264.cobblegen.network.payload.CGPayloadReader;
//$$ import io.netty.buffer.Unpooled;
//$$ import net.minecraft.network.FriendlyByteBuf;
//$$ import net.minecraft.network.protocol.common.ServerboundCustomPayloadPacket;
@@ -27,7 +27,7 @@ public abstract class ServerboundCustomPayloadPacketMixin {
//$$ if (!id.getNamespace().equals(MOD_ID))
//$$ return;
//$$
//$$ val reader = KNOWN_SERVER_PAYLOADS.get(CGIdentifier.fromMC(id));
//$$ CGPayloadReader<? extends net.minecraft.network.protocol.common.custom.CustomPacketPayload> reader = KNOWN_SERVER_PAYLOADS.get(CGIdentifier.fromMC(id));
//$$ if (reader == null) return;
//$$
//$$ cir.setReturnValue(reader.apply(buf));