Reformat and clean up reactor and base scripts
This commit is contained in:
@@ -1,22 +1,26 @@
|
||||
function action() {
|
||||
var flames = Array("d1", "d2", "e1", "e2", "f1", "f2");
|
||||
for (var i = 0; i < flames.length; i++) {
|
||||
rm.getMap().toggleEnvironment(flames[i]);
|
||||
}
|
||||
var flames = Array("d1", "d2", "e1", "e2", "f1", "f2");
|
||||
for (var i = 0; i < flames.length; i++) {
|
||||
rm.getMap().toggleEnvironment(flames[i]);
|
||||
}
|
||||
}
|
||||
|
||||
var fid = "glpq_f3";
|
||||
|
||||
function touch() {
|
||||
var eim = rm.getEventInstance();
|
||||
|
||||
if(eim.getIntProperty(fid) == 0) action();
|
||||
eim.setIntProperty(fid, eim.getIntProperty(fid) + 1);
|
||||
var eim = rm.getEventInstance();
|
||||
|
||||
if (eim.getIntProperty(fid) == 0) {
|
||||
action();
|
||||
}
|
||||
eim.setIntProperty(fid, eim.getIntProperty(fid) + 1);
|
||||
}
|
||||
|
||||
function untouch() {
|
||||
var eim = rm.getEventInstance();
|
||||
|
||||
if(eim.getIntProperty(fid) == 1) action();
|
||||
eim.setIntProperty(fid, eim.getIntProperty(fid) - 1);
|
||||
var eim = rm.getEventInstance();
|
||||
|
||||
if (eim.getIntProperty(fid) == 1) {
|
||||
action();
|
||||
}
|
||||
eim.setIntProperty(fid, eim.getIntProperty(fid) - 1);
|
||||
}
|
||||
Reference in New Issue
Block a user