Make it easier to build the development environment. (#133)

* Fix the warning about removing duplicate source roots when open the project with Intellij IDEA.

* Add Gradle wrapper.

* CustomSkinLoader can be loaded in Forge development environment now.

* CustomSkinLoader can be loaded in Fabric development environment now.
This commit is contained in:
ZekerZhayard authored and GitHub committed 2021-01-03 02:53:57 +08:00
1 parent 855131d1aa
commit 1b2a4dc260
28 files changed
+746 -532

No files matched your search

@@ -0,0 +1,35 @@
package customskinloader.forge;
import java.io.File;
import java.util.List;
import net.minecraft.launchwrapper.ITweaker;
import net.minecraft.launchwrapper.Launch;
import net.minecraft.launchwrapper.LaunchClassLoader;
/**
* The tweaker for development environment.
*/
public class ForgeDevTweaker implements ITweaker {
@Override
public void acceptOptions(List<String> args, File gameDir, File assetsDir, String profile) {
}
@Override
@SuppressWarnings("unchecked")
public void injectIntoClassLoader(LaunchClassLoader classLoader) {
// ForgeTweaker should be added after FMLTweaker being initialized.
((List<String>) Launch.blackboard.get("TweakClasses")).add(ForgeTweaker.class.getName());
}
@Override
public String getLaunchTarget() {
return "";
}
@Override
public String[] getLaunchArguments() {
return new String[0];
}
}