Some final fixes for 1.7.10.
This commit is contained in:
parent
0d88ca125a
commit
d8ac715066
|
@ -40,7 +40,7 @@ configFile.withReader {
|
||||||
|
|
||||||
def buildnumber = System.getenv("BUILD_NUMBER")
|
def buildnumber = System.getenv("BUILD_NUMBER")
|
||||||
def travisbuildnumber = (System.getenv("TRAVIS_BUILD_NUMBER") ?: -111).toInteger() + 111
|
def travisbuildnumber = (System.getenv("TRAVIS_BUILD_NUMBER") ?: -111).toInteger() + 111
|
||||||
version = "${config.mod_version}." + (buildnumber ?: travisbuildnumber)
|
version = "${minecraft_version}-${mod_version}.${buildnumber ?: travisbuildnumber}"
|
||||||
group= "${config.group_id}" // http://maven.apache.org/guides/mini/guide-naming-conventions.html
|
group= "${config.group_id}" // http://maven.apache.org/guides/mini/guide-naming-conventions.html
|
||||||
archivesBaseName = "${config.mod_id}"
|
archivesBaseName = "${config.mod_id}"
|
||||||
def numina_version = (System.getenv("NUMINA_VERSION") ?:"0.4.1.104")
|
def numina_version = (System.getenv("NUMINA_VERSION") ?:"0.4.1.104")
|
||||||
|
@ -48,6 +48,7 @@ def numina_version = (System.getenv("NUMINA_VERSION") ?:"0.4.1.104")
|
||||||
minecraft {
|
minecraft {
|
||||||
version = "${config.minecraft_version}-${config.forge_version}"
|
version = "${config.minecraft_version}-${config.forge_version}"
|
||||||
replace "@numina_version@", numina_version
|
replace "@numina_version@", numina_version
|
||||||
|
replace "@VERSION@", project.version
|
||||||
runDir = "run"
|
runDir = "run"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,7 @@ public abstract class ElectricAdapter {
|
||||||
if (stack == null)
|
if (stack == null)
|
||||||
return null;
|
return null;
|
||||||
Item i = stack.getItem();
|
Item i = stack.getItem();
|
||||||
if (i instanceof MuseElectricItem) {
|
if (i instanceof IMuseElectricItem) {
|
||||||
return new MuseElectricAdapter(stack);
|
return new MuseElectricAdapter(stack);
|
||||||
} else if (ModCompatibility.isRFAPILoaded() && i instanceof IEnergyContainerItem) {
|
} else if (ModCompatibility.isRFAPILoaded() && i instanceof IEnergyContainerItem) {
|
||||||
return new TEElectricAdapter(stack);
|
return new TEElectricAdapter(stack);
|
||||||
|
@ -35,4 +35,4 @@ public abstract class ElectricAdapter {
|
||||||
public abstract double drainEnergy(double requested);
|
public abstract double drainEnergy(double requested);
|
||||||
|
|
||||||
public abstract double giveEnergy(double provided);
|
public abstract double giveEnergy(double provided);
|
||||||
}
|
}
|
|
@ -7,11 +7,11 @@ import net.minecraft.item.ItemStack;
|
||||||
*/
|
*/
|
||||||
public class MuseElectricAdapter extends ElectricAdapter {
|
public class MuseElectricAdapter extends ElectricAdapter {
|
||||||
ItemStack stack;
|
ItemStack stack;
|
||||||
MuseElectricItem item;
|
IMuseElectricItem item;
|
||||||
|
|
||||||
public MuseElectricAdapter(ItemStack stack) {
|
public MuseElectricAdapter(ItemStack stack) {
|
||||||
this.stack = stack;
|
this.stack = stack;
|
||||||
this.item = (MuseElectricItem)stack.getItem();
|
this.item = (IMuseElectricItem)stack.getItem();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -33,4 +33,4 @@ public class MuseElectricAdapter extends ElectricAdapter {
|
||||||
public double giveEnergy(double provided) {
|
public double giveEnergy(double provided) {
|
||||||
return item.giveEnergyTo(stack, provided);
|
return item.giveEnergyTo(stack, provided);
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -7,47 +7,47 @@ import net.machinemuse.powersuits.control.KeybindManager;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
|
||||||
public class KeyConfigGui extends MuseGui {
|
public class KeyConfigGui extends MuseGui {
|
||||||
private EntityPlayer player;
|
private EntityPlayer player;
|
||||||
protected KeybindConfigFrame frame;
|
protected KeybindConfigFrame frame;
|
||||||
protected int worldx;
|
protected int worldx;
|
||||||
protected int worldy;
|
protected int worldy;
|
||||||
protected int worldz;
|
protected int worldz;
|
||||||
|
|
||||||
public KeyConfigGui(EntityPlayer player, int x, int y, int z) {
|
public KeyConfigGui(EntityPlayer player, int x, int y, int z) {
|
||||||
super();
|
super();
|
||||||
KeybindManager.readInKeybinds();
|
KeybindManager.readInKeybinds();
|
||||||
this.player = player;
|
this.player = player;
|
||||||
this.xSize = 256;
|
this.xSize = 256;
|
||||||
this.ySize = 226;
|
this.ySize = 226;
|
||||||
this.worldx = x;
|
this.worldx = x;
|
||||||
this.worldy = y;
|
this.worldy = y;
|
||||||
this.worldz = z;
|
this.worldz = z;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Add the buttons (and other controls) to the screen.
|
* Add the buttons (and other controls) to the screen.
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public void initGui() {
|
public void initGui() {
|
||||||
super.initGui();
|
super.initGui();
|
||||||
frame = new KeybindConfigFrame(this,
|
frame = new KeybindConfigFrame(this,
|
||||||
new MusePoint2D(absX(-0.95), absY(-0.95)),
|
new MusePoint2D(absX(-0.95), absY(-0.95)),
|
||||||
new MusePoint2D(absX(0.95), absY(0.95)), player);
|
new MusePoint2D(absX(0.95), absY(0.95)), player);
|
||||||
frames.add(frame);
|
frames.add(frame);
|
||||||
|
|
||||||
TabSelectFrame tabFrame = new TabSelectFrame(player, new MusePoint2D(absX(-0.95F), absY(-1.05f)),new MusePoint2D(absX(0.95F), absY(-0.95f)), worldx, worldy, worldz);
|
TabSelectFrame tabFrame = new TabSelectFrame(player, new MusePoint2D(absX(-0.95F), absY(-1.05f)), new MusePoint2D(absX(0.95F), absY(-0.95f)), worldx, worldy, worldz);
|
||||||
frames.add(tabFrame);
|
frames.add(tabFrame);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void handleKeyboardInput() {
|
public void handleKeyboardInput() {
|
||||||
super.handleKeyboardInput();
|
super.handleKeyboardInput();
|
||||||
frame.handleKeyboard();
|
frame.handleKeyboard();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onGuiClosed() {
|
public void onGuiClosed() {
|
||||||
super.onGuiClosed();
|
super.onGuiClosed();
|
||||||
KeybindManager.writeOutKeybinds();
|
KeybindManager.writeOutKeybinds();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,7 +23,7 @@ import java.util.List;
|
||||||
/**
|
/**
|
||||||
* Ported to Java by lehjr on 10/19/16.
|
* Ported to Java by lehjr on 10/19/16.
|
||||||
*/
|
*/
|
||||||
public class ClickableKeybinding extends ClickableButton{
|
public class ClickableKeybinding extends ClickableButton {
|
||||||
protected List<ClickableModule> boundModules = new ArrayList<ClickableModule>();
|
protected List<ClickableModule> boundModules = new ArrayList<ClickableModule>();
|
||||||
public boolean toggleval = false;
|
public boolean toggleval = false;
|
||||||
boolean toggled = false;
|
boolean toggled = false;
|
||||||
|
|
|
@ -83,7 +83,8 @@ public class PlayerUpdateHandler {
|
||||||
Musique.stopPlayerSound(player, SoundDictionary.SOUND_GLIDER);
|
Musique.stopPlayerSound(player, SoundDictionary.SOUND_GLIDER);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
} // kinda hacky fix for item that gets unequipped when the sound is playing, like when player dies or takes it off
|
||||||
|
else Musique.stopPlayerSound(player, SoundDictionary.SOUND_GLIDER);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -113,7 +113,7 @@ public class ModularItemBase extends Item implements IModularItemBase {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void givePlayerEnergy(EntityPlayer player, double joulesToGive) {
|
public void givePlayerEnergy(EntityPlayer player, double joulesToGive) {
|
||||||
ElectricItemUtils.drainPlayerEnergy(player, joulesToGive);
|
ElectricItemUtils.givePlayerEnergy(player, joulesToGive);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue