Skip to content

Commit

Permalink
1.7.0
Browse files Browse the repository at this point in the history
  • Loading branch information
MORIMORI0317 committed Dec 30, 2023
1 parent b5e395a commit b877b2f
Show file tree
Hide file tree
Showing 7 changed files with 38 additions and 18 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ Please write according to [Keep a Changelog](https://keepachangelog.com/en/1.0.0

### Fixed

- Fixed an issue where physical strength would not reach maximum when summoning

### Security

## [1.6.0] - 2023-06-14
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import net.minecraft.util.Mth;
import net.minecraft.world.Difficulty;
import net.minecraft.world.damagesource.DamageSource;
import net.minecraft.world.entity.EntityEvent;
import net.minecraft.world.entity.EntityType;
import net.minecraft.world.entity.LivingEntity;
import net.minecraft.world.entity.MobSpawnType;
Expand Down Expand Up @@ -81,6 +82,15 @@ private static void createAttributes(CallbackInfoReturnable<AttributeSupplier.Bu
}
}

@Override
public void heal(float f) {
if (this.getInvulnerableTicks() > 0) {
super.heal(f * 2);
} else {
super.heal(f);
}
}

protected WitherBossMixin(EntityType<? extends Monster> entityType, Level level) {
super(entityType, level);
}
Expand Down Expand Up @@ -257,24 +267,26 @@ protected void tickDeath() {
deathTime++;
bossEvent.setProgress(this.getHealth() / this.getMaxHealth());

if (this.deathTime % 4 == 0)
if (this.deathTime % 4 == 0) {
setForcedPowered(random.nextInt((int) Math.max(5 - ((float) this.deathTime / (20f * 10f) * 5f), 1)) == 0);
}

if (!this.level().isClientSide()) {
if (this.deathTime == MAX_WITHER_DEATH_TIME - 1) {
this.level().explode(this, this.getX(), this.getEyeY(), this.getZ(), 8f, false, Level.ExplosionInteraction.MOB);
if (!this.isSilent())
if (!this.isSilent()) {
this.level().globalLevelEvent(LevelEvent.SOUND_WITHER_BLOCK_BREAK, this.blockPosition(), 0);
}

SoundEvent soundevent = this.getDeathSound();
if (soundevent != null)
if (soundevent != null) {
this.playSound(soundevent, this.getSoundVolume() * 1.5f, this.getVoicePitch());
} else if (this.deathTime == MAX_WITHER_DEATH_TIME) {
}
} else if (this.deathTime >= MAX_WITHER_DEATH_TIME && !this.isRemoved()) {
this.lastHurtByPlayerTime = Math.max(lastHurtByPlayerTime, 1);
var dmg = lastDeathDamageSource == null ? level().damageSources().fellOutOfWorld() : lastDeathDamageSource;
DamageSource dmg = lastDeathDamageSource == null ? level().damageSources().fellOutOfWorld() : lastDeathDamageSource;
dropAllDeathLoot(dmg);

this.level().broadcastEntityEvent(this, (byte) 60);
this.level().broadcastEntityEvent(this, EntityEvent.POOF);
this.remove(RemovalReason.KILLED);
}
}
Expand Down
4 changes: 4 additions & 0 deletions fabric/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,13 @@ curseforge {
releaseType = "${rootProject.release_type}"
addGameVersion "${rootProject.minecraft_version}"
addGameVersion 'Java 17'

addGameVersion "Fabric"
addGameVersion "Quilt"

addGameVersion "Server"
addGameVersion "Client"

project.support_versions.split(",").each {
String version -> addGameVersion version
}
Expand Down
4 changes: 4 additions & 0 deletions forge/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,12 @@ curseforge {
releaseType = "${rootProject.release_type}"
addGameVersion "${rootProject.minecraft_version}"
addGameVersion 'Java 17'

addGameVersion "Forge"

addGameVersion "Server"
addGameVersion "Client"

project.support_versions.split(",").each {
String version -> addGameVersion version
}
Expand Down
5 changes: 1 addition & 4 deletions forge/src/main/resources/META-INF/mods.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,4 @@ modId = "minecraft"
mandatory = true
versionRange = "[1.20.2,)"
ordering = "NONE"
side = "BOTH"

[[mixins]]
config = "bestylewither-common.mixins.json"
side = "BOTH"
2 changes: 2 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@
org.gradle.jvmargs=-Xmx6142M
# Environment
minecraft_version=1.20.2
support_versions=1.20.2
enabled_platforms=fabric,forge,neoforge
# Mod
archives_base_name=bestylewither
mod_display_name=BEStyleWither
mod_version=1.7.0
maven_group=net.morimori0317
architectury_version=10.0.17
Expand Down
13 changes: 6 additions & 7 deletions neoforge/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,6 @@ architectury {

loom {
accessWidenerPath = project(":common").loom.accessWidenerPath

/* neoForge {
convertAccessWideners = true
extraAccessWideners.add loom.accessWidenerPath.get().asFile.name
mixinConfig "bestylewither-common.mixins.json"
}*/
}

configurations {
Expand Down Expand Up @@ -56,6 +49,8 @@ remapJar {
dependsOn shadowJar
archiveClassifier.set(null)
setArchivesBaseName("${rootProject.archives_base_name}-${project.name}-mc${rootProject.minecraft_version}")

atAccessWideners.add loom.accessWidenerPath.get().asFile.name
}

sourcesJar {
Expand All @@ -82,8 +77,12 @@ curseforge {
releaseType = "${rootProject.release_type}"
addGameVersion "${rootProject.minecraft_version}"
addGameVersion 'Java 17'

addGameVersion "NeoForge"

addGameVersion "Server"
addGameVersion "Client"

project.support_versions.split(",").each {
String version -> addGameVersion version
}
Expand Down

0 comments on commit b877b2f

Please sign in to comment.