I am teaching my students scriptcraft.
What I want to do is to make the JavaScript code that students create available only to the student.
For example,
username1.js
command ('stoneblock1', function (parameters, player) {
var theDrone = new Drone (player);
theDrone.up ();
theDrone.chkpt ('start');
theDrone.box ('1', 3,1,2);
});
username2.js
command ('stoneblock2', function (parameters, player) {
var theDrone = new Drone (player);
theDrone.up ();
theDrone.chkpt ('start');
theDrone.box ('1', 3,1,2);
});
Let's say that the files created by each student are stored in the plugins folder.
I want username1.js to be able to run only username1 students.
In other words, username1 student can not run username2.js file.
So student 1 will be able to run / jsp stoneblock1, but stoneblock2 will not run due to permission issues.
Please answer me. Thank you.
cheers,
Woody
(More a Perl Programmer than a JS one!)