Convert map scripts to Graal
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms){
|
||||
|
||||
if(ms.getQuestStatus(2175) == 1){
|
||||
@@ -11,6 +9,8 @@ function start(ms){
|
||||
return;
|
||||
}
|
||||
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(mobId), new java.awt.Point(-1027, 216));
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(mobId), new Point(-1027, 216));
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,4 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
function start(ms) {
|
||||
if(ms.getMapId() == 108010101) { // Archer
|
||||
spawnMob(188, 20, 9001002, ms.getPlayer().getMap());
|
||||
} else if(ms.getMapId() == 108010301) { // Warrior
|
||||
@@ -17,7 +15,9 @@ function start(ms) {
|
||||
function spawnMob(x, y, id, map) {
|
||||
if(map.getMonsterById(id) != null)
|
||||
return;
|
||||
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var mob = MapleLifeFactory.getMonster(id);
|
||||
map.spawnMonsterOnGroundBelow(mob, new java.awt.Point(x, y));
|
||||
map.spawnMonsterOnGroundBelow(mob, new Point(x, y));
|
||||
}
|
||||
@@ -1,6 +1,4 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
function start(ms) {
|
||||
if(ms.getMapId() == 108010101) { // Archer
|
||||
spawnMob(188, 20, 9001002, ms.getPlayer().getMap());
|
||||
} else if(ms.getMapId() == 108010301) { // Warrior
|
||||
@@ -17,7 +15,9 @@ function start(ms) {
|
||||
function spawnMob(x, y, id, map) {
|
||||
if(map.getMonsterById(id) != null)
|
||||
return;
|
||||
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var mob = MapleLifeFactory.getMonster(id);
|
||||
map.spawnMonsterOnGroundBelow(mob, new java.awt.Point(x, y));
|
||||
map.spawnMonsterOnGroundBelow(mob, new Point(x, y));
|
||||
}
|
||||
@@ -1,6 +1,4 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
function start(ms) {
|
||||
if(ms.getMapId() == 108010101) { // Archer
|
||||
spawnMob(188, 20, 9001002, ms.getPlayer().getMap());
|
||||
} else if(ms.getMapId() == 108010301) { // Warrior
|
||||
@@ -17,7 +15,9 @@ function start(ms) {
|
||||
function spawnMob(x, y, id, map) {
|
||||
if(map.getMonsterById(id) != null)
|
||||
return;
|
||||
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var mob = MapleLifeFactory.getMonster(id);
|
||||
map.spawnMonsterOnGroundBelow(mob, new java.awt.Point(x, y));
|
||||
map.spawnMonsterOnGroundBelow(mob, new Point(x, y));
|
||||
}
|
||||
@@ -1,6 +1,4 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
function start(ms) {
|
||||
if(ms.getMapId() == 108010101) { // Archer
|
||||
spawnMob(188, 20, 9001002, ms.getPlayer().getMap());
|
||||
} else if(ms.getMapId() == 108010301) { // Warrior
|
||||
@@ -17,7 +15,9 @@ function start(ms) {
|
||||
function spawnMob(x, y, id, map) {
|
||||
if(map.getMonsterById(id) != null)
|
||||
return;
|
||||
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var mob = MapleLifeFactory.getMonster(id);
|
||||
map.spawnMonsterOnGroundBelow(mob, new java.awt.Point(x, y));
|
||||
map.spawnMonsterOnGroundBelow(mob, new Point(x, y));
|
||||
}
|
||||
@@ -1,6 +1,4 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
function start(ms) {
|
||||
if(ms.getMapId() == 108010101) { // Archer
|
||||
spawnMob(188, 20, 9001002, ms.getPlayer().getMap());
|
||||
} else if(ms.getMapId() == 108010301) { // Warrior
|
||||
@@ -17,7 +15,9 @@ function start(ms) {
|
||||
function spawnMob(x, y, id, map) {
|
||||
if(map.getMonsterById(id) != null)
|
||||
return;
|
||||
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var mob = MapleLifeFactory.getMonster(id);
|
||||
map.spawnMonsterOnGroundBelow(mob, new java.awt.Point(x, y));
|
||||
map.spawnMonsterOnGroundBelow(mob, new Point(x, y));
|
||||
}
|
||||
@@ -1,15 +1,14 @@
|
||||
// Author: Ronan
|
||||
importPackage(Packages.tools);
|
||||
|
||||
var mapId = 200090000;
|
||||
|
||||
function start(ms) {
|
||||
var map = ms.getClient().getChannelServer().getMapFactory().getMap(mapId);
|
||||
|
||||
if(map.getDocked()) {
|
||||
const MaplePacketCreator = Java.type('tools.MaplePacketCreator');
|
||||
ms.getClient().announce(MaplePacketCreator.musicChange("Bgm04/ArabPirate"));
|
||||
ms.getClient().announce(MaplePacketCreator.crogBoatPacket(true));
|
||||
}
|
||||
|
||||
return(true);
|
||||
return true;
|
||||
}
|
||||
@@ -1,15 +1,14 @@
|
||||
// Author: Ronan
|
||||
importPackage(Packages.tools);
|
||||
|
||||
var mapId = 200090010;
|
||||
|
||||
function start(ms) {
|
||||
var map = ms.getClient().getChannelServer().getMapFactory().getMap(mapId);
|
||||
|
||||
if(map.getDocked()) {
|
||||
const MaplePacketCreator = Java.type('tools.MaplePacketCreator');
|
||||
ms.getClient().announce(MaplePacketCreator.musicChange("Bgm04/ArabPirate"));
|
||||
ms.getClient().announce(MaplePacketCreator.crogBoatPacket(true));
|
||||
}
|
||||
|
||||
return(true);
|
||||
return true;
|
||||
}
|
||||
@@ -1,9 +1,8 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
var pos = new java.awt.Point(461, 61);
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var pos = new Point(461, 61);
|
||||
var mobId = 9400612;
|
||||
var mobName = "Marbas";
|
||||
var mobName = "Marbas";
|
||||
|
||||
var player = ms.getPlayer();
|
||||
var map = player.getMap();
|
||||
@@ -12,6 +11,7 @@ function start(ms) {
|
||||
return;
|
||||
}
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(mobId), pos);
|
||||
player.message(mobName + " has appeared!");
|
||||
}
|
||||
@@ -1,9 +1,8 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
var pos = new java.awt.Point(467, 0);
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var pos = new Point(467, 0);
|
||||
var mobId = 9400610;
|
||||
var mobName = "Amdusias";
|
||||
var mobName = "Amdusias";
|
||||
|
||||
var player = ms.getPlayer();
|
||||
var map = player.getMap();
|
||||
@@ -12,6 +11,7 @@ function start(ms) {
|
||||
return;
|
||||
}
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(mobId), pos);
|
||||
player.message(mobName + " has appeared!");
|
||||
}
|
||||
@@ -1,9 +1,8 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
var pos = new java.awt.Point(201, 80);
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var pos = new Point(201, 80);
|
||||
var mobId = 9400609;
|
||||
var mobName = "Andras";
|
||||
var mobName = "Andras";
|
||||
|
||||
var player = ms.getPlayer();
|
||||
var map = player.getMap();
|
||||
@@ -12,6 +11,7 @@ function start(ms) {
|
||||
return;
|
||||
}
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(mobId), pos);
|
||||
player.message(mobName + " has appeared!");
|
||||
}
|
||||
@@ -1,9 +1,8 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
var pos = new java.awt.Point(171, 50);
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var pos = new Point(171, 50);
|
||||
var mobId = 9400611;
|
||||
var mobName = "Crocell";
|
||||
var mobName = "Crocell";
|
||||
|
||||
var player = ms.getPlayer();
|
||||
var map = player.getMap();
|
||||
@@ -12,6 +11,7 @@ function start(ms) {
|
||||
return;
|
||||
}
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(mobId), pos);
|
||||
player.message(mobName + " has appeared!");
|
||||
}
|
||||
@@ -1,9 +1,8 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
var pos = new java.awt.Point(251, -841);
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var pos = new Point(251, -841);
|
||||
var mobId = 9400613;
|
||||
var mobName = "Valefor";
|
||||
var mobName = "Valefor";
|
||||
|
||||
var player = ms.getPlayer();
|
||||
var map = player.getMap();
|
||||
@@ -12,6 +11,7 @@ function start(ms) {
|
||||
return;
|
||||
}
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(mobId), pos);
|
||||
player.message(mobName + " has appeared!");
|
||||
}
|
||||
@@ -1,9 +1,8 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms) {
|
||||
var pos = new java.awt.Point(842, 0);
|
||||
const Point = Java.type('java.awt.Point');
|
||||
var pos = new Point(842, 0);
|
||||
var mobId = 9400633;
|
||||
var mobName = "Astaroth";
|
||||
var mobName = "Astaroth";
|
||||
|
||||
var player = ms.getPlayer();
|
||||
var map = player.getMap();
|
||||
@@ -12,6 +11,7 @@ function start(ms) {
|
||||
return;
|
||||
}
|
||||
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(mobId), pos);
|
||||
player.message(mobName + " has appeared!");
|
||||
}
|
||||
@@ -1,16 +1,16 @@
|
||||
importPackage(Packages.server.life);
|
||||
function start(ms) {
|
||||
var player = ms.getPlayer();
|
||||
var map = player.getMap();
|
||||
|
||||
function start(ms){
|
||||
var player = ms.getPlayer();
|
||||
var map = player.getMap();
|
||||
|
||||
if(player.isCygnus()) {
|
||||
if(ms.isQuestStarted(20730) && ms.getQuestProgressInt(20730, 9300285) == 0) {
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(9300285), new java.awt.Point(680, 258));
|
||||
}
|
||||
} else {
|
||||
if(ms.isQuestStarted(21731) && ms.getQuestProgressInt(21731, 9300344) == 0) {
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(9300344), new java.awt.Point(680, 258));
|
||||
}
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
if (player.isCygnus()) {
|
||||
if (ms.isQuestStarted(20730) && ms.getQuestProgressInt(20730, 9300285) == 0) {
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(9300285), new Point(680, 258));
|
||||
}
|
||||
} else {
|
||||
if (ms.isQuestStarted(21731) && ms.getQuestProgressInt(21731, 9300344) == 0) {
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(9300344), new Point(680, 258));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms){
|
||||
var player = ms.getPlayer();
|
||||
var map = player.getMap();
|
||||
|
||||
if(ms.isQuestStarted(21747) && ms.getQuestProgressInt(21747, 9300351) == 0) {
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(9300351), new java.awt.Point(897, 51));
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(9300351), new Point(897, 51));
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,9 @@
|
||||
importPackage(Packages.server.life);
|
||||
|
||||
function start(ms){
|
||||
var mobId = 3300000 + (Math.floor(Math.random() * 3) + 5);
|
||||
var player = ms.getPlayer();
|
||||
var map = player.getMap();
|
||||
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(mobId), new java.awt.Point(-28, -67));
|
||||
const MapleLifeFactory = Java.type('server.life.MapleLifeFactory');
|
||||
const Point = Java.type('java.awt.Point');
|
||||
map.spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(mobId), new Point(-28, -67));
|
||||
}
|
||||
Reference in New Issue
Block a user