Skip to content

Commit d9aca1d

Browse files
committed
Yea I'm unsure what I got in here actually.
1 parent 21c8d8d commit d9aca1d

88 files changed

Lines changed: 2260 additions & 2052 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

common/src/main/java/generations/gg/generations/core/generationscore/common/GenerationsCore.java

Lines changed: 1 addition & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import com.cobblemon.mod.common.api.data.DataProvider;
1212
import com.cobblemon.mod.common.api.spawning.detail.SpawnDetail;
1313
import com.cobblemon.mod.common.api.storage.player.PlayerDataExtensionRegistry;
14-
import com.google.gson.JsonObject;
1514
import com.mojang.logging.LogUtils;
1615
import dev.architectury.event.events.common.LootEvent;
1716
import generations.gg.generations.core.generationscore.common.api.GenerationsMolangFunctions;
@@ -39,7 +38,6 @@
3938
import generations.gg.generations.core.generationscore.common.world.sound.GenerationsSounds;
4039
import generations.gg.generations.core.generationscore.common.world.spawning.ZygardeCellDetail;
4140
import net.minecraft.core.registries.Registries;
42-
import net.minecraft.network.FriendlyByteBuf;
4341
import net.minecraft.network.chat.MutableComponent;
4442
import net.minecraft.resources.ResourceKey;
4543
import net.minecraft.resources.ResourceLocation;
@@ -50,7 +48,6 @@
5048
import net.minecraft.world.level.storage.loot.*;
5149
import net.minecraft.world.level.storage.loot.entries.NestedLootTable;
5250
import org.apache.logging.log4j.util.TriConsumer;
53-
import org.jetbrains.annotations.NotNull;
5451
import org.slf4j.Logger;
5552

