I'm trying to teach students how to program JavaScript inside Minecraft with ScriptCraft. It's been amazing, except for the fact that even my most focused students get so distracted with playing minecraft instead of learning to program. I need a way for them to essentially not be able to do anything in Minecraft if it wasn't done programmatically through JavaScript.
ScriptCraft requires running a CraftBukkit server. Is there a mechanism to do disallow mining or building in Minecraft, CraftBukkit or a CraftBukkit plugin?
Best Answer
PermissionsEx and ModifyWorld should solve this problem quite nicely.
PermissionsEx is a general permissions plugin and ModifyWorld is an optional part of PEX:
The PEX wiki has a nice series of articles explaining exactly how to setup PEX with modofyworld. I suggest you follow along the tutorial so you understand how to install and configure PEX. Then when you get to the "Basic-Permissions-Setup" page, use my suggested configuration instead of theirs.
config.yml:
Once this is done, it sounds like this ought to work as your permissions.yml:
This puts the listed students into the students group, which denies all permissions except those specifically listed. You may want to browse the block ID list and allow
modifyworld.blocks.interact.<Block ID>
with some more of them (e.g. chests, buttons, doors). Make sure to use the "Dec" value listed, not the "Hex". You may also want to browse the permissions list to check for other things you want to allow students to do.If you miss any student names they will be allowed to do everything, which is equivalent to the permissions they have right now. If any students are in this group when they chat their name will be prefixed by "default" in coloured letters, which will alert you to fix this error. You can fix this by typing in game using your op account:
Note: I specifically did not make the default group the limited one for students. PEX often messes up plugins by trying to apply permissions to the actions of the plugins (so in this case ScriptCraft might have the same limitations as the students). I have no idea if this is a problem for ScriptCraft, you could test it by moving all the student permissions to default and seeing if ScriptCraft still works.
In Response To Comment: I've modified the config to account for all students needing to be op. By using
allowOps: false
this tells PEX that it should apply permissions rules even to ops. With this setting on you will probably need to allow access to all of the ScriptCraft commands, simply add the relevant permission nodes to the relevant groups.