diff --git a/build.gradle b/build.gradle index c5af041..a423585 100644 --- a/build.gradle +++ b/build.gradle @@ -1,5 +1,5 @@ plugins { - id 'fabric-loom' version '1.1.+' + id 'fabric-loom' version '1.4.+' id 'maven-publish' } @@ -30,7 +30,7 @@ dependencies { // Fabric API. This is technically optional, but you probably want it anyway. modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}" - modImplementation "xyz.nucleoid:plasmid:0.5+1.20.1-SNAPSHOT" + modImplementation "xyz.nucleoid:plasmid:0.5.102-SNAPSHOT+1.20.4" modImplementation "xyz.nucleoid:substrate:0.2.1+1.19.4" implementation include("kdotjpg:open-simplex:2.0") @@ -57,7 +57,7 @@ tasks.withType(JavaCompile) { // if it is present. // If you remove this task, sources will not be generated. task sourcesJar(type: Jar, dependsOn: classes) { - classifier = "sources" + //classifier = "sources" from sourceSets.main.allSource } diff --git a/gradle.properties b/gradle.properties index d36b20b..10f2090 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,14 +1,14 @@ # Done to increase the memory available to gradle. -org.gradle.jvmargs=-Xmx1G +org.gradle.jvmargs=-Xmx2G # Fabric Properties # check these on https://modmuss50.me/fabric.html -minecraft_version=1.20.1 -yarn_mappings=1.20.1+build.9 -loader_version=0.14.21 +minecraft_version=1.20.4 +yarn_mappings=1.20.4+build.1 +loader_version=0.15.6 # Mod Properties -mod_version=0.2.0 +mod_version=0.2.1 maven_group=supercoder79 archives_base_name=wavedefense # Dependencies # check this on https://modmuss50.me/fabric.html -fabric_version=0.85.0+1.20.1 +fabric_version=0.91.1+1.20.4 diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index e750102..e411586 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.3-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveSkeletonEntity.java b/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveSkeletonEntity.java index e8bdf73..b7119f2 100644 --- a/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveSkeletonEntity.java +++ b/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveSkeletonEntity.java @@ -64,7 +64,7 @@ public void setAttributes() { } @Override - public void attack(LivingEntity target, float pullProgress) { + public void shootAt(LivingEntity target, float pullProgress) { ItemStack itemStack = this.getProjectileType(this.getStackInHand(ProjectileUtil.getHandPossiblyHolding(this, Items.BOW))); PersistentProjectileEntity arrowProjectile = this.createArrowProjectile(itemStack, pullProgress); arrowProjectile.setDamage(arrowProjectile.getDamage() * this.getMonsterClass().damageScale()); diff --git a/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveStrayEntity.java b/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveStrayEntity.java index 6b452f9..1dc7afb 100644 --- a/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveStrayEntity.java +++ b/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveStrayEntity.java @@ -92,7 +92,7 @@ public void setAttributes() { } @Override - public void attack(LivingEntity target, float pullProgress) { + public void shootAt(LivingEntity target, float pullProgress) { ItemStack itemStack = this.getProjectileType(this.getStackInHand(ProjectileUtil.getHandPossiblyHolding(this, Items.BOW))); PersistentProjectileEntity arrowProjectile = this.createArrowProjectile(itemStack, pullProgress); arrowProjectile.setDamage(arrowProjectile.getDamage() * this.getMonsterClass().damageScale()); diff --git a/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveWitchEntity.java b/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveWitchEntity.java index 1429e76..abaa834 100644 --- a/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveWitchEntity.java +++ b/src/main/java/supercoder79/wavedefense/entity/monster/waveentity/WaveWitchEntity.java @@ -146,7 +146,7 @@ public void setAttributes() { } @Override - public void attack(LivingEntity target, float pullProgress) { + public void shootAt(LivingEntity target, float pullProgress) { } @Override diff --git a/src/main/java/supercoder79/wavedefense/game/WdActive.java b/src/main/java/supercoder79/wavedefense/game/WdActive.java index eb507e9..0fc7ed2 100644 --- a/src/main/java/supercoder79/wavedefense/game/WdActive.java +++ b/src/main/java/supercoder79/wavedefense/game/WdActive.java @@ -143,7 +143,7 @@ private void tick() { if (this.world.getBlockState(local).isOf(Blocks.CHEST)) { if (!this.openedChests.contains(local)) { this.participants.forEach((participant) -> { - participant.sendMessage(Text.literal(player.getEntityName() + " has found a loot chest!"), false); + participant.sendMessage(Text.literal(player.getNameForScoreboard() + " has found a loot chest!"), false); if (new Random().nextInt(4) == 0) { participant.sendMessage(Text.literal("You recieved 6 iron and 1 gold!"), false); diff --git a/src/main/java/supercoder79/wavedefense/game/WdWaveManager.java b/src/main/java/supercoder79/wavedefense/game/WdWaveManager.java index a721e11..f01b491 100644 --- a/src/main/java/supercoder79/wavedefense/game/WdWaveManager.java +++ b/src/main/java/supercoder79/wavedefense/game/WdWaveManager.java @@ -41,7 +41,7 @@ private void tickActive(long time, WdWave wave) { PlayerSet players = game.space.getPlayers(); players.sendMessage(Text.literal("The wave has ended!") .styled(style -> - style.withColor(TextColor.parse("green")) + style.withColor(TextColor.parse("green").result().get()) )); int survivalBonus = 3 + wave.ordinal; int survivalGold = wave.ordinal % 5 == 0 ? MathHelper.ceil(wave.ordinal / 20d) : 0; @@ -49,12 +49,12 @@ private void tickActive(long time, WdWave wave) { if (survivalGold == 0) players.sendMessage(Text.literal("You earned " + survivalBonus + " iron for surviving this wave!") .styled(style -> - style.withColor(TextColor.parse("yellow")) + style.withColor(TextColor.parse("yellow").result().get()) )); else players.sendMessage(Text.literal("You earned " + survivalBonus + " iron and " + survivalGold + " gold for surviving this wave!") .styled(style -> - style.withColor(TextColor.parse("yellow")) + style.withColor(TextColor.parse("yellow").result().get()) )); for (PlayerEntity player : game.getParticipants()) { @@ -84,7 +84,7 @@ private void openWave(WdWave wave) { PlayerSet players = game.space.getPlayers(); players.sendMessage(Text.literal("Wave #" + wave.ordinal + " with " + wave.monsterCount + " monsters is coming!") .styled(style -> - style.withColor(TextColor.parse("light_purple")) + style.withColor(TextColor.parse("light_purple").result().get()) )); game.averageGroupSize = (game.averageGroupSize + game.getParticipants().size()) / 2; diff --git a/src/main/java/supercoder79/wavedefense/util/ASCIIProgressBar.java b/src/main/java/supercoder79/wavedefense/util/ASCIIProgressBar.java index 77b0153..c5d9d58 100644 --- a/src/main/java/supercoder79/wavedefense/util/ASCIIProgressBar.java +++ b/src/main/java/supercoder79/wavedefense/util/ASCIIProgressBar.java @@ -20,7 +20,7 @@ else if (currentProgress - progress < 1d / length) color = "gray"; String finalColor = color; - bar.append(Text.literal("█").styled(style -> style.withColor(TextColor.parse(finalColor)))); + bar.append(Text.literal("█").styled(style -> style.withColor(TextColor.parse(finalColor).result().get()))); } return bar;