mirror of
https://github.com/squeek502/Squake.git
synced 2025-08-03 17:58:08 -04:00
astromine support yeef
This commit is contained in:
parent
0767c83625
commit
da6e99549e
16
build.gradle
16
build.gradle
@ -17,7 +17,22 @@ repositories {
|
||||
name = "ModMenu"
|
||||
url = "https://maven.fabricmc.net/io/github/prospector/modmenu/"
|
||||
}
|
||||
//Begin Astromine
|
||||
maven {
|
||||
name = "Spinnery"
|
||||
url = "https://dl.bintray.com/spinnery/Spinnery"
|
||||
}
|
||||
maven {
|
||||
name = "Jared"
|
||||
url = "https://maven.blamejared.com"
|
||||
}
|
||||
maven {
|
||||
name = "BuildCraft"
|
||||
url = "https://mod-buildcraft.com/maven"
|
||||
}
|
||||
//End Astromine
|
||||
jcenter()
|
||||
maven { url 'https://jitpack.io' }
|
||||
}
|
||||
|
||||
dependencies {
|
||||
@ -33,6 +48,7 @@ dependencies {
|
||||
include "me.shedaniel.cloth:config-2:${project.cloth_version}"
|
||||
|
||||
modImplementation "io.github.prospector:modmenu:${project.modmenu_version}"
|
||||
modImplementation "com.github.Chainmail-Studios:Astromine:1.3.5"
|
||||
}
|
||||
|
||||
processResources {
|
||||
|
13
java/squeek/quakemovement/AstromineSupport.java
Normal file
13
java/squeek/quakemovement/AstromineSupport.java
Normal file
@ -0,0 +1,13 @@
|
||||
package squeek.quakemovement;
|
||||
|
||||
import com.github.chainmailstudios.astromine.common.registry.GravityRegistry;
|
||||
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
|
||||
public class AstromineSupport {
|
||||
private AstromineSupport(){}
|
||||
|
||||
public static double getGravity(PlayerEntity player) {
|
||||
return GravityRegistry.INSTANCE.get(player.world.getDimensionRegistryKey());
|
||||
}
|
||||
}
|
@ -1,5 +1,6 @@
|
||||
package squeek.quakemovement;
|
||||
|
||||
import net.fabricmc.loader.api.FabricLoader;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockRenderType;
|
||||
import net.minecraft.block.BlockState;
|
||||
@ -280,7 +281,11 @@ public class QuakeClientPlayer
|
||||
else
|
||||
{
|
||||
// gravity
|
||||
velocityY -= 0.08D;
|
||||
if (FabricLoader.getInstance().isModLoaded("astromine")) {
|
||||
velocityY -= AstromineSupport.getGravity(player);
|
||||
} else {
|
||||
velocityY -= 0.08D;
|
||||
}
|
||||
}
|
||||
|
||||
// air resistance
|
||||
|
Loading…
x
Reference in New Issue
Block a user