Fixes data file loading (#145)
This commit is contained in:
parent
eb0f960be6
commit
5ea11cef11
10 changed files with 70 additions and 100 deletions
|
|
@ -1548,7 +1548,7 @@ namespace Server.Commands
|
|||
{
|
||||
List<BodyEntry> list = new List<BodyEntry>();
|
||||
|
||||
string path = Core.FindDataFile("models/models.txt");
|
||||
string path = Path.Combine(Core.BaseDirectory, "Data/models.txt");
|
||||
|
||||
if (File.Exists(path))
|
||||
{
|
||||
|
|
@ -1681,9 +1681,6 @@ namespace Server.Commands
|
|||
{
|
||||
Dictionary<int, SpeechEntry> table = tables[p];
|
||||
|
||||
if (p > 0)
|
||||
html.WriteLine(" <br>");
|
||||
|
||||
html.WriteLine(" <table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" border=\"0\">");
|
||||
html.WriteLine(" <tr><td class=\"tbl-border\">");
|
||||
html.WriteLine(" <table width=\"100%\" cellpadding=\"4\" cellspacing=\"1\">");
|
||||
|
|
@ -1767,7 +1764,7 @@ namespace Server.Commands
|
|||
|
||||
Dictionary<int, SpeechEntry> table = null;
|
||||
|
||||
string path = Core.FindDataFile("speech.mul");
|
||||
string path = Core.FindDataFile("speech.mul", false);
|
||||
|
||||
if (File.Exists(path))
|
||||
{
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ namespace Server.Engines.MLQuests.Objectives
|
|||
AcceptedType = type;
|
||||
Name = name;
|
||||
|
||||
if (MLQuestSystem.Debug && ShowDetailed && name.Number > 0)
|
||||
if (MLQuestSystem.Debug && ShowDetailed && name?.Number > 0)
|
||||
{
|
||||
int itemid = LabelToItemID(name.Number);
|
||||
|
||||
|
|
|
|||
|
|
@ -36,12 +36,9 @@ namespace Server.Misc
|
|||
|
||||
EventSink.ClientVersionReceived += EventSink_ClientVersionReceived;
|
||||
|
||||
// ClientVersion.Required = null;
|
||||
// Required = new ClientVersion( "6.0.0.0" );
|
||||
|
||||
if (m_DetectClientRequirement)
|
||||
{
|
||||
string path = Core.FindDataFile("client.exe");
|
||||
string path = Core.FindDataFile("client.exe", false);
|
||||
|
||||
if (File.Exists(path))
|
||||
{
|
||||
|
|
@ -71,10 +68,10 @@ namespace Server.Misc
|
|||
return;
|
||||
|
||||
if (Required != null && version < Required && (m_OldClientResponse == OldClientResponse.Kick ||
|
||||
(m_OldClientResponse == OldClientResponse.LenientKick &&
|
||||
m_OldClientResponse == OldClientResponse.LenientKick &&
|
||||
DateTime.UtcNow - state.Mobile.CreationTime > m_AgeLeniency &&
|
||||
state.Mobile is PlayerMobile mobile &&
|
||||
mobile.GameTime > m_GameTimeLeniency)))
|
||||
mobile.GameTime > m_GameTimeLeniency))
|
||||
{
|
||||
kickMessage = $"This server requires your client version be at least {Required}.";
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue