Skip to content

Commit

Permalink
Well this is a new update for Gaspunk...
Browse files Browse the repository at this point in the history
* update .gitignore

* Fix for player collection error thing...

* update

* Version Support

* built

* version bump

* Update SpecialRewardChecker.java

* tiny thing

* Added config to perhaps allow various thing

* Credited myself, figured out how to sign this thing
  • Loading branch information
sschr15 authored Dec 22, 2019
1 parent 518c991 commit a5cec3c
Show file tree
Hide file tree
Showing 11 changed files with 72 additions and 45 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,11 @@ out
# gradle
build
.gradle
logs

# other
eclipse
run
classes
.vscode/
keystore.jks
16 changes: 10 additions & 6 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -188,21 +188,25 @@ jar {
}
}


task signJar(type: SignJar, dependsOn: reobfJar) {
if (canJarBeSigned()) {
keyStore = project.keyStore
alias = project.keyStoreAlias
storePass = project.keyStorePass
keyPass = project.keyStoreKeyPass
keyStore = project.findProperty("keyStore")
alias = project.findProperty("keyStoreAlias")
storePass = project.findProperty("keyStorePass")
keyPass = project.findProperty("keyStoreKeyPass")
inputFile = jar.archivePath
outputFile = jar.archivePath
}
}



boolean canJarBeSigned() {
return project.hasProperty('keyStore')
}


