You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the REDCAVE01 map, use the mage profession to summon heroes, adjust the attack mode to all, first use the magic shield, then quickly consume 2 bottles of HP potion in Beltcell around the monster, and continuously use the skill FlameField. Repeating this operation will cause the server to crash, resulting in an error:
[Work loop error Thread 1342]System.NullReferenceException: Object reference not set to an instance of an object.
at Server.MirEnvir.Map.CompleteMagic(IList`1 data) in E:\legend\mir2-main\Server\MirEnvir\Map.cs:line 1342
at Server.MirEnvir.Map.Process(DelayedAction action) in E:\legend\mir2-main\Server\MirEnvir\Map.cs:line 820
at Server.MirEnvir.Map.Process() in E:\legend\mir2-main\Server\MirEnvir\Map.cs:line 759
at Server.MirEnvir.Envir.WorkLoop() in E:\legend\mir2-main\Server\MirEnvir\Envir.cs:line 651
The error code is:# region ThunderStorm
case Spell.ThunderStorm:
case Spell.FlameField:
case Spell.NapalmShot:
//case Spell. StormEscape:
value = (int)data[2];
location = (Point)data[3];
for (int y = location.Y - 2; y <= location.Y + 2; y++)
{
if (y < 0) continue;
if (y >= Height) break;
for (int x = location.X - 2; x <= location.X + 2; x++)
{
if (x < 0) continue;
if (x >= Width) break;
cell = GetCell(x, y);
if (!cell.Valid || cell.Objects == null) continue;
for (int i = 0; i < cell.Objects.Count; i++) //
{
MapObject target = cell.Objects[i];
switch (target.Race)
{
case ObjectType.Monster:
case ObjectType.Player:
//Only targets
if (!target.IsAttackTarget(player)) break;
target.Attacked(player, magic.Spell == Spell.ThunderStorm && !target.Undead ? value / 10 : value, DefenceType.MAC, false);
train = true;
break;
}
}
}
}
break;
#endregion
The text was updated successfully, but these errors were encountered:
In the REDCAVE01 map, use the mage profession to summon heroes, adjust the attack mode to all, first use the magic shield, then quickly consume 2 bottles of HP potion in Beltcell around the monster, and continuously use the skill FlameField. Repeating this operation will cause the server to crash, resulting in an error:
[Work loop error Thread 1342]System.NullReferenceException: Object reference not set to an instance of an object.
at Server.MirEnvir.Map.CompleteMagic(IList`1 data) in E:\legend\mir2-main\Server\MirEnvir\Map.cs:line 1342
at Server.MirEnvir.Map.Process(DelayedAction action) in E:\legend\mir2-main\Server\MirEnvir\Map.cs:line 820
at Server.MirEnvir.Map.Process() in E:\legend\mir2-main\Server\MirEnvir\Map.cs:line 759
at Server.MirEnvir.Envir.WorkLoop() in E:\legend\mir2-main\Server\MirEnvir\Envir.cs:line 651
The error code is:# region ThunderStorm
case Spell.ThunderStorm:
case Spell.FlameField:
case Spell.NapalmShot:
//case Spell. StormEscape:
value = (int)data[2];
location = (Point)data[3];
for (int y = location.Y - 2; y <= location.Y + 2; y++)
{
if (y < 0) continue;
if (y >= Height) break;
for (int x = location.X - 2; x <= location.X + 2; x++)
{
if (x < 0) continue;
if (x >= Width) break;
cell = GetCell(x, y);
if (!cell.Valid || cell.Objects == null) continue;
for (int i = 0; i < cell.Objects.Count; i++) //
{
MapObject target = cell.Objects[i];
switch (target.Race)
{
case ObjectType.Monster:
case ObjectType.Player:
//Only targets
if (!target.IsAttackTarget(player)) break;
target.Attacked(player, magic.Spell == Spell.ThunderStorm && !target.Undead ? value / 10 : value, DefenceType.MAC, false);
train = true;
break;
}
}
}
}
break;
#endregion
The text was updated successfully, but these errors were encountered: