Skip to content

Commit

Permalink
version update
Browse files Browse the repository at this point in the history
  • Loading branch information
Tigereye504 committed Mar 23, 2022
1 parent c8ad1e9 commit 6dc4be4
Show file tree
Hide file tree
Showing 13 changed files with 78 additions and 359 deletions.
10 changes: 6 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
id 'fabric-loom' version '0.10-SNAPSHOT'
id 'fabric-loom' version '0.11-SNAPSHOT'
id 'maven-publish'
}

Expand Down Expand Up @@ -38,7 +38,9 @@ dependencies {
modApi("me.shedaniel.cloth:cloth-config-fabric:5.0.38") {
exclude(group: "net.fabricmc.fabric-api")
}
modImplementation "com.terraformersmc:modmenu:2.0.4"
modImplementation ("com.terraformersmc:modmenu:2.0.4"){
exclude(group: "net.fabricmc.fabric-api")
}
}

processResources {
Expand All @@ -50,7 +52,7 @@ processResources {
}

tasks.withType(JavaCompile).configureEach {
// Minecraft 1.17 (21w19a) upwards uses Java 16.
// Minecraft 1.18 (1.18-pre2) upwards uses Java 17.
it.options.release = 17
}

Expand Down Expand Up @@ -82,4 +84,4 @@ publishing {
// The repositories here will be used for publishing your artifact, not for
// retrieving dependencies.
}
}
}
10 changes: 5 additions & 5 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ org.gradle.jvmargs=-Xmx1G

# Fabric Properties
# check these on https://fabricmc.net/versions.html
minecraft_version=1.18.1
yarn_mappings=1.18.1+build.7
loader_version=0.12.12
minecraft_version=1.18.2
yarn_mappings=1.18.2+build.2
loader_version=0.13.3

# Mod Properties
mod_version = 0.3.0
mod_version = 0.4.0
maven_group = net.tigereye.lava-java
archives_base_name = lava-java

# Dependencies
fabric_version=0.44.0+1.18
fabric_version=0.48.0+1.18.2
bannerspp_version=2.0.4+mc.1.17-rc1
32 changes: 3 additions & 29 deletions src/main/java/net/tigereye/lavajava/LavaJava.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,31 +5,12 @@
import me.shedaniel.autoconfig.AutoConfig;
import me.shedaniel.autoconfig.serializer.GsonConfigSerializer;
import net.fabricmc.api.ModInitializer;
import net.fabricmc.fabric.api.biome.v1.BiomeModifications;
import net.fabricmc.fabric.api.biome.v1.BiomeSelectors;
import net.fabricmc.fabric.api.object.builder.v1.entity.FabricDefaultAttributeRegistry;
import net.fabricmc.fabric.api.object.builder.v1.entity.FabricEntityTypeBuilder;
import net.fabricmc.fabric.api.resource.ResourceManagerHelper;
import net.minecraft.entity.EntityDimensions;
import net.minecraft.entity.EntityType;
import net.minecraft.entity.SpawnGroup;
import net.minecraft.item.FoodComponent;
import net.minecraft.item.Item;
import net.minecraft.item.ItemGroup;
import net.minecraft.resource.ResourceType;
import net.minecraft.util.Identifier;
import net.minecraft.util.registry.BuiltinRegistries;
import net.minecraft.util.registry.Registry;
import net.minecraft.util.registry.RegistryKey;
import net.minecraft.world.biome.Biome;
import net.tigereye.lavajava.config.LJConfig;
import net.tigereye.lavajava.flavor.*;
import net.tigereye.lavajava.item.LavaJavaItem;
import net.tigereye.lavajava.mob.WitherBaristaEntity;
import net.tigereye.lavajava.register.LJConfiguredStructures;
import net.tigereye.lavajava.register.LJEntities;
import net.tigereye.lavajava.register.LJItems;
import net.tigereye.lavajava.register.LJStructures;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

Expand All @@ -49,26 +30,19 @@ public void onInitialize() {
ResourceManagerHelper.get(ResourceType.SERVER_DATA).registerReloadListener(new FlavorManager());
LJItems.register();
LJEntities.register();
LJStructures.setupAndRegisterStructureFeatures();
LJConfiguredStructures.registerConfiguredStructures();
addStructureSpawningToDimensionsAndBiomes();
//addStructureSpawningToDimensionsAndBiomes();
//TODO: once Banners++ updates to 1.18, unlock glorious banners
//Registry.register(LoomPatterns.REGISTRY, new Identifier("lavajava", "lava_java_banner"), new LoomPattern(false));
}


/*
private void addStructureSpawningToDimensionsAndBiomes(){
/*
* This is the API you will use to add anything to any biome.
* This includes spawns, changing the biome's looks, messing with its temperature,
* adding carvers, spawning new features... etc
*/
BiomeModifications.addStructure(
BiomeSelectors.categories(Biome.Category.NETHER),
RegistryKey.of(Registry.CONFIGURED_STRUCTURE_FEATURE_KEY,
BuiltinRegistries.CONFIGURED_STRUCTURE_FEATURE.getId(LJConfiguredStructures.CONFIGURED_LAVA_JAVA_CAFE))
);
}

*/
}

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -100,13 +100,13 @@ public boolean canSpawn(WorldAccess world, SpawnReason spawnReason) {
}

@Override
public void setCurrentCustomer(@Nullable PlayerEntity customer) {
public void setCustomer(@Nullable PlayerEntity customer) {
this.customer = customer;
}

@Nullable
@Override
public PlayerEntity getCurrentCustomer() {
public PlayerEntity getCustomer() {
return this.customer;
}

Expand Down Expand Up @@ -204,7 +204,7 @@ public ActionResult interactMob(PlayerEntity player, Hand hand) {
return ActionResult.success(this.world.isClient);
} else {
if (!this.world.isClient) {
this.setCurrentCustomer(player);
this.setCustomer(player);
this.sendOffers(player, this.getDisplayName(), this.getLevel());
}

Expand Down Expand Up @@ -368,8 +368,7 @@ public TradeOffer create(Entity entity, Random random) {
for (int i = 0; i < rolls; i++) {
Pair<Identifier, FlavorData> flavor = FlavorManager.getWeightedRandomFlavor(random);
if(flavor != null){
boolean badResult = false;
if(flavors.containsKey(flavor.getLeft())) badResult = true;
boolean badResult = flavors.containsKey(flavor.getLeft());
if(!badResult) {
//if any existing flavors are excluded by this flavor, it is no good
for (Identifier excludedFlavor :
Expand Down

This file was deleted.

48 changes: 0 additions & 48 deletions src/main/java/net/tigereye/lavajava/register/LJStructures.java

This file was deleted.

Loading

0 comments on commit 6dc4be4

Please sign in to comment.