mirror of
https://github.com/GTNewHorizons/ThaumicTinkerer.git
synced 2026-11-28 16:06:07 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d87599e38d | ||
|
|
edcac6b16d | ||
|
|
e11de173f8 | ||
|
|
dc69ee1728 | ||
|
|
13166986e3 | ||
|
|
903f158d38 |
No files matched your search
@@ -1,5 +1,3 @@
|
||||
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
|
||||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
|
||||
|
||||
name: Build and test
|
||||
|
||||
@@ -11,35 +9,5 @@ on:
|
||||
|
||||
jobs:
|
||||
build-and-test:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Set up JDK 8
|
||||
uses: actions/setup-java@v2
|
||||
with:
|
||||
java-version: '8'
|
||||
distribution: 'adopt'
|
||||
cache: gradle
|
||||
|
||||
- name: Grant execute permission for gradlew
|
||||
run: chmod +x gradlew
|
||||
|
||||
- name: Setup the workspace
|
||||
run: ./gradlew setupCIWorkspace
|
||||
|
||||
- name: Build the mod
|
||||
run: ./gradlew build
|
||||
|
||||
- name: Run server for 1.5 minutes
|
||||
run: |
|
||||
mkdir run
|
||||
echo "eula=true" > run/eula.txt
|
||||
timeout 90 ./gradlew runServer 2>&1 | tee -a server.log || true
|
||||
|
||||
- name: Test no errors reported during server run
|
||||
run: |
|
||||
chmod +x .github/scripts/test-no-error-reports.sh
|
||||
.github/scripts/test-no-error-reports.sh
|
||||
uses: GTNewHorizons/GTNH-Actions-Workflows/.github/workflows/build-and-test.yml@master
|
||||
secrets: inherit
|
||||
@@ -1,51 +1,14 @@
|
||||
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
|
||||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
|
||||
|
||||
name: Release tagged build
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- '*'
|
||||
tags: [ '*' ]
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Set release version
|
||||
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
|
||||
|
||||
- name: Set up JDK 8
|
||||
uses: actions/setup-java@v2
|
||||
with:
|
||||
java-version: '8'
|
||||
distribution: 'adopt'
|
||||
cache: gradle
|
||||
|
||||
- name: Grant execute permission for gradlew
|
||||
run: chmod +x gradlew
|
||||
|
||||
- name: Setup the workspace
|
||||
run: ./gradlew setupCIWorkspace
|
||||
|
||||
- name: Build the mod
|
||||
run: ./gradlew build
|
||||
|
||||
- name: Release under current tag
|
||||
uses: "marvinpinto/action-automatic-releases@latest"
|
||||
with:
|
||||
repo_token: "${{ secrets.GITHUB_TOKEN }}"
|
||||
automatic_release_tag: "${{ env.RELEASE_VERSION }}"
|
||||
prerelease: false
|
||||
title: "${{ env.RELEASE_VERSION }}"
|
||||
files: build/libs/*.jar
|
||||
|
||||
- name: Publish to Maven
|
||||
run: ./gradlew publish
|
||||
env:
|
||||
MAVEN_USER: ${{ secrets.MAVEN_USER }}
|
||||
MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }}
|
||||
release-tags:
|
||||
uses: GTNewHorizons/GTNH-Actions-Workflows/.github/workflows/release-tags.yml@master
|
||||
secrets: inherit
|
||||
+1
-1
@@ -35,7 +35,7 @@ buildscript {
|
||||
}
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.github.GTNewHorizons:ForgeGradle:1.2.7'
|
||||
classpath 'com.github.GTNewHorizons:ForgeGradle:1.2.13'
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -23,15 +23,7 @@ public class BotaniaFunctions {
|
||||
}
|
||||
|
||||
public static boolean isEntityHarmless(Entity entity) {
|
||||
if(entity instanceof IManaBurst) {
|
||||
ItemStack lens = ((IManaBurst)entity).getSourceLens();
|
||||
if(lens.getItemDamage()!=8 && lens.getItemDamage()!=11)
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
}
|
||||
else
|
||||
return true;
|
||||
|
||||
ItemStack lens = ((IManaBurst)entity).getSourceLens();
|
||||
return lens.getItemDamage() != 8 && lens.getItemDamage() != 11;
|
||||
}
|
||||
}
|
||||
@@ -41,9 +41,9 @@ import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
import vazkii.botania.api.internal.IManaBurst;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
public class ItemFocusDeflect extends ItemModFocus {
|
||||
@@ -65,9 +65,9 @@ public class ItemFocusDeflect extends ItemModFocus {
|
||||
int range = 0;
|
||||
if (stack != null) {
|
||||
ItemWandCasting wand = (ItemWandCasting) stack.getItem();
|
||||
range = wand.getFocusEnlarge(stack);
|
||||
range = wand.getFocusEnlarge(stack);
|
||||
}
|
||||
|
||||
|
||||
List<Entity> projectiles = p.worldObj.getEntitiesWithinAABB(IProjectile.class, AxisAlignedBB.getBoundingBox(p.posX - (4 + range), p.posY - (4 + range), p.posZ - (4 + range), p.posX + (3 + range), p.posY + (3 + range), p.posZ + (3 + range)));
|
||||
|
||||
for (Entity e : projectiles) {
|
||||
@@ -89,15 +89,15 @@ public class ItemFocusDeflect extends ItemModFocus {
|
||||
{
|
||||
switch (rank)
|
||||
{
|
||||
case 1:
|
||||
case 1:
|
||||
return new FocusUpgradeType[] { FocusUpgradeType.frugal};
|
||||
case 2:
|
||||
case 2:
|
||||
return new FocusUpgradeType[] { FocusUpgradeType.frugal, FocusUpgradeType.enlarge};
|
||||
case 3:
|
||||
case 3:
|
||||
return new FocusUpgradeType[] { FocusUpgradeType.frugal};
|
||||
case 4:
|
||||
case 4:
|
||||
return new FocusUpgradeType[] { FocusUpgradeType.frugal, FocusUpgradeType.enlarge};
|
||||
case 5:
|
||||
case 5:
|
||||
return new FocusUpgradeType[] { FocusUpgradeType.frugal};
|
||||
}
|
||||
return null;
|
||||
@@ -107,15 +107,14 @@ public class ItemFocusDeflect extends ItemModFocus {
|
||||
Class<? extends Entity> aClass=entity.getClass();
|
||||
if(DeflectBlacklist.contains(aClass))
|
||||
return true;
|
||||
if (Loader.isModLoaded("Botania"))
|
||||
if (Loader.isModLoaded("Botania") && entity instanceof IManaBurst)
|
||||
{
|
||||
return BotaniaFunctions.isEntityHarmless(entity);
|
||||
}
|
||||
for(Class<?> testClass:DeflectBlacklist)
|
||||
{
|
||||
if(testClass.isInterface())
|
||||
if(testClass.isAssignableFrom(aClass))
|
||||
return true;
|
||||
if(testClass.isInterface() && testClass.isAssignableFrom(aClass))
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
@@ -148,8 +147,8 @@ public class ItemFocusDeflect extends ItemModFocus {
|
||||
public AspectList getVisCost(ItemStack stack) {
|
||||
return visUsage;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
|
||||
@@ -83,7 +83,7 @@ public class ItemIchorclothArmor extends ItemArmor implements IVisDiscountGear,
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(final ItemStack stack, final EntityPlayer player, final List list, final boolean par4)
|
||||
public void addInformation(final ItemStack stack, final EntityPlayer player, final List list, final boolean par4)
|
||||
{
|
||||
list.add(EnumChatFormatting.DARK_PURPLE + StatCollector.translateToLocal("tc.visdiscount") + ": " + this.getVisDiscount(stack, player, null) + "%");
|
||||
}
|
||||
@@ -115,7 +115,7 @@ public class ItemIchorclothArmor extends ItemArmor implements IVisDiscountGear,
|
||||
|
||||
@Override
|
||||
public int getVisDiscount(ItemStack arg0, EntityPlayer arg1, Aspect arg2) {
|
||||
return 5;
|
||||
return 6;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -75,12 +75,12 @@ public abstract class ItemIchorclothArmorAdv extends ItemIchorclothArmor {
|
||||
public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type) {
|
||||
return slot == 2 ? LibResources.MODEL_ARMOR_ICHOR_GEM_2 : LibResources.MODEL_ARMOR_ICHOR_GEM_1;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public int getVisDiscount(ItemStack arg0, EntityPlayer arg1, Aspect arg2) {
|
||||
return 6;
|
||||
return 10;
|
||||
}
|
||||
|
||||
|
||||
|
||||
boolean ticks() {
|
||||
return false;
|
||||
|
||||
Reference in new issue
Block a user