Well, I thought of releasing this since I had it for a long time yet unable to find a solution for linking channels hosting on a server, there's no progress for ages!
It might cause /find and maple messenger to be bugged, need someone to fix it .
[color:3289="Red"]Advantages :
Shutdown specific channels without shutting down the entire world
Less lag for players [Faster processing speed] for those channels hosted in a server [dedi / vps]
[color:3289="Red"]Disadvantages :
More memory needed
Replace your function in ChannelServer :
Run your channels with this bat file :
- Channel 1 -
- Channel 2 -
It might cause /find and maple messenger to be bugged, need someone to fix it .
[color:3289="Red"]Advantages :
Shutdown specific channels without shutting down the entire world
Less lag for players [Faster processing speed] for those channels hosted in a server [dedi / vps]
[color:3289="Red"]Disadvantages :
More memory needed
Replace your function in ChannelServer :
- Code:
public static void main(String args[]) throws FileNotFoundException, IOException, NotBoundException, InstanceAlreadyExistsException, MBeanRegistrationException, NotCompliantMBeanException, MalformedObjectNameException {
initialProp = new Properties();
initialProp.load(new FileReader(System.getProperty("net.sf.odinms.channel.config")));
Registry registry = LocateRegistry.getRegistry(initialProp.getProperty("net.sf.odinms.world.host"), Registry.REGISTRY_PORT, new SslRMIClientSocketFactory());
worldRegistry = (WorldRegistry) registry.lookup("WorldRegistry");
newInstance(initialProp.getProperty("net.sf.odinms.channel."+ new File(System.getProperty("net.sf.odinms.channelToLaunch")) +".key")).run();
DatabaseConnection.getConnection(); // touch - so we see database problems early...
}
Run your channels with this bat file :
- Channel 1 -
- Code:
@echo off
@title Channel Server Console - Channel 1
set CLASSPATH=.;dist\odinms.jar;dist\mina-core.jar;dist\slf4j-api.jar;dist\slf4j-jdk14.jar;dist\mysql-connector-java-bin.jar
java -Dnet.sf.odinms.channelToLaunch=0 -Dnet.sf.odinms.recvops=recvops.properties -Dnet.sf.odinms.sendops=sendops.properties -Dnet.sf.odinms.wzpath=wz\ -Dnet.sf.odinms.channel.config=channel.properties -Djavax.net.ssl.keyStore=filename.keystore -Djavax.net.ssl.keyStorePassword=passwd -Djavax.net.ssl.trustStore=filename.keystore -Djavax.net.ssl.trustStorePassword=passwd net.sf.odinms.net.channel.ChannelServer -Dcom.sun.management.jmxremote.port=13373 -Dcom.sun.management.jmxremote.password.file=jmxremote.password -Dcom.sun.management.jmxremote.access.file=jmxremote.access
pause
- Channel 2 -
- Code:
@echo off
@title Channel Server Console - Channel 2
set CLASSPATH=.;dist\odinms.jar;dist\mina-core.jar;dist\slf4j-api.jar;dist\slf4j-jdk14.jar;dist\mysql-connector-java-bin.jar
java -Dnet.sf.odinms.channelToLaunch=1 -Dnet.sf.odinms.recvops=recvops.properties -Dnet.sf.odinms.sendops=sendops.properties -Dnet.sf.odinms.wzpath=wz\ -Dnet.sf.odinms.channel.config=channel.properties -Djavax.net.ssl.keyStore=filename.keystore -Djavax.net.ssl.keyStorePassword=passwd -Djavax.net.ssl.trustStore=filename.keystore -Djavax.net.ssl.trustStorePassword=passwd net.sf.odinms.net.channel.ChannelServer -Dcom.sun.management.jmxremote.port=13373 -Dcom.sun.management.jmxremote.password.file=jmxremote.password -Dcom.sun.management.jmxremote.access.file=jmxremote.access
pause