├── gradle.properties
├── zip.exe
├── logo.png
├── loader
├── packer.jar
└── eloader
│ ├── eloader
│ ├── main.cpp
│ ├── eloader.vcxproj.user
│ └── eloader.vcxproj.filters
│ └── eloader.sln
├── proguard
└── lib
│ ├── proguard.jar
│ ├── retrace.jar
│ ├── annotations.jar
│ └── proguardgui.jar
├── gradle
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── src
└── main
│ └── java
│ └── forgefuck
│ └── team
│ └── xenobyte
│ ├── api
│ ├── gui
│ │ ├── PanelLayout.java
│ │ ├── InputType.java
│ │ ├── PanelSorting.java
│ │ ├── ElementAligment.java
│ │ ├── WidgetMode.java
│ │ ├── ColorPicker.java
│ │ ├── WidgetMessage.java
│ │ ├── TextElement.java
│ │ ├── ElementAbility.java
│ │ ├── GuiElement.java
│ │ └── XenoJFrame.java
│ ├── module
│ │ ├── PerformSource.java
│ │ ├── Category.java
│ │ └── PerformMode.java
│ ├── render
│ │ └── IDraw.java
│ ├── integration
│ │ ├── JavaInjector.java
│ │ └── NEI.java
│ ├── exceptions
│ │ ├── ConfigTypeException.java
│ │ └── DuplicateModuleException.java
│ ├── config
│ │ └── Cfg.java
│ └── Xeno.java
│ ├── render
│ ├── Renderer.java
│ ├── Textures.java
│ ├── Colors.java
│ ├── XRayHintRender.java
│ ├── GuiRender.java
│ ├── GuiScaler.java
│ └── XenoFont.java
│ ├── utils
│ ├── Reflections.java
│ ├── LangProvider.java
│ ├── TickHelper.java
│ ├── Delimitter.java
│ ├── Keys.java
│ ├── NetUtils.java
│ ├── Rand.java
│ ├── FileProvider.java
│ └── EventHelper.java
│ ├── modules
│ ├── NoRain.java
│ ├── AutoSprint.java
│ ├── Credits.java
│ ├── CmdTest.java
│ ├── FastPlace.java
│ ├── NoWeb.java
│ ├── XenoGui.java
│ ├── NoFall.java
│ ├── TinkerNoFall.java
│ ├── ThaumicFinger.java
│ ├── ThaumicInvise.java
│ ├── TinkerChest.java
│ ├── AdvancedTooltip.java
│ ├── FluidWalk.java
│ ├── MekFire.java
│ ├── NEIShowHidden.java
│ ├── AntiKnockBack.java
│ ├── RedGive.java
│ ├── TinkerGive.java
│ ├── CarpenterUse.java
│ ├── FakeCreative.java
│ ├── TravellersGive.java
│ ├── GuiReplacer.java
│ ├── EIOXpGrab.java
│ ├── RedBarrelGive.java
│ ├── ExtraFakeSlot.java
│ ├── FakeItem.java
│ ├── ShearDupe.java
│ ├── CreativeGive.java
│ ├── Rocket.java
│ ├── NanoTechGive.java
│ ├── BobbingControl.java
│ ├── Step.java
│ ├── TextRadar.java
│ ├── CrayfishGive.java
│ ├── BlinkCam.java
│ ├── RenderControl.java
│ ├── ZtonesMeta.java
│ ├── BiblioSignEdit.java
│ ├── FastBreak.java
│ ├── BiblioTableGive.java
│ ├── ChatBind.java
│ ├── BiblioAtlasGive.java
│ ├── BuildMarkerGive.java
│ ├── MatterGiveItem.java
│ ├── OneWayTicket.java
│ ├── HiJump.java
│ ├── ClientSpeed.java
│ ├── NCPanelEdit.java
│ ├── Spider.java
│ ├── FTBSatchelDupe.java
│ ├── PacketProtector.java
│ ├── RFCellDupe.java
│ ├── AdvertHack.java
│ ├── FullBright.java
│ ├── GalacticFire.java
│ ├── FactoryRocket.java
│ ├── VanillaMagic.java
│ ├── Ceiling.java
│ ├── QuestGive.java
│ ├── BlockOverlay.java
│ ├── WallHack.java
│ ├── MalisisDoors.java
│ ├── MekOpener.java
│ ├── AutoDrop.java
│ ├── MachineChaos.java
│ ├── CrayfishNuker.java
│ ├── TurretNuker.java
│ ├── BiblioFrameGive.java
│ ├── TainedAura.java
│ ├── OCShutDown.java
│ ├── FactoryDupe.java
│ ├── WayLine.java
│ ├── CacheGive.java
│ ├── RadioHack.java
│ ├── BunnyHop.java
│ └── FakeBreak.java
│ ├── XenoByte.java
│ ├── gui
│ ├── click
│ │ └── elements
│ │ │ ├── GuiWidget.java
│ │ │ ├── ScrollSlider.java
│ │ │ └── Button.java
│ └── swing
│ │ ├── CreditsGui.java
│ │ └── ColorPickerGui.java
│ └── handlers
│ └── PacketHandler.java
├── .gitignore
├── README.md
├── appveyor.yml
└── gradlew.bat
/gradle.properties:
--------------------------------------------------------------------------------
1 | org.gradle.jvmargs=-Xmx1G
--------------------------------------------------------------------------------
/zip.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/N1nt4nd0/Xenobyte/HEAD/zip.exe
--------------------------------------------------------------------------------
/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/N1nt4nd0/Xenobyte/HEAD/logo.png
--------------------------------------------------------------------------------
/loader/packer.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/N1nt4nd0/Xenobyte/HEAD/loader/packer.jar
--------------------------------------------------------------------------------
/proguard/lib/proguard.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/N1nt4nd0/Xenobyte/HEAD/proguard/lib/proguard.jar
--------------------------------------------------------------------------------
/proguard/lib/retrace.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/N1nt4nd0/Xenobyte/HEAD/proguard/lib/retrace.jar
--------------------------------------------------------------------------------
/proguard/lib/annotations.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/N1nt4nd0/Xenobyte/HEAD/proguard/lib/annotations.jar
--------------------------------------------------------------------------------
/proguard/lib/proguardgui.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/N1nt4nd0/Xenobyte/HEAD/proguard/lib/proguardgui.jar
--------------------------------------------------------------------------------
/loader/eloader/eloader/main.cpp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/N1nt4nd0/Xenobyte/HEAD/loader/eloader/eloader/main.cpp
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/N1nt4nd0/Xenobyte/HEAD/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/PanelLayout.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | public enum PanelLayout {
4 |
5 | VERTICAL, HORIZONTAL
6 |
7 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/module/PerformSource.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.module;
2 |
3 | public enum PerformSource {
4 |
5 | BUTTON, KEY
6 |
7 | }
8 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/InputType.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | public enum InputType {
4 |
5 | COORDS, SINGLE_STRING, CUSTOM
6 |
7 | }
8 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/PanelSorting.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | public enum PanelSorting {
4 |
5 | WIDTH, ALPHABET, DEFAULT
6 |
7 | }
8 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/ElementAligment.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | public enum ElementAligment {
4 |
5 | CENTER, LEFT, RIGHT
6 |
7 | }
8 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/module/Category.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.module;
2 |
3 | public enum Category {
4 |
5 | PLAYER, MOVE, WORLD, MODS, MISC, NEI, NONE
6 |
7 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/render/IDraw.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.render;
2 |
3 | @FunctionalInterface
4 | public interface IDraw {
5 |
6 | void draw();
7 |
8 | }
9 |
--------------------------------------------------------------------------------
/loader/eloader/eloader/eloader.vcxproj.user:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/module/PerformMode.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.module;
2 |
3 | public enum PerformMode {
4 |
5 | TOGGLE, SINGLE, ENABLED_ON_START, DISABLED_ON_START;
6 |
7 | }
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | .gradle
2 | build/
3 | *.txt
4 | *.md
5 | loader/classes.h
6 | loader/xenobyte-1.0.0.jar
7 | loader/eloader/.vs/
8 | loader/eloader/output/
9 | loader/eloader/temp/
10 | loader/eloader/eloader/classes.h
11 | mainclass.txt
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/render/Renderer.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.render;
2 |
3 | public class Renderer {
4 |
5 | public final WorldRender WORLD = new WorldRender();
6 | public final GuiRender GUI = new GuiRender();
7 |
8 | }
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Wed Jul 02 15:54:47 CDT 2014
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=https\://services.gradle.org/distributions/gradle-4.4.1-all.zip
7 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/integration/JavaInjector.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.integration;
2 |
3 | import forgefuck.team.xenobyte.XenoByte;
4 |
5 | public class JavaInjector extends XenoByte {
6 |
7 | {
8 | starter(null);
9 | }
10 |
11 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/render/Textures.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.render;
2 |
3 | import static net.minecraft.client.renderer.texture.TextureUtil.*;
4 |
5 | public class Textures {
6 |
7 | public static final int FONT = uploadTextureImage(glGenTextures(), Images.FONT);
8 |
9 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/exceptions/ConfigTypeException.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.exceptions;
2 |
3 | public class ConfigTypeException extends Exception {
4 |
5 | public ConfigTypeException(String type) {
6 | super("Type [" + type + "] not implemented");
7 | }
8 |
9 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/exceptions/DuplicateModuleException.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.exceptions;
2 |
3 | import forgefuck.team.xenobyte.api.module.CheatModule;
4 |
5 | public class DuplicateModuleException extends RuntimeException {
6 |
7 | public DuplicateModuleException(CheatModule module) {
8 | super("Duplicate module found [" + module + "]");
9 | }
10 |
11 | }
12 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/config/Cfg.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.config;
2 |
3 | import java.lang.annotation.ElementType;
4 | import java.lang.annotation.Retention;
5 | import java.lang.annotation.RetentionPolicy;
6 | import java.lang.annotation.Target;
7 |
8 | @Target(ElementType.FIELD)
9 | @Retention(RetentionPolicy.RUNTIME)
10 | public @interface Cfg {
11 |
12 | String value();
13 |
14 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/utils/Reflections.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.utils;
2 |
3 | import cpw.mods.fml.relauncher.ReflectionHelper;
4 |
5 | public class Reflections extends ReflectionHelper {
6 |
7 | public static boolean exists(String clazz) {
8 | try {
9 | Class.forName(clazz);
10 | return true;
11 | } catch (ClassNotFoundException e) {}
12 | return false;
13 | }
14 |
15 | }
16 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/WidgetMode.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | import forgefuck.team.xenobyte.render.Colors;
4 |
5 | public enum WidgetMode {
6 |
7 | INFO(Colors.SKY), SUCCESS(Colors.GREEN), FAIL(Colors.RED);
8 |
9 | private int color;
10 |
11 | WidgetMode(int color) {
12 | this.color = color;
13 | }
14 |
15 | public int getColor() {
16 | return color;
17 | }
18 |
19 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/utils/LangProvider.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.utils;
2 |
3 | import net.minecraft.client.Minecraft;
4 |
5 | public class LangProvider {
6 |
7 | public String get(String eng, String rus) {
8 | switch (Minecraft.getMinecraft().getLanguageManager().getCurrentLanguage().getLanguageCode()) {
9 | case "ru_RU":
10 | return rus;
11 | default:
12 | return eng;
13 | }
14 | }
15 |
16 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/utils/TickHelper.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.utils;
2 |
3 | public class TickHelper {
4 |
5 | public static final int ONE_SEC = fromSeconds(1);
6 | public static final int TWO_SEC = fromSeconds(2);
7 | public static final int THREE_SEC = fromSeconds(3);
8 | public static final int FOUR_SEC = fromSeconds(4);
9 | public static final int FIVE_SEC = fromSeconds(5);
10 | public static final int SIX_SEC = fromSeconds(6);
11 |
12 | public static int fromSeconds(int secs) {
13 | return secs * ticksInSeconds();
14 | }
15 |
16 | public static int ticksInSeconds() {
17 | return 40;
18 | }
19 |
20 | }
21 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/NoRain.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.module.Category;
4 | import forgefuck.team.xenobyte.api.module.CheatModule;
5 | import forgefuck.team.xenobyte.api.module.PerformMode;
6 |
7 | public class NoRain extends CheatModule {
8 |
9 | public NoRain() {
10 | super("NoRain", Category.WORLD, PerformMode.TOGGLE);
11 | }
12 |
13 | @Override public void onTick(boolean inGame) {
14 | if (inGame) {
15 | utils.world().setRainStrength(0);
16 | }
17 | }
18 |
19 | @Override public String moduleDesc() {
20 | return lang.get("When the PC is shit", "Когда комп говно");
21 | }
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/AutoSprint.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.module.Category;
4 | import forgefuck.team.xenobyte.api.module.CheatModule;
5 | import forgefuck.team.xenobyte.api.module.PerformMode;
6 |
7 | public class AutoSprint extends CheatModule {
8 |
9 | public AutoSprint() {
10 | super("AutoSprint", Category.MOVE, PerformMode.TOGGLE);
11 | }
12 |
13 | @Override public void onTick(boolean inGame) {
14 | if (inGame) {
15 | utils.player().setSprinting(true);
16 | }
17 | }
18 |
19 | @Override public String moduleDesc() {
20 | return lang.get("Non-stop sprint", "Постоянный спринт");
21 | }
22 |
23 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/XenoByte.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte;
2 |
3 | import cpw.mods.fml.common.Mod;
4 | import cpw.mods.fml.common.Mod.EventHandler;
5 | import cpw.mods.fml.common.event.FMLInitializationEvent;
6 | import cpw.mods.fml.common.event.FMLLoadCompleteEvent;
7 | import forgefuck.team.xenobyte.api.Xeno;
8 | import forgefuck.team.xenobyte.handlers.ModuleHandler;
9 |
10 | @Mod(modid = Xeno.mod_id, name = Xeno.mod_name, version = Xeno.mod_version)
11 |
12 | public class XenoByte {
13 |
14 | @EventHandler public void init(FMLInitializationEvent e) {
15 | if (e == null) {
16 | starter(null);
17 | }
18 | }
19 |
20 | @EventHandler public void starter(FMLLoadCompleteEvent e) {
21 | new ModuleHandler();
22 | }
23 |
24 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/Credits.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.module.Category;
4 | import forgefuck.team.xenobyte.api.module.CheatModule;
5 | import forgefuck.team.xenobyte.api.module.PerformMode;
6 | import forgefuck.team.xenobyte.api.module.PerformSource;
7 | import forgefuck.team.xenobyte.gui.swing.CreditsGui;
8 |
9 | public class Credits extends CheatModule {
10 |
11 | public Credits() {
12 | super("Credits", Category.MISC, PerformMode.SINGLE);
13 | }
14 |
15 | @Override public void onPerform(PerformSource src) {
16 | new CreditsGui().showFrame();
17 | }
18 |
19 | @Override public String moduleDesc() {
20 | return lang.get("Product information + links", "Информация о продукте + ссылки");
21 | }
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/CmdTest.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.module.Category;
4 | import forgefuck.team.xenobyte.api.module.CheatModule;
5 | import forgefuck.team.xenobyte.api.module.PerformMode;
6 | import forgefuck.team.xenobyte.api.module.PerformSource;
7 | import io.netty.buffer.Unpooled;
8 |
9 | public class CmdTest extends CheatModule {
10 |
11 | public CmdTest() {
12 | super("CmdTest", Category.MISC, PerformMode.SINGLE);
13 | }
14 |
15 | @Override public String moduleDesc() {
16 | return lang.get("Checking the command block for operability", "Проверка командного блока на работоспособность");
17 | }
18 |
19 | @Override public void onPerform(PerformSource src) {
20 | utils.sendPacket("MC|AdvCdm", Unpooled.buffer());
21 | }
22 |
23 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/FastPlace.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.module.Category;
4 | import forgefuck.team.xenobyte.api.module.CheatModule;
5 | import forgefuck.team.xenobyte.api.module.PerformMode;
6 | import forgefuck.team.xenobyte.utils.Reflections;
7 | import net.minecraft.client.Minecraft;
8 |
9 | public class FastPlace extends CheatModule {
10 |
11 | public FastPlace() {
12 | super("FastPlace", Category.WORLD, PerformMode.TOGGLE);
13 | }
14 |
15 | @Override public void onTick(boolean inGame) {
16 | if (inGame) {
17 | Reflections.setPrivateValue(Minecraft.class, utils.mc(), 0, 47);
18 | }
19 | }
20 |
21 | @Override public String moduleDesc() {
22 | return lang.get("Quick block placing", "Быстрая установка блоков");
23 | }
24 |
25 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/NoWeb.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.module.Category;
4 | import forgefuck.team.xenobyte.api.module.CheatModule;
5 | import forgefuck.team.xenobyte.api.module.PerformMode;
6 | import forgefuck.team.xenobyte.utils.Reflections;
7 | import net.minecraft.entity.Entity;
8 |
9 | public class NoWeb extends CheatModule {
10 |
11 | public NoWeb() {
12 | super("NoWeb", Category.MOVE, PerformMode.TOGGLE);
13 | }
14 |
15 | @Override public void onTick(boolean inGame) {
16 | if (inGame) {
17 | Reflections.setPrivateValue(Entity.class, utils.player(), false, 27);
18 | }
19 | }
20 |
21 | @Override public String moduleDesc() {
22 | return lang.get("The web no longer clings", "Паутина больше не цепляет");
23 | }
24 |
25 | }
26 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/utils/Delimitter.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.utils;
2 |
3 | public class Delimitter {
4 |
5 | private int value, iterate, min, max;
6 |
7 | public Delimitter(int min, int max) {
8 | this(min, min, max);
9 | }
10 |
11 | public Delimitter(int value, int min, int max) {
12 | this.iterate = value;
13 | this.value = value;
14 | this.max = max;
15 | this.min = min;
16 | }
17 |
18 | public int getMin() {
19 | return min;
20 | }
21 |
22 | public int getMax() {
23 | return max;
24 | }
25 |
26 | public void reset() {
27 | iterate = value;
28 | }
29 |
30 | public int calc(int step) {
31 | iterate += step;
32 | return iterate = iterate > max ? max : iterate < min ? min : iterate;
33 | }
34 |
35 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/XenoGui.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import org.lwjgl.input.Keyboard;
4 |
5 | import forgefuck.team.xenobyte.api.module.Category;
6 | import forgefuck.team.xenobyte.api.module.CheatModule;
7 | import forgefuck.team.xenobyte.api.module.PerformMode;
8 | import forgefuck.team.xenobyte.api.module.PerformSource;
9 | import forgefuck.team.xenobyte.gui.click.XenoGuiScreen;
10 |
11 | public class XenoGui extends CheatModule {
12 |
13 | public XenoGui() {
14 | super("XenoGui", Category.NONE, PerformMode.SINGLE);
15 | setKeyBind(Keyboard.KEY_B);
16 | }
17 |
18 | @Override public void onPerform(PerformSource type) {
19 | utils.openGui(new XenoGuiScreen(moduleHandler()), true);
20 | }
21 |
22 | @Override public boolean allowStateMessages() {
23 | return false;
24 | }
25 |
26 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/NoFall.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.module.Category;
4 | import forgefuck.team.xenobyte.api.module.CheatModule;
5 | import forgefuck.team.xenobyte.api.module.PerformMode;
6 | import net.minecraft.network.play.client.C03PacketPlayer.C04PacketPlayerPosition;
7 |
8 | public class NoFall extends CheatModule {
9 |
10 | public NoFall() {
11 | super("NoFall", Category.MOVE, PerformMode.TOGGLE);
12 | }
13 |
14 | @Override public void onTick(boolean inGame) {
15 | if (inGame && utils.player().fallDistance > 2) {
16 | utils.sendPacket(new C04PacketPlayerPosition(utils.player().motionX, -999, -999, utils.player().motionZ, !utils.player().onGround));
17 | }
18 | }
19 |
20 | @Override public String moduleDesc() {
21 | return lang.get("Disables fall damage", "Отключает урон от падения");
22 | }
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/TinkerNoFall.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 |
8 | public class TinkerNoFall extends CheatModule {
9 |
10 | public TinkerNoFall() {
11 | super("TinkerNoFall", Category.MODS, PerformMode.TOGGLE);
12 | }
13 |
14 | @Override public void onTick(boolean inGame) {
15 | if (inGame && utils.player().fallDistance > 2) {
16 | utils.sendPacket("TConstruct", (byte) 4);
17 | }
18 | }
19 |
20 | @Override public boolean isWorking() {
21 | return Loader.isModLoaded("TConstruct");
22 | }
23 |
24 | @Override public String moduleDesc() {
25 | return lang.get("Removes fall damage", "Убирает урон от падения");
26 | }
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/Xeno.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api;
2 |
3 | import org.apache.logging.log4j.LogManager;
4 | import org.apache.logging.log4j.Logger;
5 |
6 | import forgefuck.team.xenobyte.render.Renderer;
7 | import forgefuck.team.xenobyte.utils.LangProvider;
8 | import forgefuck.team.xenobyte.utils.Utils;
9 |
10 | public interface Xeno {
11 |
12 | String mod_id = "xenobyte";
13 | String mod_name = "X3N0BYT3";
14 | String mod_version = "1.0.9";
15 | String mod_author = "N1nt4nd0";
16 | String format_prefix = "§8[§4" + mod_name + "§8]§r ";
17 |
18 | String ds_link = "N1nt4nd0#0613";
19 | String tg_link = "t.me/N1nt4nd0";
20 | String gh_link = "github.com/N1nt4nd0/Xenobyte";
21 | String yt_link = "youtube.com/channel/UClXGh0w1BiBEyxn7iFI4dsA";
22 |
23 | Utils utils = new Utils();
24 | Renderer render = new Renderer();
25 | LangProvider lang = new LangProvider();
26 | Logger logger = LogManager.getLogger(mod_name);
27 |
28 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/ThaumicFinger.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 |
9 | public class ThaumicFinger extends CheatModule {
10 |
11 | public ThaumicFinger() {
12 | super("ThaumicFinger", Category.MODS, PerformMode.SINGLE);
13 | }
14 |
15 | @Override public void onPerform(PerformSource src) {
16 | utils.sendPacket("thaumichorizons", (byte) 9, utils.myId(), utils.worldId());
17 | }
18 |
19 | @Override public boolean isWorking() {
20 | return Loader.isModLoaded("ThaumicHorizons");
21 | }
22 |
23 | @Override public String moduleDesc() {
24 | return lang.get("Opening the dupe workbench", "Открытие дюп - верстака");
25 | }
26 |
27 | }
28 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/ThaumicInvise.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 |
9 | public class ThaumicInvise extends CheatModule {
10 |
11 | public ThaumicInvise() {
12 | super("ThaumicInvise", Category.MODS, PerformMode.SINGLE);
13 | }
14 |
15 | @Override public void onPerform(PerformSource src) {
16 | utils.sendPacket("thaumichorizons", (byte) 13, utils.myId(), utils.worldId());
17 | }
18 |
19 | @Override public boolean isWorking() {
20 | return Loader.isModLoaded("ThaumicHorizons");
21 | }
22 |
23 | @Override public String moduleDesc() {
24 | return lang.get("Toggle player invisibility", "Переключение невидимости игрока");
25 | }
26 |
27 | }
28 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/TinkerChest.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 |
9 | public class TinkerChest extends CheatModule {
10 |
11 | public TinkerChest() {
12 | super("TinkerChest", Category.MODS, PerformMode.SINGLE);
13 | }
14 |
15 | @Override public void onPerform(PerformSource src) {
16 | utils.sendPacket("TConstruct", (byte) 1, 102);
17 | }
18 |
19 | @Override public boolean isWorking() {
20 | return Loader.isModLoaded("TConstruct");
21 | }
22 |
23 | @Override public String moduleDesc() {
24 | return lang.get("Opening a travel bag without having it in your inventory", "Открытие дорожной сумки без её наличия в инвентаре");
25 | }
26 |
27 | }
28 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/ColorPicker.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | import java.awt.Color;
4 |
5 | public abstract class ColorPicker {
6 |
7 | public int r, g, b, a, rgb, rgba;
8 | public float rf, gf, bf, af;
9 | public Color color;
10 |
11 | public ColorPicker(int c) {
12 | this(new Color(c, true));
13 | }
14 |
15 | public ColorPicker(Color c) {
16 | setColor(c.getRed(), c.getGreen(), c.getBlue(), c.getAlpha());
17 | }
18 |
19 | public void setColor(int r, int g, int b, int a) {
20 | this.rgb = new Color(r, g, b).getRGB();
21 | this.color = new Color(r, g, b, a);
22 | this.rgba = color.getRGB();
23 | this.rf = r / 255F;
24 | this.gf = g / 255F;
25 | this.bf = b / 255F;
26 | this.af = a / 255F;
27 | this.r = r;
28 | this.g = g;
29 | this.b = b;
30 | this.a = a;
31 | onColorUpdate();
32 | }
33 |
34 | protected void onColorUpdate() {}
35 |
36 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/AdvancedTooltip.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import net.minecraft.item.Item;
8 | import net.minecraftforge.event.entity.player.ItemTooltipEvent;
9 |
10 | public class AdvancedTooltip extends CheatModule {
11 |
12 | public AdvancedTooltip() {
13 | super("AdvancedTooltip", Category.MISC, PerformMode.TOGGLE);
14 | }
15 |
16 | @SubscribeEvent public void tooltipHook(ItemTooltipEvent e) {
17 | e.toolTip.add(utils.stringId(e.itemStack) + " " + Item.getIdFromItem(e.itemStack.getItem()) + ":" + e.itemStack.getItemDamage());
18 | }
19 |
20 | @Override public String moduleDesc() {
21 | return lang.get("Displays metadata in the item description", "Отображает в описании предмета его метаданные");
22 | }
23 |
24 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/FluidWalk.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import org.lwjgl.input.Keyboard;
4 |
5 | import forgefuck.team.xenobyte.api.module.Category;
6 | import forgefuck.team.xenobyte.api.module.CheatModule;
7 | import forgefuck.team.xenobyte.api.module.PerformMode;
8 | import net.minecraft.block.BlockLiquid;
9 |
10 | public class FluidWalk extends CheatModule {
11 |
12 | public FluidWalk() {
13 | super("FluidWalk", Category.MOVE, PerformMode.TOGGLE);
14 | }
15 |
16 | @Override public void onTick(boolean inGame) {
17 | if (inGame && utils.block(utils.myCoords()) instanceof BlockLiquid) {
18 | utils.player().motionY = 0;
19 | if (Keyboard.isKeyDown(utils.mc().gameSettings.keyBindJump.getKeyCode())) {
20 | utils.player().motionY = 0.4;
21 | }
22 | }
23 | }
24 |
25 | @Override public String moduleDesc() {
26 | return lang.get("Walking on liquids", "Прогулки по жидкостям");
27 | }
28 |
29 | }
30 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/MekFire.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 |
8 | public class MekFire extends CheatModule {
9 |
10 | public MekFire() {
11 | super("MekFire", Category.MODS, PerformMode.TOGGLE);
12 | }
13 |
14 | @Override public int tickDelay() {
15 | return 4;
16 | }
17 |
18 | @Override public void onTick(boolean inGame) {
19 | if (inGame) {
20 | byte[] name = utils.myName().getBytes();
21 | utils.sendPacket("MEK", (byte) 20, 0, name.length, name, true);
22 | }
23 | }
24 |
25 | @Override public boolean isWorking() {
26 | return Loader.isModLoaded("Mekanism");
27 | }
28 |
29 | @Override public String moduleDesc() {
30 | return lang.get("Mekanism backpack fire lights", "Огни ранца Mekanism");
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/NEIShowHidden.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
4 | import forgefuck.team.xenobyte.api.integration.NEI;
5 | import forgefuck.team.xenobyte.api.module.Category;
6 | import forgefuck.team.xenobyte.api.module.CheatModule;
7 | import forgefuck.team.xenobyte.api.module.PerformMode;
8 | import net.minecraft.client.gui.inventory.GuiContainer;
9 | import net.minecraftforge.client.event.GuiOpenEvent;
10 |
11 | public class NEIShowHidden extends CheatModule {
12 |
13 | public NEIShowHidden() {
14 | super("NEIShowHidden", Category.NONE, PerformMode.ENABLED_ON_START);
15 | }
16 |
17 | @Override public boolean isWorking() {
18 | return NEI.isAvailable();
19 | }
20 |
21 | @Override public boolean isWidgetable() {
22 | return false;
23 | }
24 |
25 | @SubscribeEvent public void guiOpen(GuiOpenEvent e) {
26 | if (e.gui instanceof GuiContainer) {
27 | NEI.clearHiddenItems();
28 | }
29 | }
30 |
31 | }
32 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/AntiKnockBack.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.module.Category;
4 | import forgefuck.team.xenobyte.api.module.CheatModule;
5 | import forgefuck.team.xenobyte.api.module.PerformMode;
6 | import net.minecraft.network.Packet;
7 | import net.minecraft.network.play.server.S12PacketEntityVelocity;
8 |
9 | public class AntiKnockBack extends CheatModule {
10 |
11 | public AntiKnockBack() {
12 | super("AntiKnockBack", Category.MOVE, PerformMode.TOGGLE);
13 | }
14 |
15 | @Override public boolean doReceivePacket(Packet packet) {
16 | if (packet instanceof S12PacketEntityVelocity) {
17 | if (utils.isInGame() && utils.myId() == ((S12PacketEntityVelocity)packet).func_149412_c()) {
18 | return false;
19 | }
20 | }
21 | return true;
22 | }
23 |
24 | @Override public String moduleDesc() {
25 | return lang.get("Turns off the knockback effect of the player", "Выключает эфект отбрасывания у игрока");
26 | }
27 |
28 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/RedGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 |
9 | public class RedGive extends CheatModule {
10 |
11 | public RedGive() {
12 | super("RedGive", Category.MODS, PerformMode.SINGLE);
13 | }
14 |
15 | @Override public void onPerform(PerformSource type) {
16 | utils.sendPacket("PR|Transp", (byte) 4, (byte) utils.player().inventory.currentItem, giveSelector().givedItem());
17 | }
18 |
19 | @Override public boolean isWorking() {
20 | return Loader.isModLoaded("ProjRed|Transportation");
21 | }
22 |
23 | @Override public String moduleDesc() {
24 | return lang.get("Issuing an item to the active slot (will replace the current item)", "Выдача предмета в активный слот (заменит текущий предмет)");
25 | }
26 |
27 | }
28 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 |

2 |
3 | # X3N0BYT3 - Hack Pack for Minecraft 1.7.10 Forge [](https://ci.appveyor.com/project/N1nt4nd0/xenobyte/branch/master)
4 |
5 | # A short video guide to use
6 |
7 | - https://youtu.be/nZAEb3mmXL4
8 |
9 | # Possible causes of crashes
10 |
11 | - Using an injector that does not match the operating system or java bitness (использование инжекта не соответствующей с операционной системой или java разрядности)
12 | - Minecraft version does not match the declared (версия Minecraft не соответствует заявленной)
13 | - Protection against injection in the launcher (защита от инжекта в лаунчере)
14 | - Using java version below 1.8 (использование java версии ниже 1.8)
15 |
16 | # Links
17 |
18 | - YouTube https://www.youtube.com/channel/UClXGh0w1BiBEyxn7iFI4dsA
19 | - Instagram https://www.instagram.com/n1nt4nd0
20 | - Telegram https://t.me/N1nt4nd0
21 | - Discord - N1nt4nd0#0613
22 |
23 | # Thanks
24 |
25 | - Tenon4ik, Left4Dead, radioegor146, SongJ
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/TinkerGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 |
9 | public class TinkerGive extends CheatModule {
10 |
11 | public TinkerGive() {
12 | super("TinkerGive", Category.MODS, PerformMode.SINGLE);
13 | }
14 |
15 | @Override public void onPerform(PerformSource src) {
16 | int[] mop = utils.mop();
17 | utils.sendPacket("TConstruct", (byte) 8, mop[0], mop[1], mop[2], giveSelector().givedItem());
18 | }
19 |
20 | @Override public boolean isWorking() {
21 | return Loader.isModLoaded("TConstruct");
22 | }
23 |
24 | @Override public String moduleDesc() {
25 | return lang.get("Issuing an item to any inventory from TinkersConstruct that the player is looking at", "Выдача предмета в любой инвентарь из TinkersConstruct на который смотрит игрок");
26 | }
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/render/Colors.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.render;
2 |
3 | import java.awt.Color;
4 |
5 | public class Colors {
6 |
7 | public static final int TRANSPARENT_DARKEST = new Color(0, 0, 0, 180).getRGB();
8 | public static final int TRANSPARENT_DARK = new Color(0, 0, 0, 100).getRGB();
9 | public static final int WHITE_BG = new Color(255, 255, 255, 80).getRGB();
10 | public static final int TRANSPARENT = new Color(0, 0, 0, 0).getRGB();
11 | public static final int GREEN_DARK = new Color(0, 80, 0).getRGB();
12 | public static final int WHITE = new Color(255, 255, 255).getRGB();
13 | public static final int SKY_DARK = new Color(20, 50, 64).getRGB();
14 | public static final int ORANGE = new Color(255, 160, 0).getRGB();
15 | public static final int YELLOW = new Color(255, 255, 0).getRGB();
16 | public static final int RED_DARK = new Color(80, 0, 0).getRGB();
17 | public static final int GREEN = new Color(0, 255, 0).getRGB();
18 | public static final int SKY = new Color(0, 200, 255).getRGB();
19 | public static final int BLACK = new Color(0, 0, 0).getRGB();
20 | public static final int RED = new Color(255, 0, 0).getRGB();
21 |
22 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/WidgetMessage.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | import forgefuck.team.xenobyte.api.module.CheatModule;
4 |
5 | public class WidgetMessage {
6 |
7 | private CheatModule module;
8 | private WidgetMode mode;
9 | private Object mess;
10 |
11 | public WidgetMessage(CheatModule module, Object mess) {
12 | this(module, mess, WidgetMode.INFO);
13 | }
14 |
15 | public WidgetMessage(Object mess, WidgetMode mode) {
16 | this(null, mess, mode);
17 | }
18 |
19 | public WidgetMessage(CheatModule module, Object mess, WidgetMode mode) {
20 | this.mess = module != null ? module + " " + mess : mess;
21 | this.module = module;
22 | this.mode = mode;
23 | }
24 |
25 | public CheatModule getModule() {
26 | return module;
27 | }
28 |
29 | public boolean hasModule() {
30 | return module != null;
31 | }
32 |
33 | public String getMessage() {
34 | return new String() + mess;
35 | }
36 |
37 | public WidgetMode getMode() {
38 | return mode;
39 | }
40 |
41 | @Override public String toString() {
42 | return getMessage();
43 | }
44 |
45 | }
46 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/CarpenterUse.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
5 | import forgefuck.team.xenobyte.api.module.Category;
6 | import forgefuck.team.xenobyte.api.module.CheatModule;
7 | import forgefuck.team.xenobyte.api.module.PerformMode;
8 | import net.minecraftforge.client.event.MouseEvent;
9 |
10 | public class CarpenterUse extends CheatModule {
11 |
12 | public CarpenterUse() {
13 | super("CarpenterUse", Category.MODS, PerformMode.TOGGLE);
14 | }
15 |
16 | @SubscribeEvent public void mouseEvent(MouseEvent e) {
17 | if (e.button == 1 && e.buttonstate) {
18 | int[] mop = utils.mop();
19 | utils.sendPacket("CarpentersBlocks", 0, mop[0], mop[1], mop[2], mop[3]);
20 | e.setCanceled(true);
21 | }
22 | }
23 |
24 | @Override public String moduleDesc() {
25 | return lang.get("In most cases, allows you to use right click in clamed area", "В большинстве случаев позволяет использовать ПКМ в привате");
26 | }
27 |
28 | @Override public boolean isWorking() {
29 | return Loader.isModLoaded("CarpentersBlocks");
30 | }
31 |
32 | }
--------------------------------------------------------------------------------
/loader/eloader/eloader/eloader.vcxproj.filters:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | {4FC737F1-C7A5-4376-A066-2A32D752A2FF}
6 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx
7 |
8 |
9 | {93995380-89BD-4b04-88EB-625FBE52EBFB}
10 | h;hh;hpp;hxx;hm;inl;inc;ipp;xsd
11 |
12 |
13 | {67DA6AB6-F800-4c08-8B7A-83BB121AAD01}
14 | rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms
15 |
16 |
17 |
18 |
19 | Исходные файлы
20 |
21 |
22 |
23 |
24 | Файлы заголовков
25 |
26 |
27 | Файлы заголовков
28 |
29 |
30 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/FakeCreative.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.module.Category;
4 | import forgefuck.team.xenobyte.api.module.CheatModule;
5 | import forgefuck.team.xenobyte.api.module.PerformMode;
6 | import forgefuck.team.xenobyte.api.module.PerformSource;
7 | import net.minecraft.world.WorldSettings;
8 |
9 | public class FakeCreative extends CheatModule {
10 |
11 | public FakeCreative() {
12 | super("FakeCreative", Category.PLAYER, PerformMode.SINGLE);
13 | }
14 |
15 | @Override public void onPerform(PerformSource src) {
16 | if (utils.isInCreative()) {
17 | utils.mc().playerController.setGameType(WorldSettings.GameType.SURVIVAL);
18 | WorldSettings.GameType.SURVIVAL.configurePlayerCapabilities(utils.player().capabilities);
19 | utils.player().sendPlayerAbilities();
20 | } else {
21 | utils.mc().playerController.setGameType(WorldSettings.GameType.CREATIVE);
22 | WorldSettings.GameType.CREATIVE.configurePlayerCapabilities(utils.player().capabilities);
23 | utils.player().sendPlayerAbilities();
24 | }
25 | }
26 |
27 | @Override public String moduleDesc() {
28 | return lang.get("Visual /gamemode 1", "Визуальный /gamemode 1");
29 | }
30 |
31 | }
32 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/TravellersGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.tileentity.TileEntity;
9 | import net.minecraft.tileentity.TileEntityChest;
10 |
11 | public class TravellersGive extends CheatModule {
12 |
13 | public TravellersGive() {
14 | super("TravellersGive", Category.MODS, PerformMode.SINGLE);
15 | }
16 |
17 | @Override public void onPerform(PerformSource src) {
18 | TileEntity checkTile = utils.tile();
19 | if (checkTile instanceof TileEntityChest) {
20 | utils.sendPacket("TravellersGear", (byte) 8, utils.worldId(), utils.coords(checkTile), utils.chestGiveHelper((TileEntityChest) checkTile, giveSelector()));
21 | }
22 | }
23 |
24 | @Override public String moduleDesc() {
25 | return lang.get("Issuing an item into a vanilla chest that the player is looking at", "Выдача предмета в обычный сундук на который смотрит игрок");
26 | }
27 |
28 | @Override public boolean isWorking() {
29 | return Loader.isModLoaded("TravellersGear");
30 | }
31 |
32 | }
33 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/GuiReplacer.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.utils.Rand;
8 | import forgefuck.team.xenobyte.utils.Reflections;
9 | import net.minecraft.client.gui.GuiMainMenu;
10 | import net.minecraft.client.gui.GuiScreen;
11 | import net.minecraftforge.client.event.GuiOpenEvent;
12 |
13 | public class GuiReplacer extends CheatModule {
14 |
15 | public GuiReplacer() {
16 | super("GuiReplacer", Category.NONE, PerformMode.ENABLED_ON_START);
17 | }
18 |
19 | private void replaceSplash(GuiScreen gui) {
20 | if (gui instanceof GuiMainMenu) {
21 | try {
22 | Reflections.setPrivateValue(GuiMainMenu.class, (GuiMainMenu) gui, Rand.splash(), 3);
23 | } catch(Exception e) {}
24 | }
25 | }
26 |
27 | @Override public void onPostInit() {
28 | replaceSplash(utils.currentScreen());
29 | }
30 |
31 | @Override public boolean isWidgetable() {
32 | return false;
33 | }
34 |
35 | @SubscribeEvent public void guiOpen(GuiOpenEvent e) {
36 | replaceSplash(e.gui);
37 | }
38 |
39 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/EIOXpGrab.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.tileentity.TileEntity;
9 |
10 | public class EIOXpGrab extends CheatModule {
11 |
12 | public EIOXpGrab() {
13 | super("EIOXpGrab", Category.MODS, PerformMode.SINGLE);
14 | }
15 |
16 | private void sendGrab(TileEntity tile) {
17 | try {
18 | if (Class.forName("crazypants.enderio.machine.obelisk.xp.TileExperienceObelisk").isInstance(tile)) {
19 | utils.sendPacket("enderio", (byte) 69, utils.coords(tile), Short.MAX_VALUE);
20 | }
21 | } catch(Exception e) {}
22 | }
23 |
24 | @Override public void onPerform(PerformSource src) {
25 | utils.nearTiles().forEach(this::sendGrab);
26 | }
27 |
28 | @Override public boolean isWorking() {
29 | return Loader.isModLoaded("EnderIO");
30 | }
31 |
32 | @Override public String moduleDesc() {
33 | return lang.get("Drains experience from all experience obelisks in the radius", "Высасывает опыт из всех обелисков опыта в радиусе");
34 | }
35 |
36 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/utils/Keys.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.utils;
2 |
3 | import static org.lwjgl.input.Keyboard.*;
4 |
5 | import forgefuck.team.xenobyte.api.Xeno;
6 | import forgefuck.team.xenobyte.api.module.CheatModule;
7 | import net.minecraft.client.settings.KeyBinding;
8 |
9 | public class Keys {
10 |
11 | private static final boolean[] pressed = new boolean[256];
12 |
13 | private static boolean isPressed(int key) {
14 | return isKeyDown(key) != pressed[key] && (pressed[key] = !pressed[key]);
15 | }
16 |
17 | public static boolean isShiftDown() {
18 | return isKeyDown(KEY_LSHIFT) || isKeyDown(KEY_RSHIFT);
19 | }
20 |
21 | public static boolean isPressed(KeyBinding key) {
22 | return isKeyDown(key.getKeyCode());
23 | }
24 |
25 | public static boolean isPressed(CheatModule module) {
26 | if (isPressed(module.getKeyBind())) {
27 | return module.inGuiPerform() || Xeno.utils.isInGameGui();
28 | }
29 | return false;
30 | }
31 |
32 | public static boolean isAvalible(int key) {
33 | switch(key) {
34 | case KEY_NONE:
35 | case KEY_ESCAPE:
36 | case KEY_SYSRQ:
37 | case KEY_LSHIFT:
38 | case KEY_LCONTROL:
39 | case KEY_LMENU:
40 | case KEY_BACK:
41 | return false;
42 | }
43 | return true;
44 | }
45 |
46 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/RedBarrelGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.tileentity.TileEntity;
9 |
10 | public class RedBarrelGive extends CheatModule {
11 |
12 | public RedBarrelGive() {
13 | super("RedBarrelGive", Category.MODS, PerformMode.SINGLE);
14 | }
15 |
16 | @Override public void onPerform(PerformSource src) {
17 | TileEntity checkTile = utils.tile();
18 | try {
19 | if (Class.forName("mrtjp.projectred.exploration.TileBarrel").isInstance(checkTile)) {
20 | utils.sendPacket("MrTJPCoreMod", (byte) 1, utils.coords(checkTile), (byte) 2, giveSelector().givedItem(), giveSelector().fillAllSlots() ? Integer.MAX_VALUE : giveSelector().itemCount());
21 | }
22 | } catch(Exception e) {}
23 | }
24 |
25 | @Override public String moduleDesc() {
26 | return lang.get("Issuing an item to the Barrel (ProjectRed) which the player is looking at", "Выдача предмета в Бочку (ProjectRed) на которую смотрит игрок");
27 | }
28 |
29 | @Override public boolean isWorking() {
30 | return Loader.isModLoaded("ProjRed|Exploration");
31 | }
32 |
33 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/gui/click/elements/GuiWidget.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.gui.click.elements;
2 |
3 | import forgefuck.team.xenobyte.api.gui.ElementAligment;
4 | import forgefuck.team.xenobyte.api.gui.TextElement;
5 | import forgefuck.team.xenobyte.api.gui.WidgetMode;
6 | import forgefuck.team.xenobyte.render.Colors;
7 |
8 | public class GuiWidget extends TextElement {
9 |
10 | private static int indicatorWidth = 2;
11 | private ElementAligment aligment;
12 | private final int bgColor;
13 | private WidgetMode mode;
14 | public int delay;
15 |
16 | public GuiWidget(String text, WidgetMode mode, ElementAligment indicatorAligment, int bgColor, int delay) {
17 | super(text, indicatorAligment == ElementAligment.LEFT ? ElementAligment.RIGHT : ElementAligment.LEFT, indicatorWidth + (indicatorAligment == ElementAligment.LEFT ? 1 : 0), 0);
18 | this.aligment = indicatorAligment;
19 | this.bgColor = bgColor;
20 | this.delay = delay;
21 | this.mode = mode;
22 | }
23 |
24 | @Override public void draw() {
25 | render.GUI.drawRect(getX(), getY(), getMaxX(), getMaxY(), bgColor);
26 | int indicatorX = aligment == ElementAligment.LEFT ? getX() : getMaxX() - indicatorWidth;
27 | render.GUI.drawRect(indicatorX, getY(), indicatorX + indicatorWidth, getMaxY(), mode.getColor());
28 | render.GUI.xenoFont().drawString(getText(), getTextX(), getY(), Colors.WHITE);
29 | }
30 |
31 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/ExtraFakeSlot.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.tileentity.TileEntity;
9 |
10 | public class ExtraFakeSlot extends CheatModule {
11 |
12 | public ExtraFakeSlot() {
13 | super("ExtraFakeSlot", Category.MODS, PerformMode.SINGLE);
14 | }
15 |
16 | @Override public void onPerform(PerformSource src) {
17 | TileEntity checkTile = utils.tile();
18 | try {
19 | if (Class.forName("extracells.tileentity.TileEntityFluidFiller").isInstance(checkTile)) {
20 | utils.sendPacket("extracells", (byte) 8, (byte) 0, true, utils.worldId(), utils.myName().length(), utils.myName().getBytes(), utils.worldId(), utils.coords(checkTile), giveSelector().givedItem());
21 | }
22 | } catch(Exception e) {}
23 | }
24 |
25 | @Override public String moduleDesc() {
26 | return lang.get("Issuing a fake item into a liquid filler that the player is looking at", "Выдача фейк предмета в жидкостный заполнитель на который смотрит игрок");
27 | }
28 |
29 | @Override public boolean isWorking() {
30 | return Loader.isModLoaded("extracells");
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/FakeItem.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.config.Cfg;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
8 | import forgefuck.team.xenobyte.gui.click.elements.ScrollSlider;
9 | import net.minecraft.network.play.client.C09PacketHeldItemChange;
10 |
11 | public class FakeItem extends CheatModule {
12 |
13 | @Cfg("slot") private int slot;
14 |
15 | public FakeItem() {
16 | super("FakeItem", Category.PLAYER, PerformMode.TOGGLE);
17 | slot = 1;
18 | }
19 |
20 | @Override public void onTick(boolean inGame) {
21 | if (inGame) {
22 | utils.sendPacket(new C09PacketHeldItemChange(slot - 1));
23 | }
24 | }
25 |
26 | @Override public String moduleDesc() {
27 | return lang.get("Players will see an item from the specified slot in their hand", "Игроки будут видеть в руке предмет из заданного слота");
28 | }
29 |
30 | @Override public Panel settingPanel() {
31 | return new Panel(
32 | new ScrollSlider("Slot", slot, 9) {
33 | @Override public void onScroll(int dir, boolean withShift) {
34 | slot = processSlider(dir, withShift);
35 | }
36 | }
37 | );
38 | }
39 |
40 | }
41 |
--------------------------------------------------------------------------------
/loader/eloader/eloader.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio 15
4 | VisualStudioVersion = 15.0.27703.2026
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "eloader", "eloader\eloader.vcxproj", "{E9CC4995-F9F1-4DEE-B13E-DAAC69C92DE3}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|x64 = Debug|x64
11 | Debug|x86 = Debug|x86
12 | Release|x64 = Release|x64
13 | Release|x86 = Release|x86
14 | EndGlobalSection
15 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
16 | {E9CC4995-F9F1-4DEE-B13E-DAAC69C92DE3}.Debug|x64.ActiveCfg = Debug|x64
17 | {E9CC4995-F9F1-4DEE-B13E-DAAC69C92DE3}.Debug|x64.Build.0 = Debug|x64
18 | {E9CC4995-F9F1-4DEE-B13E-DAAC69C92DE3}.Debug|x86.ActiveCfg = Debug|Win32
19 | {E9CC4995-F9F1-4DEE-B13E-DAAC69C92DE3}.Debug|x86.Build.0 = Debug|Win32
20 | {E9CC4995-F9F1-4DEE-B13E-DAAC69C92DE3}.Release|x64.ActiveCfg = Release|x64
21 | {E9CC4995-F9F1-4DEE-B13E-DAAC69C92DE3}.Release|x64.Build.0 = Release|x64
22 | {E9CC4995-F9F1-4DEE-B13E-DAAC69C92DE3}.Release|x86.ActiveCfg = Release|Win32
23 | {E9CC4995-F9F1-4DEE-B13E-DAAC69C92DE3}.Release|x86.Build.0 = Release|Win32
24 | EndGlobalSection
25 | GlobalSection(SolutionProperties) = preSolution
26 | HideSolutionNode = FALSE
27 | EndGlobalSection
28 | GlobalSection(ExtensibilityGlobals) = postSolution
29 | SolutionGuid = {784D2A64-F494-4852-82CE-F8112027DA0F}
30 | EndGlobalSection
31 | EndGlobal
32 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/ShearDupe.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import net.minecraft.entity.Entity;
8 | import net.minecraft.item.ItemShears;
9 | import net.minecraft.item.ItemStack;
10 | import net.minecraft.network.play.client.C02PacketUseEntity;
11 | import net.minecraftforge.client.event.MouseEvent;
12 |
13 | public class ShearDupe extends CheatModule {
14 |
15 | public ShearDupe() {
16 | super("ShearDupe", Category.MISC, PerformMode.TOGGLE);
17 | }
18 |
19 | @SubscribeEvent public void mouseEvent(MouseEvent e) {
20 | if (e.button == 1 && e.buttonstate) {
21 | Entity ent = utils.entity();
22 | ItemStack handItem = utils.item();
23 | if (ent != null && !utils.isInCreative() && handItem != null && handItem.getItem() instanceof ItemShears) {
24 | for (int i = 0; i < 2000; i++) {
25 | utils.sendPacket(new C02PacketUseEntity(ent, C02PacketUseEntity.Action.INTERACT));
26 | }
27 | }
28 | }
29 | }
30 |
31 | @Override public String moduleDesc() {
32 | return lang.get("Dupe cows and mushrooms (right click with scissors on a mushroom cow)", "Дюп коров и грибов (ПКМ ножницами по грибной корове)");
33 | }
34 |
35 | }
36 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/CreativeGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.config.Cfg;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import forgefuck.team.xenobyte.gui.click.elements.Button;
9 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
10 |
11 | public class CreativeGive extends CheatModule {
12 |
13 | @Cfg("drop") boolean drop;
14 |
15 | public CreativeGive() {
16 | super("CreativeGive", Category.PLAYER, PerformMode.SINGLE);
17 | }
18 |
19 | @Override public void onPerform(PerformSource src) {
20 | utils.creativeGive(drop ? -1 : utils.activeSlot(), giveSelector().givedItem());
21 | }
22 |
23 | @Override public String moduleDesc() {
24 | return lang.get("Issuing an item (only in creative)", "Выдача предмета (только в креативе)");
25 | }
26 |
27 | @Override public Panel settingPanel() {
28 | return new Panel(
29 | new Button("DropItem", drop) {
30 | @Override public void onLeftClick() {
31 | buttonValue(drop = !drop);
32 | }
33 | @Override public String elementDesc() {
34 | return lang.get("Drop item, or in active slot", "Выбрасывание предмета, или в активный слот");
35 | }
36 | }
37 | );
38 | }
39 |
40 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/Rocket.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.config.Cfg;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
9 | import forgefuck.team.xenobyte.gui.click.elements.ScrollSlider;
10 |
11 | public class Rocket extends CheatModule {
12 |
13 | @Cfg("strength") private int strength;
14 | public Rocket() {
15 | super("Rocket", Category.MOVE, PerformMode.SINGLE);
16 | strength = 2;
17 | }
18 |
19 | @Override public void onPerform(PerformSource src) {
20 | this.utils.player().addVelocity(0.0d, strength * 0.5d, 0.0d);
21 | }
22 |
23 | @Override public String moduleDesc() {
24 | return lang.get("Acceleration to the sky", "Ускорение в небо");
25 | }
26 |
27 | @Override public Panel settingPanel() {
28 | return new Panel(
29 | new ScrollSlider("Strength", strength, 30) {
30 | @Override public void onScroll(int dir, boolean withShift) {
31 | strength = processSlider(dir, withShift);
32 | }
33 | @Override public String elementDesc() {
34 | return lang.get("Acceleration amount", "Величина ускорения");
35 | }
36 | }
37 | );
38 | }
39 |
40 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/NanoTechGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.tileentity.TileEntity;
9 | import net.minecraft.tileentity.TileEntityChest;
10 |
11 | public class NanoTechGive extends CheatModule {
12 |
13 | public NanoTechGive() {
14 | super("NanoTechGive", Category.MODS, PerformMode.SINGLE);
15 | }
16 |
17 | @Override public void onPerform(PerformSource src) {
18 | TileEntity checkTile = utils.tile();
19 | if (checkTile instanceof TileEntityChest) {
20 | try {
21 | Class yogpstop = Class.forName("com.yogpc.qp.YogpstopPacket");
22 | Class.forName("com.yogpc.qp.PacketHandler").getMethod("sendPacketToServer", yogpstop).invoke(null, yogpstop.getConstructor(TileEntity.class).newInstance(utils.tile(checkTile, utils.chestGiveHelper((TileEntityChest) checkTile, giveSelector()))));
23 | } catch(Exception e) {}
24 | }
25 | }
26 |
27 | @Override public String moduleDesc() {
28 | return lang.get("Item give into a vanilla chest that the player is looking at", "Выдача предмета в обычный сундук на который смотрит игрок");
29 | }
30 |
31 | @Override public boolean isWorking() {
32 | return Loader.isModLoaded("NanoTech_Machine");
33 | }
34 |
35 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/gui/click/elements/ScrollSlider.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.gui.click.elements;
2 |
3 | import forgefuck.team.xenobyte.render.Colors;
4 | import forgefuck.team.xenobyte.utils.Delimitter;
5 |
6 | public class ScrollSlider extends Button {
7 |
8 | private int processed, shiftFactor, indent;
9 | private Delimitter counter;
10 |
11 | public ScrollSlider(String text, int value, int max) {
12 | this(text, value, 1, max);
13 | }
14 |
15 | public ScrollSlider(String text, int value, int min, int max) {
16 | this(text, value, min, max, 6);
17 | }
18 |
19 | public ScrollSlider(String text, int value, int min, int max, int indent) {
20 | super(text, value);
21 | shiftFactor = (int)Math.ceil((float)(max - min) / 10);
22 | counter = new Delimitter(value, min, max);
23 | this.indent = indent < 0 ? 0 : indent;
24 | processSlider(0, false);
25 | }
26 |
27 | public int processSlider(int step, boolean withShift) {
28 | buttonValue(processed = counter.calc(withShift ? step * shiftFactor : step));
29 | return processed;
30 | }
31 |
32 | public int getSliderX() {
33 | return getX() + indent + (int)((float) processed * ((float) (getWidth() - indent * 2) / (float) counter.getMax()));
34 | }
35 |
36 | @Override public void playClick() {}
37 |
38 | @Override public void onDraw() {
39 | super.onDraw();
40 | render.GUI.drawRect(getX() + indent, getY() + getHeight() - 1, getSliderX(), getMaxY(), Colors.ORANGE);
41 | }
42 |
43 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/TextElement.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | public abstract class TextElement extends GuiElement {
4 |
5 | private ElementAligment aligment;
6 | private int indentX, indentY;
7 | private String text;
8 |
9 | public TextElement(String text) {
10 | this(text, ElementAligment.CENTER);
11 | }
12 |
13 | public TextElement(String text, ElementAligment aligment) {
14 | this(text, aligment, 0, 0);
15 | }
16 |
17 | public TextElement(String text, ElementAligment aligment, int indentX, int indentY) {
18 | this.aligment = aligment;
19 | this.indentX = indentX;
20 | this.indentY = indentY;
21 | setText(text);
22 | }
23 |
24 | public void setText(String text) {
25 | setWidth(render.GUI.xenoFont().textWidth(text) + indentX);
26 | setHeight(render.GUI.xenoFont().fontHeight() + indentY);
27 | this.text = text;
28 | }
29 |
30 | public String getText() {
31 | return text;
32 | }
33 |
34 | protected int getTextY() {
35 | return getY() + indentY / 2;
36 | }
37 |
38 | protected int getTextX() {
39 | return getTextX(text);
40 | }
41 |
42 | protected int getTextX(String in) {
43 | switch (aligment) {
44 | case CENTER:
45 | return getX() + (getWidth() - render.GUI.xenoFont().textWidth(in)) / 2;
46 | case RIGHT:
47 | return getX() + (getWidth() - render.GUI.xenoFont().textWidth(in));
48 | default:
49 | return getX();
50 | }
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/BobbingControl.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.eventhandler.EventPriority;
4 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
5 | import forgefuck.team.xenobyte.api.module.Category;
6 | import forgefuck.team.xenobyte.api.module.CheatModule;
7 | import forgefuck.team.xenobyte.api.module.PerformMode;
8 | import net.minecraftforge.client.event.RenderWorldLastEvent;
9 |
10 | public class BobbingControl extends CheatModule {
11 |
12 | private PortalHelper phelper;
13 | private XRay xray;
14 | private Esp esp;
15 |
16 | public BobbingControl() {
17 | super("BobbingControl", Category.NONE, PerformMode.ENABLED_ON_START);
18 | }
19 |
20 | @Override public boolean isWidgetable() {
21 | return false;
22 | }
23 |
24 | @Override public void onPostInit() {
25 | phelper = (PortalHelper) moduleHandler().getModuleByClass(PortalHelper.class);
26 | xray = (XRay) moduleHandler().getModuleByClass(XRay.class);
27 | esp = (Esp) moduleHandler().getModuleByClass(Esp.class);
28 | }
29 |
30 | @SubscribeEvent(priority = EventPriority.HIGHEST) public void renderWorld(RenderWorldLastEvent e) {
31 | phelper.linesCheck = false;
32 | xray.linesCheck = false;
33 | esp.linesCheck = false;
34 | }
35 |
36 | @SubscribeEvent(priority = EventPriority.LOWEST) public void renderWorldL(RenderWorldLastEvent e) {
37 | utils.mc().gameSettings.viewBobbing = (!xray.linesCheck || !xray.bindLines) && (!esp.linesCheck || !esp.bindLines) && !phelper.linesCheck;
38 | }
39 |
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/handlers/PacketHandler.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.handlers;
2 |
3 | import forgefuck.team.xenobyte.api.Xeno;
4 | import forgefuck.team.xenobyte.utils.Rand;
5 | import io.netty.channel.ChannelDuplexHandler;
6 | import io.netty.channel.ChannelHandlerContext;
7 | import io.netty.channel.ChannelPromise;
8 | import net.minecraft.client.network.NetHandlerPlayClient;
9 | import net.minecraft.network.Packet;
10 |
11 | public class PacketHandler {
12 |
13 | public PacketHandler(ModuleHandler handler, NetHandlerPlayClient clientHandler) {
14 | if (handler != null && clientHandler != null) {
15 | clientHandler.getNetworkManager().channel().pipeline().addBefore("packet_handler", Rand.str(), new ChannelDuplexHandler() {
16 | @Override public void channelRead(ChannelHandlerContext ctx, Object in) throws Exception {
17 | if (handler.enabledModules().allMatch(m -> m.doReceivePacket((Packet) in))) {
18 | super.channelRead(ctx, in);
19 | }
20 | }
21 | @Override public void write(ChannelHandlerContext ctx, Object out, ChannelPromise pr) throws Exception {
22 | if (handler.enabledModules().allMatch(m -> m.doSendPacket((Packet) out))) {
23 | super.write(ctx, out, pr);
24 | }
25 | }
26 | @Override public void handlerAdded(ChannelHandlerContext ctx) throws Exception {
27 | Xeno.logger.info("XenoPacketHandler registered: " + ctx.name());
28 | }
29 | });
30 | }
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/Step.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.config.Cfg;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
8 | import forgefuck.team.xenobyte.gui.click.elements.ScrollSlider;
9 |
10 | public class Step extends CheatModule {
11 |
12 | @Cfg("stepHeight") private int stepHeight;
13 |
14 | public Step() {
15 | super("Step", Category.MOVE, PerformMode.TOGGLE);
16 | stepHeight = 5;
17 | }
18 |
19 | @Override public void onTick(boolean inGame) {
20 | if (inGame) {
21 | utils.player().stepHeight = stepHeight;
22 | }
23 | }
24 |
25 | @Override public void onDisabled() {
26 | utils.player().stepHeight = 0.5F;
27 | }
28 |
29 | @Override public String moduleDesc() {
30 | return lang.get("High step a given number of blocks", "Мгновенное взбирание на заданное количество блоков");
31 | }
32 |
33 | @Override public Panel settingPanel() {
34 | return new Panel(
35 | new ScrollSlider("Height", stepHeight, 30) {
36 | @Override public void onScroll(int dir, boolean withShift) {
37 | stepHeight = processSlider(dir, withShift);
38 | }
39 | @Override public String elementDesc() {
40 | return lang.get("Step height", "Высота взбирания");
41 | }
42 | }
43 | );
44 | }
45 |
46 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/TextRadar.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.gui.WidgetMode;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import net.minecraft.entity.player.EntityPlayer;
8 |
9 | public class TextRadar extends CheatModule {
10 |
11 | public TextRadar() {
12 | super("TextRadar", Category.MISC, PerformMode.TOGGLE);
13 | }
14 |
15 | @Override public int tickDelay() {
16 | return 10;
17 | }
18 |
19 | @Override public void onTick(boolean inGame) {
20 | if (inGame) {
21 | int[] my = utils.myCoords();
22 | StringBuilder out = new StringBuilder();
23 | utils.nearEntityes(200)
24 | .filter(e -> e instanceof EntityPlayer && !e.isDead)
25 | .forEach(e -> {
26 | int[] pl = utils.coords(e);
27 | int dist = (int)Math.sqrt((my[0] - pl[0])*(my[0] - pl[0]) + (my[1] - pl[1])*(my[1] - pl[1]) + (my[2] - pl[2])*(my[2] - pl[2]));
28 | out.append("[" + utils.name(e) + " " + dist + "]");
29 | });
30 | boolean empty = out.length() == 0;
31 | infoMessage(empty ? lang.get("nobody", "пусто") : out.toString(), empty ? WidgetMode.SUCCESS : WidgetMode.FAIL);
32 | }
33 | }
34 |
35 | @Override public String moduleDesc() {
36 | return lang.get("Displays the nearest players and the distance to them on the info panel", "Выводит на инфопанель ближайших игроков и расстояние до них");
37 | }
38 |
39 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/CrayfishGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.init.Items;
9 | import net.minecraft.item.ItemStack;
10 | import net.minecraft.nbt.NBTTagCompound;
11 | import net.minecraft.nbt.NBTTagList;
12 |
13 | public class CrayfishGive extends CheatModule {
14 |
15 | public CrayfishGive() {
16 | super("CrayfishGive", Category.MODS, PerformMode.SINGLE);
17 | }
18 |
19 | @Override public void onPerform(PerformSource src) {
20 | ItemStack outStack = new ItemStack(Items.apple);
21 | NBTTagCompound root = new NBTTagCompound();
22 | NBTTagCompound pack = new NBTTagCompound();
23 | NBTTagList list = new NBTTagList();
24 | for (int i = 0; i < (giveSelector().fillAllSlots() ? 6 : 1); i++) {
25 | list.appendTag(utils.nbtItem(giveSelector().givedItem(), i, "Slot"));
26 | }
27 | pack.setTag("Items", list);
28 | root.setTag("Package", pack);
29 | outStack.setTagCompound(root);
30 | utils.sendPacket("cfm", (byte) 10, outStack);
31 | }
32 |
33 | @Override public String moduleDesc() {
34 | return lang.get("Issuing an item in a package to the active slot (will replace the current item)", "Выдача предмета в посылке в активный слот (заменит текущий предмет)");
35 | }
36 |
37 | @Override public boolean isWorking() {
38 | return Loader.isModLoaded("cfm");
39 | }
40 |
41 | }
--------------------------------------------------------------------------------
/appveyor.yml:
--------------------------------------------------------------------------------
1 | version: 1.0.{build}
2 | image: Visual Studio 2017
3 | build_script:
4 | - cmd: >-
5 | gradlew build
6 |
7 | IF NOT EXIST build\libs\xenobyte-1.0.0.jar exit 1
8 |
9 | IF EXIST loader\xenobyte-1.0.0.jar del /F /Q loader\xenobyte-1.0.0.jar
10 |
11 | copy build\libs\xenobyte-1.0.0.jar loader\xenobyte-1.0.0.jar
12 |
13 | cd loader
14 |
15 | IF EXIST classes.h del /F /Q classes.h
16 |
17 | java -jar packer.jar xenobyte-1.0.0.jar
18 |
19 | IF EXIST eloader\eloader\classes.h del /F /Q eloader\eloader\classes.h
20 |
21 | copy classes.h eloader\eloader\classes.h
22 |
23 | cd eloader
24 |
25 | msbuild eloader.sln /p:Configuration=Release /p:Platform=x86 /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
26 |
27 | msbuild eloader.sln /p:Configuration=Release /p:Platform=x64 /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
28 |
29 | cd ..\..
30 |
31 | IF EXIST output-total rmdir /S /Q output-total
32 |
33 | mkdir output-total
34 |
35 | copy build\libs\xenobyte-1.0.0.jar output-total\xenobyte.jar
36 |
37 | copy loader\eloader\output\Release\xenobyte.x32.dll output-total\xenobyte.x32.dll
38 |
39 | copy loader\eloader\output\Release\xenobyte.x64.dll output-total\xenobyte.x64.dll
40 |
41 | zip -z output-total\xenobyte.jar commands;
19 |
20 | public ChatBind() {
21 | super("ChatBind", Category.MISC, PerformMode.SINGLE);
22 | commands = new ArrayList();
23 | commands.add("/home");
24 | }
25 |
26 | @Override public void onPerform(PerformSource src) {
27 | commands.forEach(utils::serverChatMessage);
28 | }
29 |
30 | @Override public String moduleDesc() {
31 | return lang.get("Execution of the set commands by keybind", "Выполнение заданных команд по кейбинду");
32 | }
33 |
34 | @Override public Panel settingPanel() {
35 | return new Panel(
36 | new Button("Commands") {
37 | @Override public void onLeftClick() {
38 | new UserInput(lang.get("Commands", "Команды"), commands, InputType.CUSTOM).showFrame();
39 | }
40 | @Override public String elementDesc() {
41 | return lang.get("Command list", "Список команд");
42 | }
43 | }
44 | );
45 | }
46 |
47 | }
48 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/BiblioAtlasGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.item.ItemStack;
9 | import net.minecraft.nbt.NBTTagCompound;
10 | import net.minecraft.nbt.NBTTagList;
11 |
12 | public class BiblioAtlasGive extends CheatModule {
13 |
14 | public BiblioAtlasGive() {
15 | super("BiblioAtlasGive", Category.MODS, PerformMode.SINGLE);
16 | }
17 |
18 | @Override public void onPerform(PerformSource src) {
19 | ItemStack ckeckItem = utils.item();
20 | try {
21 | if (Class.forName("jds.bibliocraft.items.ItemAtlas").isInstance(ckeckItem.getItem())) {
22 | NBTTagCompound root = new NBTTagCompound();
23 | NBTTagList list = new NBTTagList();
24 | for (int i = 0; i < (giveSelector().fillAllSlots() ? 48 : 1); i++) {
25 | list.appendTag(utils.nbtItem(giveSelector().givedItem(), i, "Slot"));
26 | }
27 | root.setTag("Inventory", list);
28 | utils.sendPacket("BiblioAtlasSWP", utils.item(ckeckItem, root));
29 | }
30 | } catch(Exception e) {}
31 | }
32 |
33 | @Override public String moduleDesc() {
34 | return lang.get("Issuing an item to the Atlas in hand (to re-give you need to craft a new atlas)", "Выдача предмета в Атлас находящийся в руке (для повторного гива нужно скрафтить новый атлас)");
35 | }
36 |
37 | @Override public boolean isWorking() {
38 | return Loader.isModLoaded("BiblioCraft");
39 | }
40 |
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/BuildMarkerGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import io.netty.buffer.ByteBuf;
9 | import net.minecraft.item.ItemStack;
10 | import net.minecraft.tileentity.TileEntity;
11 |
12 | public class BuildMarkerGive extends CheatModule {
13 |
14 | public BuildMarkerGive() {
15 | super("BuildMarkerGive", Category.MODS, PerformMode.SINGLE);
16 | }
17 |
18 | @Override public void onPerform(PerformSource src) {
19 | TileEntity checkTile = utils.tile();
20 | try {
21 | if (Class.forName("buildcraft.builders.TileConstructionMarker").isInstance(checkTile)) {
22 | int x = checkTile.xCoord;
23 | int y = checkTile.yCoord;
24 | int z = checkTile.zCoord;
25 | ByteBuf buf = utils.bufWriter((short)0, x, (short)y, z, (byte)0, x, (short)y, z, x, (short)y, z, (byte)2);
26 | Class.forName("buildcraft.core.lib.utils.NetworkUtils").getMethod("writeStack", ByteBuf.class, ItemStack.class).invoke(null, buf, giveSelector().givedItem());
27 | utils.sendPacket("BC-CORE", buf);
28 | }
29 | } catch(Exception e) {}
30 | }
31 |
32 | @Override public String moduleDesc() {
33 | return lang.get("Issuing an item to the Construction Marker that the player is looking at", "Выдача предмета в Строительную Метку на которую смотрит игрок");
34 | }
35 |
36 | @Override public boolean isWorking() {
37 | return Loader.isModLoaded("BuildCraft|Builders");
38 | }
39 |
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/MatterGiveItem.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.nbt.NBTTagCompound;
9 | import net.minecraft.nbt.NBTTagList;
10 | import net.minecraft.tileentity.TileEntity;
11 |
12 | public class MatterGiveItem extends CheatModule {
13 |
14 | public MatterGiveItem() {
15 | super("MatterGiveItem", Category.MODS, PerformMode.SINGLE);
16 | }
17 |
18 | @Override public void onPerform(PerformSource src) {
19 | TileEntity checkTile = utils.tile();
20 | try {
21 | if (Class.forName("matteroverdrive.tile.TileEntityTritaniumCrate").isInstance(checkTile)) {
22 | NBTTagCompound root = new NBTTagCompound();
23 | NBTTagList list = new NBTTagList();
24 | int slots = giveSelector().fillAllSlots() ? utils.slots(checkTile) : 1;
25 | for (int i = 0; i < slots; i++) {
26 | list.appendTag(utils.nbtItem(giveSelector().givedItem(), i, "Slot"));
27 | }
28 | root.setTag("Items", list);
29 | utils.sendPacket("mo_channel", (byte) 24, utils.coords(checkTile), root, 4, true);
30 | }
31 | } catch(Exception e) {}
32 | }
33 |
34 | @Override public String moduleDesc() {
35 | return lang.get("Issuing an item to the Tritanium Crate that the player is looking at", "Выдача предмета в Тритановый Ящик на который смотрит игрок");
36 | }
37 |
38 | @Override public boolean isWorking() {
39 | return Loader.isModLoaded("mo");
40 | }
41 |
42 | }
43 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/OneWayTicket.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.entity.player.EntityPlayer;
9 | import net.minecraft.item.ItemStack;
10 | import net.minecraft.nbt.NBTTagCompound;
11 |
12 | public class OneWayTicket extends CheatModule {
13 |
14 | public OneWayTicket() {
15 | super("OneWayTicket", Category.MODS, PerformMode.SINGLE);
16 | }
17 |
18 | @Override public void onPerform(PerformSource src) {
19 | ItemStack ckeckItem = utils.item();
20 | try {
21 | if (Class.forName("mods.railcraft.common.util.network.IEditableItem").isInstance(ckeckItem.getItem())) {
22 | NBTTagCompound nbt = giveSelector().givedNBT();
23 | if (!nbt.hasNoTags()) {
24 | Class.forName("mods.railcraft.common.util.network.PacketDispatcher").getMethod("sendToServer", Class.forName("mods.railcraft.common.util.network.RailcraftPacket")).invoke(null, Class.forName("mods.railcraft.common.util.network.PacketCurrentItemNBT").getConstructor(EntityPlayer.class, ItemStack.class).newInstance(utils.player(), utils.item(ckeckItem, nbt)));
25 | }
26 | }
27 | } catch(Exception e) {}
28 | }
29 |
30 | @Override public String moduleDesc() {
31 | return lang.get("Applying NBT from Chanter to a Ticket or Routing Table in hand", "Применение NBT из Chanter'a к Билету или Таблице Маршрутизации находящейся в руке");
32 | }
33 |
34 | @Override public boolean isWorking() {
35 | return Loader.isModLoaded("Railcraft");
36 | }
37 |
38 | }
39 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/HiJump.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.config.Cfg;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
8 | import forgefuck.team.xenobyte.gui.click.elements.ScrollSlider;
9 | import forgefuck.team.xenobyte.utils.TickHelper;
10 | import net.minecraft.potion.Potion;
11 | import net.minecraft.potion.PotionEffect;
12 |
13 | public class HiJump extends CheatModule {
14 |
15 | @Cfg("power") private int power;
16 |
17 | public HiJump() {
18 | super("HiJump", Category.MOVE, PerformMode.TOGGLE);
19 | power = 5;
20 | }
21 |
22 | private void removePotion() {
23 | utils.player().removePotionEffect(Potion.jump.getId());
24 | }
25 |
26 | @Override public void onDisabled() {
27 | removePotion();
28 | }
29 |
30 | @Override public int tickDelay() {
31 | return TickHelper.ONE_SEC;
32 | }
33 |
34 | @Override public void onTick(boolean inGame) {
35 | if (inGame) {
36 | removePotion();
37 | utils.player().addPotionEffect(new PotionEffect(Potion.jump.getId(), Integer.MAX_VALUE, power));
38 | }
39 | }
40 |
41 | @Override public String moduleDesc() {
42 | return lang.get("Jump with a given power", "Прыжок с заданной мощностью");
43 | }
44 |
45 | @Override public Panel settingPanel() {
46 | return new Panel(
47 | new ScrollSlider("Power", power, 20) {
48 | @Override public void onScroll(int dir, boolean withShift) {
49 | power = processSlider(dir, withShift);
50 | }
51 | }
52 | );
53 | }
54 |
55 | }
56 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/render/XRayHintRender.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.render;
2 |
3 | import org.lwjgl.opengl.GL11;
4 |
5 | import forgefuck.team.xenobyte.api.Xeno;
6 | import forgefuck.team.xenobyte.modules.XRaySelect;
7 | import forgefuck.team.xenobyte.modules.XRaySelect.SelectedBlock;
8 | import net.minecraft.client.renderer.RenderHelper;
9 | import net.minecraft.client.renderer.entity.RenderItem;
10 | import net.minecraft.item.ItemStack;
11 | import net.minecraftforge.client.IItemRenderer;
12 |
13 | public class XRayHintRender implements IItemRenderer {
14 |
15 | private RenderItem itemRender;
16 | private XRaySelect selector;
17 | private SelectedBlock block;
18 |
19 | public XRayHintRender(XRaySelect selector) {
20 | this.itemRender = new RenderItem();
21 | this.selector = selector;
22 | }
23 |
24 | @Override public boolean handleRenderType(ItemStack item, ItemRenderType type) {
25 | block = selector.getBlock(item);
26 | return block != null && selector.guiHint && type == ItemRenderType.INVENTORY;
27 | }
28 |
29 | @Override public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) {
30 | return false;
31 | }
32 |
33 | @Override public void renderItem(ItemRenderType type, ItemStack item, Object ... data) {
34 | GL11.glPushMatrix();
35 | if (block.hidden) {
36 | Xeno.render.GUI.drawRect(0, 14, 8, 16, Colors.RED);
37 | }
38 | if (block.tracer) {
39 | Xeno.render.GUI.drawRect(8, 14, 16, 16, Colors.SKY);
40 | }
41 | Xeno.render.GUI.drawBorderRect(1, 1, 15, 15, 1, Colors.TRANSPARENT, block.rgb);
42 | RenderHelper.enableGUIStandardItemLighting();
43 | RenderItem.getInstance().renderItemIntoGUI(Xeno.utils.mc().fontRenderer, Xeno.utils.mc().getTextureManager(), item, 0, 0);
44 | GL11.glPopMatrix();
45 | }
46 |
47 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/ElementAbility.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | import forgefuck.team.xenobyte.api.Xeno;
4 |
5 | public abstract class ElementAbility implements Xeno {
6 |
7 | /**
8 | * Called when an element is initialized
9 | */
10 | public void onInit() {}
11 |
12 | /**
13 | * Rendering an element
14 | */
15 | public void onDraw() {}
16 |
17 | /**
18 | * Called when an item is added to the render list
19 | */
20 | public void onShow() {}
21 |
22 | /**
23 | * Called when an item is removed from the render list
24 | */
25 | public void onHide() {}
26 |
27 | /**
28 | * Called when hovering over an element
29 | */
30 | public void onHovered() {}
31 |
32 | /**
33 | * Called by clicking the left mouse button on an element
34 | */
35 | public void onLeftClick() {}
36 |
37 | /**
38 | * Called when the cursor leaves the element
39 | */
40 | public void onDishovered() {}
41 |
42 | /**
43 | * Called by right-clicking on an element
44 | */
45 | public void onRightClick() {}
46 |
47 | /**
48 | * Called by clicking the mouse wheel mouse button on an element
49 | */
50 | public void onScrollClick() {}
51 |
52 | /**
53 | * Called when a key is pressed on the focused element
54 | * @param symb char
55 | * @param key int code
56 | */
57 | public void onKeyTyped(char symb, int key) {}
58 |
59 | /**
60 | * Called when scrolling on the element with focus
61 | * @param dir int direction: 1 mw down, -1 mw up
62 | * @param withShift
63 | */
64 | public void onScroll(int dir, boolean withShift) {}
65 |
66 | /**
67 | * Description of the element for the tooltip
68 | * @return String
69 | */
70 | public String elementDesc() {
71 | return null;
72 | }
73 |
74 | }
75 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/ClientSpeed.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.config.Cfg;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
8 | import forgefuck.team.xenobyte.gui.click.elements.ScrollSlider;
9 | import forgefuck.team.xenobyte.utils.Reflections;
10 | import net.minecraft.client.Minecraft;
11 | import net.minecraft.util.Timer;
12 |
13 | public class ClientSpeed extends CheatModule {
14 |
15 | @Cfg("tickRate") private int tickRate;
16 | private Timer vanilaTimer;
17 |
18 | public ClientSpeed() {
19 | super("ClientSpeed", Category.PLAYER, PerformMode.TOGGLE);
20 | tickRate = 5;
21 | }
22 |
23 | @Override public void onPostInit() {
24 | vanilaTimer = Reflections.getPrivateValue(Minecraft.class, utils.mc(), 16);
25 | }
26 |
27 | @Override public void onDisabled() {
28 | vanilaTimer.timerSpeed = 1;
29 | }
30 |
31 | @Override public void onTick(boolean inGame) {
32 | if (inGame) {
33 | vanilaTimer.timerSpeed = tickRate;
34 | }
35 | }
36 |
37 | @Override public String moduleDesc() {
38 | return lang.get("Changing the speed of client ticks", "Изменение скорости клиентских тиков");
39 | }
40 |
41 | @Override public Panel settingPanel() {
42 | return new Panel(
43 | new ScrollSlider("TickRate", tickRate, 20) {
44 | @Override public void onScroll(int dir, boolean withShift) {
45 | tickRate = processSlider(dir, withShift);
46 | }
47 | @Override public String elementDesc() {
48 | return lang.get("Tick modifier", "Модификатор частоты тиков");
49 | }
50 | }
51 | );
52 | }
53 |
54 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/render/GuiRender.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.render;
2 |
3 | import forgefuck.team.xenobyte.api.Xeno;
4 | import net.minecraft.client.gui.FontRenderer;
5 | import net.minecraft.client.gui.Gui;
6 |
7 | public class GuiRender extends Gui {
8 |
9 | private XenoFont xenoFont;
10 |
11 | public GuiRender() {
12 | xenoFont = new XenoFont();
13 | }
14 |
15 | public FontRenderer mcFont() {
16 | return Xeno.utils.mc().fontRenderer;
17 | }
18 |
19 | public XenoFont xenoFont() {
20 | return xenoFont;
21 | }
22 |
23 | public void drawGradientRect(int x, int y, int xMax, int yMax, int col1, int col2) {
24 | super.drawGradientRect(x, y, xMax, yMax, col1, col2);
25 | }
26 |
27 | public void drawBorderRect(int x, int y, int xMax, int yMax, int borderSize, int rectColor, int borderColor) {
28 | super.drawRect(x, y, xMax, yMax, rectColor);
29 | super.drawRect(x - borderSize, y - borderSize, xMax + borderSize, y, borderColor);
30 | super.drawRect(x - borderSize, yMax, xMax + borderSize, yMax + borderSize, borderColor);
31 | super.drawRect(x - borderSize, y, x, yMax, borderColor);
32 | super.drawRect(xMax, y, xMax + borderSize, yMax, borderColor);
33 | }
34 |
35 | public void drawDesc(String text) {
36 | int width = xenoFont().textWidth(text);
37 | int height = xenoFont().fontHeight();
38 | int xStart = GuiScaler.mouseX() - 6;
39 | int yStart = GuiScaler.mouseY() - 16;
40 | xStart = xStart + width + 10 >= GuiScaler.scaledScreenWidth() ? GuiScaler.scaledScreenWidth() - width - 10 : xStart;
41 | yStart = yStart <= 10 ? 10 : yStart;
42 | drawRect(xStart + 4, yStart + 4, xStart + width + 4, yStart + height + 4, Colors.TRANSPARENT_DARK);
43 | drawBorderRect(xStart, yStart, xStart + width, yStart + height, 1, Colors.BLACK, Colors.ORANGE);
44 | xenoFont().drawString(text, xStart, yStart, Colors.WHITE);
45 | }
46 |
47 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/NCPanelEdit.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import java.util.Map;
4 |
5 | import cpw.mods.fml.common.Loader;
6 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
7 | import forgefuck.team.xenobyte.api.module.Category;
8 | import forgefuck.team.xenobyte.api.module.CheatModule;
9 | import forgefuck.team.xenobyte.api.module.PerformMode;
10 | import net.minecraft.client.gui.GuiScreen;
11 | import net.minecraft.entity.player.EntityPlayer;
12 | import net.minecraft.tileentity.TileEntity;
13 | import net.minecraftforge.client.event.MouseEvent;
14 |
15 | public class NCPanelEdit extends CheatModule {
16 |
17 | public NCPanelEdit() {
18 | super("NCPanelEdit", Category.MODS, PerformMode.TOGGLE);
19 | }
20 |
21 | @SubscribeEvent public void mouseEvent(MouseEvent e) {
22 | if (e.button == 1 && e.buttonstate) {
23 | TileEntity checkTile = utils.tile();
24 | try {
25 | Map blocks = (Map) Class.forName("shedar.mods.ic2.nuclearcontrol.blocks.BlockNuclearControlMain").getDeclaredField("subblocks").get(null);
26 | for (Object block : blocks.values()) {
27 | if (block.getClass().getMethod("getTileEntity").invoke(block).getClass().isInstance(checkTile)) {
28 | utils.openGui((GuiScreen) block.getClass().getMethod("getClientGuiElement", TileEntity.class, EntityPlayer.class).invoke(block, checkTile, utils.player()));
29 | e.setCanceled(true);
30 | break;
31 | }
32 | }
33 | } catch (Exception ex) {}
34 | }
35 | }
36 |
37 | @Override public String moduleDesc() {
38 | return lang.get("Opener of blocks from IC2NuclearControl in clamed area by right click", "Открывашка блоков из IC2NuclearControl в привате по ПКМ");
39 | }
40 |
41 | @Override public boolean isWorking() {
42 | return Loader.isModLoaded("IC2NuclearControl");
43 | }
44 |
45 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/Spider.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.config.Cfg;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
8 | import forgefuck.team.xenobyte.gui.click.elements.ScrollSlider;
9 | import forgefuck.team.xenobyte.utils.Keys;
10 |
11 | public class Spider extends CheatModule {
12 |
13 | @Cfg("vSpeed") private float vSpeed;
14 | private boolean spiding = false;
15 |
16 | public Spider() {
17 | super("Spider", Category.MOVE, PerformMode.TOGGLE);
18 | vSpeed = 1F;
19 | }
20 |
21 | @Override public void onTick(boolean inGame) {
22 | if (inGame && utils.player().isCollidedHorizontally && (Keys.isPressed(utils.mc().gameSettings.keyBindForward) || Keys.isPressed(utils.mc().gameSettings.keyBindBack) || Keys.isPressed(utils.mc().gameSettings.keyBindLeft) || Keys.isPressed(utils.mc().gameSettings.keyBindRight))) {
23 | utils.player().motionY = vSpeed;
24 | spiding = true;
25 | } else if(inGame && spiding) {
26 | utils.player().motionY = Math.min(0.4F, vSpeed);
27 | spiding = false;
28 | }
29 | }
30 |
31 | @Override public String moduleDesc() {
32 | return lang.get("Climbing the walls", "Лазание по стенам");
33 | }
34 |
35 | @Override public Panel settingPanel() {
36 | return new Panel(
37 | new ScrollSlider("Speed", (int) (vSpeed * 10), 30) {
38 | @Override public void onScroll(int dir, boolean withShift) {
39 | vSpeed = (float) processSlider(dir, withShift) / 10;
40 | }
41 | @Override public String elementDesc() {
42 | return lang.get("Climbing speed", "Cкорость взбирания");
43 | }
44 | }
45 | );
46 | }
47 |
48 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/FTBSatchelDupe.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.item.ItemStack;
9 | import net.minecraft.nbt.NBTTagCompound;
10 |
11 | public class FTBSatchelDupe extends CheatModule{
12 |
13 | public FTBSatchelDupe() {
14 | super("FTBSatchelDupe", Category.MODS, PerformMode.SINGLE);
15 | }
16 |
17 | @Override public void onPerform(PerformSource src) {
18 | try {
19 | if (Class.forName("cofh.thermalexpansion.gui.container.ContainerSatchel").isInstance(utils.player().openContainer)) {
20 | Class.forName("ftb.lib.api.net.MessageLM").getMethod("sendToServer").invoke(Class.forName("ftb.lib.mod.net.MessageClientItemAction").getConstructor(String.class, NBTTagCompound.class).newInstance("", new NBTTagCompound()));
21 | int dropCount = (int) Class.forName("cofh.thermalexpansion.item.ItemSatchel").getMethod("getStorageIndex", ItemStack.class).invoke(null, utils.item());
22 | for(int slot = utils.mySlotsCount(); slot < utils.mySlotsCount() + dropCount * 9; slot++) {
23 | utils.dropSlot(slot, true);
24 | }
25 | utils.player().closeScreen();
26 | }
27 | } catch (Exception e) {}
28 | }
29 |
30 | @Override public boolean inGuiPerform() {
31 | return true;
32 | }
33 |
34 | @Override public boolean isWorking() {
35 | return Loader.isModLoaded("ThermalExpansion") && Loader.isModLoaded("FTBL");
36 | }
37 |
38 | @Override public String moduleDesc() {
39 | return lang.get("Open any ThermalExpansion bag with Items and press keybind of function", "Открыть любую сумку из ThermalExpansion с вещами и нажать кейбинд функции");
40 | }
41 |
42 | }
43 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/render/GuiScaler.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.render;
2 |
3 | import org.lwjgl.opengl.GL11;
4 |
5 | import net.minecraft.client.Minecraft;
6 | import net.minecraft.client.gui.ScaledResolution;
7 |
8 | public class GuiScaler {
9 |
10 | private static ScaledResolution resolution;
11 | private static int mouseX, mouseY;
12 |
13 | public static boolean isGuiCreated() {
14 | return resolution != null;
15 | }
16 |
17 | public static int mouseX() {
18 | return mouseX;
19 | }
20 |
21 | public static int mouseY() {
22 | return mouseY;
23 | }
24 |
25 | public static int scaleFactor() {
26 | return resolution.getScaleFactor();
27 | }
28 |
29 | public static int screenHeight() {
30 | return resolution.getScaledHeight();
31 | }
32 |
33 | public static int screenWidth() {
34 | return resolution.getScaledWidth();
35 | }
36 |
37 | public static int scaledScreenWidth() {
38 | return scaledValue(resolution.getScaledWidth());
39 | }
40 |
41 | public static int scaledScreenHeight() {
42 | return scaledValue(resolution.getScaledHeight());
43 | }
44 |
45 | public static int scaledValue(int in) {
46 | return (int)(in / guiElementScale());
47 | }
48 |
49 | public static double guiElementScale() {
50 | return 2.0D / scaleFactor();
51 | }
52 |
53 | public static void setGuiScale() {
54 | GL11.glScaled(guiElementScale(), guiElementScale(), 0);
55 | }
56 |
57 | public static void setOnTop() {
58 | GL11.glTranslatef(0, 0, 999);
59 | }
60 |
61 | public static void updateResolution() {
62 | resolution = new ScaledResolution(Minecraft.getMinecraft(), Minecraft.getMinecraft().displayWidth, Minecraft.getMinecraft().displayHeight);
63 | }
64 |
65 | public static void updateMouse(int mX, int mY) {
66 | mouseX = scaledValue(mX);
67 | mouseY = scaledValue(mY);
68 | }
69 |
70 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/PacketProtector.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.network.internal.FMLProxyPacket;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import net.minecraft.network.Packet;
8 | import net.minecraft.network.play.client.C01PacketChatMessage;
9 |
10 | public class PacketProtector extends CheatModule {
11 |
12 | private EIOTeleport teleporter;
13 | private RadioHack radiohack;
14 |
15 | public PacketProtector() {
16 | super("PacketProtector", Category.NONE, PerformMode.ENABLED_ON_START);
17 | }
18 |
19 | @Override public boolean isWidgetable() {
20 | return false;
21 | }
22 |
23 | @Override public void onPostInit() {
24 | teleporter = (EIOTeleport) moduleHandler().getModuleByClass(EIOTeleport.class);
25 | radiohack = (RadioHack) moduleHandler().getModuleByClass(RadioHack.class);
26 | }
27 |
28 | @Override public boolean doSendPacket(Packet packet) {
29 | if (teleporter.getIntercept()) {
30 | if (packet instanceof C01PacketChatMessage) {
31 | String[] args = ((C01PacketChatMessage) packet).func_149439_c().replaceAll(" +", " ").split(" ");
32 | if ("/tp".equals(args[0]) && args.length == 5) {
33 | teleporter.doTeleport(-1, Integer.valueOf(args[2]), Integer.valueOf(args[3]), Integer.valueOf(args[4]));
34 | return false;
35 | }
36 | }
37 | }
38 | return true;
39 | }
40 |
41 | @Override public boolean doReceivePacket(Packet packet) {
42 | if (radiohack.getKick()) {
43 | if (packet instanceof FMLProxyPacket) {
44 | if ("DragonsRadioMod".equals(((FMLProxyPacket) packet).channel())) {
45 | return false;
46 | }
47 | }
48 | }
49 | return true;
50 | }
51 |
52 | }
53 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/RFCellDupe.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import java.lang.reflect.Array;
4 |
5 | import cpw.mods.fml.common.Loader;
6 | import cpw.mods.fml.common.network.simpleimpl.IMessage;
7 | import cpw.mods.fml.common.network.simpleimpl.SimpleNetworkWrapper;
8 | import forgefuck.team.xenobyte.api.module.Category;
9 | import forgefuck.team.xenobyte.api.module.CheatModule;
10 | import forgefuck.team.xenobyte.api.module.PerformMode;
11 | import forgefuck.team.xenobyte.api.module.PerformSource;
12 | import net.minecraft.item.ItemStack;
13 |
14 | public class RFCellDupe extends CheatModule {
15 |
16 | public RFCellDupe() {
17 | super("RFCellDupe", Category.MODS, PerformMode.SINGLE);
18 | }
19 |
20 | @Override public void onPerform(PerformSource src) {
21 | ItemStack ckeckItem = utils.item();
22 | try {
23 | if (Class.forName("appeng.items.storage.ItemBasicStorageCell").isInstance(ckeckItem.getItem())) {
24 | Object args = Array.newInstance(Class.forName("mcjty.lib.network.Argument"), 63);
25 | for (int i = 0; i < 63; i++) {
26 | Array.set(args, i, Class.forName("mcjty.lib.network.Argument").getConstructor(String.class, int.class).newInstance("@" + i, Integer.MAX_VALUE));
27 | }
28 | SimpleNetworkWrapper.class.getMethod("sendToServer", IMessage.class).invoke(Class.forName("mcjty.rftools.network.RFToolsMessages").getField("INSTANCE").get(null), Class.forName("mcjty.lib.network.PacketUpdateNBTItem").getConstructor(Class.forName("[Lmcjty.lib.network.Argument;")).newInstance(args));
29 | }
30 | } catch(Exception e) {}
31 | }
32 |
33 | @Override public String moduleDesc() {
34 | return lang.get("Creating infinite items in a ME cell in hand", "Создание бесконечных предметов в ME ячейке в руке");
35 | }
36 |
37 | @Override public boolean isWorking() {
38 | return Loader.isModLoaded("rftools") && Loader.isModLoaded("appliedenergistics2");
39 | }
40 |
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/AdvertHack.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import java.util.ArrayList;
4 | import java.util.List;
5 |
6 | import cpw.mods.fml.common.Loader;
7 | import forgefuck.team.xenobyte.api.config.Cfg;
8 | import forgefuck.team.xenobyte.api.gui.InputType;
9 | import forgefuck.team.xenobyte.api.module.Category;
10 | import forgefuck.team.xenobyte.api.module.CheatModule;
11 | import forgefuck.team.xenobyte.api.module.PerformMode;
12 | import forgefuck.team.xenobyte.api.module.PerformSource;
13 | import forgefuck.team.xenobyte.gui.click.elements.Button;
14 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
15 | import forgefuck.team.xenobyte.gui.swing.UserInput;
16 | import forgefuck.team.xenobyte.utils.Rand;
17 |
18 | public class AdvertHack extends CheatModule {
19 |
20 | @Cfg("urls") private List urls;
21 |
22 | public AdvertHack() {
23 | super("AdvertHack", Category.MODS, PerformMode.SINGLE);
24 | urls = new ArrayList();
25 | urls.add("");
26 | }
27 |
28 | @Override public void onPerform(PerformSource src) {
29 | String url = urls.get(0);
30 | if (!url.isEmpty()) {
31 | for (int id = 0; id <= 100; id++) {
32 | utils.sendPacket("malisisadvert", (byte) 7, id, Rand.str(), url);
33 | }
34 | }
35 | }
36 |
37 | @Override public boolean isWorking() {
38 | return Loader.isModLoaded("malisisadvert");
39 | }
40 |
41 | @Override public String moduleDesc() {
42 | return lang.get("Replacing all advertising images in MalisisAdvert with an image from the link", "Замена всех рекламных картинок в MalisisAdvert на картинку из ссылки");
43 | }
44 |
45 | @Override public Panel settingPanel() {
46 | return new Panel(
47 | new Button("AdvertUrl") {
48 | @Override public void onLeftClick() {
49 | new UserInput(lang.get("Links", "Ссылки"), urls, InputType.SINGLE_STRING).showFrame();
50 | }
51 | }
52 | );
53 | }
54 |
55 | }
56 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/FullBright.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.config.Cfg;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.gui.click.elements.Button;
8 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
9 | import forgefuck.team.xenobyte.utils.TickHelper;
10 | import net.minecraft.potion.Potion;
11 | import net.minecraft.potion.PotionEffect;
12 |
13 | public class FullBright extends CheatModule {
14 |
15 | @Cfg("withPotion") private boolean withPotion;
16 |
17 | public FullBright() {
18 | super("FullBright", Category.WORLD, PerformMode.TOGGLE);
19 | }
20 |
21 | @Override public void onDisabled() {
22 | utils.reloadWorld();
23 | utils.player().removePotionEffectClient(Potion.nightVision.getId());
24 | }
25 |
26 | @Override public int tickDelay() {
27 | return TickHelper.ONE_SEC;
28 | }
29 |
30 | @Override public void onTick(boolean inGame) {
31 | if (inGame) {
32 | float[] bright = utils.world().provider.lightBrightnessTable;
33 | for (int i = 0; i < bright.length; ++i) {
34 | bright[i] = 1.0f;
35 | }
36 | if (withPotion) {
37 | utils.player().addPotionEffect(new PotionEffect(Potion.nightVision.getId(), Integer.MAX_VALUE));
38 | }
39 | }
40 | }
41 |
42 | @Override public String moduleDesc() {
43 | return lang.get("Let there be light!", "Да будет свет!");
44 | }
45 |
46 | @Override public Panel settingPanel() {
47 | return new Panel(
48 | new Button("WithPotion", withPotion) {
49 | @Override public void onLeftClick() {
50 | buttonValue(withPotion = !withPotion);
51 | }
52 | @Override public String elementDesc() {
53 | return lang.get("Fallback - using a potion", "Запасной вариант - с применением зелья");
54 | }
55 | }
56 | );
57 | }
58 |
59 | }
60 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/utils/NetUtils.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.utils;
2 |
3 | import java.awt.image.BufferedImage;
4 | import java.io.BufferedReader;
5 | import java.io.InputStream;
6 | import java.io.InputStreamReader;
7 | import java.net.URL;
8 | import java.net.URLConnection;
9 |
10 | import javax.imageio.ImageIO;
11 |
12 | import com.google.gson.GsonBuilder;
13 | import com.google.gson.JsonObject;
14 |
15 | public class NetUtils {
16 |
17 | public static JsonObject getServerInfo(String ip) {
18 | try {
19 | return new GsonBuilder().create().fromJson(getContent("https://api.mcsrvstat.us/1/" + ip), JsonObject.class);
20 | } catch(Exception e) {
21 | return new JsonObject();
22 | }
23 | }
24 |
25 | public static InputStream getInputStream(String address) {
26 | return getInputStream(address, 5);
27 | }
28 |
29 | public static BufferedImage getImage(String address) {
30 | try {
31 | return ImageIO.read(getInputStream(address));
32 | } catch (Exception e) {
33 | return null;
34 | }
35 | }
36 |
37 | public static InputStream getInputStream(String address, int setTimeout) {
38 | try {
39 | URLConnection con = new URL(address).openConnection();
40 | con.setReadTimeout((setTimeout * 1000) * 2);
41 | con.setConnectTimeout(setTimeout * 1000);
42 | con.setDoOutput(true);
43 | con.connect();
44 | return con.getInputStream();
45 | } catch (Exception e) {
46 | return null;
47 | }
48 | }
49 |
50 | public static String getContent(String address) {
51 | try {
52 | BufferedReader in = new BufferedReader(new InputStreamReader(getInputStream(address)));
53 | StringBuilder response = new StringBuilder();
54 | String inputLine;
55 | while ((inputLine = in.readLine()) != null) {
56 | response.append(inputLine);
57 | }
58 | in.close();
59 | return response.toString();
60 | } catch (Exception e) {
61 | return new String();
62 | }
63 | }
64 |
65 | }
66 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/utils/Rand.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.utils;
2 |
3 | import java.util.UUID;
4 | import java.util.concurrent.ThreadLocalRandom;
5 |
6 | import org.apache.commons.codec.digest.DigestUtils;
7 |
8 | public class Rand {
9 |
10 | private static String[] formatColors = { "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "b", "c", "d", "e", "f" };
11 |
12 | private static final String[] splashes = {
13 | "Жизнь боль, когда дебажки ноль",
14 | "Хыыы ёпта бля",
15 | "За веранду и двор стреляю в упор",
16 | "МАЙНКРАФТ СУКА ЭТО МОЯ ЖИЗНЬ",
17 | "ЩАС ПОФИКШУ (с)4epB9Ik",
18 | "Иди уроки учи добоиб",
19 | "ВАМ БАН СЕР",
20 | "LiteLoader Fuck Team",
21 | "БУНД БЛЯТ!!1",
22 | "Интеллектуально (с)radioegor146",
23 | "EHacks потик",
24 | "Это не фикс - это заглушка",
25 | "Тупа бан",
26 | "Взлом жоп",
27 | "Продам EHack",
28 | "vk.com/forgefuck",
29 | "LUASUCC"
30 | };
31 |
32 | public static int num() {
33 | return num(-1337, 1337);
34 | }
35 |
36 | public static int num(int max) {
37 | return num(0, max);
38 | }
39 | public static int num(int min, int max) {
40 | return ThreadLocalRandom.current().nextInt(min, max);
41 | }
42 |
43 | public static String str(String in) {
44 | return DigestUtils.md5Hex(in);
45 | }
46 |
47 | public static String str() {
48 | return str(UUID.randomUUID().toString());
49 | }
50 |
51 | public static boolean bool() {
52 | return ThreadLocalRandom.current().nextBoolean();
53 | }
54 |
55 | public static int[] coords(int[] c, int r) {
56 | return new int[] { num(c[0] - r, c[0] + r), num(c[1] - r, c[1] + r), num(c[2] - r, c[2] + r) };
57 | }
58 |
59 | public static String formatColor() {
60 | return "§" + formatColors[num(formatColors.length)];
61 | }
62 |
63 | public static String formatSplash() {
64 | return formatColor().concat(splash());
65 | }
66 |
67 | public static String splash() {
68 | return splashes[num(splashes.length)];
69 | }
70 |
71 | }
72 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/GalacticFire.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
5 | import forgefuck.team.xenobyte.api.config.Cfg;
6 | import forgefuck.team.xenobyte.api.module.Category;
7 | import forgefuck.team.xenobyte.api.module.CheatModule;
8 | import forgefuck.team.xenobyte.api.module.PerformMode;
9 | import forgefuck.team.xenobyte.gui.click.elements.Button;
10 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
11 | import net.minecraft.entity.Entity;
12 | import net.minecraft.entity.EntityLivingBase;
13 | import net.minecraftforge.client.event.MouseEvent;
14 |
15 | public class GalacticFire extends CheatModule {
16 |
17 | @Cfg("inRadius") private boolean inRadius;
18 |
19 | public GalacticFire() {
20 | super("GalacticFire", Category.MODS, PerformMode.TOGGLE);
21 | }
22 |
23 | private void sendFirePacket(Entity e) {
24 | if (e != null) {
25 | utils.sendPacket("GalacticraftCore", (byte) 0, 7, e.getEntityId());
26 | }
27 | }
28 |
29 | @SubscribeEvent public void mouseEvent(MouseEvent e) {
30 | if (e.button == 0 && e.buttonstate) {
31 | if (inRadius) {
32 | utils.nearEntityes().filter(ent -> ent instanceof EntityLivingBase).forEach(this::sendFirePacket);
33 | } else {
34 | sendFirePacket(utils.entity());
35 | }
36 | }
37 | }
38 |
39 | @Override public boolean isWorking() {
40 | return Loader.isModLoaded("GalacticraftCore");
41 | }
42 |
43 | @Override public String moduleDesc() {
44 | return lang.get("Sets fire to living creatures by left mouse click", "Поджигает живность по ЛКМ");
45 | }
46 |
47 | @Override public Panel settingPanel() {
48 | return new Panel(
49 | new Button("InRadius", inRadius) {
50 | @Override public void onLeftClick() {
51 | buttonValue(inRadius = !inRadius);
52 | }
53 | @Override public String elementDesc() {
54 | return lang.get("By radius or sight", "По радиусу или взгляду");
55 | }
56 | }
57 | );
58 | }
59 |
60 | }
61 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/FactoryRocket.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
5 | import forgefuck.team.xenobyte.api.config.Cfg;
6 | import forgefuck.team.xenobyte.api.module.Category;
7 | import forgefuck.team.xenobyte.api.module.CheatModule;
8 | import forgefuck.team.xenobyte.api.module.PerformMode;
9 | import forgefuck.team.xenobyte.gui.click.elements.Button;
10 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
11 | import net.minecraft.entity.EntityLivingBase;
12 | import net.minecraftforge.client.event.MouseEvent;
13 |
14 | public class FactoryRocket extends CheatModule {
15 |
16 | @Cfg("inRadius") private boolean inRadius;
17 |
18 | public FactoryRocket() {
19 | super("FactoryRocket", Category.MODS, PerformMode.TOGGLE);
20 | }
21 |
22 | private void sendRocketPacket(int sourceId, int targetId) {
23 | utils.sendPacket("MFReloaded", (byte) 0, utils.worldId(), (short) 11, sourceId, targetId);
24 | }
25 |
26 | @SubscribeEvent public void mouseEvent(MouseEvent e) {
27 | if (e.button == 0 && e.buttonstate) {
28 | if (inRadius) {
29 | utils.nearEntityes().filter(ent -> ent instanceof EntityLivingBase).forEach(ent -> sendRocketPacket(utils.myId(), ent.getEntityId()));
30 | } else {
31 | sendRocketPacket(utils.myId(), -1);
32 | }
33 | }
34 | }
35 |
36 | @Override public boolean isWorking() {
37 | return Loader.isModLoaded("MineFactoryReloaded");
38 | }
39 |
40 | @Override public String moduleDesc() {
41 | return lang.get("Launching rocket on left mouse click", "Запуск ракет по ЛКМ");
42 | }
43 |
44 | @Override public Panel settingPanel() {
45 | return new Panel(
46 | new Button("InRadius", inRadius) {
47 | @Override public void onLeftClick() {
48 | buttonValue(inRadius = !inRadius);
49 | }
50 | @Override public String elementDesc() {
51 | return lang.get("By living creatures in radius or sight", "По живности в радиусе или взгляду");
52 | }
53 | }
54 | );
55 | }
56 |
57 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/VanillaMagic.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import java.util.stream.Stream;
4 |
5 | import org.lwjgl.input.Mouse;
6 |
7 | import forgefuck.team.xenobyte.api.module.Category;
8 | import forgefuck.team.xenobyte.api.module.CheatModule;
9 | import forgefuck.team.xenobyte.api.module.PerformMode;
10 | import net.minecraft.item.Item;
11 | import net.minecraft.item.ItemFood;
12 | import net.minecraft.item.ItemPotion;
13 | import net.minecraft.item.ItemStack;
14 | import net.minecraft.network.play.client.C03PacketPlayer;
15 | import net.minecraft.potion.Potion;
16 |
17 | public class VanillaMagic extends CheatModule {
18 |
19 | private final Potion[] badEffects = new Potion[] {
20 | Potion.moveSlowdown,
21 | Potion.digSlowdown,
22 | Potion.blindness,
23 | Potion.confusion,
24 | Potion.weakness,
25 | Potion.hunger,
26 | Potion.poison,
27 | Potion.wither,
28 | };
29 |
30 | public VanillaMagic() {
31 | super("VanillaMagic", Category.PLAYER, PerformMode.TOGGLE);
32 | }
33 |
34 | private void doMagic(int count) {
35 | for (int i = 0; i <= count; i++) {
36 | utils.sendPacket(new C03PacketPlayer());
37 | }
38 | }
39 |
40 | private boolean hasBadEffect() {
41 | return Stream.of(badEffects).filter(utils.player()::isPotionActive).findFirst().isPresent();
42 | }
43 |
44 | @Override public void onTick(boolean inGame) {
45 | if (inGame) {
46 | ItemStack held = utils.item();
47 | if (utils.player().isBurning() && utils.player().onGround) {
48 | doMagic(10);
49 | } else if (!utils.player().getActivePotionEffects().isEmpty() && hasBadEffect()) {
50 | doMagic(500);
51 | } else if (held != null) {
52 | Item item = held.getItem();
53 | if ((item instanceof ItemFood || item instanceof ItemPotion) && Mouse.isButtonDown(1)) {
54 | doMagic(10);
55 | }
56 | }
57 | }
58 | }
59 |
60 | @Override public String moduleDesc() {
61 | return lang.get("Instant: eat, self-extinguish and debuff", "Мгновенное: поедание, самотушение и дебаф");
62 | }
63 |
64 | }
65 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/Ceiling.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.gui.WidgetMode;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.block.material.Material;
9 |
10 | public class Ceiling extends CheatModule {
11 |
12 | public Ceiling() {
13 | super("Ceiling", Category.MOVE, PerformMode.SINGLE);
14 | }
15 |
16 | private boolean isHeight(int y) {
17 | return y > 0 && y < 255;
18 | }
19 |
20 | private Material getMaterial(int x, int y, int z) {
21 | return utils.block(x, y, z).getMaterial();
22 | }
23 |
24 | private boolean isAir(int x, int y, int z) {
25 | return getMaterial(x, y, z) == Material.air && getMaterial(x, y + 1, z) == Material.air;
26 | }
27 |
28 | private boolean isLava(int x, int y, int z) {
29 | return getMaterial(x, y - 1, z) == Material.lava || getMaterial(x, y, z) == Material.lava || getMaterial(x, y + 1, z) == Material.lava;
30 | }
31 |
32 | @Override public void onPerform(PerformSource src) {
33 | int[] coords = utils.myCoords();
34 | int x = coords[0];
35 | int y = coords[1];
36 | int z = coords[2];
37 | int step = utils.player().rotationPitch < 0 ? 1 : -1;
38 | do y += step; while( isAir(x, y, z) && isHeight(y));
39 | do y += step; while(!isAir(x, y, z) && isHeight(y));
40 | do y --; while( isAir(x, y, z) && isHeight(y));
41 | if (isHeight(y)) {
42 | if (isLava(x, y, z)) {
43 | widgetMessage("- " + lang.get("lava on the way!", "лава на пути!"), WidgetMode.FAIL);
44 | } else {
45 | utils.verticalTeleport(y + 1, true);
46 | }
47 | } else {
48 | widgetMessage("- " + lang.get("no matching block found", "подходящий блок не найден"), WidgetMode.FAIL);
49 | }
50 | }
51 |
52 | @Override public String moduleDesc() {
53 | return lang.get("Teleportation along the Y axis through blocks up/down by sight", "Телепортация по оси Y сквозь блоки вверх/вниз по взгляду");
54 | }
55 |
56 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/QuestGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import net.minecraft.nbt.NBTTagCompound;
9 | import net.minecraft.tileentity.TileEntity;
10 | import net.minecraft.util.ResourceLocation;
11 |
12 | public class QuestGive extends CheatModule {
13 |
14 | public QuestGive() {
15 | super("QuestGive", Category.MODS, PerformMode.SINGLE);
16 | }
17 |
18 | @Override public void onPerform(PerformSource src) {
19 | TileEntity checkTile = utils.tile();
20 | try {
21 | if (Class.forName("betterquesting.blocks.TileSubmitStation").isInstance(checkTile)) {
22 | NBTTagCompound stackTag = new NBTTagCompound();
23 | NBTTagCompound tileTag = new NBTTagCompound();
24 | NBTTagCompound root = new NBTTagCompound();
25 | giveSelector().givedItem().writeToNBT(stackTag);
26 | checkTile.writeToNBT(tileTag);
27 | if (giveSelector().fillAllSlots()) {
28 | tileTag.setTag("ouput", stackTag);
29 | }
30 | tileTag.setTag("input", stackTag);
31 | root.setTag("tile", tileTag);
32 | Class.forName("betterquesting.network.PacketSender").getMethod("sendToServer", Class.forName("betterquesting.api.network.QuestingPacket")).invoke(Class.forName("betterquesting.network.PacketSender").getField("INSTANCE").get(null), Class.forName("betterquesting.api.network.QuestingPacket").getConstructor(ResourceLocation.class, NBTTagCompound.class).newInstance(new ResourceLocation("betterquesting:edit_station"), root));
33 | }
34 | } catch (Exception e) {}
35 | }
36 |
37 | @Override public String moduleDesc() {
38 | return lang.get("Issuance of an item in the SubmitStation (OSS) which the player is looking at", "Выдача предмета в SubmitStation (OSS) на которую смотрит игрок");
39 | }
40 |
41 | @Override public boolean isWorking() {
42 | return Loader.isModLoaded("betterquesting");
43 | }
44 |
45 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/BlockOverlay.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import net.minecraft.block.Block;
8 | import net.minecraft.block.material.Material;
9 | import net.minecraft.util.MovingObjectPosition;
10 | import net.minecraftforge.client.event.RenderWorldLastEvent;
11 |
12 | public class BlockOverlay extends CheatModule {
13 |
14 | public BlockOverlay() {
15 | super("BlockOverlay", Category.WORLD, PerformMode.TOGGLE);
16 | }
17 |
18 | @SubscribeEvent public void worldRender(RenderWorldLastEvent e) {
19 | MovingObjectPosition position = utils.mc().objectMouseOver;
20 | if(position != null && utils.world() != null) {
21 | Block block = utils.world().getBlock(position.blockX, position.blockY, position.blockZ);
22 | if (block != null && block.getMaterial() != Material.air) {
23 | utils.mc().entityRenderer.disableLightmap(0.0f);
24 | int x = position.blockX, y = position.blockY, z = position.blockZ;
25 | render.WORLD.drawOutlinedEspBlock(x, y, z, 0.0f, 0.0f, 0.0f, 0.4F, 1);
26 | render.WORLD.drawEspBlock(x, y, z, 0.0f, 0.4f, 0.0f, 0.4F, 1);
27 | utils.mc().entityRenderer.enableLightmap(0.0f);
28 | return;
29 | }
30 | }
31 | MovingObjectPosition mop = utils.mc().renderViewEntity.rayTrace(200, 1.0F);
32 | if(mop != null) {
33 | int blockHitSide = mop.sideHit;
34 | int x = mop.blockX, y = mop.blockY, z = mop.blockZ;
35 | if(utils.world().getBlock(x, y, z).getMaterial() != Material.air) {
36 | render.WORLD.drawOutlinedEspBlock(x, y, z, 0.0f, 0.0f, 0.0f, 0.4F, 1);
37 | render.WORLD.drawEspBlock(x, y, z, 0.4f, 0.0f, 0.0f, 0.4F, 1);
38 | utils.mc().entityRenderer.enableLightmap(0.0f);
39 | }
40 | }
41 | }
42 |
43 | @Override public String moduleDesc() {
44 | return lang.get("Shows whether you can interact with the block", "Показывает можно ли взаимодействовать с блоком");
45 | }
46 |
47 | }
48 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/WallHack.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.relauncher.ReflectionHelper;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import net.minecraft.client.renderer.RenderGlobal;
8 | import net.minecraft.client.renderer.WorldRenderer;
9 |
10 | public class WallHack extends CheatModule {
11 |
12 | private WorldRenderer[] chunkCache;
13 |
14 | public WallHack() {
15 | super("WallHack", Category.WORLD, PerformMode.TOGGLE);
16 | chunkCache = new WorldRenderer[4];
17 | }
18 |
19 | private void renderChunks(boolean isVisible) {
20 | WorldRenderer[] renderChunks = ReflectionHelper.getPrivateValue(RenderGlobal.class, utils.mc().renderGlobal, 9);
21 | if (renderChunks.length > 4 && renderChunks[3] != null) {
22 | for (WorldRenderer ch : chunkCache) {
23 | if (ch != null) {
24 | ch.isVisible = true;
25 | }
26 | }
27 | chunkCache[0] = renderChunks[0];
28 | chunkCache[1] = renderChunks[1];
29 | chunkCache[2] = renderChunks[2];
30 | chunkCache[3] = renderChunks[3];
31 | renderChunks[0].isVisible = isVisible;
32 | renderChunks[1].isVisible = true;
33 | renderChunks[2].isVisible = true;
34 | renderChunks[3].isVisible = true;
35 | for (int i = 1; i <= 3; i++) {
36 | if (renderChunks[i].posX == renderChunks[0].posX && renderChunks[i].posZ == renderChunks[0].posZ && renderChunks[i].posY < renderChunks[0].posY) {
37 | renderChunks[i].isVisible = isVisible;
38 | }
39 | }
40 | }
41 | }
42 |
43 | @Override public void onDisabled() {
44 | renderChunks(true);
45 | }
46 |
47 | @Override public void onTick(boolean inGame) {
48 | if (inGame) {
49 | utils.mc().gameSettings.advancedOpengl = false;
50 | renderChunks(false);
51 | }
52 | }
53 |
54 | @Override public String moduleDesc() {
55 | return lang.get("Translucent chunk in which the player is", "Просвечивание чанка в котором находится игрок");
56 | }
57 |
58 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/MalisisDoors.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
5 | import forgefuck.team.xenobyte.api.config.Cfg;
6 | import forgefuck.team.xenobyte.api.module.Category;
7 | import forgefuck.team.xenobyte.api.module.CheatModule;
8 | import forgefuck.team.xenobyte.api.module.PerformMode;
9 | import forgefuck.team.xenobyte.gui.click.elements.Button;
10 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
11 | import net.minecraft.tileentity.TileEntity;
12 | import net.minecraftforge.client.event.MouseEvent;
13 |
14 | public class MalisisDoors extends CheatModule {
15 |
16 | @Cfg("inRadius") private boolean inRadius;
17 |
18 | public MalisisDoors() {
19 | super("MalisisDoors", Category.MODS, PerformMode.TOGGLE);
20 | }
21 |
22 | private boolean toggleDoorPacket(TileEntity door) {
23 | try {
24 | if (Class.forName("net.malisis.doors.door.tileentity.DoorTileEntity").isInstance(door)) {
25 | utils.sendPacket("malisisdoors", (byte) 0, utils.coords(door));
26 | return true;
27 | }
28 | } catch(Exception e) {}
29 | return false;
30 | }
31 |
32 | @SubscribeEvent public void mouseEvent(MouseEvent e) {
33 | if (e.button == 1 && e.buttonstate) {
34 | if (inRadius) {
35 | utils.nearTiles().forEach(this::toggleDoorPacket);
36 | } else {
37 | e.setCanceled(toggleDoorPacket(utils.tile()));
38 | }
39 | }
40 | }
41 |
42 | @Override public boolean isWorking() {
43 | return Loader.isModLoaded("malisisdoors");
44 | }
45 |
46 | @Override public String moduleDesc() {
47 | return lang.get("Door opener by right click", "Открывашка дверей по ПКМ");
48 | }
49 |
50 | @Override public Panel settingPanel() {
51 | return new Panel(
52 | new Button("InRadius", inRadius) {
53 | @Override public void onLeftClick() {
54 | buttonValue(inRadius = !inRadius);
55 | }
56 | @Override public String elementDesc() {
57 | return lang.get("By radius or sight", "По радиусу или взгляду");
58 | }
59 | }
60 | );
61 | }
62 |
63 | }
64 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/MekOpener.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
5 | import forgefuck.team.xenobyte.api.module.Category;
6 | import forgefuck.team.xenobyte.api.module.CheatModule;
7 | import forgefuck.team.xenobyte.api.module.PerformMode;
8 | import net.minecraft.block.Block;
9 | import net.minecraft.tileentity.TileEntity;
10 | import net.minecraftforge.client.event.MouseEvent;
11 |
12 | public class MekOpener extends CheatModule {
13 |
14 | public MekOpener() {
15 | super("MekOpener", Category.MODS, PerformMode.TOGGLE);
16 | }
17 |
18 | @SubscribeEvent public void mouseEvent(MouseEvent e) {
19 | if (e.button == 1 && e.buttonstate) {
20 | TileEntity checkTile = utils.tile();
21 | try {
22 | if (Class.forName("mekanism.common.tile.TileEntityBasicBlock").isInstance(checkTile)) {
23 | if (Class.forName("mekanism.common.tile.TileEntityPersonalChest").isInstance(checkTile)) {
24 | utils.sendPacket("MEK", (byte) 2, 1, true, utils.coords(checkTile), utils.worldId());
25 | } else {
26 | int guiId = (int) Class.forName("mekanism.common.CommonProxy").getMethod("getGuiId", Block.class, int.class).invoke(Class.forName("mekanism.common.Mekanism").getField("proxy").get(null), checkTile.blockType, checkTile.blockMetadata);
27 | utils.sendPacket("MEK", (byte) 18, utils.coords(checkTile), utils.worldId(), 0, guiId, 0);
28 | }
29 | e.setCanceled(true);
30 | } else if (Class.forName("mekanism.common.tile.TileEntityDigitalMiner").isInstance(checkTile)) {
31 | utils.sendPacket("MEK", (byte) 19, 2, utils.coords(checkTile), utils.worldId(), 0, 0);
32 | e.setCanceled(true);
33 | }
34 | } catch(Exception ex) {}
35 | }
36 | }
37 |
38 | @Override public String moduleDesc() {
39 | return lang.get("Opener of some blocks (even clamed ones) from Mekanism by right click in clamed area", "Открывашка некоторых блоков (даже приватных) из Mekanism по ПКМ в привате");
40 | }
41 |
42 | @Override public boolean isWorking() {
43 | return Loader.isModLoaded("Mekanism");
44 | }
45 |
46 | }
47 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/gui/click/elements/Button.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.gui.click.elements;
2 |
3 | import forgefuck.team.xenobyte.api.gui.ElementAligment;
4 | import forgefuck.team.xenobyte.api.gui.TextElement;
5 | import forgefuck.team.xenobyte.render.Colors;
6 |
7 | public class Button extends TextElement {
8 |
9 | private int bgColor, hoverColor, selectColor, textColor, selectTextColor, hoverTextColor;
10 | private String value;
11 |
12 | public Button(String text) {
13 | this(text, null);
14 | }
15 |
16 | public Button(String text, Object value) {
17 | this(text, value, ElementAligment.CENTER, Colors.TRANSPARENT, Colors.SKY, Colors.SKY, Colors.SKY, Colors.WHITE, Colors.WHITE);
18 | }
19 |
20 | public Button(String text, Object value, ElementAligment aligment, int bgColor, int hoverColor, int selectColor, int textColor, int selectTextColor, int hoverTextColor) {
21 | super(text, aligment, 4, 2);
22 | this.selectTextColor = selectTextColor;
23 | this.hoverTextColor = hoverTextColor;
24 | this.selectColor = selectColor;
25 | this.hoverColor = hoverColor;
26 | this.textColor = textColor;
27 | this.bgColor = bgColor;
28 | buttonValue(value);
29 | }
30 |
31 | public void buttonValue(Object value) {
32 | if (value instanceof Boolean) {
33 | setSelected((Boolean) value);
34 | this.value = null;
35 | } else {
36 | this.value = value != null ? "[" + value + "]" : null;
37 | }
38 | }
39 |
40 | public void playClick() {
41 | utils.playSound("gui.button.press", 3);
42 | }
43 |
44 | @Override public boolean click(int key) {
45 | if (isHovered() && key == 0) {
46 | playClick();
47 | }
48 | return super.click(key);
49 | }
50 |
51 | @Override public void onDraw() {
52 | render.GUI.drawRect(getX(), getY(), getMaxX(), getMaxY(), isSelected() ? selectColor : isHovered() ? hoverColor : bgColor);
53 | String out = value != null && isHovered() ? value : getText();
54 | render.GUI.xenoFont().drawString(out, getTextX(out), getTextY(), isSelected() ? selectTextColor : isHovered() ? hoverTextColor : textColor);
55 | }
56 |
57 | @Override public String toString() {
58 | return getText().concat(value == null ? "" : value);
59 | }
60 |
61 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/integration/NEI.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.integration;
2 |
3 | import java.util.List;
4 |
5 | import cpw.mods.fml.common.Loader;
6 | import forgefuck.team.xenobyte.api.Xeno;
7 | import forgefuck.team.xenobyte.utils.Reflections;
8 | import net.minecraft.client.Minecraft;
9 | import net.minecraft.client.gui.inventory.GuiContainer;
10 | import net.minecraft.client.gui.inventory.GuiInventory;
11 | import net.minecraft.item.ItemStack;
12 |
13 | public class NEI {
14 |
15 | public static boolean isAvailable() {
16 | return Loader.isModLoaded("NotEnoughItems") || Reflections.exists("codechicken.nei.api.API") || Reflections.exists("codechicken.nei.guihook.GuiContainerManager");
17 | }
18 |
19 | public static void openGui(String searchText) {
20 | setSearchField(searchText);
21 | Minecraft.getMinecraft().displayGuiScreen(new GuiInventory(Minecraft.getMinecraft().thePlayer));
22 | }
23 |
24 | public static void setSearchField(String text) {
25 | try {
26 | Class.forName("codechicken.nei.TextField").getDeclaredMethod("setText", String.class).invoke(Class.forName("codechicken.nei.LayoutManager").getDeclaredField("searchField").get(null), text);
27 | } catch (Exception e) {}
28 | }
29 |
30 | public static void clearHiddenItems() {
31 | try {
32 | Class.forName("codechicken.nei.ItemStackMap").getDeclaredMethod("clear").invoke(Class.forName("codechicken.nei.api.ItemInfo").getDeclaredField("hiddenItems").get(null));
33 | } catch (Exception e) {}
34 | }
35 |
36 | public static void addSubset(String name, List items) {
37 | try {
38 | Class.forName("codechicken.nei.api.API").getDeclaredMethod("addSubset", String.class, Iterable.class).invoke(null, name, items);
39 | } catch (Exception e) {}
40 | }
41 |
42 | public static ItemStack getStackMouseOver() {
43 | try {
44 | GuiContainer container = Xeno.utils.guiContainer();
45 | if (container instanceof GuiContainer) {
46 | Object checkItem = Class.forName("codechicken.nei.guihook.GuiContainerManager").getDeclaredMethod("getStackMouseOver", GuiContainer.class).invoke(null, container);
47 | if (checkItem != null) {
48 | return ((ItemStack)checkItem).copy();
49 | }
50 | }
51 | } catch (Exception e) {}
52 | return null;
53 | }
54 |
55 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/render/XenoFont.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.render;
2 |
3 | import java.awt.Color;
4 |
5 | import org.lwjgl.opengl.GL11;
6 |
7 | import forgefuck.team.xenobyte.api.Xeno;
8 |
9 | public class XenoFont {
10 |
11 | private int rows, charWidth, fontHeight, shadowShift;
12 | private String letters;
13 | private int[][] poses;
14 |
15 | public XenoFont() {
16 | letters = " !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ЁёАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя";
17 | poses = new int[fontLetters().length()][2];
18 | shadowShift = 2;
19 | fontHeight = 26;
20 | charWidth = 13;
21 | rows = 19;
22 | for (int ch = 0; ch < fontLetters().length(); ch ++) {
23 | poses[ch][0] = (ch % rows) * charWidth;
24 | poses[ch][1] = (ch / rows) * fontHeight;
25 | }
26 | }
27 |
28 | public int textWidth(String text) {
29 | int outLen = 0;
30 | for (char ch : text.toCharArray()) {
31 | if (fontLetters().indexOf(ch) > -1) {
32 | outLen ++;
33 | }
34 | }
35 | return ((outLen * charWidth) / 2) + 1;
36 | }
37 |
38 | public int fontHeight() {
39 | return fontHeight / 2;
40 | }
41 |
42 | public String fontLetters() {
43 | return letters;
44 | }
45 |
46 | public void drawString(String text, int x, int y, int color) {
47 | int sub = 0;
48 | float[] rgba = new Color(color, true).getRGBComponents(null);
49 | GL11.glPushMatrix();
50 | GL11.glBindTexture(GL11.GL_TEXTURE_2D, Textures.FONT);
51 | GL11.glEnable(GL11.GL_BLEND);
52 | GL11.glScalef(0.5F, 0.5F, 0);
53 | for (char ch : text.toCharArray()) {
54 | int index = fontLetters().indexOf(ch);
55 | if (index > -1) {
56 | int[] pos = poses[index];
57 | int xStart = x * 2 + sub;
58 | int yStart = y * 2;
59 | GL11.glColor4f(0, 0, 0, rgba[3]);
60 | Xeno.render.GUI.drawTexturedModalRect(xStart + shadowShift, yStart + shadowShift, pos[0], pos[1], charWidth, fontHeight);
61 | GL11.glColor4f(rgba[0], rgba[1], rgba[2], rgba[3]);
62 | Xeno.render.GUI.drawTexturedModalRect(x * 2 + sub, y * 2, pos[0], pos[1], charWidth, fontHeight);
63 | sub += charWidth;
64 | }
65 | }
66 | GL11.glDisable(GL11.GL_BLEND);
67 | GL11.glPopMatrix();
68 | }
69 |
70 | }
--------------------------------------------------------------------------------
/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if "%DEBUG%" == "" @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if "%OS%"=="Windows_NT" setlocal
10 |
11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
12 | set DEFAULT_JVM_OPTS=
13 |
14 | set DIRNAME=%~dp0
15 | if "%DIRNAME%" == "" set DIRNAME=.
16 | set APP_BASE_NAME=%~n0
17 | set APP_HOME=%DIRNAME%
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if "%ERRORLEVEL%" == "0" goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:"=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist "%JAVA_EXE%" goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windowz variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 | if "%@eval[2+2]" == "4" goto 4NT_args
53 |
54 | :win9xME_args
55 | @rem Slurp the command line arguments.
56 | set CMD_LINE_ARGS=
57 | set _SKIP=2
58 |
59 | :win9xME_args_slurp
60 | if "x%~1" == "x" goto execute
61 |
62 | set CMD_LINE_ARGS=%*
63 | goto execute
64 |
65 | :4NT_args
66 | @rem Get arguments from the 4NT Shell from JP Software
67 | set CMD_LINE_ARGS=%$
68 |
69 | :execute
70 | @rem Setup the command line
71 |
72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
73 |
74 | @rem Execute Gradle
75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
76 |
77 | :end
78 | @rem End local scope for the variables with windows NT shell
79 | if "%ERRORLEVEL%"=="0" goto mainEnd
80 |
81 | :fail
82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
83 | rem the _cmd.exe /c_ return code!
84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
85 | exit /b 1
86 |
87 | :mainEnd
88 | if "%OS%"=="Windows_NT" endlocal
89 |
90 | :omega
91 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/AutoDrop.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import forgefuck.team.xenobyte.api.config.Cfg;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.gui.click.elements.Button;
8 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
9 | import forgefuck.team.xenobyte.gui.click.elements.ScrollSlider;
10 | import forgefuck.team.xenobyte.utils.TickHelper;
11 |
12 | public class AutoDrop extends CheatModule {
13 |
14 | @Cfg("allStack") private boolean allStack;
15 | @Cfg("delay") private int delay;
16 | @Cfg("slot") private int slot;
17 |
18 | public AutoDrop() {
19 | super("AutoDrop", Category.PLAYER, PerformMode.TOGGLE);
20 | slot = 1;
21 | }
22 |
23 | @Override public int tickDelay() {
24 | return delay;
25 | }
26 |
27 | @Override public void onTick(boolean inGame) {
28 | if (inGame) {
29 | utils.dropSlot(utils.mySlotsCount() + (slot - 1), allStack);
30 | }
31 | }
32 |
33 | @Override public String moduleDesc() {
34 | return lang.get("Item drop from the active slot", "Дроп предмета из активного слота");
35 | }
36 |
37 | @Override public Panel settingPanel() {
38 | return new Panel(
39 | new ScrollSlider("Delay", delay, 0, TickHelper.ONE_SEC) {
40 | @Override public void onScroll(int dir, boolean withShift) {
41 | delay = processSlider(dir, withShift);
42 | }
43 | @Override public String elementDesc() {
44 | return lang.get("Item drop delay", "Задержка дропа предмета");
45 | }
46 | },
47 | new ScrollSlider("Slot", slot, 9) {
48 | @Override public void onScroll(int dir, boolean withShift) {
49 | slot = processSlider(dir, withShift);
50 | }
51 | @Override public String elementDesc() {
52 | return lang.get("The slot from which items are dropped", "Слот из которого дропаются предметы");
53 | }
54 | },
55 | new Button("AllStack", allStack) {
56 | @Override public void onLeftClick() {
57 | buttonValue(allStack = !allStack);
58 | }
59 | @Override public String elementDesc() {
60 | return lang.get("Drop an entire stack or one item at a time", "Дропать весь стак или по одному предмету");
61 | }
62 | }
63 | );
64 | }
65 |
66 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/MachineChaos.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.module.Category;
5 | import forgefuck.team.xenobyte.api.module.CheatModule;
6 | import forgefuck.team.xenobyte.api.module.PerformMode;
7 | import forgefuck.team.xenobyte.api.module.PerformSource;
8 | import forgefuck.team.xenobyte.utils.Rand;
9 | import net.minecraft.tileentity.TileEntity;
10 |
11 | public class MachineChaos extends CheatModule {
12 |
13 | public MachineChaos() {
14 | super("MachineChaos", Category.MODS, PerformMode.SINGLE);
15 | }
16 |
17 | private void sendBatthurt(TileEntity tile) {
18 | try {
19 | if (Class.forName("crazypants.enderio.machine.IRedstoneModeControlable").isInstance(tile)) {
20 | utils.sendPacket("enderio", (byte) 96, utils.coords(tile), (short) Rand.num(4));
21 | }
22 | if (Class.forName("crazypants.enderio.machine.IIoConfigurable").isInstance(tile)) {
23 | for (int side = 0; side <= 5; side++) {
24 | utils.sendPacket("enderio", (byte) 1, utils.coords(tile), (short) Rand.num(5), (short) side);
25 | }
26 | }
27 | if (Class.forName("crazypants.enderio.conduit.TileConduitBundle").isInstance(tile)) {
28 | Class enumTypeClass = Class.forName("crazypants.enderio.conduit.packet.ConTypeEnum");
29 | Object[] conTypes = (Object[]) enumTypeClass.getMethod("values").invoke(null);
30 | for (Object type : conTypes) {
31 | if ((boolean) Class.forName("crazypants.enderio.conduit.TileConduitBundle").getMethod("hasType", Class.class).invoke(tile, enumTypeClass.getMethod("getBaseType").invoke(type))) {
32 | for (int side = 0; side <= 5; side++) {
33 | short typeId = ((Integer) enumTypeClass.getMethod("ordinal").invoke(type)).shortValue();
34 | utils.sendPacket("enderio", (byte) 76, utils.coords(tile), (short) typeId, (short) side, (short) Rand.num(4));
35 | }
36 | }
37 | }
38 | }
39 | } catch(Exception e) {}
40 | }
41 |
42 | @Override public void onPerform(PerformSource src) {
43 | utils.nearTiles().forEach(this::sendBatthurt);
44 | }
45 |
46 | @Override public boolean isWorking() {
47 | return Loader.isModLoaded("EnderIO");
48 | }
49 |
50 | @Override public String moduleDesc() {
51 | return lang.get("Randomising configurations of EnderIO mechanisms and pipes in radius", "Рандом конфигураций механизмов и труб EnderIO в радиусе");
52 | }
53 |
54 | }
55 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/CrayfishNuker.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
5 | import forgefuck.team.xenobyte.api.config.Cfg;
6 | import forgefuck.team.xenobyte.api.module.Category;
7 | import forgefuck.team.xenobyte.api.module.CheatModule;
8 | import forgefuck.team.xenobyte.api.module.PerformMode;
9 | import forgefuck.team.xenobyte.gui.click.elements.Button;
10 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
11 | import forgefuck.team.xenobyte.gui.click.elements.ScrollSlider;
12 | import net.minecraftforge.client.event.MouseEvent;
13 |
14 | public class CrayfishNuker extends CheatModule {
15 |
16 | @Cfg("onlyXRay") private boolean onlyXRay;
17 | @Cfg("onView") private boolean onView;
18 | @Cfg("radius") private int radius;
19 |
20 | public CrayfishNuker() {
21 | super("CrayfishNuker", Category.MODS, PerformMode.TOGGLE);
22 | radius = 1;
23 | }
24 |
25 | @SubscribeEvent public void mouseEvent(MouseEvent e) {
26 | if (e.button == 0 && e.buttonstate) {
27 | utils.nukerList(onView ? utils.mop() : utils.myCoords(), radius, onlyXRay ? xraySelector() : null).forEach(pos -> {
28 | utils.sendPacket("cfm", (byte) 14, pos[0], pos[1], pos[2]);
29 | });
30 | e.setCanceled(true);
31 | }
32 | }
33 |
34 | @Override public boolean isWorking() {
35 | return Loader.isModLoaded("cfm");
36 | }
37 |
38 | @Override public String moduleDesc() {
39 | return lang.get("Deletes blocks in radius by left click", "Удаляет блоки в радиусе по ЛКМ");
40 | }
41 |
42 | @Override public Panel settingPanel() {
43 | return new Panel(
44 | new ScrollSlider("Radius", radius, 20) {
45 | @Override public void onScroll(int dir, boolean withShift) {
46 | radius = processSlider(dir, withShift);
47 | }
48 | },
49 | new Button("OnView", onView) {
50 | @Override public void onLeftClick() {
51 | buttonValue(onView = !onView);
52 | }
53 | @Override public String elementDesc() {
54 | return lang.get("By sight or around the player", "По взгляду или вокруг игрока");
55 | }
56 | },
57 | new Button("OnlyXRay", onlyXRay) {
58 | @Override public void onLeftClick() {
59 | buttonValue(onlyXRay = !onlyXRay);
60 | }
61 | @Override public String elementDesc() {
62 | return lang.get("Removing only XRay blocks", "Удаление только XRay блоков");
63 | }
64 | }
65 | );
66 | }
67 |
68 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/TurretNuker.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
5 | import forgefuck.team.xenobyte.api.config.Cfg;
6 | import forgefuck.team.xenobyte.api.module.Category;
7 | import forgefuck.team.xenobyte.api.module.CheatModule;
8 | import forgefuck.team.xenobyte.api.module.PerformMode;
9 | import forgefuck.team.xenobyte.gui.click.elements.Button;
10 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
11 | import forgefuck.team.xenobyte.gui.click.elements.ScrollSlider;
12 | import net.minecraftforge.client.event.MouseEvent;
13 |
14 | public class TurretNuker extends CheatModule {
15 |
16 | @Cfg("onlyXRay") private boolean onlyXRay;
17 | @Cfg("onView") private boolean onView;
18 | @Cfg("radius") private int radius;
19 |
20 | public TurretNuker() {
21 | super("TurretNuker", Category.MODS, PerformMode.TOGGLE);
22 | radius = 1;
23 | }
24 |
25 | @SubscribeEvent public void mouseEvent(MouseEvent e) {
26 | if (e.button == 0 && e.buttonstate) {
27 | utils.nukerList(onView ? utils.mop() : utils.myCoords(), radius, onlyXRay ? xraySelector() : null).forEach(pos -> {
28 | utils.sendPacket("openmodularturrets", (byte) 9, pos[0], pos[1], pos[2]);
29 | });
30 | e.setCanceled(true);
31 | }
32 | }
33 |
34 | @Override public boolean isWorking() {
35 | return Loader.isModLoaded("openmodularturrets");
36 | }
37 |
38 | @Override public String moduleDesc() {
39 | return lang.get("Destroys blocks in a radius by left mouse click", "Разрушает блоки в радиусе по ЛКМ");
40 | }
41 |
42 | @Override public Panel settingPanel() {
43 | return new Panel(
44 | new ScrollSlider("Radius", radius, 20) {
45 | @Override public void onScroll(int dir, boolean withShift) {
46 | radius = processSlider(dir, withShift);
47 | }
48 | },
49 | new Button("OnView", onView) {
50 | @Override public void onLeftClick() {
51 | buttonValue(onView = !onView);
52 | }
53 | @Override public String elementDesc() {
54 | return lang.get("By sight or around the player", "По взгляду или вокруг игрока");
55 | }
56 | },
57 | new Button("OnlyXRay", onlyXRay) {
58 | @Override public void onLeftClick() {
59 | buttonValue(onlyXRay = !onlyXRay);
60 | }
61 | @Override public String elementDesc() {
62 | return lang.get("Breaking only XRay blocks", "Разрушение только XRay блоков");
63 | }
64 | }
65 | );
66 | }
67 |
68 | }
69 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/BiblioFrameGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.gui.WidgetMode;
5 | import forgefuck.team.xenobyte.api.module.Category;
6 | import forgefuck.team.xenobyte.api.module.CheatModule;
7 | import forgefuck.team.xenobyte.api.module.PerformMode;
8 | import forgefuck.team.xenobyte.api.module.PerformSource;
9 | import net.minecraft.item.ItemStack;
10 | import net.minecraft.nbt.NBTTagCompound;
11 | import net.minecraft.tileentity.TileEntity;
12 |
13 | public class BiblioFrameGive extends CheatModule {
14 |
15 | private int[] coords;
16 |
17 | public BiblioFrameGive() {
18 | super("BiblioFrameGive", Category.MODS, PerformMode.SINGLE);
19 | }
20 |
21 | @Override public void onPerform(PerformSource src) {
22 | TileEntity checkTile = utils.tile();
23 | try {
24 | if (Class.forName("jds.bibliocraft.tileentities.TileEntityMapFrame").isInstance(checkTile)) {
25 | coords = new int[] {
26 | checkTile.xCoord,
27 | checkTile.yCoord,
28 | checkTile.zCoord
29 | };
30 | widgetMessage(String.format(lang.get("map frame block saved by coords", "блок карты сохранён по координатам") + " [%s, %s, %s]", coords[0], coords[1], coords[2]), WidgetMode.INFO);
31 | } else if (coords != null) {
32 | TileEntity frameTile = utils.tile(coords);
33 | if (frameTile != null) {
34 | NBTTagCompound frameTag = new NBTTagCompound();
35 | frameTile.writeToNBT(frameTag);
36 | if (frameTag.getByte("hasMap") == 1) {
37 | ItemStack out = giveSelector().givedItem();
38 | utils.item(out, "{Inventory:[]}");
39 | utils.sendPacket("BiblioAtlasWPT", false, coords[0], coords[1], coords[2], out);
40 | } else {
41 | widgetMessage(lang.get("no found map in map frame!", "карта в рамке не найдена!"), WidgetMode.FAIL);
42 | }
43 | } else {
44 | widgetMessage(lang.get("map frame block not found within client!", "блок рамки не найден в пределах клиента!"), WidgetMode.FAIL);
45 | }
46 | } else {
47 | widgetMessage(lang.get("map frame block not set! (set by look and press keybind)", "блок рамки не задан! (задать по взгляду и кейбинду)"), WidgetMode.FAIL);
48 | }
49 | } catch(Exception e) {}
50 | }
51 |
52 | @Override public String moduleDesc() {
53 | return lang.get("Issuing an item to hand using a map frame", "Выдача предмета в руку с использованием рамки с картой");
54 | }
55 |
56 | @Override public boolean isWorking() {
57 | return Loader.isModLoaded("BiblioCraft");
58 | }
59 |
60 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/TainedAura.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
5 | import forgefuck.team.xenobyte.api.config.Cfg;
6 | import forgefuck.team.xenobyte.api.module.Category;
7 | import forgefuck.team.xenobyte.api.module.CheatModule;
8 | import forgefuck.team.xenobyte.api.module.PerformMode;
9 | import forgefuck.team.xenobyte.gui.click.elements.Button;
10 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
11 | import net.minecraft.entity.Entity;
12 | import net.minecraft.entity.EntityLivingBase;
13 | import net.minecraft.entity.player.EntityPlayer;
14 | import net.minecraftforge.client.event.MouseEvent;
15 |
16 | public class TainedAura extends CheatModule {
17 |
18 | @Cfg("withSound") private boolean withSound;
19 | @Cfg("inRadius") private boolean inRadius;
20 |
21 | public TainedAura() {
22 | super("TainedAura", Category.MODS, PerformMode.TOGGLE);
23 | }
24 |
25 | private void sendTainedPacket(Entity e) {
26 | if (e != null) {
27 | int sourceId = (e instanceof EntityPlayer) ? e.getEntityId() : utils.myId();
28 | utils.sendPacket("taintedmagic", (byte) 0, e.getEntityId(), sourceId, utils.worldId(), Float.MAX_VALUE, withSound);
29 | }
30 | }
31 |
32 | @SubscribeEvent public void mouseEvent(MouseEvent e) {
33 | if (e.button == 0 && e.buttonstate) {
34 | if (inRadius) {
35 | utils.nearEntityes().filter(ent -> ent instanceof EntityLivingBase).forEach(ent -> {
36 | sendTainedPacket(ent);
37 | });
38 | } else {
39 | sendTainedPacket(utils.entity());
40 | }
41 | }
42 | }
43 |
44 | @Override public boolean isWorking() {
45 | return Loader.isModLoaded("TaintedMagic");
46 | }
47 |
48 | @Override public String moduleDesc() {
49 | return lang.get("Killing all living creatures by left mouse click", "Ваншотает живность по ЛКМ");
50 | }
51 |
52 | @Override public Panel settingPanel() {
53 | return new Panel(
54 | new Button("InRadius", inRadius) {
55 | @Override public void onLeftClick() {
56 | buttonValue(inRadius = !inRadius);
57 | }
58 | @Override public String elementDesc() {
59 | return lang.get("By radius or sight", "По радиусу или взгляду");
60 | }
61 | },
62 | new Button("WithSound", withSound) {
63 | @Override public void onLeftClick() {
64 | buttonValue(withSound = !withSound);
65 | }
66 | @Override public String elementDesc() {
67 | return lang.get("Some weird sound", "Какой-то стрёмный звук");
68 | }
69 | }
70 | );
71 | }
72 |
73 | }
74 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/OCShutDown.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.config.Cfg;
5 | import forgefuck.team.xenobyte.api.module.Category;
6 | import forgefuck.team.xenobyte.api.module.CheatModule;
7 | import forgefuck.team.xenobyte.api.module.PerformMode;
8 | import forgefuck.team.xenobyte.api.module.PerformSource;
9 | import forgefuck.team.xenobyte.gui.click.elements.Button;
10 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
11 | import net.minecraft.tileentity.TileEntity;
12 |
13 | public class OCShutDown extends CheatModule {
14 |
15 | @Cfg("inRadius") private boolean inRadius;
16 | private boolean state;
17 |
18 | public OCShutDown() {
19 | super("OCShutDown", Category.MODS, PerformMode.SINGLE);
20 | }
21 |
22 | private boolean shutDownPacket(TileEntity comp) {
23 | try {
24 | if (Class.forName("li.cil.oc.common.tileentity.Case").isInstance(comp)) {
25 | Class.forName("li.cil.oc.client.PacketSender$").getMethod("sendComputerPower", Class.forName("li.cil.oc.common.tileentity.traits.Computer"), boolean.class).invoke(Class.forName("li.cil.oc.client.PacketSender$").getField("MODULE$").get(null), comp, state);
26 | return true;
27 | } else if (Class.forName("li.cil.oc.common.tileentity.Rack").isInstance(comp)) {
28 | for (int rack = 0; rack <= 3; rack ++) {
29 | Class.forName("li.cil.oc.client.PacketSender$").getMethod("sendServerPower", Class.forName("li.cil.oc.common.tileentity.Rack"), int.class, boolean.class).invoke(Class.forName("li.cil.oc.client.PacketSender$").getField("MODULE$").get(null), comp, rack, state);
30 | }
31 | return true;
32 | }
33 | } catch(Exception e) {}
34 | return false;
35 | }
36 |
37 | @Override public void onPerform(PerformSource src) {
38 | state = !state;
39 | if (inRadius) {
40 | utils.nearTiles().forEach(this::shutDownPacket);
41 | } else {
42 | shutDownPacket(utils.tile());
43 | }
44 | }
45 |
46 | @Override public boolean isWorking() {
47 | return Loader.isModLoaded("OpenComputers");
48 | }
49 |
50 | @Override public String moduleDesc() {
51 | return lang.get("Restarting PC's from OpenComputers by keybind", "Перезагрузка компов из OpenComputers по кейбинду");
52 | }
53 |
54 | @Override public Panel settingPanel() {
55 | return new Panel(
56 | new Button("InRadius", inRadius) {
57 | @Override public void onLeftClick() {
58 | buttonValue(inRadius = !inRadius);
59 | }
60 | @Override public String elementDesc() {
61 | return lang.get("By radius or sight", "По радиусу или взгляду");
62 | }
63 | }
64 | );
65 | }
66 |
67 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/gui/swing/CreditsGui.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.gui.swing;
2 |
3 | import java.awt.Color;
4 | import java.awt.Cursor;
5 | import java.awt.GridBagLayout;
6 | import java.awt.event.ActionEvent;
7 | import java.awt.event.MouseAdapter;
8 | import java.awt.event.MouseEvent;
9 |
10 | import javax.swing.JComponent;
11 | import javax.swing.JLabel;
12 | import javax.swing.JPanel;
13 | import javax.swing.JTextField;
14 |
15 | import forgefuck.team.xenobyte.api.gui.XenoJFrame;
16 |
17 | public class CreditsGui extends XenoJFrame {
18 |
19 | private JPanel fieldsPanel;
20 |
21 | public CreditsGui() {
22 | super("Credits", DISPOSE_ON_CLOSE);
23 | }
24 |
25 | @Override public void localizeSet() {}
26 |
27 | @Override public void createObjects() {
28 | fieldsPanel = new JPanel();
29 | }
30 |
31 | @Override public void configurate() {
32 | fieldsPanel.setLayout(new GridBagLayout());
33 | accept.setText(" ОК ");
34 | }
35 |
36 | @Override public void addElements() {
37 | fieldsPanel.add(new LinkLabel(" " + mod_name + " version " + mod_version + " (C) " + mod_author + " "), GBC);
38 | fieldsPanel.add(new JLabel(" "), GBC);
39 | fieldsPanel.add(new LinkLabel("Telegram", tg_link), GBC);
40 | fieldsPanel.add(new LinkLabel("YouTube", yt_link), GBC);
41 | fieldsPanel.add(new LinkLabel("Discord", ds_link), GBC);
42 | fieldsPanel.add(new LinkLabel("GitHub", gh_link), GBC);
43 | fieldsPanel.add(new JLabel(" "), GBC);
44 | buttonsBar.add(accept);
45 | add(fieldsPanel);
46 | add(buttonsBar);
47 | }
48 |
49 | @Override public void actionPerformed(ActionEvent e) {
50 | dispose();
51 | }
52 |
53 | class LinkLabel extends JLabel {
54 |
55 | LinkLabel(String title) {
56 | this(title, null);
57 | }
58 |
59 | LinkLabel(String title, String link) {
60 | super(title);
61 | setHorizontalAlignment(JTextField.CENTER);
62 | setFont(FONT);
63 | if (link != null) {
64 | addMouseListener(new MouseAdapter() {
65 | @Override public void mouseClicked(MouseEvent e) {
66 | if (e.getClickCount() > 0) {
67 | utils.clipboardMessage(link);
68 | }
69 | }
70 | @Override public void mouseEntered(MouseEvent e) {
71 | ((JComponent)e.getSource()).setForeground(Color.RED);
72 | }
73 | @Override public void mouseExited(MouseEvent e) {
74 | ((JComponent)e.getSource()).setForeground(Color.BLUE);
75 | }
76 | });
77 | setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR));
78 | setToolTipText("Copy " + link);
79 | setForeground(Color.BLUE);
80 | }
81 | }
82 |
83 | }
84 |
85 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/FactoryDupe.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import cpw.mods.fml.common.Loader;
4 | import forgefuck.team.xenobyte.api.config.Cfg;
5 | import forgefuck.team.xenobyte.api.module.Category;
6 | import forgefuck.team.xenobyte.api.module.CheatModule;
7 | import forgefuck.team.xenobyte.api.module.PerformMode;
8 | import forgefuck.team.xenobyte.api.module.PerformSource;
9 | import forgefuck.team.xenobyte.gui.click.elements.Button;
10 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
11 | import net.minecraft.client.gui.inventory.GuiContainer;
12 | import net.minecraft.tileentity.TileEntity;
13 |
14 | public class FactoryDupe extends CheatModule {
15 |
16 | @Cfg("fillSlots") private boolean fillSlots;
17 | @Cfg("inRadius") private boolean inRadius;
18 |
19 | public FactoryDupe() {
20 | super("FactoryDupe", Category.MODS, PerformMode.SINGLE);
21 | }
22 |
23 | void sendDupePacket(TileEntity tile) {
24 | int slots = utils.slots(tile);
25 | if (slots > 0) {
26 | for (int slot = 0; slot < (fillSlots ? slots: 1); slot ++) {
27 | for (int count = 0; count < 64; count ++) {
28 | utils.sendPacket("MFReloaded", (byte) 0, utils.worldId(), (short) 20, utils.coords(tile), utils.myId(), slot, (byte) 0);
29 | }
30 | }
31 | }
32 | }
33 |
34 | @Override public boolean inGuiPerform() {
35 | return utils.currentScreen() instanceof GuiContainer;
36 | }
37 |
38 | @Override public void onPerform(PerformSource src) {
39 | if (inRadius) {
40 | utils.nearTiles().forEach(this::sendDupePacket);
41 | } else {
42 | sendDupePacket(utils.tile());
43 | }
44 | }
45 |
46 | @Override public boolean isWorking() {
47 | return Loader.isModLoaded("MineFactoryReloaded");
48 | }
49 |
50 | @Override public String moduleDesc() {
51 | return lang.get("Item dupe under the cursor in the inventories (if there is no item, then clears the inventory)", "Дюп предмета под курсором в инвентарях (если предмета нет, то очищает инвентари)");
52 | }
53 |
54 | @Override public Panel settingPanel() {
55 | return new Panel(
56 | new Button("InRadius", inRadius) {
57 | @Override public void onLeftClick() {
58 | buttonValue(inRadius = !inRadius);
59 | }
60 | @Override public String elementDesc() {
61 | return lang.get("By radius or sight", "По радиусу или взгляду");
62 | }
63 | },
64 | new Button("FillSlots", fillSlots) {
65 | @Override public void onLeftClick() {
66 | buttonValue(fillSlots = !fillSlots);
67 | }
68 | @Override public String elementDesc() {
69 | return lang.get("Across all inventory slots", "Работа по всем слотам инвентаря");
70 | }
71 | }
72 | );
73 | }
74 |
75 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/gui/swing/ColorPickerGui.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.gui.swing;
2 |
3 | import java.awt.Color;
4 | import java.awt.Dimension;
5 | import java.awt.GridBagLayout;
6 | import java.awt.event.ActionEvent;
7 |
8 | import javax.swing.JPanel;
9 | import javax.swing.JSlider;
10 | import javax.swing.JTextField;
11 | import javax.swing.event.ChangeEvent;
12 | import javax.swing.event.ChangeListener;
13 |
14 | import forgefuck.team.xenobyte.api.gui.ColorPicker;
15 | import forgefuck.team.xenobyte.api.gui.XenoJFrame;
16 |
17 | public class ColorPickerGui extends XenoJFrame implements ChangeListener {
18 |
19 | private ColorPicker picker;
20 | private JSlider r, g, b, a;
21 | protected JPanel sliders;
22 | private JTextField info;
23 | private JPanel viewer;
24 |
25 | public ColorPickerGui(String title, ColorPicker picker) {
26 | super(title, DISPOSE_ON_CLOSE);
27 | this.picker = picker;
28 | viewer.setBackground(new Color(picker.rgb));
29 | r.setValue(picker.r);
30 | g.setValue(picker.g);
31 | b.setValue(picker.b);
32 | a.setValue(picker.a);
33 | r.addChangeListener(this);
34 | g.addChangeListener(this);
35 | b.addChangeListener(this);
36 | a.addChangeListener(this);
37 | }
38 |
39 | @Override public void createObjects() {
40 | r = new JSlider(0, 255);
41 | g = new JSlider(0, 255);
42 | b = new JSlider(0, 255);
43 | a = new JSlider(0, 255);
44 | sliders = new JPanel();
45 | viewer = new JPanel();
46 | }
47 |
48 | @Override public void configurate() {
49 | viewer.setPreferredSize(new Dimension(25, 25));
50 | r.setPreferredSize(new Dimension(350, 50));
51 | g.setPreferredSize(new Dimension(350, 50));
52 | b.setPreferredSize(new Dimension(350, 50));
53 | a.setPreferredSize(new Dimension(350, 50));
54 | sliders.setLayout(new GridBagLayout());
55 | }
56 |
57 | @Override public void localizeSet() {
58 | a.setBorder(customTitledBorder(lang.get("Transparency", "Прозрачность")));
59 | r.setBorder(customTitledBorder(lang.get("Red", "Красный")));
60 | g.setBorder(customTitledBorder(lang.get("Green", "Зеленый")));
61 | b.setBorder(customTitledBorder(lang.get("Blue", "Синий")));
62 | }
63 |
64 | @Override public void addElements() {
65 | buttonsBar.add(accept);
66 | add(viewer);
67 | sliders.add(r, GBC);
68 | sliders.add(g, GBC);
69 | sliders.add(b, GBC);
70 | sliders.add(a, GBC);
71 | add(sliders);
72 | add(buttonsBar);
73 | }
74 |
75 | @Override public void stateChanged(ChangeEvent e) {
76 | viewer.setBackground(new Color(r.getValue(), g.getValue(), b.getValue()));
77 | picker.setColor(r.getValue(), g.getValue(), b.getValue(), a.getValue());
78 | }
79 |
80 | @Override public void actionPerformed(ActionEvent e) {
81 | if (e.getSource() == accept) {
82 | dispose();
83 | }
84 | }
85 |
86 | }
87 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/WayLine.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import java.awt.Color;
4 | import java.util.List;
5 | import java.util.concurrent.CopyOnWriteArrayList;
6 |
7 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
8 | import forgefuck.team.xenobyte.api.config.Cfg;
9 | import forgefuck.team.xenobyte.api.gui.ColorPicker;
10 | import forgefuck.team.xenobyte.api.module.Category;
11 | import forgefuck.team.xenobyte.api.module.CheatModule;
12 | import forgefuck.team.xenobyte.api.module.PerformMode;
13 | import forgefuck.team.xenobyte.gui.click.elements.Button;
14 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
15 | import forgefuck.team.xenobyte.gui.swing.ColorPickerGui;
16 | import net.minecraft.client.renderer.entity.RenderManager;
17 | import net.minecraft.entity.player.EntityPlayer;
18 | import net.minecraftforge.client.event.RenderWorldLastEvent;
19 |
20 | public class WayLine extends CheatModule {
21 |
22 | @Cfg("color") private int color;
23 | private List poses;
24 | private ColorPicker picker;
25 |
26 | public WayLine() {
27 | super("WayLine", Category.WORLD, PerformMode.TOGGLE);
28 | poses = new CopyOnWriteArrayList();
29 | color = new Color(0, 255, 255).getRGB();
30 | }
31 |
32 | @Override public void onPostInit() {
33 | picker = new ColorPicker(color) {
34 | @Override public void onColorUpdate() {
35 | WayLine.this.color = rgba;
36 | }
37 | };
38 | }
39 |
40 | @Override public int tickDelay() {
41 | return 5;
42 | }
43 |
44 | @Override public void onTick(boolean inGame) {
45 | if (inGame) {
46 | EntityPlayer pl = utils.player();
47 | if (!pl.isDead && !pl.isPlayerSleeping() && !utils.isAfk(pl)) {
48 | poses.add(new double[] { RenderManager.renderPosX, RenderManager.renderPosY - pl.height, RenderManager.renderPosZ });
49 | }
50 | }
51 | }
52 |
53 | @SubscribeEvent public void worldRender(RenderWorldLastEvent e) {
54 | render.WORLD.drawWayLine(poses, picker.rf, picker.gf, picker.bf, picker.af, 3);
55 | }
56 |
57 | @Override public String moduleDesc() {
58 | return lang.get("Drawing the trackline behind the player", "Отрисовка путевой линии за игроком");
59 | }
60 |
61 | @Override public Panel settingPanel() {
62 | return new Panel(
63 | new Button("LineColor") {
64 | @Override public void onLeftClick() {
65 | new ColorPickerGui("Цвет линии", picker).showFrame();
66 | }
67 | @Override public String elementDesc() {
68 | return lang.get("Line color", "Цвет линии");
69 | }
70 | },
71 | new Button("Clear") {
72 | @Override public void onLeftClick() {
73 | poses.clear();
74 | }
75 | @Override public String elementDesc() {
76 | return lang.get("Clear line", "Очистить линию");
77 | }
78 | }
79 | );
80 | }
81 |
82 | }
83 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/CacheGive.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import java.util.UUID;
4 |
5 | import cpw.mods.fml.common.Loader;
6 | import forgefuck.team.xenobyte.api.module.Category;
7 | import forgefuck.team.xenobyte.api.module.CheatModule;
8 | import forgefuck.team.xenobyte.api.module.PerformMode;
9 | import forgefuck.team.xenobyte.api.module.PerformSource;
10 | import net.minecraft.item.ItemStack;
11 | import net.minecraft.tileentity.TileEntity;
12 |
13 | public class CacheGive extends CheatModule {
14 |
15 | public CacheGive() {
16 | super("CacheGive", Category.MODS, PerformMode.SINGLE);
17 | }
18 |
19 | @Override public void onPerform(PerformSource src) {
20 | TileEntity checkTile = utils.tile();
21 | try {
22 | if (Class.forName("cofh.thermalexpansion.block.cache.TileCache").isInstance(checkTile)) {
23 | Object packet = Class.forName("cofh.core.network.PacketTile").getConstructor(TileEntity.class).newInstance(checkTile);
24 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addString", String.class).invoke(packet, "");
25 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addByte", byte.class).invoke(packet, (byte) 0);
26 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addUUID", UUID.class).invoke(packet, UUID.randomUUID());
27 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addString", String.class).invoke(packet, "");
28 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addBool", boolean.class).invoke(packet, true);
29 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addByte", byte.class).invoke(packet, (byte) 0);
30 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addBool", boolean.class).invoke(packet, true);
31 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addInt", int.class).invoke(packet, 0);
32 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addByteArray", byte[].class).invoke(packet, new byte[6]);
33 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addByte", byte.class).invoke(packet, (byte) 0);
34 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addBool", boolean.class).invoke(packet, false);
35 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addItemStack", ItemStack.class).invoke(packet, giveSelector().givedItem());
36 | Class.forName("cofh.core.network.PacketCoFHBase").getMethod("addInt", int.class).invoke(packet, giveSelector().fillAllSlots() ? Integer.MAX_VALUE : giveSelector().itemCount());
37 | Class.forName("cofh.core.network.PacketHandler").getMethod("sendToServer", Class.forName("cofh.core.network.PacketBase")).invoke(null, packet);
38 | }
39 | } catch(Exception e) {}
40 | }
41 |
42 | @Override public String moduleDesc() {
43 | return lang.get("Issuance of an item to the cache that the player is looking at", "Выдача предмета в Тайник на который смотрит игрок");
44 | }
45 |
46 | @Override public boolean isWorking() {
47 | return Loader.isModLoaded("ThermalExpansion");
48 | }
49 |
50 | }
51 |
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/utils/FileProvider.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.utils;
2 |
3 | import java.awt.Dimension;
4 | import java.awt.Toolkit;
5 | import java.io.File;
6 | import java.io.FileOutputStream;
7 | import java.io.IOException;
8 | import java.io.OutputStreamWriter;
9 | import java.nio.charset.StandardCharsets;
10 |
11 | import javax.swing.JFileChooser;
12 | import javax.swing.filechooser.FileFilter;
13 |
14 | import org.apache.commons.io.FileUtils;
15 |
16 | public class FileProvider extends File {
17 |
18 | private static int openerIndent = 350;
19 | private static File lastOpenedFile;
20 | private OutputStreamWriter linear;
21 | private long timeStamp;
22 |
23 | public FileProvider(File file) {
24 | super(file.getPath());
25 | }
26 |
27 | public FileProvider(File file, boolean lines) {
28 | this(file);
29 | try {
30 | linear = new OutputStreamWriter(new FileOutputStream(this), StandardCharsets.UTF_8);
31 | } catch (IOException e) {}
32 | }
33 |
34 | public String readFile() {
35 | try {
36 | return FileUtils.readFileToString(this, StandardCharsets.UTF_8).replaceAll("\\s+", " ");
37 | } catch (IOException e) {
38 | e.printStackTrace();
39 | }
40 | timeStamp = lastModified();
41 | return "";
42 | }
43 |
44 | public void writeFile(String in) {
45 | try {
46 | FileUtils.writeStringToFile(this, in, StandardCharsets.UTF_8);
47 | } catch (IOException e) {
48 | e.printStackTrace();
49 | }
50 | }
51 |
52 | public void writeLine(String line) {
53 | try {
54 | linear.write(line);
55 | linear.flush();
56 | } catch (Exception e) {}
57 | }
58 |
59 | public boolean checkTimeStamp() {
60 | long newTimeStamp = new File(getPath()).lastModified();
61 | if (timeStamp != newTimeStamp) {
62 | readFile();
63 | return true;
64 | }
65 | return false;
66 | }
67 |
68 | public static File openFileDialog(String message, String filter) {
69 | Dimension scr = Toolkit.getDefaultToolkit().getScreenSize();
70 | JFileChooser fileopen = new JFileChooser(lastOpenedFile);
71 | fileopen.setFileFilter(new FileFilter() {
72 | @Override public boolean accept(File file) {
73 | if(file != null) {
74 | if (file.isDirectory()) {
75 | return true;
76 | }
77 | return file.getName().endsWith(filter);
78 | }
79 | return false;
80 | }
81 | @Override public String getDescription() {
82 | return "*." + filter;
83 | }
84 |
85 | });
86 | fileopen.setAcceptAllFileFilterUsed(false);
87 | fileopen.setMultiSelectionEnabled(false);
88 | fileopen.setPreferredSize(new Dimension(scr.width - openerIndent, scr.height - openerIndent));
89 | if (fileopen.showDialog(null, message + " *" + filter) == JFileChooser.APPROVE_OPTION) {
90 | File openedFile = fileopen.getSelectedFile();
91 | lastOpenedFile = openedFile;
92 | return openedFile;
93 | }
94 | return null;
95 | }
96 |
97 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/GuiElement.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | import forgefuck.team.xenobyte.api.Xeno;
4 | import forgefuck.team.xenobyte.api.render.IDraw;
5 | import forgefuck.team.xenobyte.render.GuiScaler;
6 |
7 | public abstract class GuiElement extends ElementAbility implements IDraw, Xeno {
8 |
9 | private boolean hovered, selected, hoverCheck;
10 | private int x, y, width, height;
11 |
12 | public GuiElement() {
13 | onInit();
14 | }
15 |
16 | public void setPos(int x, int y) {
17 | setX(x);
18 | setY(y);
19 | }
20 |
21 | public void setX(int x) {
22 | this.x = x;
23 | }
24 |
25 | public void setY(int y) {
26 | this.y = y;
27 | }
28 |
29 | public void setWidth(int width) {
30 | this.width = width;
31 | }
32 |
33 | public void setHeight(int height) {
34 | this.height = height;
35 | }
36 |
37 | public int getX() {
38 | return x;
39 | }
40 |
41 | public int getY() {
42 | return y;
43 | }
44 |
45 | public int getWidth() {
46 | return width;
47 | }
48 |
49 | public int getHeight() {
50 | return height;
51 | }
52 |
53 | public int getMaxX() {
54 | return getX() + getWidth();
55 | }
56 |
57 | public int getMaxY() {
58 | return getY() + getHeight();
59 | }
60 |
61 | public void setSelected(boolean selected) {
62 | this.selected = selected;
63 | }
64 |
65 | public boolean isSelected() {
66 | return selected;
67 | }
68 |
69 | public boolean isHovered() {
70 | return hovered;
71 | }
72 |
73 | public void scroll(int dir, boolean withShift) {
74 | if (isHovered()) {
75 | onScroll(dir, withShift);
76 | }
77 | }
78 |
79 | public void keyTyped(char symb, int key) {
80 | if (isHovered()) {
81 | onKeyTyped(symb, key);
82 | }
83 | }
84 |
85 | public boolean click(int key) {
86 | if (isHovered()) {
87 | switch (key) {
88 | case 0:
89 | onLeftClick();
90 | break;
91 | case 1:
92 | onRightClick();
93 | break;
94 | case 2:
95 | onScrollClick();
96 | break;
97 | }
98 | return true;
99 | }
100 | return false;
101 | }
102 |
103 | public void drawDesc() {
104 | if (elementDesc() != null && isHovered()) {
105 | render.GUI.drawDesc(elementDesc());
106 | }
107 | }
108 |
109 | @Override public void draw() {
110 | int mouseX = GuiScaler.mouseX();
111 | int mouseY = GuiScaler.mouseY();
112 | if (hovered = (mouseX >= getX() && mouseX < getMaxX()) && (mouseY >= getY() && mouseY < getMaxY())) {
113 | if (!hoverCheck) {
114 | hoverCheck = true;
115 | onHovered();
116 | }
117 | } else {
118 | if (hoverCheck) {
119 | hoverCheck = false;
120 | onDishovered();
121 | }
122 | }
123 | onDraw();
124 | }
125 |
126 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/modules/RadioHack.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.modules;
2 |
3 | import java.util.ArrayList;
4 | import java.util.List;
5 |
6 | import cpw.mods.fml.common.Loader;
7 | import forgefuck.team.xenobyte.api.config.Cfg;
8 | import forgefuck.team.xenobyte.api.gui.InputType;
9 | import forgefuck.team.xenobyte.api.module.Category;
10 | import forgefuck.team.xenobyte.api.module.CheatModule;
11 | import forgefuck.team.xenobyte.api.module.PerformMode;
12 | import forgefuck.team.xenobyte.api.module.PerformSource;
13 | import forgefuck.team.xenobyte.gui.click.elements.Button;
14 | import forgefuck.team.xenobyte.gui.click.elements.Panel;
15 | import forgefuck.team.xenobyte.gui.swing.UserInput;
16 | import net.minecraft.tileentity.TileEntity;
17 |
18 | public class RadioHack extends CheatModule {
19 |
20 | @Cfg("urls") private List urls;
21 | @Cfg("kick") private boolean kick;
22 |
23 | public RadioHack() {
24 | super("RadioHack", Category.MODS, PerformMode.SINGLE);
25 | urls = new ArrayList();
26 | urls.add("https://files.catbox.moe/s0wkfi.mp3");
27 | }
28 |
29 | private void sendRadioPacket(TileEntity tile, boolean playing) {
30 | String url = urls.get(0);
31 | if (!url.isEmpty()) {
32 | utils.sendPacket("DragonsRadioMod", (byte) 0, 13, (double) tile.xCoord, (double) tile.yCoord, (double) tile.zCoord, utils.worldId(), url.length(), url.getBytes(), playing, (float) 1, (double) 0, (double) 0, (double) 0);
33 | }
34 | }
35 |
36 | private boolean isRadioTile(TileEntity tile) {
37 | try {
38 | return Class.forName("eu.thesociety.DragonbornSR.DragonsRadioMod.Block.TileEntity.TileEntityRadio").isInstance(tile);
39 | } catch(Exception e) {
40 | return false;
41 | }
42 | }
43 |
44 | public boolean getKick() {
45 | return kick;
46 | }
47 |
48 | @Override public void onPerform(PerformSource src) {
49 | for (TileEntity tile : utils.nearTiles()) {
50 | if (kick && !isRadioTile(tile)) {
51 | sendRadioPacket(tile, true);
52 | break;
53 | } else if (isRadioTile(tile)) {
54 | sendRadioPacket(tile, false);
55 | sendRadioPacket(tile, true);
56 | }
57 | }
58 | }
59 |
60 | @Override public boolean isWorking() {
61 | return Loader.isModLoaded("DragonsRadioMod");
62 | }
63 |
64 | @Override public String moduleDesc() {
65 | return lang.get("Replacing links in nearby radio blocks", "Замена ссылки в находящихся вблизи блоках радио");
66 | }
67 |
68 | @Override public Panel settingPanel() {
69 | return new Panel(
70 | new Button("RadioUrl") {
71 | @Override public void onLeftClick() {
72 | new UserInput(lang.get("Url", "Ссылка"), urls, InputType.SINGLE_STRING).showFrame();
73 | }
74 | },
75 | new Button("KickMode", kick) {
76 | @Override public void onLeftClick() {
77 | buttonValue(kick = !kick);
78 | }
79 | @Override public String elementDesc() {
80 | return lang.get("Kick nearby players", "Режим кика ближайших игроков");
81 | }
82 | }
83 | );
84 | }
85 |
86 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/api/gui/XenoJFrame.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.api.gui;
2 |
3 | import java.awt.Color;
4 | import java.awt.Font;
5 | import java.awt.GridBagConstraints;
6 | import java.awt.event.ActionListener;
7 |
8 | import javax.swing.BorderFactory;
9 | import javax.swing.BoxLayout;
10 | import javax.swing.JButton;
11 | import javax.swing.JFrame;
12 | import javax.swing.JToolBar;
13 | import javax.swing.border.Border;
14 | import javax.swing.border.TitledBorder;
15 |
16 | import forgefuck.team.xenobyte.api.Xeno;
17 | import forgefuck.team.xenobyte.render.Images;
18 |
19 | public abstract class XenoJFrame extends JFrame implements ActionListener, Xeno {
20 |
21 | public static final Border BORDER = BorderFactory.createLineBorder(Color.BLACK);
22 | public static final GridBagConstraints GBC = new GridBagConstraints();
23 | public static final Font FONT = new Font("Terminal", Font.BOLD, 12);
24 | public static final Color WHITE = new Color(255, 255, 255);
25 | public static final Color FAIL = new Color(255, 200, 200);
26 | protected final JButton accept, clear;
27 | protected final JToolBar buttonsBar;
28 | private static XenoJFrame lastFrame;
29 | private boolean resume;
30 |
31 | public XenoJFrame(String title, int closeOperation) {
32 | super(title);
33 | setLayout(new BoxLayout(getContentPane(), BoxLayout.Y_AXIS));
34 | GBC.gridwidth = GridBagConstraints.REMAINDER;
35 | setDefaultCloseOperation(closeOperation);
36 | accept = new JButton();
37 | clear = new JButton();
38 | accept.addActionListener(this);
39 | clear.addActionListener(this);
40 | buttonsBar = new JToolBar();
41 | buttonsBar.setFloatable(false);
42 | setIconImage(Images.ICON);
43 | accept.setFont(FONT);
44 | clear.setFont(FONT);
45 | setResizable(false);
46 | createObjects();
47 | configurate();
48 | addElements();
49 | fillData();
50 | }
51 |
52 | public static Border customTitledBorder(String title, int align) {
53 | TitledBorder border = BorderFactory.createTitledBorder(title);
54 | border.setTitleJustification(align);
55 | return border;
56 | }
57 |
58 | public static Border customTitledBorder(String title) {
59 | return customTitledBorder(title, TitledBorder.LEFT);
60 | }
61 |
62 | public void packFrame() {
63 | pack();
64 | setLocationRelativeTo(null);
65 | }
66 |
67 | public void showFrame() {
68 | showFrame(false);
69 | }
70 |
71 | public void resume() {
72 | resume = true;
73 | }
74 |
75 | public void showFrame(boolean waiting) {
76 | if (lastFrame != null) {
77 | lastFrame.dispose();
78 | }
79 | lastFrame = this;
80 | accept.setText(lang.get("Accept", "Применить"));
81 | clear.setText(lang.get("Reset", "Сбросить"));
82 | setState(NORMAL);
83 | localizeSet();
84 | packFrame();
85 | setVisible(true);
86 | toFront();
87 | if (waiting) {
88 | for (;;) {
89 | if (resume) break;
90 | try {
91 | Thread.sleep(100);
92 | } catch(Exception e) {}
93 | }
94 | }
95 | }
96 |
97 | protected abstract void createObjects();
98 | protected abstract void configurate();
99 | protected abstract void addElements();
100 | protected abstract void localizeSet();
101 | protected void fillData() {};
102 |
103 | }
--------------------------------------------------------------------------------
/src/main/java/forgefuck/team/xenobyte/utils/EventHelper.java:
--------------------------------------------------------------------------------
1 | package forgefuck.team.xenobyte.utils;
2 |
3 | import java.lang.reflect.Constructor;
4 | import java.lang.reflect.Method;
5 | import java.util.ArrayList;
6 | import java.util.Map;
7 | import java.util.Set;
8 | import java.util.concurrent.ConcurrentHashMap;
9 |
10 | import com.google.common.reflect.TypeToken;
11 |
12 | import cpw.mods.fml.common.FMLCommonHandler;
13 | import cpw.mods.fml.common.Loader;
14 | import cpw.mods.fml.common.ModContainer;
15 | import cpw.mods.fml.common.eventhandler.ASMEventHandler;
16 | import cpw.mods.fml.common.eventhandler.Event;
17 | import cpw.mods.fml.common.eventhandler.EventBus;
18 | import cpw.mods.fml.common.eventhandler.IEventListener;
19 | import cpw.mods.fml.common.eventhandler.SubscribeEvent;
20 | import cpw.mods.fml.relauncher.ReflectionHelper;
21 | import net.minecraftforge.common.MinecraftForge;
22 |
23 | public class EventHelper {
24 |
25 | public static void register(Object o) {
26 | registerBus(FMLCommonHandler.instance().bus(), o);
27 | registerBus(MinecraftForge.EVENT_BUS, o);
28 | }
29 |
30 | public static void unregister(Object o) {
31 | FMLCommonHandler.instance().bus().unregister(o);
32 | MinecraftForge.EVENT_BUS.unregister(o);
33 | }
34 |
35 | private static void registerBus(EventBus bus, Object target) {
36 | ConcurrentHashMap