a number object system to use in the oblivion language.
//variable retrieval testing
//number object
var NumberObj = function(value) {
this.value = value;
};
NumberObj.prototype.add = function(amount) {
this.value += amount;
};
NumberObj.prototype.subtract = function(amount) {
this.value -= amount;
};
//makes a list of number objects
var NumberList = function(end) {
for(var i=0;i<end;i++) this[i] = new NumberObj(i);
};
NumberList.prototype.addto = function(index, amount) {
this[index] += amount;
};