Convert remaining scripts to Graal
Mainly missed scripts that use Nashorn's "Packages"
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
function enter(pi) {
|
||||
var mapobj = pi.getWarpMap(104000004);
|
||||
if(pi.isQuestActive(21733) && pi.getQuestProgressInt(21733, 9300345) == 0 && mapobj.countMonsters() == 0) {
|
||||
mapobj.spawnMonsterOnGroundBelow(Packages.server.life.MapleLifeFactory.getMonster(9300345), new java.awt.Point(0, 0));
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
mapobj.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(9300345), new Point(0, 0));
|
||||
pi.setQuestProgress(21733, 21762, 2);
|
||||
}
|
||||
|
||||
|
||||
@@ -6,8 +6,10 @@ function enter(pi) {
|
||||
if(mapobj1.countPlayers() == 0 && mapobj2.countPlayers() == 0) {
|
||||
mapobj1.resetPQ(1);
|
||||
mapobj2.resetPQ(1);
|
||||
|
||||
mapobj2.spawnMonsterOnGroundBelow(Packages.server.life.MapleLifeFactory.getMonster(9300348), new Packages.java.awt.Point(591, -34));
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
mapobj2.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(9300348), new Point(591, -34));
|
||||
|
||||
pi.playPortalSound(); pi.warp(920030000,2);
|
||||
return true;
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
function enter(pi) {
|
||||
if (pi.getPlayer().getMapId() != 777777777) {
|
||||
if(!Packages.net.server.Server.getInstance().canEnterDeveloperRoom()) {
|
||||
const Server = Java.type('net.server.Server');
|
||||
if(!Server.getInstance().canEnterDeveloperRoom()) {
|
||||
pi.message("The next room is currently unavailable.");
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user