-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
46 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
src/main/java/mods/Hileb/rml/compat/groovyscript/GroovyScriptContainer.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
package mods.Hileb.rml.compat.groovyscript; | ||
|
||
import com.cleanroommc.groovyscript.GroovyScript; | ||
import com.cleanroommc.groovyscript.sandbox.GroovySandbox; | ||
import com.google.gson.JsonObject; | ||
import net.minecraftforge.fml.common.ModContainer; | ||
|
||
import java.io.File; | ||
|
||
/** | ||
* @Project ResourceModLoader | ||
* @Author Hileb | ||
* @Date 2024/3/3 11:24 | ||
**/ | ||
public class GroovyScriptContainer { | ||
private static JsonObject updateRunConfigJson(ModContainer container, JsonObject json) { | ||
json.addProperty("packName", container.getName()); | ||
json.addProperty("packId", container.getModId()); | ||
json.addProperty("version", container.getVersion()); | ||
return json; | ||
} | ||
/** | ||
* {@link GroovySandbox#getClassFiles()} | ||
* {@link GroovySandbox#getScriptFiles()} | ||
* {@link GroovyScript#getResourcesFile()} | ||
* | ||
* hard to generate a running time {@link File} | ||
* all logic writed with {@link File} | ||
* **/ | ||
|
||
} |
11 changes: 11 additions & 0 deletions
11
src/main/java/mods/Hileb/rml/compat/groovyscript/RMLGroovySandbox.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package mods.Hileb.rml.compat.groovyscript; | ||
|
||
import com.cleanroommc.groovyscript.sandbox.GroovyScriptSandbox; | ||
|
||
/** | ||
* @Project ResourceModLoader | ||
* @Author Hileb | ||
* @Date 2024/3/3 11:45 | ||
**/ | ||
public class RMLGroovySandbox extends GroovyScriptSandbox { | ||
} |