commit e7179fad45888f3afa25093eadcd8677f949bccf
Author: LAX1DUDE
Date: Sun Dec 25 01:12:28 2022 -0800
Update #0 - First Release
diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 00000000..e3813a4d
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,7 @@
+#
+# https://help.github.com/articles/dealing-with-line-endings/
+#
+
+*.bat text eol=crlf
+*.sh text eol=lf
+gradlew text eol=lf
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 00000000..cb59d986
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,10 @@
+buildtools_config.json
+MinecraftSrc.zip
+/MinecraftSrc/*
+/pullrequest_merged_*
+/patches.*
+/mcp918/*
+!/mcp918/readme.txt
+!/mcp918/assetsIndexTransformer.json
+/rundir/*
+/##TEAVM.TMP##/*
\ No newline at end of file
diff --git a/CREDITS b/CREDITS
new file mode 100644
index 00000000..7f6ab472
--- /dev/null
+++ b/CREDITS
@@ -0,0 +1,553 @@
+
+ EaglercraftX Developers
+ ~~~~~~~~~~~~~~~~~~~~~~~
+
+ lax1dude:
+
+ - Creator of Eaglercraft
+ - Wrote HW accelerated OpenGL 1.3 emulator
+ - Wrote all desktop emulation code
+ - Ported the Minecraft 1.8 client src to TeaVM
+ - Wrote EaglercraftXBungee
+ - Wrote the patch and build system
+
+ ayunami2000:
+
+ - Many bug fixes
+ - Added resource packs
+ - Added screen recording
+ - Created the replit
+
+
+
+ Code used within EaglercraftX
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: TeaVM
+ Project Author: Alexey Andreev
+ Project URL: https://teavm.org/
+
+ Used For: Compiling Java to JS, JRE implementation
+
+ * Copyright 2014 Alexey Andreev.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: LWJGL 3
+ Project Author: Spasi
+ Project URL: https://www.lwjgl.org
+
+ Used For: OpenGL, OpenAL, and GLFW bindings in desktop debug runtime
+
+ * Copyright (c) 2012-present Lightweight Java Game Library
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * - Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * - Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * - Neither the name Lightweight Java Game Library nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: java-diff-utils
+ Project Author: Google, forked by wumpz
+ Project URL: https://java-diff-utils.github.io/java-diff-utils/
+
+ Used For: generating and applying patch files in build system
+
+ * Copyright 2009-2017 java-diff-utils.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: Google Guava
+ Project Author: Google
+ Project URL: https://github.com/google/guava
+
+ Used For: It's a dependency for Minecraft 1.8
+
+ * Copyright (C) 2011 The Guava Authors
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: javax.annotation
+ Project Author: Oracle Inc.
+ Project URL: ??
+
+ Used For: Dependency for Google Guava
+
+ * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved.
+ *
+ * The contents of this file are subject to the terms of either the GNU
+ * General Public License Version 2 only ("GPL") or the Common Development
+ * and Distribution License("CDDL") (collectively, the "License"). You
+ * may not use this file except in compliance with the License. You can
+ * obtain a copy of the License at
+ * https://oss.oracle.com/licenses/CDDL+GPL-1.1
+ * or LICENSE.txt. See the License for the specific
+ * language governing permissions and limitations under the License.
+ *
+ * When distributing the software, include this License Header Notice in each
+ * file and include the License file at LICENSE.txt.
+ *
+ * GPL Classpath Exception:
+ * Oracle designates this particular file as subject to the "Classpath"
+ * exception as provided by Oracle in the GPL Version 2 section of the License
+ * file that accompanied this code.
+ *
+ * Modifications:
+ * If applicable, add the following below the License Header, with the fields
+ * enclosed by brackets [] replaced by your own identifying information:
+ * "Portions Copyright [year] [name of copyright owner]"
+ *
+ * Contributor(s):
+ * If you wish your version of this file to be governed by only the CDDL or
+ * only the GPL Version 2, indicate your decision by adding "[Contributor]
+ * elects to include this software in this distribution under the [CDDL or GPL
+ * Version 2] license." If you don't indicate a single choice of license, a
+ * recipient has the option to distribute your version of this file under
+ * either the CDDL, the GPL Version 2 or to extend the choice of license to
+ * its licensees as provided above. However, if you add GPL Version 2 code
+ * and therefore, elected the GPL Version 2 license, then the option applies
+ * only if the new code is made subject to such option by the copyright
+ * holder.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: Apache Commons Lang
+ Project Author: Apache Software Foundation
+ Project URL: https://commons.apache.org/proper/commons-lang/
+
+ Used For: It's a dependency for Minecraft 1.8
+
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: Apache Commons IO
+ Project Author: Apache Software Foundation
+ Project URL: https://commons.apache.org/proper/commons-io/
+
+ Used For: simplifying file IO in build system
+
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: Apache Commons CSV
+ Project Author: Apache Software Foundation
+ Project URL: https://commons.apache.org/proper/commons-csv/
+
+ Used For: loading mod coder pack config files in build system
+
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: JSON-java
+ Project Author: Sean Leary (stleary)
+ Project URL: https://github.com/stleary/JSON-java
+
+ Used For: JSON serialization and parsing in client and build system
+
+ * Public domain.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: Eclipse IDE Java Formatter
+ Project Author: Eclipse Foundation
+ Project URL: https://www.eclipse.org/
+
+ Used For: Formatting source code in build system before making diffs
+
+ * License is here: https://www.eclipse.org/legal/epl-2.0/
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: ObjectWeb ASM
+ Project Author: OW2
+ Project URL: https://asm.ow2.io/
+
+ Used For: parsing method signatures in build system
+
+ * ASM: a very small and fast Java bytecode manipulation framework
+ * Copyright (c) 2000-2011 INRIA, France Telecom
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the copyright holders nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: Bouncy Castle Crypto
+ Project Author: The Legion of the Bouncy Castle
+ Project URL: https://www.bouncycastle.org/java.html
+
+ Used For: MD5, SHA-1, SHA-256 implementations
+
+ * Copyright (c) 2000-2021 The Legion of the Bouncy Castle Inc. (https://www.bouncycastle.org)
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software
+ * and associated documentation files (the "Software"), to deal in the Software without restriction,
+ * including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so,
+ * subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all copies or substantial
+ * portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+ * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
+ * PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+ * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+ * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+ * DEALINGS IN THE SOFTWARE.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: Apache Harmony JRE
+ Project Author: Apache Software Foundation
+ Project URL: https://harmony.apache.org/
+
+ Used For: TeaVM compatible String.format implementation
+
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: Apache Commons Codec
+ Project Author: Apache Software Foundation
+ Project URL: https://commons.apache.org/proper/commons-codec/
+
+ Used For: Base64 encoder/decoder implementation
+
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: JZlib
+ Project Author: ymnk, JCraft Inc.
+ Project URL: http://www.jcraft.com/jzlib/
+
+ Used For: Deflate and GZIP implementations in client
+
+ * Copyright (c) 2011 ymnk, JCraft,Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright notice,
+ * this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the distribution.
+ *
+ * 3. The names of the authors may not be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
+ * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
+ * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,
+ * INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
+ * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: Java-WebSocket
+ Project Author: Nathan Rajlich (TooTallNate)
+ Project URL: http://tootallnate.github.io/Java-WebSocket
+
+ Used For: WebSockets in desktop runtime
+
+ * Copyright (c) 2010-2020 Nathan Rajlich
+ *
+ * Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: Netty
+ Project Author: Netty Project
+ Project URL: https://netty.io/
+
+ Used For: 'ByteBuf' classes implementations for Minecraft 1.8's networking engine
+
+ * Copyright 2015 The Netty Project
+ *
+ * The Netty Project licenses this file to you under the Apache License, version 2.0 (the
+ * "License"); you may not use this file except in compliance with the License. You may obtain a
+ * copy of the License at:
+ *
+ * https://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software distributed under the License
+ * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
+ * or implied. See the License for the specific language governing permissions and limitations under
+ * the License.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: 3D Sound System
+ Project Author: Paul Lamb
+ Project URL: http://www.paulscode.com/forum/index.php?topic=4.0
+
+ Used For: Audio in desktop runtime
+
+ * SoundSystem License:
+ *
+ * You are free to use this library for any purpose, commercial or
+ * otherwise. You may modify this library or source code, and distribute it any
+ * way you like, provided the following conditions are met:
+ *
+ * 1) You must abide by the conditions of the aforementioned LWJGL License.
+ *
+ * 2) You may not falsely claim to be the author of this library or any
+ * unmodified portion of it.
+ *
+ * 3) You may not copyright this library or a modified version of it and then
+ * sue me for copyright infringement.
+ *
+ * 4) If you modify the source code, you must clearly document the changes made
+ * before redistributing the modified source code, so other users know it is not
+ * the original code.
+ *
+ * 5) You are not required to give me credit for this library in any derived
+ * work, but if you do, you must also mention my website:
+ * http://www.paulscode.com
+ *
+ * 6) I the author will not be responsible for any damages (physical, financial,
+ * or otherwise) caused by the use if this library or any part of it.
+ *
+ * 7) I the author do not guarantee, warrant, or make any representations,
+ * either expressed or implied, regarding the use of this library or any part of
+ * it.
+ *
+ * Author: Paul Lamb
+ * http://www.paulscode.com
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: JOrbis
+ Project Author: ymnk, JCraft Inc.
+ Project URL: http://www.jcraft.com/jorbis/
+
+ Used For: Audio in desktop runtime
+
+ * JOrbis
+ * Copyright (C) 2000 ymnk, JCraft,Inc.
+ *
+ * Written by: 2000 ymnk
+ *
+ * Many thanks to
+ * Monty and
+ * The XIPHOPHORUS Company http://www.xiph.org/ .
+ * JOrbis has been based on their awesome works, Vorbis codec.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public License
+ * as published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Project Name: sqlite-jdbc
+ Project Author: Taro L. Saito (xerial)
+ Project URL: https://github.com/xerial/sqlite-jdbc
+
+ Used For: Default skin cache and authentication JDBC driver in EaglerXBungee
+
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+ Make sure you also update the copy of this file in "sources/resources/assets/eagler/CREDITS"
+
+ The content of both files should match, but not include this notice in the resources one
diff --git a/CompileLatestClient.bat b/CompileLatestClient.bat
new file mode 100644
index 00000000..e1f1a079
--- /dev/null
+++ b/CompileLatestClient.bat
@@ -0,0 +1,6 @@
+@echo off
+title CompileLatestClient
+java -cp "buildtools/BuildTools.jar" net.lax1dude.eaglercraft.v1_8.buildtools.gui.CompileLatestClientGUI
+del /S /Q "##TEAVM.TMP##\*"
+rmdir /S /Q "##TEAVM.TMP##"
+pause
\ No newline at end of file
diff --git a/CompileLatestClient.sh b/CompileLatestClient.sh
new file mode 100644
index 00000000..eddf1a97
--- /dev/null
+++ b/CompileLatestClient.sh
@@ -0,0 +1,3 @@
+#!/bin/sh
+java -cp "buildtools/BuildTools.jar" net.lax1dude.eaglercraft.v1_8.buildtools.gui.CompileLatestClientGUI
+rm -rf "##TEAVM.TMP##"
\ No newline at end of file
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 00000000..b4273446
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,64 @@
+
+Copyright (c) 2022 LAX1DUDE. All Rights Reserved.
+
+WITH THE EXCEPTION OF PATCH FILES, MINIFIED JAVASCRIPT, AND ALL FILES NORMALLY
+FOUND IN AN UNMODIFIED MINECRAFT RESOURCE PACK, YOU ARE NOT ALLOWED TO SHARE,
+DISTRIBUTE, OR REPURPOSE ANY FILE USED BY OR PRODUCED BY THE SOFTWARE IN THIS
+REPOSITORY WITHOUT PRIOR PERMISSION FROM THE PROJECT AUTHOR.
+
+NOT FOR COMMERCIAL OR MALICIOUS USE
+
+Prohibited sharing, distribution, and repurposing these files includes but is not
+limited to: Publicly sharing or distributing any significant portion, modified or
+unmodified, of any source code files produced by the buildtools commands without
+minification or obfuscation, with the exception of patch files. Publicly
+repurposing, without permission, the source code for any file which is a part of
+the Eaglercraft runtime, as in any additional source files required for output of
+buildtools commands to run on a specific platform. Publicly repurposing, without
+permission, any resource file found in the project's default resource pack that
+does not exist in vanilla Minecraft resource packs. And, additionally, publicly
+repurposing, without permission, any data produced by the act of compiling or
+converting the files described in these previous three cases, besides the compiled
+or minified application (the 'game') itself.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+
+Prohibited commercial use includes selling access to any files or data (including
+the game itself) contained or produced by this repository, requiring the direct
+forced viewing of advertisement presented when a user attempts to load a compiled
+version of this project (or follow a hyperlink to the project's source or files
+derived from it, examples include using adfoc.us or adf.ly on your site), and
+selling content in any form that can only be accessed through the use of this
+project or files produced by or derived from it. Making a pay-to-win multiplayer
+server, for example, would be prohibited under these terms.
+
+Malicious use includes creating and/or distributing modified versions of the
+game's 1.8 client (often referred to as "hacked clients") which give you an unfair
+advantage on multiplayer servers, creating and/or distributing modified clients
+which allow you to exploit bugs in EaglercraftXBungee or Eagler-compatible server
+software, creating and/or distributing modified clients which allow you to exploit
+bugs in Minecraft servers or Minecraft-compatible server software, or creating
+and/or distributing modified clients which allow you to exploit bugs in portions of
+any other software used in companion with EaglerXBungee or on an Eagler-compatible
+server (e.g. VIAaaS, NGINX, Caddy)
+
+Distribution of any file or a product of compilation or conversion covered by this
+document must retain all existing copyright notices found within the file and
+folders before any modifications were made.
+
+BY VIOLATING THESE TERMS YOU AGREE TO A BLOCK/BAN FROM ALL SOURCES OF DOCUMENTATION
+AND SUPPORT FOR THIS PROJECT, PERMISSION TO USE THESE FILES WAS GIVEN TO YOU IN
+GOOD FAITH THAT THE WORK WILL NOT BE ABUSED, AND VIOLATING THIS AGREEMENT IS A
+DEMONSTRATION OF A LACK OF RESPECT AND GOOD INTENTIONS ON BEHALF OF YOUR EFFORTS TO
+LEARN HOW TO USE THESE TOOLS CORRECTLY AND IS JUSTIFICATION FOR YOUR EXCLUSION FROM
+ANY AND ALL SOURCES OF DOCUMENTATION OR SUPPORT THAT WILL ASSIST YOU TO CONTINUE TO
+VIOLATE THESE TERMS
diff --git a/README.md b/README.md
new file mode 100644
index 00000000..05cbf612
--- /dev/null
+++ b/README.md
@@ -0,0 +1,67 @@
+# EaglercraftX 1.8
+
+### Play real Minecraft 1.8 in your browser, currently only supports multiplayer
+
+
+
+## ATTENTION MOJANG/MICROSOFT EMPLOYEE ASSIGNED TO STALK ME:
+
+### THIS REPOSITORY DOES NOT CONTAIN YOUR INTELLECTUAL PROPERTY
+
+### FILING A FALSE DMCA IS ILLEGAL AND IMMORAL
+
+### This repository contains:
+
+ - **Utilities to decompile Minecraft 1.8 and apply patch files to it**
+ - **Source code to provide the LWJGL keyboard, mouse, and OpenGL APIs in a browser**
+ - **Source code for an OpenGL 1.3 emulator built on top of WebGL 2.0**
+ - **Patch files to mod the Minecraft 1.8 source code to make it browser compatible**
+ - **Browser-modified portions of Minecraft 1.8's open-source dependencies**
+ - **Plugins for Minecraft servers to allow the eagler client to connect to them**
+
+### This repository does NOT contain:
+
+ - **Any portion of the decompiled Minecraft 1.8 source code or resources**
+ - **Any portion of Mod Coder Pack and it's config files**
+ - **Data that can be used alone to reconstruct portions of the game's source code**
+ - **Code configured by default to allow users to play without owning a copy of Minecraft**
+
+## Getting Started:
+
+### To compile the latest version of the client, on Windows:
+
+1. Make sure you have at least Java 11 installed and added to your PATH
+2. Download (clone) this repository to your computer
+3. Double click `CompileLatestClient.bat`, a GUI resembling a classic windows installer should open
+4. Follow the steps shown to you in the new window to finish compiling
+
+### To compile the latest version of the client, on Linux/macOS:
+
+1. Make sure you have at least Java 11 installed
+2. Download (clone) this repository to your computer
+3. Open a terminal in the folder the repository was cloned to
+4. Type `chmod +x CompileLatestClient.sh` and hit enter
+5. Type `./CompileLatestClient.sh` and hit enter, a GUI resembling a classic windows installer should open
+6. Follow the steps shown to you in the new window to finish compiling
+
+## Making a Server:
+
+**EaglercraftX 1.8's server is a BungeeCord/Waterfall PLUGIN, not an entire "fork" of bungeecord like the 1.5 Eaglerbungee was, and I can't believe I have to clarify this too but the EaglerXBungee 1.8 plugin is not compatible with the old 1.5 bungee, you must migrate to the latest version of official BungeeCord/Waterfall to use it**
+
+Simply set up the latest version of BungeeCord or Waterfall and download [EaglerXBungee-Latest.jar](https://gitlab.com/lax1dude/eaglercraftx-1.8/-/raw/main/gateway/EaglercraftXBungee/EaglerXBungee-Latest.jar) and place it in the plugins directory.
+
+Then to actually log in to the server with Eaglercraft, first join your server using vanilla Minecraft Java Edition 1.8 and run the new `/eagler` command to set a password. Then leave the server and switch to your EaglercraftX client.
+
+Set your EaglercraftX username to the same username as the vanilla minecraft account you set the password with, then when you try to join your server it will present you with a login screen where you can enter the password you set. If the password is correct it will let you join the server.
+
+**NOTE: If you set `online_mode` to `false` on BungeeCord/Waterfall's config.yml, the password system will be disabled and you will be able to join with any username without setting a password like Eaglercraft 1.5. This should only ever be used for testing.**
+
+A config guide will be added here too eventually
+
+## Contributing:
+
+This part of the guide is incomplete
+
+## Developing a Client:
+
+There is currently no system in place to make forks of 1.8 and merge commits made to the patch files in this repository with the patch files or workspace of the fork, you're on your own if you try to keep a fork of this repo for reasons other than to contribute to it
diff --git a/build_clean_tmp.bat b/build_clean_tmp.bat
new file mode 100644
index 00000000..ab67fe84
--- /dev/null
+++ b/build_clean_tmp.bat
@@ -0,0 +1,4 @@
+@echo off
+title BuildTools: clean
+java -jar buildtools/BuildTools.jar clean
+pause
\ No newline at end of file
diff --git a/build_clean_tmp.sh b/build_clean_tmp.sh
new file mode 100644
index 00000000..efc95793
--- /dev/null
+++ b/build_clean_tmp.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+java -jar buildtools/BuildTools.jar clean
\ No newline at end of file
diff --git a/build_help.bat b/build_help.bat
new file mode 100644
index 00000000..7261a765
--- /dev/null
+++ b/build_help.bat
@@ -0,0 +1,4 @@
+@echo off
+title BuildTools: help
+java -jar buildtools/BuildTools.jar help
+pause
\ No newline at end of file
diff --git a/build_help.sh b/build_help.sh
new file mode 100644
index 00000000..920dd43d
--- /dev/null
+++ b/build_help.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+java -jar buildtools/BuildTools.jar help
\ No newline at end of file
diff --git a/build_init.bat b/build_init.bat
new file mode 100644
index 00000000..e6a66f5b
--- /dev/null
+++ b/build_init.bat
@@ -0,0 +1,4 @@
+@echo off
+title BuildTools: init
+java -jar buildtools/BuildTools.jar init
+pause
\ No newline at end of file
diff --git a/build_init.sh b/build_init.sh
new file mode 100644
index 00000000..56581db1
--- /dev/null
+++ b/build_init.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+java -jar buildtools/BuildTools.jar init
\ No newline at end of file
diff --git a/build_make_pullrequest.bat b/build_make_pullrequest.bat
new file mode 100644
index 00000000..b74baf49
--- /dev/null
+++ b/build_make_pullrequest.bat
@@ -0,0 +1,4 @@
+@echo off
+title BuildTools: pullrequest
+java -jar buildtools/BuildTools.jar pullrequest
+pause
\ No newline at end of file
diff --git a/build_make_pullrequest.sh b/build_make_pullrequest.sh
new file mode 100644
index 00000000..7b8dd530
--- /dev/null
+++ b/build_make_pullrequest.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+java -jar buildtools/BuildTools.jar pullrequest
\ No newline at end of file
diff --git a/build_make_unpatched.bat b/build_make_unpatched.bat
new file mode 100644
index 00000000..32855a5b
--- /dev/null
+++ b/build_make_unpatched.bat
@@ -0,0 +1,4 @@
+@echo off
+title BuildTools: unpatched
+java -jar buildtools/BuildTools.jar unpatched
+pause
\ No newline at end of file
diff --git a/build_make_unpatched.sh b/build_make_unpatched.sh
new file mode 100644
index 00000000..48d88e30
--- /dev/null
+++ b/build_make_unpatched.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+java -jar buildtools/BuildTools.jar unpatched
\ No newline at end of file
diff --git a/build_make_workspace.bat b/build_make_workspace.bat
new file mode 100644
index 00000000..33a2d78c
--- /dev/null
+++ b/build_make_workspace.bat
@@ -0,0 +1,4 @@
+@echo off
+title BuildTools: workspace
+java -jar buildtools/BuildTools.jar workspace
+pause
\ No newline at end of file
diff --git a/build_make_workspace.sh b/build_make_workspace.sh
new file mode 100644
index 00000000..b5e156bd
--- /dev/null
+++ b/build_make_workspace.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+java -jar buildtools/BuildTools.jar workspace
\ No newline at end of file
diff --git a/build_merge_direct.bat b/build_merge_direct.bat
new file mode 100644
index 00000000..aeb33188
--- /dev/null
+++ b/build_merge_direct.bat
@@ -0,0 +1,4 @@
+@echo off
+title BuildTools: merge_direct
+java -jar buildtools/BuildTools.jar merge_direct
+pause
\ No newline at end of file
diff --git a/build_merge_direct.sh b/build_merge_direct.sh
new file mode 100644
index 00000000..49d09e05
--- /dev/null
+++ b/build_merge_direct.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+java -jar buildtools/BuildTools.jar merge_direct
\ No newline at end of file
diff --git a/build_merge_pullrequest.bat b/build_merge_pullrequest.bat
new file mode 100644
index 00000000..f08d0e96
--- /dev/null
+++ b/build_merge_pullrequest.bat
@@ -0,0 +1,4 @@
+@echo off
+title BuildTools: merge
+java -jar buildtools/BuildTools.jar merge
+pause
\ No newline at end of file
diff --git a/build_merge_pullrequest.sh b/build_merge_pullrequest.sh
new file mode 100644
index 00000000..01730f15
--- /dev/null
+++ b/build_merge_pullrequest.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+java -jar buildtools/BuildTools.jar merge
\ No newline at end of file
diff --git a/build_test_pullrequest.bat b/build_test_pullrequest.bat
new file mode 100644
index 00000000..a6fcb373
--- /dev/null
+++ b/build_test_pullrequest.bat
@@ -0,0 +1,4 @@
+@echo off
+title BuildTools: pullrequest_test
+java -jar buildtools/BuildTools.jar pullrequest_test
+pause
\ No newline at end of file
diff --git a/build_test_pullrequest.sh b/build_test_pullrequest.sh
new file mode 100644
index 00000000..3fdfcf45
--- /dev/null
+++ b/build_test_pullrequest.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+java -jar buildtools/BuildTools.jar pullrequest_test
\ No newline at end of file
diff --git a/buildtools/BuildTools.jar b/buildtools/BuildTools.jar
new file mode 100644
index 00000000..20885f56
Binary files /dev/null and b/buildtools/BuildTools.jar differ
diff --git a/buildtools/Java11Check.jar b/buildtools/Java11Check.jar
new file mode 100644
index 00000000..c9194da7
Binary files /dev/null and b/buildtools/Java11Check.jar differ
diff --git a/buildtools/MAINFEST-README-PLEASE.txt b/buildtools/MAINFEST-README-PLEASE.txt
new file mode 100644
index 00000000..868b1e49
--- /dev/null
+++ b/buildtools/MAINFEST-README-PLEASE.txt
@@ -0,0 +1,4 @@
+
+when you export the BuildTools source as a jar you must copy the "MANIFEST.MF" file in this directory into the "META-INF" directory inside the JAR!!
+
+reasons: limitations in eclipse/intellij, lazyness
diff --git a/buildtools/MANIFEST.MF b/buildtools/MANIFEST.MF
new file mode 100644
index 00000000..dd4cfea0
--- /dev/null
+++ b/buildtools/MANIFEST.MF
@@ -0,0 +1,4 @@
+Manifest-Version: 1.0
+Main-Class: net.lax1dude.eaglercraft.v1_8.buildtools.EaglerBuildTools
+Class-Path: Java11Check.jar deps/asm-signature.jar deps/commons-csv-1.9.0.jar deps/commons-io-2.11.0.jar deps/eclipse-formatter.jar deps/java-diff-utils-4.11.jar deps/json-20220320.jar
+
diff --git a/buildtools/TeaVMBridge.jar b/buildtools/TeaVMBridge.jar
new file mode 100644
index 00000000..ed38b21e
Binary files /dev/null and b/buildtools/TeaVMBridge.jar differ
diff --git a/buildtools/deps/asm-signature.jar b/buildtools/deps/asm-signature.jar
new file mode 100644
index 00000000..b5c7c747
Binary files /dev/null and b/buildtools/deps/asm-signature.jar differ
diff --git a/buildtools/deps/commons-csv-1.9.0-javadoc.jar b/buildtools/deps/commons-csv-1.9.0-javadoc.jar
new file mode 100644
index 00000000..0d03f8b8
Binary files /dev/null and b/buildtools/deps/commons-csv-1.9.0-javadoc.jar differ
diff --git a/buildtools/deps/commons-csv-1.9.0.jar b/buildtools/deps/commons-csv-1.9.0.jar
new file mode 100644
index 00000000..0e3f6785
Binary files /dev/null and b/buildtools/deps/commons-csv-1.9.0.jar differ
diff --git a/buildtools/deps/commons-io-2.11.0-javadoc.jar b/buildtools/deps/commons-io-2.11.0-javadoc.jar
new file mode 100644
index 00000000..7ca3a966
Binary files /dev/null and b/buildtools/deps/commons-io-2.11.0-javadoc.jar differ
diff --git a/buildtools/deps/commons-io-2.11.0.jar b/buildtools/deps/commons-io-2.11.0.jar
new file mode 100644
index 00000000..be507d94
Binary files /dev/null and b/buildtools/deps/commons-io-2.11.0.jar differ
diff --git a/buildtools/deps/eclipse-formatter.jar b/buildtools/deps/eclipse-formatter.jar
new file mode 100644
index 00000000..f7ebb6d0
Binary files /dev/null and b/buildtools/deps/eclipse-formatter.jar differ
diff --git a/buildtools/deps/java-diff-utils-4.11-javadoc.jar b/buildtools/deps/java-diff-utils-4.11-javadoc.jar
new file mode 100644
index 00000000..bed4587b
Binary files /dev/null and b/buildtools/deps/java-diff-utils-4.11-javadoc.jar differ
diff --git a/buildtools/deps/java-diff-utils-4.11.jar b/buildtools/deps/java-diff-utils-4.11.jar
new file mode 100644
index 00000000..25ff1b9e
Binary files /dev/null and b/buildtools/deps/java-diff-utils-4.11.jar differ
diff --git a/buildtools/deps/json-20220320-javadoc.jar b/buildtools/deps/json-20220320-javadoc.jar
new file mode 100644
index 00000000..03d1342e
Binary files /dev/null and b/buildtools/deps/json-20220320-javadoc.jar differ
diff --git a/buildtools/deps/json-20220320.jar b/buildtools/deps/json-20220320.jar
new file mode 100644
index 00000000..6121978b
Binary files /dev/null and b/buildtools/deps/json-20220320.jar differ
diff --git a/buildtools/production-favicon.png b/buildtools/production-favicon.png
new file mode 100644
index 00000000..9c9fc898
Binary files /dev/null and b/buildtools/production-favicon.png differ
diff --git a/buildtools/production-index-ext.html b/buildtools/production-index-ext.html
new file mode 100644
index 00000000..faa27f5b
--- /dev/null
+++ b/buildtools/production-index-ext.html
@@ -0,0 +1,48 @@
+
+
+
+
+
+
+
+ EaglercraftX 1.8
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/buildtools/production-index.html b/buildtools/production-index.html
new file mode 100644
index 00000000..331f51f8
--- /dev/null
+++ b/buildtools/production-index.html
@@ -0,0 +1,52 @@
+
+
+
+
+
+
+
+ EaglercraftX 1.8
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/EaglerBuildTools.java b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/EaglerBuildTools.java
new file mode 100644
index 00000000..234ef1e2
--- /dev/null
+++ b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/EaglerBuildTools.java
@@ -0,0 +1,167 @@
+package net.lax1dude.eaglercraft.v1_8.buildtools;
+
+import java.io.File;
+import java.net.URL;
+import java.net.URLClassLoader;
+
+import net.lax1dude.eaglercraft.v1_8.buildtools.task.diff.MergePullRequest;
+import net.lax1dude.eaglercraft.v1_8.buildtools.task.diff.PullRequestTask;
+import net.lax1dude.eaglercraft.v1_8.buildtools.task.init.CreateUnpatched;
+import net.lax1dude.eaglercraft.v1_8.buildtools.task.init.InitTask;
+import net.lax1dude.eaglercraft.v1_8.buildtools.task.init.SetupWorkspace;
+import net.lax1dude.eaglercraft.v1_8.buildtools.task.init.TaskClean;
+
+/**
+ * Copyright (c) 2022 LAX1DUDE. All Rights Reserved.
+ *
+ * WITH THE EXCEPTION OF PATCH FILES, MINIFIED JAVASCRIPT, AND ALL FILES
+ * NORMALLY FOUND IN AN UNMODIFIED MINECRAFT RESOURCE PACK, YOU ARE NOT ALLOWED
+ * TO SHARE, DISTRIBUTE, OR REPURPOSE ANY FILE USED BY OR PRODUCED BY THE
+ * SOFTWARE IN THIS REPOSITORY WITHOUT PRIOR PERMISSION FROM THE PROJECT AUTHOR.
+ *
+ * NOT FOR COMMERCIAL OR MALICIOUS USE
+ *
+ * (please read the 'LICENSE' file this repo's root directory for more info)
+ *
+ */
+public class EaglerBuildTools {
+
+ public static File repositoryRoot = new File(".");
+
+ public static void main(String[] args) {
+ System.out.println("Eaglercraft 1.8 Build Tools");
+ System.out.println("Copyright (c) 2022 LAX1DUDE");
+ System.out.println();
+
+ if(!System.getProperty("eaglercraft.isJava11", "false").equalsIgnoreCase("true")) {
+ try {
+ if (!(boolean) Class
+ .forName("net.lax1dude.eaglercraft.v1_8.buildtools.Java11Check", true,
+ new URLClassLoader(new URL[] { (new File("buildtools/Java11Check.jar")).toURI().toURL() }))
+ .getMethod("classLoadCheck").invoke(null)) {
+ throw new RuntimeException("wtf?");
+ }
+ }catch(Throwable t) {
+ System.err.println("ERROR: A minimum of Java 11 is required to run this tool!");
+ System.err.println();
+ System.err.println("You are using Java " + System.getProperty("java.version"));
+ System.err.println();
+ return;
+ }
+ }
+
+ if(args.length == 0 || (args.length == 1 && args[0].equalsIgnoreCase("help"))) {
+ System.out.println("Options:");
+ System.out.println(" help - displays this message");
+ System.out.println(" init - decompiles 1.8.8 and applies the main repo's patch files");
+ System.out.println(" workspace - creates a dev workspace with a gradle project to compile the source");
+ System.out.println(" pullrequest - scans changes in the dev workspace and creates patch files for pull requests");
+ System.out.println(" pullrequest_test - makes new workspace and re-applies the patches in 'pullrequest'");
+ System.out.println(" unpatched - creates a zip file with the vanilla minecraft source without patches");
+ System.out.println(" merge - merges the patch files in the pullrequest folder with the repo's main patch files");
+ System.out.println(" merge_direct - merges changes in the dev workspace with the repo's main patch files");
+ System.out.println(" clean - delete init and pullrequest directories, keeps dev workspace");
+ System.out.println();
+ }else if(args.length == 1 && args[0].equalsIgnoreCase("init")) {
+ LicensePrompt.display();
+ System.out.println("Running task '" + args[0] + "':");
+ System.out.println();
+ if(InitTask.initTask()) {
+ System.out.println();
+ System.out.println("Task Complete.");
+ System.out.println();
+ }else {
+ System.err.println();
+ System.err.println("Task Failed!");
+ System.err.println();
+ }
+ }else if(args.length == 1 && args[0].equalsIgnoreCase("workspace")) {
+ System.out.println("Running task '" + args[0] + "':");
+ System.out.println();
+ if(SetupWorkspace.setupWorkspace()) {
+ System.out.println();
+ System.out.println("Task Complete.");
+ System.out.println();
+ }else {
+ System.err.println();
+ System.err.println("Task Failed!");
+ System.err.println();
+ }
+ }else if(args.length == 1 && args[0].equalsIgnoreCase("pullrequest")) {
+ System.out.println("Running task '" + args[0] + "':");
+ System.out.println();
+ if(PullRequestTask.pullRequest()) {
+ System.out.println();
+ System.out.println("Task Complete.");
+ System.out.println();
+ }else {
+ System.err.println();
+ System.err.println("Task Failed!");
+ System.err.println();
+ }
+ }else if(args.length == 1 && args[0].equalsIgnoreCase("pullrequest_test")) {
+ System.out.println("Running task '" + args[0] + "':");
+ System.out.println();
+ if(SetupWorkspace.pullRequestTest()) {
+ System.out.println();
+ System.out.println("Task Complete.");
+ System.out.println();
+ }else {
+ System.err.println();
+ System.err.println("Task Failed!");
+ System.err.println();
+ }
+ }else if(args.length == 1 && args[0].equalsIgnoreCase("unpatched")) {
+ System.out.println("Running task '" + args[0] + "':");
+ System.out.println();
+ if(CreateUnpatched.createUnpatched()) {
+ System.out.println();
+ System.out.println("Task Complete.");
+ System.out.println();
+ }else {
+ System.err.println();
+ System.err.println("Task Failed!");
+ System.err.println();
+ }
+ }else if(args.length == 1 && args[0].equalsIgnoreCase("merge")) {
+ System.out.println("Running task '" + args[0] + "':");
+ System.out.println();
+ if(MergePullRequest.mergeTask()) {
+ System.out.println();
+ System.out.println("Task Complete.");
+ System.out.println();
+ }else {
+ System.err.println();
+ System.err.println("Task Failed!");
+ System.err.println();
+ }
+ }else if(args.length == 1 && args[0].equalsIgnoreCase("merge_direct")) {
+ System.out.println("Running task '" + args[0] + "':");
+ System.out.println();
+ if(MergePullRequest.mergeDirect()) {
+ System.out.println();
+ System.out.println("Task Complete.");
+ System.out.println();
+ }else {
+ System.err.println();
+ System.err.println("Task Failed!");
+ System.err.println();
+ }
+ }else if(args.length == 1 && args[0].equalsIgnoreCase("clean")) {
+ System.out.println("Running task '" + args[0] + "':");
+ System.out.println();
+ if(TaskClean.taskClean()) {
+ System.out.println();
+ System.out.println("Task Complete.");
+ System.out.println();
+ }else {
+ System.err.println();
+ System.err.println("Task Failed!");
+ System.err.println();
+ }
+ }else {
+ System.err.println("Invalid arguments!");
+ }
+ }
+
+}
diff --git a/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/EaglerBuildToolsConfig.java b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/EaglerBuildToolsConfig.java
new file mode 100644
index 00000000..f70957a0
--- /dev/null
+++ b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/EaglerBuildToolsConfig.java
@@ -0,0 +1,183 @@
+package net.lax1dude.eaglercraft.v1_8.buildtools;
+
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.InputStreamReader;
+import java.nio.charset.StandardCharsets;
+
+import org.json.JSONObject;
+
+/**
+ * Copyright (c) 2022 LAX1DUDE. All Rights Reserved.
+ *
+ * WITH THE EXCEPTION OF PATCH FILES, MINIFIED JAVASCRIPT, AND ALL FILES
+ * NORMALLY FOUND IN AN UNMODIFIED MINECRAFT RESOURCE PACK, YOU ARE NOT ALLOWED
+ * TO SHARE, DISTRIBUTE, OR REPURPOSE ANY FILE USED BY OR PRODUCED BY THE
+ * SOFTWARE IN THIS REPOSITORY WITHOUT PRIOR PERMISSION FROM THE PROJECT AUTHOR.
+ *
+ * NOT FOR COMMERCIAL OR MALICIOUS USE
+ *
+ * (please read the 'LICENSE' file this repo's root directory for more info)
+ *
+ */
+public class EaglerBuildToolsConfig {
+
+ public static File temporary_directory = new File(System.getProperty("user.home"), ".eaglercraft_1.8_buildtools");
+ private static boolean temporary_directory_isInit = false;
+ private static boolean temporary_directory_mentioned = false;
+
+ public static File workspace_directory = new File("../eaglercraft_1.8_workspace");
+ private static boolean workspace_directory_isInit = false;
+ private static boolean workspace_directory_mentioned = false;
+
+ private static boolean config_file_loaded = false;
+
+ public static final File configFile = new File("./buildtools_config.json");
+
+ public static void load() {
+ if(configFile.exists()) {
+ try(FileInputStream is = new FileInputStream(configFile)) {
+ byte[] r = new byte[(int)configFile.length()];
+ is.read(r);
+ is.close();
+ String jsonTxt = new String(r, StandardCharsets.UTF_8);
+ JSONObject obj = new JSONObject(jsonTxt);
+ String path = obj.optString("temporary_directory", null);
+ if(path != null) {
+ temporary_directory = new File(path);
+ temporary_directory_isInit = true;
+ }
+ path = obj.optString("workspace_directory", null);
+ if(path != null) {
+ workspace_directory = new File(path);
+ workspace_directory_isInit = true;
+ }
+ }catch(Throwable ex) {
+ System.err.println("Failed to read config!");
+ ex.printStackTrace();
+ }
+ }
+ }
+
+ public static void save() {
+ JSONObject obj = new JSONObject();
+ if(temporary_directory_isInit) obj.put("temporary_directory", temporary_directory.getAbsolutePath());
+ if(workspace_directory_isInit) obj.put("workspace_directory", workspace_directory.getAbsoluteFile());
+ try(FileOutputStream os = new FileOutputStream(configFile)) {
+ os.write(obj.toString(4).getBytes(StandardCharsets.UTF_8));
+ os.close();
+ }catch(IOException e) {
+ System.err.println("Failed to write config!");
+ e.printStackTrace();
+ }
+ }
+
+ private static void mentionConfigPath() {
+ System.out.println("Edit '" + configFile.getName() + "' to change");
+ }
+
+ public static File getTemporaryDirectory() {
+ if(!config_file_loaded) {
+ load();
+ config_file_loaded = true;
+ }
+ if(!temporary_directory_isInit) {
+ File f = temporary_directory;
+ System.out.println();
+ System.out.println("Using temporary directory: " + f.getAbsolutePath());
+ temporary_directory_mentioned = true;
+ f = askIfChangeIsWanted(f);
+ temporary_directory = f;
+ temporary_directory_isInit = true;
+ while(!temporary_directory.isDirectory() && !temporary_directory.mkdirs()) {
+ System.err.println("Failed to create: " + f.getAbsolutePath());
+ temporary_directory = askIfChangeIsWanted(f);
+ }
+ save();
+ System.out.println();
+ return temporary_directory;
+ }else {
+ if(!temporary_directory_mentioned) {
+ System.out.println("Using temporary directory: " + temporary_directory.getAbsolutePath());
+ temporary_directory_mentioned = true;
+ while(!temporary_directory.isDirectory() && !temporary_directory.mkdirs()) {
+ System.err.println("Failed to create: " + temporary_directory.getAbsolutePath());
+ temporary_directory = askIfChangeIsWanted(temporary_directory);
+ }
+ mentionConfigPath();
+ }
+ return temporary_directory;
+ }
+ }
+
+ public static File getWorkspaceDirectory() {
+ if(!config_file_loaded) {
+ load();
+ config_file_loaded = true;
+ }
+ if(!workspace_directory_isInit) {
+ File f = workspace_directory;
+ System.out.println();
+ System.out.println("Using workspace directory: " + f.getAbsolutePath());
+ workspace_directory_mentioned = true;
+ f = askIfChangeIsWanted(f);
+ workspace_directory = f;
+ workspace_directory_isInit = true;
+ while(!workspace_directory.isDirectory() && !workspace_directory.mkdirs()) {
+ System.err.println("Failed to create: " + f.getAbsolutePath());
+ workspace_directory = askIfChangeIsWanted(f);
+ }
+ save();
+ System.out.println();
+ return workspace_directory;
+ }else {
+ if(!workspace_directory_mentioned) {
+ System.out.println("Using workspace directory: " + workspace_directory.getAbsolutePath());
+ workspace_directory_mentioned = true;
+ while(!workspace_directory.isDirectory() && !workspace_directory.mkdirs()) {
+ System.err.println("Failed to create: " + workspace_directory.getAbsolutePath());
+ workspace_directory = askIfChangeIsWanted(workspace_directory);
+ }
+ mentionConfigPath();
+ }
+ return workspace_directory;
+ }
+ }
+
+ public static File askIfChangeIsWanted(File in) {
+ System.out.println("Would you like to change this directory?");
+ System.out.println("Enter 'Y' for yes or 'N' for no: ");
+ String l = "N";
+
+ try {
+ l = (new BufferedReader(new InputStreamReader(System.in))).readLine();
+ } catch (IOException e) {
+ }
+
+ if(l != null && ((l = l.trim()).equalsIgnoreCase("y") || l.equalsIgnoreCase("yes"))) {
+ System.out.println();
+ System.out.println("Type a new filename or hit 'Enter' to browse: ");
+ try {
+ l = (new BufferedReader(new InputStreamReader(System.in))).readLine();
+ } catch (IOException e) {
+ }
+ if(l != null && (l = l.trim()).length() > 0) {
+ in = new File(l);
+ }else {
+ File f = FileChooserTool.load(true);
+ if(f == null) {
+ System.out.println("You hit cancel on the file chooser, the directory '" + in.getAbsolutePath() + "' will be used.");
+ in = askIfChangeIsWanted(in);
+ }else {
+ in = f;
+ }
+ }
+ }
+
+ return in;
+ }
+
+}
diff --git a/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/FileChooserTool.java b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/FileChooserTool.java
new file mode 100644
index 00000000..54e056ba
--- /dev/null
+++ b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/FileChooserTool.java
@@ -0,0 +1,46 @@
+package net.lax1dude.eaglercraft.v1_8.buildtools;
+
+import java.io.File;
+
+import javax.swing.JFileChooser;
+import javax.swing.JFrame;
+
+/**
+ * Copyright (c) 2022 LAX1DUDE. All Rights Reserved.
+ *
+ * WITH THE EXCEPTION OF PATCH FILES, MINIFIED JAVASCRIPT, AND ALL FILES
+ * NORMALLY FOUND IN AN UNMODIFIED MINECRAFT RESOURCE PACK, YOU ARE NOT ALLOWED
+ * TO SHARE, DISTRIBUTE, OR REPURPOSE ANY FILE USED BY OR PRODUCED BY THE
+ * SOFTWARE IN THIS REPOSITORY WITHOUT PRIOR PERMISSION FROM THE PROJECT AUTHOR.
+ *
+ * NOT FOR COMMERCIAL OR MALICIOUS USE
+ *
+ * (please read the 'LICENSE' file this repo's root directory for more info)
+ *
+ */
+public class FileChooserTool {
+
+ public static final JFileChooser fc = new JFileChooser();
+
+ public static File load(boolean directory) {
+ fc.setFileSelectionMode(directory ? JFileChooser.DIRECTORIES_ONLY : JFileChooser.FILES_ONLY);
+ fc.setMultiSelectionEnabled(false);
+ fc.setFileHidingEnabled(false);
+ fc.setDialogTitle("Eaglercraft Buildtools");
+ JFrame parent = new JFrame();
+ parent.setBounds(0, 0, 50, 50);
+ parent.setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE);
+ parent.setAlwaysOnTop(true);
+ parent.setTitle("File Chooser");
+ parent.setLocationRelativeTo(null);
+ parent.setVisible(true);
+ if(fc.showOpenDialog(parent) == JFileChooser.APPROVE_OPTION) {
+ parent.dispose();
+ return fc.getSelectedFile();
+ }else {
+ parent.dispose();
+ return null;
+ }
+ }
+
+}
diff --git a/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/LicensePrompt.java b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/LicensePrompt.java
new file mode 100644
index 00000000..2238ee0c
--- /dev/null
+++ b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/LicensePrompt.java
@@ -0,0 +1,64 @@
+package net.lax1dude.eaglercraft.v1_8.buildtools;
+
+import java.io.BufferedReader;
+import java.io.IOException;
+import java.io.InputStreamReader;
+import java.nio.charset.StandardCharsets;
+
+/**
+ * Copyright (c) 2022 LAX1DUDE. All Rights Reserved.
+ *
+ * WITH THE EXCEPTION OF PATCH FILES, MINIFIED JAVASCRIPT, AND ALL FILES
+ * NORMALLY FOUND IN AN UNMODIFIED MINECRAFT RESOURCE PACK, YOU ARE NOT ALLOWED
+ * TO SHARE, DISTRIBUTE, OR REPURPOSE ANY FILE USED BY OR PRODUCED BY THE
+ * SOFTWARE IN THIS REPOSITORY WITHOUT PRIOR PERMISSION FROM THE PROJECT AUTHOR.
+ *
+ * NOT FOR COMMERCIAL OR MALICIOUS USE
+ *
+ * (please read the 'LICENSE' file this repo's root directory for more info)
+ *
+ */
+public class LicensePrompt {
+
+ public static void main(String[] args) {
+ System.out.println();
+ display();
+ }
+
+ public static void display() {
+ System.out.println("WARNING: You must agree to the LICENSE before running this command");
+ System.out.println();
+ try (BufferedReader reader = new BufferedReader(
+ new InputStreamReader(LicensePrompt.class.getResourceAsStream("/lang/LICENSE_console_wrapped.txt"), StandardCharsets.UTF_8))) {
+ String line;
+ while((line = reader.readLine()) != null) {
+ if(line.equals("")) {
+ pressEnter();
+ }else {
+ System.out.println(line);
+ }
+ }
+ }catch(IOException ex) {
+ System.err.println();
+ System.err.println("ERROR: could not display license text");
+ System.err.println("Please read the \"LICENSE\" file before using this software");
+ System.err.println();
+ pressEnter();
+ }
+ }
+
+ private static void pressEnter() {
+ System.out.println();
+ System.out.println("(press ENTER to continue)");
+ while(true) {
+ try {
+ if(System.in.read() == '\n') {
+ break;
+ }
+ }catch(IOException ex) {
+ throw new RuntimeException("Unexpected IOException reading STDIN", ex);
+ }
+ }
+ }
+
+}
diff --git a/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/decompiler/LocalVariableGenerator.java b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/decompiler/LocalVariableGenerator.java
new file mode 100644
index 00000000..2684839a
--- /dev/null
+++ b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/decompiler/LocalVariableGenerator.java
@@ -0,0 +1,447 @@
+package net.lax1dude.eaglercraft.v1_8.buildtools.decompiler;
+
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Map;
+import java.util.Set;
+
+import org.objectweb.asm.Opcodes;
+import org.objectweb.asm.signature.SignatureReader;
+import org.objectweb.asm.signature.SignatureVisitor;
+
+/**
+ * Copyright (c) 2022 LAX1DUDE. All Rights Reserved.
+ *
+ * WITH THE EXCEPTION OF PATCH FILES, MINIFIED JAVASCRIPT, AND ALL FILES
+ * NORMALLY FOUND IN AN UNMODIFIED MINECRAFT RESOURCE PACK, YOU ARE NOT ALLOWED
+ * TO SHARE, DISTRIBUTE, OR REPURPOSE ANY FILE USED BY OR PRODUCED BY THE
+ * SOFTWARE IN THIS REPOSITORY WITHOUT PRIOR PERMISSION FROM THE PROJECT AUTHOR.
+ *
+ * NOT FOR COMMERCIAL OR MALICIOUS USE
+ *
+ * (please read the 'LICENSE' file this repo's root directory for more info)
+ *
+ */
+public class LocalVariableGenerator extends SignatureVisitor {
+
+ public static final Map primitiveNames = new HashMap();
+ public static final Set illegalVariableNames = new HashSet();
+
+ static {
+
+ primitiveNames.put('Z', "Flag");
+ primitiveNames.put('C', "Char");
+ primitiveNames.put('B', "Byte");
+ primitiveNames.put('S', "Short");
+ primitiveNames.put('I', "Int");
+ primitiveNames.put('F', "Float");
+ primitiveNames.put('J', "Long");
+ primitiveNames.put('D', "Double");
+ primitiveNames.put('V', "Void");
+
+ illegalVariableNames.addAll(Arrays.asList(
+ "abstract", "assert", "boolean", "break", "byte", "case", "catch", "char", "class",
+ "continue", "const", "default", "do", "double", "else", "enum", "exports", "extends",
+ "final", "finally", "float", "for", "goto", "if", "implements", "import",
+ "instanceof", "int", "interface", "long", "native", "new", "package", "private",
+ "protected", "public", "return", "short", "static", "strictfp", "super", "switch",
+ "synchronized", "this", "throw", "throws", "transient", "try", "var", "void",
+ "volatile", "while", "string"
+ ));
+
+ }
+
+ private String baseClass = null;
+ private boolean isArray = false;
+ private String typeParam1 = null;
+ private boolean typeParam1IsArray = false;
+ private String typeParam2 = null;
+ private boolean typeParam2IsArray = false;
+
+ public static final SignatureVisitor nopVisitor = new SignatureVisitor(Opcodes.ASM5) {};
+
+ LocalVariableGenerator() {
+ super(Opcodes.ASM5);
+ }
+
+ public static String createName(String sig) {
+ SignatureReader rd = new SignatureReader(sig);
+ LocalVariableGenerator gen = new LocalVariableGenerator();
+ rd.acceptType(gen);
+ return gen.getResult();
+ }
+
+ private String removePath(String in) {
+ int idx = in.lastIndexOf('/');
+ int idx2 = in.lastIndexOf('$');
+ if(idx2 > idx && idx2 != in.length() - 1) {
+ idx = idx2;
+ }
+ if(idx != -1) {
+ in = in.substring(idx + 1);
+ }
+ if(in.length() == 0 || Character.isDigit(in.charAt(0))) {
+ in = "obj" + in;
+ }
+ return in;
+ }
+
+ String getResult() {
+ String rt;
+ if(baseClass == null) {
+ rt = "Object";
+ }else {
+ rt = removePath(baseClass);
+ }
+ if(typeParam1 == null && typeParam2 == null) {
+ if(isArray) {
+ rt = "ArrayOf" + rt;
+ }
+ }else {
+ if(isArray) {
+ rt = rt + "Array";
+ }
+ }
+ if(typeParam1 != null && typeParam2 == null) {
+ if(typeParam1IsArray) {
+ typeParam1 = typeParam1 + "Array";
+ }
+ rt = rt + "Of" + removePath(typeParam1);
+ }else if(typeParam1 != null && typeParam2 != null) {
+ if(typeParam1IsArray) {
+ typeParam1 = typeParam1 + "Array";
+ }
+ if(typeParam2IsArray) {
+ typeParam2 = typeParam2 + "Array";
+ }
+ rt = rt + "Of" + removePath(typeParam1) + "And" + removePath(typeParam2);
+ }
+ return rt;
+ }
+
+ @Override
+ public SignatureVisitor visitArrayType() {
+ if(baseClass == null) {
+ isArray = true;
+ return new ArrayTypeVisitor();
+ }else {
+ return nopVisitor;
+ }
+ }
+
+ private class ArrayTypeVisitor extends SignatureVisitor {
+
+ protected ArrayTypeVisitor() {
+ super(Opcodes.ASM5);
+ }
+
+ @Override
+ public void visitBaseType(char descriptor) {
+ if(baseClass == null) {
+ baseClass = primitiveNames.get(descriptor);
+ }
+ }
+
+ @Override
+ public void visitClassType(String name) {
+ if(baseClass == null) {
+ baseClass = name;
+ }
+ }
+
+ @Override
+ public SignatureVisitor visitArrayType() {
+ if(baseClass == null) {
+ baseClass = "array";
+ }
+ return nopVisitor;
+ }
+
+ @Override public SignatureVisitor visitClassBound() { return nopVisitor; }
+ @Override public SignatureVisitor visitExceptionType() { return nopVisitor; }
+ @Override public SignatureVisitor visitInterface() { return nopVisitor; }
+ @Override public SignatureVisitor visitInterfaceBound() { return nopVisitor; }
+ @Override public SignatureVisitor visitParameterType() { return nopVisitor; }
+ @Override public SignatureVisitor visitTypeArgument(char wildcard) { return nopVisitor; }
+ @Override public SignatureVisitor visitReturnType() { return nopVisitor; }
+
+ }
+
+ @Override
+ public void visitBaseType(char descriptor) {
+ if(baseClass == null) {
+ baseClass = primitiveNames.get(descriptor);
+ }
+ }
+
+ @Override
+ public SignatureVisitor visitClassBound() {
+ //System.out.println("class: " + this);
+ return nopVisitor;
+ }
+
+ @Override
+ public void visitClassType(String name) {
+ //System.out.println("classType: " + name);
+ if(baseClass == null) {
+ baseClass = name;
+ }
+ }
+
+ @Override
+ public void visitEnd() {
+
+ }
+
+ @Override
+ public SignatureVisitor visitExceptionType() {
+ return nopVisitor;
+ }
+
+ @Override
+ public void visitFormalTypeParameter(String name) {
+ //System.out.println("formalTypeParam: " + name);
+ }
+
+ @Override
+ public void visitInnerClassType(String name) {
+ //System.out.println("innerClassType: " + name);
+
+ }
+
+ @Override
+ public SignatureVisitor visitInterface() {
+ return nopVisitor;
+ }
+
+ @Override
+ public SignatureVisitor visitInterfaceBound() {
+ return nopVisitor;
+ }
+
+ @Override
+ public SignatureVisitor visitParameterType() {
+ return nopVisitor;
+ }
+
+ private class TypeParamVisitor extends SignatureVisitor {
+
+ private boolean hasVisited = false;
+ private final int firstOrSecond;
+
+ protected TypeParamVisitor(int firstOrSecond) {
+ super(Opcodes.ASM5);
+ this.firstOrSecond = firstOrSecond;
+ }
+
+ @Override
+ public void visitBaseType(char descriptor) {
+ if(!hasVisited) {
+ if(firstOrSecond == 1) {
+ if(typeParam1 == null) {
+ typeParam1 = primitiveNames.get(descriptor);
+ }
+ }else if(firstOrSecond == 2) {
+ if(typeParam2 == null) {
+ typeParam2 = primitiveNames.get(descriptor);
+ }
+ }
+ hasVisited = true;
+ }
+ }
+
+ @Override
+ public void visitClassType(String name) {
+ if(!hasVisited) {
+ if(firstOrSecond == 1) {
+ if(typeParam1 == null) {
+ typeParam1 = name;
+ }
+ }else if(firstOrSecond == 2) {
+ if(typeParam2 == null) {
+ typeParam2 = name;
+ }
+ }
+ hasVisited = true;
+ }
+ }
+
+ @Override
+ public SignatureVisitor visitArrayType() {
+ if(!hasVisited) {
+ if(firstOrSecond == 1) {
+ if(typeParam1 == null) {
+ typeParam1IsArray = true;
+ return new TypeParamArrayVisitor();
+ }
+ }else if(firstOrSecond == 2) {
+ if(typeParam2 == null) {
+ typeParam2IsArray = true;
+ return new TypeParamArrayVisitor();
+ }
+ }
+ }
+ return nopVisitor;
+ }
+
+ private class TypeParamArrayVisitor extends SignatureVisitor {
+
+ protected TypeParamArrayVisitor() {
+ super(Opcodes.ASM5);
+ }
+
+ @Override
+ public void visitBaseType(char descriptor) {
+ if(!hasVisited) {
+ if(firstOrSecond == 1) {
+ if(typeParam1 == null) {
+ typeParam1 = primitiveNames.get(descriptor);
+ }
+ }else if(firstOrSecond == 2) {
+ if(typeParam2 == null) {
+ typeParam2 = primitiveNames.get(descriptor);
+ }
+ }
+ hasVisited = true;
+ }
+ }
+
+ @Override
+ public void visitClassType(String name) {
+ if(!hasVisited) {
+ if(firstOrSecond == 1) {
+ if(typeParam1 == null) {
+ typeParam1 = name;
+ }
+ }else if(firstOrSecond == 2) {
+ if(typeParam2 == null) {
+ typeParam2 = name;
+ }
+ }
+ hasVisited = true;
+ }
+ }
+
+ @Override
+ public SignatureVisitor visitArrayType() {
+ if(!hasVisited) {
+ if(firstOrSecond == 1) {
+ if(typeParam1 == null) {
+ typeParam1 = "array";
+ }
+ }else if(firstOrSecond == 2) {
+ if(typeParam2 == null) {
+ typeParam2 = "array";
+ }
+ }
+ hasVisited = true;
+ }
+ return nopVisitor;
+ }
+
+ @Override public SignatureVisitor visitClassBound() { return nopVisitor; }
+ @Override public SignatureVisitor visitExceptionType() { return nopVisitor; }
+ @Override public SignatureVisitor visitInterface() { return nopVisitor; }
+ @Override public SignatureVisitor visitInterfaceBound() { return nopVisitor; }
+ @Override public SignatureVisitor visitParameterType() { return nopVisitor; }
+ @Override public SignatureVisitor visitTypeArgument(char wildcard) { return nopVisitor; }
+ @Override public SignatureVisitor visitReturnType() { return nopVisitor; }
+
+ }
+
+ }
+
+ @Override
+ public SignatureVisitor visitReturnType() {
+ return nopVisitor;
+ }
+
+ @Override
+ public SignatureVisitor visitSuperclass() {
+ return nopVisitor;
+ }
+
+ @Override
+ public void visitTypeArgument() {
+
+ }
+
+ @Override
+ public SignatureVisitor visitTypeArgument(char wildcard) {
+ if(typeParam1 == null) {
+ return new TypeParamVisitor(1);
+ }else if(typeParam2 == null) {
+ return new TypeParamVisitor(2);
+ }else {
+ return nopVisitor;
+ }
+ }
+
+ @Override
+ public void visitTypeVariable(String name) {
+
+ }
+
+ public static String nextLocalVariableNameFromString(Map tmpLocalsMap, String signature, String pfx) {
+ String str = signature.length() == 1 ? primitiveNames.get(signature.charAt(0)) : null;
+ if(str == null) {
+ str = LocalVariableGenerator.createName(signature);
+ }
+ String ls = str.toLowerCase();
+ Integer i = tmpLocalsMap.get(ls);
+ if(i == null) {
+ tmpLocalsMap.put(ls, 1);
+ if(Character.isDigit(str.charAt(str.length() - 1))) {
+ str = str + "_1";
+ }else {
+ str = illegalVariableNames.contains(str.toLowerCase()) ? str + "1" : str;
+ }
+ }else {
+ int ii = i.intValue() + 1;
+ tmpLocalsMap.put(ls, ii);
+ if(Character.isDigit(str.charAt(str.length() - 1)) || str.contains("And") || str.length() > 16) {
+ str = str + "_" + ii;
+ }else {
+ str = str + ii;
+ }
+ }
+ return pfx == null ? camelCase(str) : pfx + str;
+ }
+
+ public static String nextLocalVariableName(Map tmpLocalsMap, LocalVariableGenerator signature, String pfx) {
+ String str = signature.getResult();
+ String ls = str.toLowerCase();
+ Integer i = tmpLocalsMap.get(ls);
+ if(i == null) {
+ tmpLocalsMap.put(ls, 1);
+ if(Character.isDigit(str.charAt(str.length() - 1))) {
+ str = str + "_1";
+ }else {
+ str = illegalVariableNames.contains(str.toLowerCase()) ? str + "1" : str;
+ }
+ }else {
+ int ii = i.intValue() + 1;
+ tmpLocalsMap.put(ls, ii);
+ if(Character.isDigit(str.charAt(str.length() - 1)) || str.contains("And") || str.length() > 16) {
+ str = str + "_" + ii;
+ }else {
+ str = str + ii;
+ }
+ }
+ return pfx == null ? camelCase(str) : pfx + str;
+ }
+
+ public static String camelCase(String in) {
+ if(in == null || in.length() <= 0) {
+ return "name";
+ }else {
+ if(in.length() > 1 && Character.isUpperCase(in.charAt(0)) && Character.isUpperCase(in.charAt(1))) {
+ return "var" + in;
+ }else {
+ return in.substring(0, 1).toLowerCase() + in.substring(1);
+ }
+ }
+ }
+
+}
diff --git a/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/decompiler/ParameterSplitter.java b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/decompiler/ParameterSplitter.java
new file mode 100644
index 00000000..77fd2be1
--- /dev/null
+++ b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/decompiler/ParameterSplitter.java
@@ -0,0 +1,88 @@
+package net.lax1dude.eaglercraft.v1_8.buildtools.decompiler;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+
+import org.objectweb.asm.Opcodes;
+import org.objectweb.asm.signature.SignatureReader;
+import org.objectweb.asm.signature.SignatureVisitor;
+
+/**
+ * Copyright (c) 2022 LAX1DUDE. All Rights Reserved.
+ *
+ * WITH THE EXCEPTION OF PATCH FILES, MINIFIED JAVASCRIPT, AND ALL FILES
+ * NORMALLY FOUND IN AN UNMODIFIED MINECRAFT RESOURCE PACK, YOU ARE NOT ALLOWED
+ * TO SHARE, DISTRIBUTE, OR REPURPOSE ANY FILE USED BY OR PRODUCED BY THE
+ * SOFTWARE IN THIS REPOSITORY WITHOUT PRIOR PERMISSION FROM THE PROJECT AUTHOR.
+ *
+ * NOT FOR COMMERCIAL OR MALICIOUS USE
+ *
+ * (please read the 'LICENSE' file this repo's root directory for more info)
+ *
+ */
+public class ParameterSplitter extends SignatureVisitor {
+
+ protected ParameterSplitter() {
+ super(Opcodes.ASM5);
+ }
+
+ protected static final ArrayList ret = new ArrayList();
+ protected static final HashMap usedLocals = new HashMap();
+
+ public static int getParameterArray(String sig, String[] input) {
+ SignatureReader rd = new SignatureReader(sig);
+ ParameterSplitter pms = new ParameterSplitter();
+ ret.clear();
+ usedLocals.clear();
+ rd.accept(pms);
+ int l = ret.size();
+ if(l > input.length) {
+ l = input.length;
+ }
+ int c = 0;
+ for(int i = 0; i < l; ++i) {
+ if(input[i] == null) {
+ input[i] = LocalVariableGenerator.nextLocalVariableName(usedLocals, ret.get(i), "par");
+ ++c;
+ }
+ }
+ return c;
+ }
+
+ public static String[] getParameterSigArray(String sig, String pfx) {
+ SignatureReader rd = new SignatureReader(sig);
+ ParameterSplitter pms = new ParameterSplitter();
+ ret.clear();
+ usedLocals.clear();
+ rd.accept(pms);
+ String[] r = new String[ret.size()];
+ for(int i = 0; i < r.length; ++i) {
+ r[i] = LocalVariableGenerator.nextLocalVariableName(usedLocals, ret.get(i), pfx);
+ }
+ return r;
+ }
+
+ @Override
+ public SignatureVisitor visitParameterType() {
+ LocalVariableGenerator lv = new LocalVariableGenerator();
+ ret.add(lv);
+ return lv;
+ }
+
+ @Override public SignatureVisitor visitClassBound() { return LocalVariableGenerator.nopVisitor; }
+ @Override public SignatureVisitor visitExceptionType() { return LocalVariableGenerator.nopVisitor; }
+ @Override public SignatureVisitor visitInterface() { return LocalVariableGenerator.nopVisitor; }
+ @Override public SignatureVisitor visitInterfaceBound() { return LocalVariableGenerator.nopVisitor; }
+ @Override public SignatureVisitor visitTypeArgument(char wildcard) { return LocalVariableGenerator.nopVisitor; }
+ @Override public SignatureVisitor visitReturnType() { return LocalVariableGenerator.nopVisitor; }
+ @Override public SignatureVisitor visitArrayType() { return LocalVariableGenerator.nopVisitor; }
+ @Override public void visitBaseType(char descriptor) { }
+ @Override public void visitClassType(String name) { }
+ @Override public void visitEnd() { }
+ @Override public void visitFormalTypeParameter(String name) { }
+ @Override public void visitInnerClassType(String name) { }
+ @Override public SignatureVisitor visitSuperclass() { return LocalVariableGenerator.nopVisitor; }
+ @Override public void visitTypeArgument() { }
+ @Override public void visitTypeVariable(String name) { }
+
+}
diff --git a/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/gui/CompileLatestClientFrame.java b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/gui/CompileLatestClientFrame.java
new file mode 100644
index 00000000..0502d4db
--- /dev/null
+++ b/buildtools/src/main/java/net/lax1dude/eaglercraft/v1_8/buildtools/gui/CompileLatestClientFrame.java
@@ -0,0 +1,1355 @@
+package net.lax1dude.eaglercraft.v1_8.buildtools.gui;
+
+import javax.swing.JFrame;
+import java.awt.Color;
+import javax.swing.JPanel;
+import java.awt.BorderLayout;
+import java.awt.CardLayout;
+import javax.swing.JButton;
+import java.awt.FlowLayout;
+import javax.swing.JLabel;
+import javax.swing.JOptionPane;
+
+import java.awt.Font;
+import java.awt.Toolkit;
+
+import javax.swing.ButtonGroup;
+import javax.swing.ImageIcon;
+import javax.swing.border.EmptyBorder;
+import javax.swing.JSeparator;
+import java.awt.Component;
+import java.awt.Desktop;
+import java.awt.Dimension;
+import java.awt.EventQueue;
+
+import javax.swing.SwingConstants;
+import javax.swing.JTextPane;
+import java.awt.Insets;
+import java.awt.Point;
+
+import javax.swing.JTextField;
+import javax.swing.JRadioButton;
+import javax.swing.JScrollBar;
+import javax.swing.JCheckBox;
+import javax.swing.JFileChooser;
+import javax.swing.JScrollPane;
+import javax.swing.ScrollPaneConstants;
+import java.awt.event.ActionListener;
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.IOException;
+import java.io.InputStreamReader;
+import java.lang.reflect.InvocationTargetException;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.nio.charset.StandardCharsets;
+import java.awt.event.ActionEvent;
+import javax.swing.event.HyperlinkListener;
+
+import net.lax1dude.eaglercraft.v1_8.buildtools.gui.TeaVMBinaries.MissingJARsException;
+import net.lax1dude.eaglercraft.v1_8.buildtools.task.init.FFMPEG;
+
+import javax.swing.event.HyperlinkEvent;
+import javax.swing.event.ChangeListener;
+import javax.swing.event.ChangeEvent;
+import java.awt.event.WindowAdapter;
+import java.awt.event.WindowEvent;
+import javax.swing.JPopupMenu;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import javax.swing.JMenuItem;
+import javax.swing.BoxLayout;
+import java.awt.ComponentOrientation;
+import javax.swing.JTextArea;
+
+/**
+ * Copyright (c) 2022 LAX1DUDE. All Rights Reserved.
+ *
+ * WITH THE EXCEPTION OF PATCH FILES, MINIFIED JAVASCRIPT, AND ALL FILES
+ * NORMALLY FOUND IN AN UNMODIFIED MINECRAFT RESOURCE PACK, YOU ARE NOT ALLOWED
+ * TO SHARE, DISTRIBUTE, OR REPURPOSE ANY FILE USED BY OR PRODUCED BY THE
+ * SOFTWARE IN THIS REPOSITORY WITHOUT PRIOR PERMISSION FROM THE PROJECT AUTHOR.
+ *
+ * NOT FOR COMMERCIAL OR MALICIOUS USE
+ *
+ * (please read the 'LICENSE' file this repo's root directory for more info)
+ *
+ */
+public class CompileLatestClientFrame {
+
+ public JFrame frmCompileLatestClient;
+ public JTextField textField_ModCoderPack;
+ public JTextField textField_JarFilePath;
+ public JTextField textField_AssetsIndexJSON;
+ public JTextField textField_MavenRepoCustomURL;
+ public JTextField textField_MavenRepoLocal;
+ public JTextField textField_OutputDirectory;
+ public JTextField textField_RepositoryPath;
+ public JRadioButton rdbtnMavenRepoLocal;
+ public JRadioButton rdbtnMavenRepoCustom;
+ public JRadioButton rdbtnMavenRepoSonatype;
+ public JRadioButton rdbtnMavenRepoBintray;
+ public JRadioButton rdbtnMavenRepoCentral;
+ public JTextPane txtpnLogOutput;
+ public JLabel lblProgressState;
+ public JButton btnBack;
+ public JButton btnNext;
+ public JPanel pagesRoot;
+ public JScrollPane scrollPane;
+ public JTextPane txtpnfuckOffreview;
+ public JCheckBox chckbxOutputOfflineDownload;
+ public JCheckBox chckbxKeepTemporaryFiles;
+ public JTextField textField_pathToFFmpeg;
+ public JButton btnBrowsePathToFFmpeg;
+ public JCheckBox chckbxUsePathFFmpeg;
+ public JCheckBox chckbxAgreeLicense;
+ public JTextArea txtrLicenseText;
+ public JScrollPane scrollPane_LicenseText;
+
+ /**
+ * Create the application.
+ */
+ public CompileLatestClientFrame() {
+ initialize();
+ }
+
+ public int page = 0;
+ public boolean compiling;
+ public boolean finished;
+
+ public void setPage(int i) {
+ if(i < 0) i = 0;
+ if(i > 10) i = 10;
+ if(page != i) {
+ if(page < i) {
+ String pp;
+ switch(page) {
+ case 1:
+ if(!chckbxAgreeLicense.isSelected()) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "You must agree to the license to continue!", "Permission Denied", JOptionPane.ERROR_MESSAGE);
+ return;
+ }
+ break;
+ case 2:
+ pp = textField_RepositoryPath.getText().trim();
+ if(pp.length() == 0) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "Please select a folder!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }else if(!(new File(pp)).isDirectory()){
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "The path \"" + pp + "\" is not a folder!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }
+ break;
+ case 3:
+ pp = textField_ModCoderPack.getText().trim();
+ if(pp.length() == 0) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "Please select a file!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }else if(!(new File(pp)).isFile()){
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "The path \"" + pp + "\" is not a file!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }
+ break;
+ case 4:
+ pp = textField_JarFilePath.getText().trim();
+ if(pp.length() == 0) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "Please select a file!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }else if(!(new File(pp)).isFile()){
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "The path \"" + pp + "\" is not a file!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }
+ break;
+ case 5:
+ pp = textField_AssetsIndexJSON.getText().trim();
+ if(pp.length() == 0) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "Please select a file!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }else if(!(new File(pp)).isFile()){
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "The path \"" + pp + "\" is not a file!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }
+ break;
+ case 6:
+ if(rdbtnMavenRepoLocal.isSelected()) {
+ pp = textField_MavenRepoLocal.getText().trim();
+ if(pp.length() == 0) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "Please select a folder!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }else {
+ File f = new File(pp);
+ if(!f.isDirectory()){
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "The path \"" + pp + "\" is not a folder!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }else {
+ try {
+ TeaVMBinaries.loadFromDirectory(f);
+ }catch(MissingJARsException ex) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "The following JARs are missing:\n - " + String.join("\n - ", ex.jars), "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }
+ }
+ }
+ }else if(rdbtnMavenRepoCustom.isSelected()) {
+ pp = textField_MavenRepoCustomURL.getText().trim();
+ if(pp.length() == 0) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "Please enter a URL!", "Invalid URL", JOptionPane.ERROR_MESSAGE);
+ return;
+ }else {
+ try {
+ URL u = new URL(pp);
+ }catch(MalformedURLException ex) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "MalformedURLException: " + ex.getMessage(), "Invalid URL", JOptionPane.ERROR_MESSAGE);
+ return;
+ }
+ }
+ }
+ break;
+ case 7:
+ if(!chckbxUsePathFFmpeg.isSelected()) {
+ pp = textField_pathToFFmpeg.getText().trim();
+ if(pp.length() == 0) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "Please select a file!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }else if(!(new File(pp)).isFile()){
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "The path \"" + pp + "\" is not a file!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }
+ }else if(!isFFmpegOnPath()) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "FFmpeg is not on your system's PATH!", "Error", JOptionPane.ERROR_MESSAGE);
+ chckbxUsePathFFmpeg.setSelected(false);
+ chckbxUsePathFFmpeg.setEnabled(false);
+ textField_pathToFFmpeg.setEnabled(true);
+ btnBrowsePathToFFmpeg.setEnabled(true);
+ return;
+ }
+ break;
+ case 8:
+ pp = textField_OutputDirectory.getText().trim();
+ if(pp.length() == 0) {
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "Please select a folder!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }else {
+ File f = new File(pp);
+ if(!f.isDirectory()){
+ JOptionPane.showMessageDialog(frmCompileLatestClient, "The path \"" + pp + "\" is not a folder!", "Invalid Path", JOptionPane.ERROR_MESSAGE);
+ return;
+ }else if(f.list().length > 0) {
+ if(JOptionPane.showConfirmDialog(frmCompileLatestClient, "The directory \"" + pp + "\" is not empty, would you like to continue?\nThe existing files will be deleted.", "Confirm", JOptionPane.YES_NO_OPTION) != JOptionPane.YES_OPTION) {
+ return;
+ }
+ }
+ }
+ break;
+ default:
+ break;
+ }
+ }
+ CardLayout pagesLayout = (CardLayout)pagesRoot.getLayout();
+ switch(i) {
+ case 0:
+ default:
+ pagesLayout.show(pagesRoot, "pageHome");
+ break;
+ case 1:
+ pagesLayout.show(pagesRoot, "pageLicense");
+ break;
+ case 2:
+ pagesLayout.show(pagesRoot, "pageBrowseRepositoryPath");
+ break;
+ case 3:
+ pagesLayout.show(pagesRoot, "pageModCoderPack");
+ break;
+ case 4:
+ pagesLayout.show(pagesRoot, "pageBrowseJarFile");
+ break;
+ case 5:
+ pagesLayout.show(pagesRoot, "pageBrowseAssetsIndexJSON");
+ break;
+ case 6:
+ pagesLayout.show(pagesRoot, "pageMavenRepo");
+ break;
+ case 7:
+ pagesLayout.show(pagesRoot, "pageFFmpeg");
+ if(isFFmpegOnPath()) {
+ chckbxUsePathFFmpeg.setEnabled(true);
+ if(!hasAskedFFmpegOnPath) {
+ hasAskedFFmpegOnPath = true;
+ EventQueue.invokeLater(new Runnable() {
+ @Override
+ public void run() {
+ if(JOptionPane.showConfirmDialog(frmCompileLatestClient, "FFmpeg was found on your system's PATH!\nwould you like to select it automatically?", "Confirmation", JOptionPane.YES_NO_OPTION) == JOptionPane.YES_OPTION) {
+ chckbxUsePathFFmpeg.setSelected(true);
+ textField_pathToFFmpeg.setEnabled(false);
+ btnBrowsePathToFFmpeg.setEnabled(false);
+ setPage(page + 1);
+ }
+ }
+ });
+ }
+ }else {
+ chckbxUsePathFFmpeg.setEnabled(false);
+ }
+ break;
+ case 8:
+ pagesLayout.show(pagesRoot, "pageOutputDirectory");
+ break;
+ case 9:
+ txtpnfuckOffreview.setText("\r\nfuck off\r\n\r\n
This tool will allow you to automatically compile the latest version of the EaglercraftX 1.8 client using the files in this repository.
\r\n
You are required to download several required files manually in order to better respect the Microsoft/Mojang TOS. The links to these files will be provided.
\r\n
To view or modify portions of the EaglercraftX 1.8 source code directly, please use the other batch files to generate a gradle project instead of compiling the javascript files directly
\r\n
If you are from Microsoft/Mojang or the developer of MCP trying to get dirt on me, please just let me live my life, the repository does not contain your intellectual property. Using this code to play your game for free is not the default behavior of the gateway plugin or this compiler utility and is not encouraged by the documentation
A copy of Mod Coder Pack v9.18 is required to compile the EaglercraftX 1.8 client
\r\n
According to the Mod Coder Pack LICENSE.txt, \"You are NOT allowed to: release modified or unmodified versions of MCP anywhere\" so a copy of the files are not included in this repository, you're gonna have to download them separately
Obviously the JAR file containing the original Minecraft 1.8 bytecode is required to compile EaglercraftX 1.8, but it must again be downloaded separately from this repository because Microsoft/Mojang does not allow it to be redistributed without permission
\r\n
To download it, BUY MINECRAFT, install the Minecraft launcher, make a new launcher profile for MINECRAFT 1.8.8, and launch it at least once.
\r\n
Use the file chooser below to navigate to your \".minecraft\" folder, open the folder named \"versions\", then open the folder within it called \"1.8.8\", and then within that folder select the JAR file called \"1.8.8.jar\"
Some of Minecraft 1.8's assets are not included in the 1.8.8.jar file, they are downloaded separately, but are identified by their SHA-1 checksums. An additional JSON file must also be downloaded in order to map the checksums to their internal filenames
\r\n
Complete the previous step, then use the file chooser below to navigate to your \".minecraft\" folder, open the folder named \"assets\", then open the folder within it called \"indexes\", and then within that folder select the JSON file called \"1.8.json\"
EaglercraftX 1.8 uses TeaVM 0.6.1 to compile java to javascript. It's not included in the eagler repository to save space, so it must be downloaded from a public maven repository via HTTP, or loaded from a temporary local directory
A tool called FFmpeg is required to compress minecraft's audio so it's smaller, the tool is an excessively large single standalone executable file so it is not included in this repository and must be downloaded externally
Select the destination directory where you would like this tool to save the compiled files to once this tool is finished
\r\n
The the tool will generate an \"index.html\" file, a \"classes.js\" file, a \"classes.js.map\" file, an \"assets.epk\" file, a \"lang\" directory to hold additional .lang files, and optionally an offline download version of the client that does not require an HTTP server