Skip to content

Commit

Permalink
Merged 1.8.1 release
Browse files Browse the repository at this point in the history
  • Loading branch information
Majrusz authored Sep 15, 2023
2 parents 3305d25 + 2b10b2d commit d8aa150
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 3 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ versions_minecraft=1.20.1
versions_minecraft_range=[1.20.1,1.21)
versions_forge=47.1.0
versions_forge_range=[47.1.0,)
versions_mod=1.8.0
versions_mod=1.8.1
versions_mlib=5.0.0
versions_mlib_range=[5.0.0,6.0.0)
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ private void increaseDamage( OnPreDamaged.Data data ) {
public static class Tooltip {
public Tooltip() {
OnItemAttributeTooltip.listen( this::addSpellInfo )
.addCondition( Condition.predicate( data->Registries.EVOKER_FANG_SCROLL.isPresent() ) )
.addCondition( Condition.predicate( data->data.itemStack.is( Registries.EVOKER_FANG_SCROLL.get() ) ) );
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ protected SoundEvent getCastSound() {
public static class Tooltip {
public Tooltip() {
OnItemAttributeTooltip.listen( this::addSpellInfo )
.addCondition( Condition.predicate( data->Registries.SONIC_BOOM_SCROLL.isPresent() ) )
.addCondition( Condition.predicate( data->data.itemStack.is( Registries.SONIC_BOOM_SCROLL.get() ) ) );
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ private void increaseDamage( OnPreDamaged.Data data ) {
}

private void increaseSpeed( OnBreakSpeed.Data data ) {
data.event.setNewSpeed( data.event.getNewSpeed() + data.event.getOriginalSpeed() * MINE_BONUS * getMultiplier( data.player ) );
data.newSpeed *= 1.0f + MINE_BONUS * getMultiplier( data.player );
}

private void applyRandomSouls( OnLoot.Data data ) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ public TreasureBagManager() {
OnPlayerTick.listen( this::giveTreasureBagToHero )
.addCondition( Condition.isServer() )
.addCondition( Condition.< OnPlayerTick.Data > cooldown( 20, Dist.DEDICATED_SERVER ).configurable( false ) )
.addCondition( Condition.predicate( data->TreasureBagItem.Pillager.CONFIG.isEnabled() ) )
.addCondition( Condition.predicate( data->{
Raid raid = data.getServerLevel().getRaidAt( data.player.blockPosition() );
if( raid == null || !raid.isVictory() || !data.player.hasEffect( MobEffects.HERO_OF_THE_VILLAGE ) ) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package com.majruszsdifficulty.undeadarmy.components;

import com.majruszsdifficulty.Registries;
import com.majruszsdifficulty.items.TreasureBagItem;
import com.majruszsdifficulty.undeadarmy.UndeadArmy;
import com.majruszsdifficulty.undeadarmy.data.WaveDef;
import com.mlib.entities.EntityHelper;
Expand All @@ -12,7 +13,9 @@ record RewardsController( UndeadArmy undeadArmy ) implements IComponent {
public void onWaveFinished() {
this.giveExperienceReward();
if( this.undeadArmy.isLastWave() ) {
this.giveTreasureReward();
if( TreasureBagItem.UndeadArmy.CONFIG.isEnabled() ) {
this.giveTreasureReward();
}
if( this.undeadArmy.config.isResetAllParticipantsKillRequirementsEnabled() ) {
this.resetAllKillRequirements();
}
Expand Down

0 comments on commit d8aa150

Please sign in to comment.