Rename and clean up MapleReactor
This commit is contained in:
@@ -46,8 +46,8 @@ import server.life.Monster;
|
||||
import server.life.NPC;
|
||||
import server.maps.MapManager;
|
||||
import server.maps.MapleMap;
|
||||
import server.maps.MapleReactor;
|
||||
import server.maps.Portal;
|
||||
import server.maps.Reactor;
|
||||
import tools.PacketCreator;
|
||||
import tools.Pair;
|
||||
|
||||
@@ -1350,7 +1350,7 @@ public class EventInstanceManager {
|
||||
public boolean activatedAllReactorsOnMap(MapleMap map, int minReactorId, int maxReactorId) {
|
||||
if(map == null) return true;
|
||||
|
||||
for(MapleReactor mr : map.getReactorsByIdRange(minReactorId, maxReactorId)) {
|
||||
for(Reactor mr : map.getReactorsByIdRange(minReactorId, maxReactorId)) {
|
||||
if(mr.getReactorType() != -1) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -35,7 +35,7 @@ import server.life.LifeFactory;
|
||||
import server.life.Monster;
|
||||
import server.maps.MapMonitor;
|
||||
import server.maps.MapleMap;
|
||||
import server.maps.MapleReactor;
|
||||
import server.maps.Reactor;
|
||||
import server.maps.ReactorDropEntry;
|
||||
import server.partyquest.MapleCarnivalFactory;
|
||||
import server.partyquest.MapleCarnivalFactory.MCSkill;
|
||||
@@ -53,11 +53,11 @@ import java.util.concurrent.ScheduledFuture;
|
||||
* @author Ronan
|
||||
*/
|
||||
public class ReactorActionManager extends AbstractPlayerInteraction {
|
||||
private final MapleReactor reactor;
|
||||
private final Reactor reactor;
|
||||
private final Invocable iv;
|
||||
private ScheduledFuture<?> sprayTask = null;
|
||||
|
||||
public ReactorActionManager(Client c, MapleReactor reactor, Invocable iv) {
|
||||
public ReactorActionManager(Client c, Reactor reactor, Invocable iv) {
|
||||
super(c);
|
||||
this.reactor = reactor;
|
||||
this.iv = iv;
|
||||
@@ -185,7 +185,7 @@ public class ReactorActionManager extends AbstractPlayerInteraction {
|
||||
}
|
||||
}
|
||||
} else {
|
||||
final MapleReactor r = reactor;
|
||||
final Reactor r = reactor;
|
||||
final List<ReactorDropEntry> dropItems = items;
|
||||
final int worldMesoRate = c.getWorldServer().getMesoRate();
|
||||
|
||||
@@ -299,7 +299,7 @@ public class ReactorActionManager extends AbstractPlayerInteraction {
|
||||
}
|
||||
}
|
||||
|
||||
public MapleReactor getReactor() {
|
||||
public Reactor getReactor() {
|
||||
return reactor;
|
||||
}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ package scripting.reactor;
|
||||
|
||||
import client.Client;
|
||||
import scripting.AbstractScriptManager;
|
||||
import server.maps.MapleReactor;
|
||||
import server.maps.Reactor;
|
||||
import server.maps.ReactorDropEntry;
|
||||
import tools.DatabaseConnection;
|
||||
import tools.FilePrinter;
|
||||
@@ -51,7 +51,7 @@ public class ReactorScriptManager extends AbstractScriptManager {
|
||||
return instance;
|
||||
}
|
||||
|
||||
public void onHit(Client c, MapleReactor reactor) {
|
||||
public void onHit(Client c, Reactor reactor) {
|
||||
try {
|
||||
Invocable iv = initializeInvocable(c, reactor);
|
||||
if (iv == null) {
|
||||
@@ -66,7 +66,7 @@ public class ReactorScriptManager extends AbstractScriptManager {
|
||||
}
|
||||
}
|
||||
|
||||
public void act(Client c, MapleReactor reactor) {
|
||||
public void act(Client c, Reactor reactor) {
|
||||
try {
|
||||
Invocable iv = initializeInvocable(c, reactor);
|
||||
if (iv == null) {
|
||||
@@ -104,15 +104,15 @@ public class ReactorScriptManager extends AbstractScriptManager {
|
||||
drops.clear();
|
||||
}
|
||||
|
||||
public void touch(Client c, MapleReactor reactor) {
|
||||
public void touch(Client c, Reactor reactor) {
|
||||
touching(c, reactor, true);
|
||||
}
|
||||
|
||||
public void untouch(Client c, MapleReactor reactor) {
|
||||
public void untouch(Client c, Reactor reactor) {
|
||||
touching(c, reactor, false);
|
||||
}
|
||||
|
||||
private void touching(Client c, MapleReactor reactor, boolean touching) {
|
||||
private void touching(Client c, Reactor reactor, boolean touching) {
|
||||
try {
|
||||
Invocable iv = initializeInvocable(c, reactor);
|
||||
if (iv == null) {
|
||||
@@ -129,7 +129,7 @@ public class ReactorScriptManager extends AbstractScriptManager {
|
||||
}
|
||||
}
|
||||
|
||||
private Invocable initializeInvocable(Client c, MapleReactor reactor) {
|
||||
private Invocable initializeInvocable(Client c, Reactor reactor) {
|
||||
ScriptEngine engine = getInvocableScriptEngine("reactor/" + reactor.getId() + ".js", c);
|
||||
if (engine == null) {
|
||||
return null;
|
||||
|
||||
Reference in New Issue
Block a user