Core: Misc fixes

This commit is contained in:
hondacrx
2018-05-26 13:09:46 -04:00
parent 3f7f1a7356
commit f7e557ab71
5 changed files with 12 additions and 7 deletions
@@ -38,6 +38,12 @@ namespace Framework.Networking
return true; return true;
} }
public void Wait()
{
_thread.Join();
_thread = null;
}
public int GetConnectionCount() public int GetConnectionCount()
{ {
return _connections; return _connections;
+3 -3
View File
@@ -65,9 +65,9 @@ namespace Framework.Networking
void Wait() void Wait()
{ {
//if (_threadCount != 0) if (_threadCount != 0)
//for (int i = 0; i < _threadCount; ++i) for (int i = 0; i < _threadCount; ++i)
//_threads[i].Wait(); _threads[i].Wait();
} }
public virtual void OnSocketOpen(Socket sock) public virtual void OnSocketOpen(Socket sock)
@@ -94,7 +94,7 @@ namespace Game.Entities
Relocate(pos); Relocate(pos);
if (!IsPositionValid()) if (!IsPositionValid())
{ {
Log.outError(LogFilter.AreaTrigger, "AreaTrigger (spell {0}) not created. Invalid coordinates (X: {0} Y: {1})", spell.Id, GetPositionX(), GetPositionY()); Log.outError(LogFilter.AreaTrigger, $"AreaTrigger (spell {spell.Id}) not created. Invalid coordinates (X: {GetPositionX()} Y: {GetPositionY()})");
return false; return false;
} }
+1 -2
View File
@@ -321,7 +321,7 @@ namespace Game.Entities
{ {
SpellInfo newInfo = Global.SpellMgr.GetSpellInfo(spellId); SpellInfo newInfo = Global.SpellMgr.GetSpellInfo(spellId);
if (newInfo != null) if (newInfo != null)
return base.GetCastSpellInfo(newInfo); return GetCastSpellInfo(newInfo);
} }
} }
@@ -2612,7 +2612,6 @@ namespace Game.Entities
} }
} }
// "the bodies of template functions must be made available in a header file"
public void ApplySpellMod<T>(uint spellId, SpellModOp op, ref T basevalue, Spell spell = null) public void ApplySpellMod<T>(uint spellId, SpellModOp op, ref T basevalue, Spell spell = null)
{ {
SpellInfo spellInfo = Global.SpellMgr.GetSpellInfo(spellId); SpellInfo spellInfo = Global.SpellMgr.GetSpellInfo(spellId);
+1 -1
View File
@@ -464,7 +464,7 @@ MaxCoreStuckTime = 0
AddonChannel = 1 AddonChannel = 1
# #
# MapUpdate.Threads (NYI) # MapUpdate.Threads
# Description: Number of threads to update maps. # Description: Number of threads to update maps.
# Default: 1 # Default: 1