Skip to content

Commit d0347ed

Browse files
committed
fixed datapacks
1 parent 8f5bef9 commit d0347ed

File tree

6 files changed

+28
-15
lines changed

6 files changed

+28
-15
lines changed

TODO.txt

+9-6
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,10 @@ HEROES (in order of priority)
1919
- equipment
2020

2121
[✔] Updated the base Minecraft version to 1.20.1
22-
- Moving forward,
22+
- Moving forward, 1.19.2 is no longer supported
23+
- Servers can't load worlds that were created before the worldgen datapack was integrated into the mod
24+
- To resolve this, just delete the datapacks folder in that world
25+
- To load them in single
2326

2427
[✔] Added a new cheatcode: thebeastofcaerbannog
2528
- Not even Ghasts are safe from it :smiling_devil:
@@ -31,27 +34,27 @@ Bugfixes
3134

3235
[❌] gui scale not working?
3336

34-
[] Recreate tutorial world in 1.20.1
37+
[] Recreate tutorial world in 1.20.1
3538
[🟡] Fixed camera centering on the tutorial world
3639
[✔] Mounted piglins don't heal from nether terrain
37-
[🟡] Anchors are now saved correctly on server restart
40+
[] Anchors are now saved correctly on server restart
3841

3942
Quality of Life
4043
---------------
41-
[🟡] Added commands to send resources to allies:
44+
[] Added commands to send resources to allies:
4245
/sendfood <playername> <amount>
4346
/sendwood <playername> <amount>
4447
/sendore <playername> <amount>
4548

46-
[🟡] Ravagers that are mounted no longer automatically aggro onto buildings
49+
[] Ravagers that are mounted no longer automatically aggro onto buildings
4750
- This prevents them hurting themselves from their own splash damage
4851
[🟡] Spiders now have a button to toggle whether they climb on walls or not
4952
[🟡] Slimes and magma cubes can now no-clip through log and leaf blocks
5053
[✔] Turn cheats on by default for sandbox mode
5154
[✔] Healing Fountains now heal 1% of hp per second instead of a flat rate, up to a maximum of 1hp/s
5255
[🟡] Dripstone is now mineable by workers, worth 1 ore each
5356

54-
[] language updates
57+
[] language updates
5558

5659
Balancing
5760
---------

build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ apply plugin: 'maven-publish'
1919
apply plugin: 'org.spongepowered.mixin'
2020
apply plugin: 'org.parchmentmc.librarian.forgegradle'
2121

22-
version = '1.1.3a-1.20.1-beta'
22+
version = '1.1.4'
2323
group = 'com.solegendary.reignofnether' // http://maven.apache.org/guides/mini/guide-naming-conventions.html
2424
archivesBaseName = 'reignofnether'
2525

src/main/java/com/solegendary/reignofnether/ReignOfNether.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
public class ReignOfNether {
4747
public static final Logger LOGGER = LogManager.getLogger();
4848
public static final String MOD_ID = "reignofnether";
49-
public static final String VERSION_STRING = "1.1.3a-1.20.1-beta";
49+
public static final String VERSION_STRING = "1.1.4";
5050

5151
// Fields from ClientReset
5252
public static final Field handshakeField;

src/main/java/com/solegendary/reignofnether/resources/ResourcesServerEvents.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -347,9 +347,9 @@ public static int trySendingResources(CommandContext<CommandSourceStack> context
347347
resourceName == ResourceName.ORE ? -amount : 0
348348
));
349349
addSubtractResources(new Resources(receivingPlayerName,
350-
resourceName == ResourceName.FOOD ? -amount : 0,
351-
resourceName == ResourceName.WOOD ? -amount : 0,
352-
resourceName == ResourceName.ORE ? -amount : 0
350+
resourceName == ResourceName.FOOD ? amount : 0,
351+
resourceName == ResourceName.WOOD ? amount : 0,
352+
resourceName == ResourceName.ORE ? amount : 0
353353
));
354354
switch (resourceName) {
355355
case FOOD -> {

src/main/java/com/solegendary/reignofnether/unit/goals/GatherResourcesGoal.java

+4-3
Original file line numberDiff line numberDiff line change
@@ -294,8 +294,9 @@ else if (ResourceSources.getBlockResourceName(getGatherTarget(), mob.level()) ==
294294
gatherTicksLeft = DEFAULT_MAX_GATHER_TICKS;
295295
ResourceName resourceName = ResourceSources.getBlockResourceName(this.data.gatherTarget, mob.level());
296296

297-
boolean isLogBlock = isLogBlock(this.mob.level().getBlockState(data.gatherTarget));
298-
boolean isFallingLogBlock = isFallingLogBlock(this.mob.level().getBlockState(data.gatherTarget));
297+
BlockState bs = this.mob.level().getBlockState(data.gatherTarget);
298+
boolean isLogBlock = isLogBlock(bs);
299+
boolean isFallingLogBlock = isFallingLogBlock(bs);
299300
if (isLogBlock)
300301
ResourcesServerEvents.fellAdjacentLogs(data.gatherTarget, new ArrayList<>(), this.mob.level());
301302

@@ -304,7 +305,7 @@ else if (ResourceSources.getBlockResourceName(getGatherTarget(), mob.level()) ==
304305
expName = ResourceName.FOOD;
305306
else if (ResourceSources.getBlockResourceName(getGatherTarget(), mob.level()) == ResourceName.WOOD && (isLogBlock || isFallingLogBlock))
306307
expName = ResourceName.WOOD;
307-
else if (ResourceSources.getBlockResourceName(getGatherTarget(), mob.level()) == ResourceName.ORE)
308+
else if (ResourceSources.getBlockResourceName(getGatherTarget(), mob.level()) == ResourceName.ORE && bs.getBlock() != Blocks.POINTED_DRIPSTONE)
308309
expName = ResourceName.ORE;
309310

310311
if (mob.level().destroyBlock(data.gatherTarget, false)) {

src/main/java/com/solegendary/reignofnether/unit/units/neutral/KillerRabbitUnit.java

+10-1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
import com.solegendary.reignofnether.unit.interfaces.Unit;
1111
import com.solegendary.reignofnether.unit.units.piglins.GhastUnit;
1212
import com.solegendary.reignofnether.util.Faction;
13+
import com.solegendary.reignofnether.util.MyMath;
1314
import net.minecraft.core.BlockPos;
1415
import net.minecraft.nbt.CompoundTag;
1516
import net.minecraft.network.syncher.EntityDataAccessor;
@@ -148,8 +149,16 @@ public static AttributeSupplier.Builder createAttributes() {
148149
@Override
149150
protected float getJumpPower() {
150151
float jumpPower = super.getJumpPower();
151-
if (getTarget() instanceof GhastUnit && distanceTo(getTarget()) < 12)
152+
153+
Vec3 xz1 = new Vec3(getX(), 0, getZ());
154+
Vec3 xz2 = null;
155+
if (getTarget() != null) {
156+
xz2 = new Vec3(getTarget().getX(), 0, getTarget().getZ());
157+
}
158+
159+
if (xz2 != null && getTarget().getY() - getY() > 6 && xz1.distanceTo(xz2) < 4) {
152160
return jumpPower * 4;
161+
}
153162
else if (jumpPower > 0.1f && jumpPower < 0.3f) {
154163
// prevents getting stuck jumping on the spot when pushed flush against a block
155164
double x = (random.nextDouble() - 0.5f) / 0.5f;

0 commit comments

Comments
 (0)