-
Notifications
You must be signed in to change notification settings - Fork 4
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
4 changed files
with
106 additions
and
18 deletions.
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
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
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,53 @@ | ||
package reobf.proghatches.main; | ||
|
||
import java.util.List; | ||
|
||
import com.google.common.collect.ImmutableList; | ||
|
||
import net.minecraft.command.CommandBase; | ||
import net.minecraft.command.ICommandSender; | ||
import net.minecraft.entity.player.EntityPlayer; | ||
import net.minecraft.util.ChatComponentText; | ||
import net.minecraft.util.ChatComponentTranslation; | ||
import reobf.proghatches.block.ChunkTrackingGridCahce; | ||
import reobf.proghatches.main.MyMod.Prop; | ||
|
||
public class CommandAnchor2 extends CommandBase{ | ||
|
||
@Override | ||
public String getCommandName() { | ||
|
||
return "proghatch"; | ||
} | ||
|
||
@Override | ||
public List getCommandAliases() { | ||
|
||
return ImmutableList.of(); | ||
} | ||
@Override | ||
public String getCommandUsage(ICommandSender sender) { | ||
|
||
return ""; | ||
} | ||
@Override | ||
public int getRequiredPermissionLevel() { | ||
|
||
return 0; | ||
} | ||
@Override | ||
public void processCommand(ICommandSender sender, String[] args) { | ||
try{if(args[0].equals("tracking")){ | ||
MyMod.disable=!MyMod.disable; | ||
sender .addChatMessage(new ChatComponentText("tracking:"+!MyMod.disable)); | ||
sender .addChatMessage(new ChatComponentText("max caches:"+MyMod.max)); | ||
sender .addChatMessage(new ChatComponentText("current caches:"+ChunkTrackingGridCahce.cacheinst.size())); | ||
} | ||
}catch(Exception e){ | ||
sender .addChatMessage(new ChatComponentText("/proghatch tracking")); | ||
|
||
} | ||
|
||
} | ||
|
||
} |
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