artifacts {
archives apiJar
archives sourceJar
Expand All @@ -212,5 +216,5 @@ artifacts {
// Runs this task automatically when build is ran.
build.dependsOn signJar

apply from: 'update_json.gradle'
build.finalizedBy updateJson
//apply from: 'update_json.gradle'
//build.finalizedBy updateJson
9 changes: 5 additions & 4 deletions changelog.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"homepage": null,
"homepage": "https://github.com/Ladysnake/Gaspunk",
"promos": {
"1.12.2-latest": "1.4.7",
"1.12.2-recommended": "1.4.7"
"1.12.2-latest": "1.4.8",
"1.12.2-recommended": "1.4.8"
},
"1.12.2": {
"1.4.1": "Now requires forge 1.12.2-14.23.3.2669 or later\nAdded a few API features\n- added a way for add-ons to bypass a gas' checks when running its effect\n- exposed a few classes\nAlso now packages Ladylib as a contained dependency instead of shading the code like a caveman",
Expand All @@ -11,6 +11,7 @@
"1.4.4": "Removed an unlocalized tooltip line on candyfloss grenades and tubes.",
"1.4.5": "Update the contained library",
"1.4.6": "- Disabled candyfloss ore recipe when candyworld is not installed, fixes loading crash with Immersive Engineering\n- Gas loading errors are now more descriptive and don't crash. Check your logs if you make custom gases !",
"1.4.7": "- Fixed a startup crash on dedicated servers"
"1.4.7": "- Fixed a startup crash on dedicated servers",
"1.4.8": "- Edited the HREF for item skins\n- Added the ability to change the length gas clouds exist through configuration"
}
}
20 changes: 12 additions & 8 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,24 @@
#####Version 1.12.2-1.4.7 - BUILT
##### Version 1.12.2-1.4.8 - BUILT
- Edited the HREF for item skins
- Added the ability to change the length gas clouds exist through configuration

##### Version 1.12.2-1.4.7 - BUILT
- Fixed a startup crash on dedicated servers

#####Version 1.12.2-1.4.6 - BUILT
##### Version 1.12.2-1.4.6 - BUILT
- Disabled candyfloss ore recipe when candyworld is not installed, fixes loading crash with Immersive Engineering
- Gas loading errors are now more descriptive and don't crash. Check your logs if you make custom gases !

#####Version 1.12.2-1.4.5 - BUILT
##### Version 1.12.2-1.4.5 - BUILT
Update the contained library

#####Version 1.12.2-1.4.4 - BUILT
##### Version 1.12.2-1.4.4 - BUILT
Removed an unlocalized tooltip line on candyfloss grenades and tubes.

#####Version 1.12.2-1.4.3 - BUILT
##### Version 1.12.2-1.4.3 - BUILT
Fix a crash when Need to Breathe is not installed

#####Version 1.12.2-1.4.2 - BUILT
##### Version 1.12.2-1.4.2 - BUILT
Additions / Changes:

- Candyfloss clouds now are a lot more nutritious ! They aren't as easily breathable though.
Expand All @@ -26,7 +30,7 @@ Api changes:

Also check out UpcraftLP's new add-on, Gaspunk Inhaler !

#####Version 1.12.2-1.4.1 - BUILT
##### Version 1.12.2-1.4.1 - BUILT
Now requires forge 1.12.2-14.23.3.2669 or later


Expand All @@ -37,7 +41,7 @@ Added a few API features

Also now packages Ladylib as a contained dependency instead of shading the code like a caveman

#####Version 1.12.2-1.4 - BUILT
##### Version 1.12.2-1.4 - BUILT
Additions / changes :

- Gas agents are now defined through json files
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
modGroup=ladysnake
modVersion=1.4.7
modVersion=1.4.8
modBaseName=gaspunk
mc_version=1.12.2
forgeVersion=1.12.2-14.23.4.2738
Expand Down
13 changes: 13 additions & 0 deletions src/main/java/ladysnake/gaspunk/GasPunkConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,16 @@

import net.minecraftforge.common.config.Config;
import net.minecraftforge.common.config.ConfigManager;
import net.minecraftforge.common.config.Config.RequiresMcRestart;
import net.minecraftforge.fml.client.event.ConfigChangedEvent;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;

/**
* Main configuration section
* @author Pyrofab
* @author sschr15 (a bit)
*/
@Config(modid = GasPunk.MOD_ID, name = GasPunk.MOD_ID + "/" + GasPunk.MOD_ID)
@Mod.EventBusSubscriber(modid = GasPunk.MOD_ID)
public class GasPunkConfig {
Expand All @@ -16,6 +22,13 @@ public class GasPunkConfig {
@Config.Comment("Makes ash require smelting nether wart instead of rotten flesh")
public static boolean alternativeAshRecipe = false;

@Config.Comment({
"Sets the lifespan in ticks for gas clouds.",
"The clouds themselves look like they take a bit longer to decay,",
"but the effects no longer happen after this amount."
})
public static int gasLifespan = 600;

@Config.Comment({
"The items which ID's are added here will be considered as gas masks when breathing gas",
"You can specify entire armor sets by separating items with \"&\" in a single entry. Using \"*\" instead of an item id will match anything.",
Expand Down
4 changes: 3 additions & 1 deletion src/main/java/ladysnake/gaspunk/item/ItemGrenade.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import ladylib.misc.ItemUtil;
import ladysnake.gaspunk.GasPunk;
import ladysnake.gaspunk.GasPunkConfig;
import ladysnake.gaspunk.api.IGas;
import ladysnake.gaspunk.api.customization.IHasSkin;
import ladysnake.gaspunk.entity.EntityGasCloud;
Expand Down Expand Up @@ -88,7 +89,8 @@ public EntityGasCloud explode(WorldServer worldIn, Vec3d pos, ItemStack stack) {
worldIn.spawnParticle(EnumParticleTypes.SMOKE_LARGE, pos.x, pos.y, pos.z, 20, 0.5, 0.5, 0.5, 0.2);
EntityGasCloud cloud = new EntityGasCloud(worldIn, getContainedGas(stack));
cloud.setPosition(pos.x, pos.y, pos.z);
cloud.setMaxLifespan(600);
int lifespan = GasPunkConfig.gasLifespan;
cloud.setMaxLifespan(lifespan);
worldIn.spawnEntity(cloud);
return cloud;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
import ladysnake.gaspunk.GasPunk;
import ladysnake.gaspunk.util.SpecialRewardChecker;
import net.minecraft.client.Minecraft;
import net.minecraftforge.common.config.Config;
import net.minecraftforge.common.config.ConfigManager;
import net.minecraftforge.fml.client.event.ConfigChangedEvent;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
Expand Down
43 changes: 22 additions & 21 deletions src/main/java/ladysnake/gaspunk/sickness/SicknessTearGas.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,30 +27,31 @@ public class SicknessTearGas extends SicknessGas {

// private static final UUID TEAR_SLOWNESS_ID = UUID.fromString("6372ad90-c462-4223-8638-898c1166f824");
// private static final AttributeModifier TEAR_SLOWNESS = new AttributeModifier(TEAR_SLOWNESS_ID, "Tear gas slowness penalty", -0.1D, 2);
//

public SicknessTearGas() {
super(0.001f);
}
//
// @Override
// public boolean performEffect(EntityLivingBase carrier, SicknessEffect effect) {
// if (effect.getTicksSinceBeginning() == 0) {
// if (!carrier.world.isRemote) {
// IAttributeInstance attribute = carrier.getEntityAttribute(SharedMonsterAttributes.MOVEMENT_SPEED);
// if (attribute.getModifier(TEAR_SLOWNESS_ID) == null)
// attribute.applyModifier(TEAR_SLOWNESS);
// return true;
// }
// }
// return super.performEffect(carrier, effect);
// }
//
// @Override
// public void onCured(SicknessEffect sicknessEffect, EntityLivingBase carrier) {
// if (!carrier.world.isRemote) {
// carrier.getEntityAttribute(SharedMonsterAttributes.MOVEMENT_SPEED).removeModifier(TEAR_SLOWNESS_ID);
// }
// }
/*
@Override
public boolean performEffect(EntityLivingBase carrier, SicknessEffect effect) {
if (effect.getTicksSinceBeginning() == 0) {
if (!carrier.world.isRemote) {
IAttributeInstance attribute = carrier.getEntityAttribute(SharedMonsterAttributes.MOVEMENT_SPEED);
if (attribute.getModifier(TEAR_SLOWNESS_ID) == null)
attribute.applyModifier(TEAR_SLOWNESS);
return true;
}
}
return super.performEffect(carrier, effect);
}
@Override
public void onCured(SicknessEffect sicknessEffect, EntityLivingBase carrier) {
if (!carrier.world.isRemote) {
carrier.getEntityAttribute(SharedMonsterAttributes.MOVEMENT_SPEED).removeModifier(TEAR_SLOWNESS_ID);
}
}
*/

@Override
public boolean isSynchronized() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public static GrenadeSkins getSelectedSkin(EntityPlayer player) {
public static void retrieveSpecialRewards() {
try {
Gson GSON = new Gson();
URLConnection rewardPage = new URL("https://ladysnake.glitch.me/gaspunk/users").openConnection();
URLConnection rewardPage = new URL("https://github.com/Ladysnake/ModWinder/raw/master/gaspunkusers.json").openConnection();
rewardPage.connect();
BufferedReader in = new BufferedReader(new InputStreamReader(rewardPage.getInputStream()));
String inputLine;
Expand Down
3 changes: 2 additions & 1 deletion src/main/resources/mcmod.info
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"updateUrl": "",
"authorList": [
"Pyrofab",
"CobraDarkPoney"
"CobraDarkPoney",
"sschr15"
],
"credits": "",
"logoFile": "",
Expand Down

0 comments on commit a5cec3c

Please sign in to comment.