Remove autoswitch api as the API broke, and I cannot find a working latest version on jitpack or cursemaven. I can bring this back once fixed, right now this is breaking the build.

This commit is contained in:
modmuss50 2022-03-04 16:06:41 +00:00
parent 61c1cd7744
commit 85757e7854
3 changed files with 0 additions and 70 deletions

View file

@ -50,8 +50,6 @@ repositories {
maven {
url = "https://jitpack.io"
content {
// Autoswitch API
includeGroup "com.github.dexman545"
// Trinkets API
includeGroup "com.github.emilyploszaj"
}
@ -187,7 +185,6 @@ dependencies {
optionalDependency "me.shedaniel:RoughlyEnoughItems-fabric:${project.rei_version}"
disabledOptionalDependency "com.github.emilyploszaj:trinkets:${project.trinkets_version}"
disabledOptionalDependency "com.github.dexman545:autoswitch-api:${project.autoswitch_version}"
disabledOptionalDependency "net.oskarstrom:DashLoader:${project.dashloader_version}"
// Use groovy for datagen/gametest, if you are copying this you prob dont want it.

View file

@ -15,5 +15,4 @@ org.gradle.jvmargs=-Xmx2G
energy_version=2.2.0
rei_version=8.0.438
trinkets_version=3.0.2
autoswitch_version=-SNAPSHOT
dashloader_version=2.0

View file

@ -1,66 +0,0 @@
/*
* This file is part of TechReborn, licensed under the MIT License (MIT).
*
* Copyright (c) 2020 TechReborn
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
package techreborn.compat.autoswitch;
import autoswitch.api.AutoSwitchApi;
import autoswitch.api.AutoSwitchMap;
import autoswitch.api.DurabilityGetter;
import net.minecraft.item.Item;
import net.minecraft.tag.Tag;
import org.apache.commons.lang3.tuple.Pair;
import reborncore.common.util.ItemUtils;
import techreborn.items.tool.ChainsawItem;
import techreborn.items.tool.DrillItem;
import techreborn.items.tool.JackhammerItem;
import techreborn.items.tool.basic.RockCutterItem;
import techreborn.items.tool.basic.ElectricTreetapItem;
import techreborn.items.tool.industrial.NanosaberItem;
import techreborn.items.tool.industrial.OmniToolItem;
public class AutoSwitchApiImpl implements AutoSwitchApi {
@Override
public void moddedTargets(AutoSwitchMap<String, Object> targets, AutoSwitchMap<String, String> actionConfig, AutoSwitchMap<String, String> usableConfig) {
}
@Override
public void moddedToolGroups(AutoSwitchMap<String, Pair<Tag<Item>, Class<?>>> toolGroupings) {
}
@Override
public void customDamageSystems(AutoSwitchMap<Class<?>, DurabilityGetter> damageMap) {
// Multiply by 100 to get percentage out of decimal form
damageMap.put(DrillItem.class, stack -> 100 * ItemUtils.getPowerForDurabilityBar(stack));
damageMap.put(ChainsawItem.class, stack -> 100 * ItemUtils.getPowerForDurabilityBar(stack));
damageMap.put(JackhammerItem.class, stack -> 100 * ItemUtils.getPowerForDurabilityBar(stack));
damageMap.put(NanosaberItem.class, stack -> 100 * ItemUtils.getPowerForDurabilityBar(stack));
damageMap.put(OmniToolItem.class, stack -> 100 * ItemUtils.getPowerForDurabilityBar(stack));
damageMap.put(ElectricTreetapItem.class, stack -> 100 * ItemUtils.getPowerForDurabilityBar(stack));
damageMap.put(RockCutterItem.class, stack -> 100 * ItemUtils.getPowerForDurabilityBar(stack));
}
}