mirror of
https://github.com/GTNewHorizons/CraftTweaker.git
synced 2026-11-26 14:53:03 +00:00
- Updated to new Forge version
- Added script locking
This commit is contained in:
1 parent
ea47aec970
commit
00bcf843e5
9 files changed
+93
-7
No files matched your search
@@ -18,6 +18,13 @@ import stanhebben.zenscript.annotations.ZenMethod;
|
||||
*/
|
||||
@ZenClass("minetweaker.IMineTweaker")
|
||||
public interface ITweaker {
|
||||
/**
|
||||
* Retrieves the script data to be loaded.
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public byte[] getStagedScriptData();
|
||||
|
||||
/**
|
||||
* Executes a specified MineTweaker action. Will print a log message and
|
||||
* adds the action to the undo list.
|
||||
|
||||
@@ -45,6 +45,11 @@ public class MTTweaker implements ITweaker {
|
||||
private IScriptProvider scriptProvider;
|
||||
private byte[] scriptData;
|
||||
|
||||
@Override
|
||||
public byte[] getStagedScriptData() {
|
||||
return ScriptProviderMemory.collect(scriptProvider);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void apply(IUndoableAction action) {
|
||||
MineTweakerAPI.logInfo(action.describe());
|
||||
|
||||
Reference in new issue
Block a user