Skip to content

Commit

Permalink
Feature murder
Browse files Browse the repository at this point in the history
  • Loading branch information
Vazkii committed Nov 8, 2023
1 parent 2a9bf39 commit c2fe23b
Show file tree
Hide file tree
Showing 171 changed files with 37 additions and 2,656 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@ public static void setup(ZCommonSetup event) {

// Clientbound
network.register(DoEmoteMessage.class, ZetaNetworkDirection.PLAY_TO_CLIENT);
network.register(EditSignMessage.class, ZetaNetworkDirection.PLAY_TO_CLIENT);
network.register(UpdateTridentMessage.class, ZetaNetworkDirection.PLAY_TO_CLIENT);

// Flag Syncing
Expand Down

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,8 @@ public class CompressedBlocksModule extends ZetaModule {
@Config.Min(0)
public static int stickBlockFuelTime = 900;

@Config(name = "Bamboo Block Fuel Time")
@Config.Min(0)
public static int bambooBundleFuelTime = 500;

@Config(flag = "charcoal_block") public static boolean enableCharcoalBlock = true;
@Config(flag = "sugar_cane_block") public static boolean enableSugarCaneBlock = true;
@Config(flag = "bamboo_block") public static boolean enableBambooBlock = true;
@Config(flag = "cactus_block") public static boolean enableCactusBlock = true;
@Config(flag = "chorus_fruit_block") public static boolean enableChorusFruitBlock = true;
@Config(flag = "stick_block") public static boolean enableStickBlock = true;
Expand All @@ -77,7 +72,6 @@ public class CompressedBlocksModule extends ZetaModule {
@Hint("golden_apple_crate") public static Block golden_apple_crate;

public static Block stick_block;
public static Block bamboo_bundle;

private final List<Block> compostable = Lists.newArrayList();

Expand All @@ -90,9 +84,7 @@ public final void register(ZRegister event) {
.sound(SoundType.STONE))
.setCondition(() -> enableCharcoalBlock);

bamboo_bundle = pillar("sugar_cane", MaterialColor.COLOR_LIGHT_GREEN, true, () -> enableSugarCaneBlock, 200);
Block bamboo = pillar("bamboo", MaterialColor.COLOR_GREEN, false, () -> enableBambooBlock, 200);
Block stripped_bamboo = pillar("stripped_bamboo", MaterialColor.COLOR_YELLOW, false, () -> enableBambooBlock, 200);
pillar("sugar_cane", MaterialColor.COLOR_LIGHT_GREEN, true, () -> enableSugarCaneBlock, 200);
pillar("cactus", MaterialColor.COLOR_GREEN, true, () -> enableCactusBlock, 50);
pillar("chorus_fruit", MaterialColor.COLOR_PURPLE, false, () -> enableChorusFruitBlock, 10);
stick_block = pillar("stick", MaterialColor.WOOD, false, () -> enableStickBlock, 300);
Expand Down Expand Up @@ -126,8 +118,6 @@ public final void register(ZRegister event) {
.strength(0.4F)
.sound(SoundType.WOOL))
.setCondition(() -> enableBondedRabbitHide);

ToolInteractionHandler.registerInteraction(ToolActions.AXE_STRIP, bamboo, stripped_bamboo);
}

@LoadEvent
Expand All @@ -141,7 +131,6 @@ public void loadComplete(ZLoadComplete event) {
FuelHandler.addFuel(stick_block, stickBlockFuelTime);
FuelHandler.addFuel(charcoal_block, charcoalBlockFuelTime);
FuelHandler.addFuel(blaze_lantern, blazeLanternFuelTime);
FuelHandler.addFuel(bamboo_bundle, bambooBundleFuelTime);
}

private Block pillar(String name, MaterialColor color, boolean compost, BooleanSupplier cond, int flammability) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
package org.violetmoon.quark.content.tweaks.module;

import org.violetmoon.quark.base.Quark;
import org.violetmoon.quark.base.module.config.Config;
import org.violetmoon.zeta.event.bus.PlayEvent;
import org.violetmoon.zeta.event.play.entity.player.ZRightClickItem;
import org.violetmoon.zeta.module.ZetaLoadModule;
Expand All @@ -20,12 +22,26 @@
import net.minecraft.world.phys.BlockHitResult;

@ZetaLoadModule(category = "tweaks")
public class SpongeOnWaterPlacementModule extends ZetaModule {
public class ImprovedSpongesModule extends ZetaModule {

@Config(description = "The maximum number of water tiles that a sponge can soak up. Vanilla default is 64.")
@Config.Min(64)
public static int maximumWaterDrain = 256;

@Config(description = "The maximum number of water tiles that a sponge can 'crawl along' for draining. Vanilla default is 6.")
@Config.Min(6)
public static int maximumCrawlDistance = 10;

@Config
public static boolean enablePlacingOnWater = true;

@Hint Item sponge = Items.SPONGE;

@PlayEvent
public void onUse(ZRightClickItem event) {
if(!enablePlacingOnWater)
return;

ItemStack stack = event.getItemStack();
if(stack.is(Items.SPONGE)) {
Player player = event.getEntity();
Expand All @@ -45,5 +61,21 @@ public void onUse(ZRightClickItem event) {
}
}
}

public static int drainLimit(int previous) {
if (Quark.ZETA.modules.isEnabled(ImprovedSpongesModule.class)) {
// Additive to not directly conflict with other mods
return maximumWaterDrain - 64 + previous;
}
return previous;
}

public static int crawlLimit(int previous) {
if (Quark.ZETA.modules.isEnabled(ImprovedSpongesModule.class)) {
// Additive to not directly conflict with other mods
return maximumCrawlDistance - 6 + previous;
}
return previous;
}

}

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ public class BlossomTreesModule extends ZetaModule {
@Config public BlossomTreeConfig blue = new BlossomTreeConfig(200, Tags.Biomes.IS_SNOWY);
@Config public BlossomTreeConfig lavender = new BlossomTreeConfig(100, Tags.Biomes.IS_SWAMP);
@Config public BlossomTreeConfig orange = new BlossomTreeConfig(100, BiomeTags.IS_SAVANNA);
@Config public BlossomTreeConfig pink = new BlossomTreeConfig(100, BiomeTags.IS_MOUNTAIN);
@Config public BlossomTreeConfig yellow = new BlossomTreeConfig(200, Tags.Biomes.IS_PLAINS);
@Config public BlossomTreeConfig red = new BlossomTreeConfig(30, BiomeTags.IS_BADLANDS);

Expand All @@ -53,7 +52,6 @@ public final void register(ZRegister event) {
add("blue", MaterialColor.COLOR_LIGHT_BLUE, blue);
add("lavender", MaterialColor.COLOR_PINK, lavender);
add("orange", MaterialColor.TERRACOTTA_ORANGE, orange);
add("pink", MaterialColor.COLOR_PINK, pink);
add("yellow", MaterialColor.COLOR_YELLOW, yellow);
add("red", MaterialColor.COLOR_RED, red);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.Constant;
import org.spongepowered.asm.mixin.injection.ModifyConstant;
import org.violetmoon.quark.content.tweaks.module.SpongesBetterModule;
import org.violetmoon.quark.content.tweaks.module.ImprovedSpongesModule;

@Mixin(SpongeBlock.class)
public class SpongeBlockMixin {

@ModifyConstant(method = "removeWaterBreadthFirstSearch", constant = @Constant(intValue = 64))
public int getDrainLimit(int limit) {
return SpongesBetterModule.drainLimit(limit);
return ImprovedSpongesModule.drainLimit(limit);
}

@ModifyConstant(method = "removeWaterBreadthFirstSearch", constant = @Constant(intValue = 6))
public int getCrawlLimit(int limit) {
return SpongesBetterModule.crawlLimit(limit);
return ImprovedSpongesModule.crawlLimit(limit);
}

}
7 changes: 0 additions & 7 deletions src/main/resources/assets/quark/blockstates/bamboo_block.json

This file was deleted.

28 changes: 0 additions & 28 deletions src/main/resources/assets/quark/blockstates/bamboo_button.json

This file was deleted.

Loading

0 comments on commit c2fe23b

Please sign in to comment.