5653
import java.util.function.Consumer;
@@ -122,7 +119,7 @@ public static void init(GenerationsImplementation implementation) {
122119
GenerationsPaintings.init();
123120
GenerationsContainers.init();
124121
RksResultType.init();
125-
initRecipes();
122+
GenerationsIngredidents.init();
126123
GenerationsCoreRecipeTypes.init();
127124
GenerationsCoreRecipeSerializers.init();
128125
GenerationsCoreStats.init();
@@ -146,27 +143,6 @@ public static void init(GenerationsImplementation implementation) {
146143
// BuiltInRegistries.BLOCK.stream().map(a -> a.arch$registryName() + ": " + a.getLootTable()).forEach(a -> System.out.println(a));
147144
}
148145

149-
private static void initRecipes() {
150-
GenerationsIngredidents.register(ItemIngredient.Companion.getID(), ItemIngredientSerializer.INSTANCE);
151-
GenerationsIngredidents.register(TimeCapsuleIngredient.Companion.getID(), TimeCapsuleIngredientSerializer.INSTANCE);
152-
GenerationsIngredidents.register(PokemonItemIngredient.Companion.getID(), PokemonItemIngredient.PokemonItemIngredientSerializer.INSTANCE);
153-
GenerationsIngredidents.register(DamageIngredient.Companion.getID(), DamageIngredientSerializer.INSTANCE);
154-
GenerationsIngredidents.register(ItemTagIngredient.Companion.getID(), ItemTagIngredientSerializer.INSTANCE);
155-
GenerationsIngredidents.register(GenerationsIngredient.EmptyIngredient.INSTANCE.getId(), new GenerationsIngredientSerializer<>() {
156-
@NotNull
157-
@Override
158-
public GenerationsIngredient read(@NotNull FriendlyByteBuf buf) {
159-
return GenerationsIngredient.EmptyIngredient.INSTANCE;
160-
}
161-
162-
@NotNull
163-
@Override
164-
public GenerationsIngredient read(@NotNull JsonObject jsonObject) {
165-
return GenerationsIngredient.EmptyIngredient.INSTANCE;
166-
}
167-
});
168-
}
169-
170146
public static void initBuiltinPacks(TriConsumer<PackType, ResourceLocation, MutableComponent> consumer) {
171147
// consumer.accept(PackType.CLIENT_RESOURCES, GenerationsCore.id("smooth_pokemon"), Component.literal("Smooth Pokemon Models"));
172148
}

common/src/main/java/generations/gg/generations/core/generationscore/common/api/data/Codecs.java

Lines changed: 0 additions & 51 deletions
This file was deleted.

common/src/main/java/generations/gg/generations/core/generationscore/common/api/data/GenerationsCoreEntityDataSerializers.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ object GenerationsCoreEntityDataSerializers {
1717

1818
private fun <T> simple(encoder: (RegistryFriendlyByteBuf, T) -> Unit, decoder: (RegistryFriendlyByteBuf) -> T): EntityDataSerializer<T> = EntityDataSerializer.forValueType(StreamCodec.of(encoder, decoder))
1919

20-
fun init() {
20+
@JvmStatic fun init() {
2121
EntityDataSerializers.registerSerializer(PROPERTIES)
2222
EntityDataSerializers.registerSerializer(NULLABLE_STRING)
2323
}

common/src/main/java/generations/gg/generations/core/generationscore/common/api/player/PlayerMoney.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
11
package generations.gg.generations.core.generationscore.common.api.player;
22

3+
import com.cobblemon.mod.common.api.net.NetworkPacket;
34
import generations.gg.generations.core.generationscore.common.network.packets.shop.S2CSyncPlayerMoneyPacket;
45
import net.minecraft.server.level.ServerPlayer;
56
import net.minecraft.world.entity.player.Player;
67

78
import java.math.BigDecimal;
89
import java.util.concurrent.CompletableFuture;
10+
import java.util.function.BiConsumer;
911

1012
public interface PlayerMoney {
1113
CompletableFuture<Boolean> withdraw(BigDecimal amount);
@@ -14,7 +16,7 @@ public interface PlayerMoney {
1416

1517
default void sync(Player player) {
1618
if (player instanceof ServerPlayer serverPlayer) {
17-
balance().thenApply(S2CSyncPlayerMoneyPacket::new).thenAcceptBoth(CompletableFuture.completedFuture(serverPlayer), GenerationsNetworkPacket::sendToPlayer);
19+
balance().thenApply(S2CSyncPlayerMoneyPacket::new).thenAcceptBoth(CompletableFuture.completedFuture(serverPlayer), NetworkPacket::sendToPlayer);
1820
} else {
1921
throw new RuntimeException("Tried to sync a party from the client???");
2022
}

common/src/main/java/generations/gg/generations/core/generationscore/common/client/GenerationsCoreClient.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -269,8 +269,8 @@ private static void addWoodType(WoodType woodType) {
269269
private static void registerScreens() {
270270
MenuRegistry.registerScreenFactory(GenerationsContainers.COOKING_POT.get(), CookingPotScreen::new);
271271
MenuRegistry.registerScreenFactory(GenerationsContainers.GENERIC.get(), GenericChestScreen::new);
272-
MenuRegistry.registerScreenFactory(GenerationsContainers.WALKMON.get(), GenericChestScreen::new);
273-
MenuRegistry.registerScreenFactory(GenerationsContainers.CALYREX_STEED.get(), GenericChestScreen::new);
272+
// MenuRegistry.registerScreenFactory(GenerationsContainers.WALKMON.get(), GenericChestScreen::new);
273+
// MenuRegistry.registerScreenFactory(GenerationsContainers.CALYREX_STEED.get(), GenericChestScreen::new);
274274
MenuRegistry.registerScreenFactory(GenerationsContainers.MACHINE_BLOCK.get(), MachineBlockScreen::new);
275275
MenuRegistry.registerScreenFactory(GenerationsContainers.MELODY_FLUTE.get(), MelodyFluteScreen::new);
276276
MenuRegistry.registerScreenFactory(GenerationsContainers.TRASHCAN.get(), TrashCanScreen::new);

common/src/main/java/generations/gg/generations/core/generationscore/common/client/render/block/entity/RegigigasShrineBlockEntityRenderer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public static void processOrbs(RegigigasShrineBlockEntity shrineBlock) {
4242
List<Vector3f> colors = new ArrayList<>();
4343

4444
for (int i = 0; i < 5; i++) {
45-
if(!shrineBlock.getRegiOrbs().getItem(i).isEmpty()) {
45+
if(!shrineBlock.getRegiOrbs().get(i).isEmpty()) {
4646
colors.add(map.get(i));
4747
}
4848
}

common/src/main/java/generations/gg/generations/core/generationscore/common/client/screen/container/MachineBlockScreen.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public MachineBlockScreen(MachineBlockContainer arg, Inventory arg2, Component a
3030
public void render(@NotNull GuiGraphics poseStack, int mouseX, int mouseY, float partialTick) {
3131
this.menu.slots.stream().filter(a -> a instanceof TypeSlot).forEach(a -> TypeSlot.interpolateVectors((TypeSlot) a, 0, 0, 80, 80, bakeTimeProvider.getAsDouble()));
3232

33-
this.renderBackground(poseStack);
33+
this.renderBackground(poseStack, mouseX, mouseY, partialTick);
3434
super.render(poseStack, mouseX, mouseY, partialTick);
3535
this.renderTooltip(poseStack, mouseX, mouseY);
3636
}

common/src/main/java/generations/gg/generations/core/generationscore/common/client/screen/container/SingleSlotScreen.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ public SingleSlotScreen(T arg, Inventory arg2, Component arg3) {
1818
}
1919
@Override
2020
public void render(@NotNull GuiGraphics poseStack, int mouseX, int mouseY, float partialTick) {
21-
this.renderBackground(poseStack);
21+
this.renderBackground(poseStack, mouseX, mouseY, partialTick);
2222
super.render(poseStack, mouseX, mouseY, partialTick);
2323
this.renderTooltip(poseStack, mouseX, mouseY);
2424
}

common/src/main/java/generations/gg/generations/core/generationscore/common/client/screen/mails/MailViewScreen.java

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -196,8 +196,10 @@ public WritableMailAccess(ItemStack arg) {
196196
}
197197

198198
private static String readContents(ItemStack writtenBookStack) {
199-
CompoundTag compoundTag = writtenBookStack.getTag();
200-
return compoundTag != null ? MailViewScreen.loadPages(compoundTag) : "";
199+
return "";
200+
201+
// CompoundTag compoundTag = writtenBookStack.getTag();
202+
// return compoundTag != null ? MailViewScreen.loadPages(compoundTag) : "";
201203
}
202204

203205
@Override
@@ -229,19 +231,20 @@ public WrittenMailAccess(ItemStack arg) {
229231
}
230232

231233
private static String readAuthor(ItemStack arg) {
232-
CompoundTag compoundTag = arg.getTag();
233-
if (compoundTag != null && ClosedMailItem.makeSureTagIsValid(compoundTag)) {
234-
return compoundTag.getString("author");
235-
}
234+
// CompoundTag compoundTag = arg.getTag();
235+
// if (compoundTag != null && ClosedMailItem.makeSureTagIsValid(compoundTag)) {
236+
// return compoundTag.getString("author");
237+
// }
236238
return "";
237239
}
238240

239241
private static String readPages(ItemStack writtenBookStack) {
240-
CompoundTag compoundTag = writtenBookStack.getTag();
241-
if (compoundTag != null && ClosedMailItem.makeSureTagIsValid(compoundTag)) {
242-
return MailViewScreen.loadPages(compoundTag);
243-
}
244-
return Component.Serializer.toJson(Component.translatable("book.invalid.tag").withStyle(ChatFormatting.DARK_RED));
242+
// CompoundTag compoundTag = writtenBookStack.getTag();
243+
// if (compoundTag != null && ClosedMailItem.makeSureTagIsValid(compoundTag)) {
244+
// return MailViewScreen.loadPages(compoundTag);
245+
// }
246+
// return Component.Serializer.toJson(Component.translatable("book.invalid.tag").withStyle(ChatFormatting.DARK_RED));
247+
return "";
245248
}
246249

247250
@Override

common/src/main/java/generations/gg/generations/core/generationscore/common/config/SpeciesKey.java

Lines changed: 0 additions & 100 deletions
This file was deleted.

0 commit comments

Comments
 (0)