mirror of
https://github.com/ProjectSWGCore/NGECore2.git
synced 2026-07-14 00:02:07 -04:00
Merge branch 'master' of https://github.com/ProjectSWGCore/NGECore2
Conflicts: src/main/NGECore.java
This commit is contained in:
+18
-3
@@ -43,7 +43,7 @@ import org.apache.mina.core.session.IoSession;
|
||||
import com.sleepycat.je.Transaction;
|
||||
import com.sleepycat.persist.EntityCursor;
|
||||
|
||||
import protocol.swg.ChatSystemMessage;
|
||||
import protocol.swg.chat.ChatSystemMessage;
|
||||
import net.engio.mbassy.bus.config.BusConfiguration;
|
||||
import resources.common.RadialOptions;
|
||||
import resources.common.ThreadMonitor;
|
||||
@@ -57,8 +57,10 @@ import services.DevService;
|
||||
import services.EntertainmentService;
|
||||
import services.EquipmentService;
|
||||
import services.GroupService;
|
||||
import services.housing.HousingService;
|
||||
import services.InstanceService;
|
||||
import services.LoginService;
|
||||
import services.LootService;
|
||||
import services.MissionService;
|
||||
import services.PlayerService;
|
||||
import services.ScriptService;
|
||||
@@ -83,6 +85,7 @@ import services.LoginService;
|
||||
import services.map.MapService;
|
||||
import services.object.ObjectService;
|
||||
import services.object.UpdateService;
|
||||
import services.resources.HarvesterService;
|
||||
import services.resources.ResourceService;
|
||||
import services.retro.RetroService;
|
||||
import services.spawn.SpawnService;
|
||||
@@ -175,6 +178,9 @@ public class NGECore {
|
||||
public ResourceService resourceService;
|
||||
public ConversationService conversationService;
|
||||
public BazaarService bazaarService;
|
||||
public HousingService housingService;
|
||||
public LootService lootService;
|
||||
public HarvesterService harvesterService;
|
||||
|
||||
|
||||
// Login Server
|
||||
@@ -235,6 +241,11 @@ public class NGECore {
|
||||
if (!(config.loadConfigFile())) {
|
||||
config = DefaultConfig.getConfig();
|
||||
}
|
||||
|
||||
Config options = new Config();
|
||||
options.setFilePath("options.cfg");
|
||||
boolean optionsConfigLoaded = options.loadConfigFile();
|
||||
|
||||
// Database
|
||||
databaseConnection = new DatabaseConnection();
|
||||
databaseConnection.connect(config.getString("DB.URL"), config.getString("DB.NAME"), config.getString("DB.USER"), config.getString("DB.PASS"), "postgresql");
|
||||
@@ -288,6 +299,9 @@ public class NGECore {
|
||||
devService = new DevService(this);
|
||||
conversationService = new ConversationService(this);
|
||||
bazaarService = new BazaarService(this);
|
||||
housingService = new HousingService(this);
|
||||
lootService = new LootService(this);
|
||||
harvesterService = new HarvesterService(this);
|
||||
|
||||
if (config.keyExists("JYTHONCONSOLE.PORT")) {
|
||||
int jythonPort = config.getInt("JYTHONCONSOLE.PORT");
|
||||
@@ -304,7 +318,7 @@ public class NGECore {
|
||||
aiService = new AIService(this);
|
||||
//missionService = new MissionService(this);
|
||||
|
||||
if (config.getInt("LOAD.RESOURCE.SYSTEM") == 1) {
|
||||
if (optionsConfigLoaded && options.getInt("LOAD.RESOURCE.SYSTEM") == 1) {
|
||||
surveyService = new SurveyService(this);
|
||||
resourceService = new ResourceService(this);
|
||||
}
|
||||
@@ -409,7 +423,7 @@ public class NGECore {
|
||||
|
||||
objectService.loadBuildings();
|
||||
|
||||
if (config.getInt("LOAD.RESOURCE.SYSTEM") == 1) {
|
||||
if (optionsConfigLoaded && options.getInt("LOAD.RESOURCE.SYSTEM") > 0) {
|
||||
objectService.loadResourceRoots();
|
||||
objectService.loadResources();
|
||||
}
|
||||
@@ -452,6 +466,7 @@ public class NGECore {
|
||||
spawnService.loadLairGroups();
|
||||
spawnService.loadSpawnAreas();
|
||||
|
||||
housingService.loadHousingTemplates();
|
||||
equipmentService.loadBonusSets();
|
||||
|
||||
retroService.run();
|
||||
|
||||
Reference in New Issue
Block a user