Reformat and clean up reactor and base scripts

This commit is contained in:
P0nk
2021-09-09 23:38:09 +02:00
parent 3f43fe82d0
commit d9590078f5
231 changed files with 1192 additions and 1075 deletions

View File

@@ -19,36 +19,36 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/* @Author Ronan
*
* 2001002.js: Either spawns a PQ mob or drops the Statue piece.
*/
function act() {
if(rm.getEventInstance().getIntProperty("statusStg2") == -1) {
if (rm.getEventInstance().getIntProperty("statusStg2") == -1) {
var rnd = Math.floor(Math.random() * 14);
rm.getEventInstance().setProperty("statusStg2", "" + rnd);
rm.getEventInstance().setProperty("statusStg2_c", "0");
}
var limit = rm.getEventInstance().getIntProperty("statusStg2");
var count = rm.getEventInstance().getIntProperty("statusStg2_c");
if(count >= limit) {
if (count >= limit) {
rm.dropItems();
var eim = rm.getEventInstance();
eim.giveEventPlayersExp(3500);
eim.setProperty("statusStg2", "1");
eim.showClearEffect(true);
}
else {
} else {
count++;
rm.getEventInstance().setProperty("statusStg2_c", count);
var nextHashed = (11 * (count)) % 14;
var nextPos = rm.getMap().getReactorById(2001002 + nextHashed).getPosition();
rm.spawnMonster(9300040, 1, nextPos);
}