mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-27 20:12:58 +00:00
Renamed NPCs button on GUI, added configs for enabling player, forge, NPC, and all scripts.
This commit is contained in:
1 parent
33378fba59
commit
9a244ca2fe
6 files changed
+25
-4
No files matched your search
@@ -14,6 +14,7 @@ import java.util.Map.Entry;
|
||||
|
||||
import cpw.mods.fml.common.eventhandler.Event;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import noppes.npcs.CustomNpcs;
|
||||
import noppes.npcs.EventHooks;
|
||||
import noppes.npcs.controllers.ScriptContainer;
|
||||
import noppes.npcs.NBTTags;
|
||||
@@ -84,7 +85,7 @@ public class ForgeDataScript implements IScriptHandler {
|
||||
}
|
||||
|
||||
public boolean getEnabled() {
|
||||
return this.enabled;
|
||||
return CustomNpcs.GlobalForgeScripts && this.enabled;
|
||||
}
|
||||
|
||||
public void setEnabled(boolean bo) {
|
||||
|
||||
@@ -4,6 +4,7 @@ import com.google.common.base.Preconditions;
|
||||
import cpw.mods.fml.common.eventhandler.Event;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import noppes.npcs.CustomNpcs;
|
||||
import noppes.npcs.EventHooks;
|
||||
import noppes.npcs.NBTTags;
|
||||
import noppes.npcs.constants.EnumScriptType;
|
||||
@@ -90,7 +91,7 @@ public class NPCDataScript implements IScriptHandler {
|
||||
}
|
||||
|
||||
public boolean isEnabled() {
|
||||
return ScriptController.Instance.npcScripts.enabled && ScriptController.HasStart && (this.npc == null || !this.npc.worldObj.isRemote);
|
||||
return CustomNpcs.GlobalNPCScripts && ScriptController.Instance.npcScripts.enabled && ScriptController.HasStart && (this.npc == null || !this.npc.worldObj.isRemote);
|
||||
}
|
||||
public boolean isClient() {
|
||||
return this.npc.isClientWorld();
|
||||
|
||||
@@ -13,6 +13,7 @@ import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import cpw.mods.fml.common.eventhandler.Event;
|
||||
import net.minecraft.world.WorldServer;
|
||||
import noppes.npcs.CustomNpcs;
|
||||
import noppes.npcs.EventHooks;
|
||||
import noppes.npcs.controllers.ScriptContainer;
|
||||
import noppes.npcs.NBTTags;
|
||||
@@ -106,7 +107,7 @@ public class PlayerDataScript implements IScriptHandler {
|
||||
}
|
||||
|
||||
public boolean isEnabled() {
|
||||
return ScriptController.Instance.playerScripts.enabled && ScriptController.HasStart && (this.player == null || !this.player.worldObj.isRemote);
|
||||
return CustomNpcs.GlobalPlayerScripts && ScriptController.Instance.playerScripts.enabled && ScriptController.HasStart && (this.player == null || !this.player.worldObj.isRemote);
|
||||
}
|
||||
public boolean isClient() {
|
||||
return this.player.isClientWorld();
|
||||
|
||||
Reference in new issue
Block a user