cleanup: Fixes bugs and cleans up code (#660)
This commit is contained in:
parent
1de0b656a9
commit
679e8100f4
99 changed files with 160 additions and 346 deletions
|
|
@ -772,11 +772,7 @@ namespace Server.Engines.ConPVP
|
|||
{
|
||||
var pe = prefs.Find(players[j]);
|
||||
|
||||
if (pe.Disliked.Contains(ae.m_Arena.Name))
|
||||
{
|
||||
++ae.m_VotesAgainst;
|
||||
}
|
||||
else
|
||||
if (!pe.Disliked.Contains(ae.m_Arena.Name))
|
||||
{
|
||||
++ae.m_VotesFor;
|
||||
}
|
||||
|
|
@ -827,7 +823,6 @@ namespace Server.Engines.ConPVP
|
|||
private class ArenaEntry
|
||||
{
|
||||
public readonly Arena m_Arena;
|
||||
public int m_VotesAgainst;
|
||||
public int m_VotesFor;
|
||||
|
||||
public ArenaEntry(Arena arena) => m_Arena = arena;
|
||||
|
|
|
|||
|
|
@ -1924,24 +1924,7 @@ namespace Server.Engines.ConPVP
|
|||
var rx = dx - dy;
|
||||
var ry = dx + dy;
|
||||
|
||||
bool eastToWest;
|
||||
|
||||
if (rx >= 0 && ry >= 0)
|
||||
{
|
||||
eastToWest = false;
|
||||
}
|
||||
else if (rx >= 0)
|
||||
{
|
||||
eastToWest = true;
|
||||
}
|
||||
else if (ry >= 0)
|
||||
{
|
||||
eastToWest = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
eastToWest = false;
|
||||
}
|
||||
bool eastToWest = rx == 0 && ry >= 0 || rx >= 0 && ry == 0;
|
||||
|
||||
Effects.PlaySound(wall, Arena.Facet, 0x1F6);
|
||||
|
||||
|
|
|
|||
|
|
@ -456,8 +456,7 @@ namespace Server.Engines.ConPVP
|
|||
var point = m_Path[i];
|
||||
|
||||
var landTile = Map.Tiles.GetLandTile(point.X, point.Y);
|
||||
int landZ = 0, landAvg = 0, landTop = 0;
|
||||
Map.GetAverageZ(point.X, point.Y, ref landZ, ref landAvg, ref landTop);
|
||||
Map.GetAverageZ(point.X, point.Y, out var landZ, out _, out var landTop);
|
||||
|
||||
if (landZ <= point.Z && landTop >= point.Z && !landTile.Ignored)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -23,7 +23,6 @@ namespace Server.Engines.ConPVP
|
|||
public class TournamentBracketGump : Gump
|
||||
{
|
||||
private const int BlackColor32 = 0x000008;
|
||||
private const int LabelColor32 = 0xFFFFFF;
|
||||
private readonly Mobile m_From;
|
||||
private List<object> m_List;
|
||||
private readonly object m_Object;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Server.ContextMenus;
|
||||
using Server.Gumps;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue