Add lobby tooltips for registered / anonymous players.

This commit is contained in:
Paul Chote
2018-07-07 16:26:48 +00:00
committed by abcdefg30
parent b5a5eecc25
commit 70706ca531
16 changed files with 690 additions and 29 deletions

View File

@@ -296,15 +296,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
return "Poor";
}
public static string DescriptiveIpAddress(string ip)
{
if (ip == null)
return "Unknown Host";
if (ip == IPAddress.Loopback.ToString())
return "Local Host";
return ip;
}
public static void SetupLatencyWidget(Widget parent, Session.Client c, OrderManager orderManager, bool visible)
{
var block = parent.GetOrNull("LATENCY");
@@ -323,6 +314,29 @@ namespace OpenRA.Mods.Common.Widgets.Logic
tooltip.Bind(orderManager, null, c);
}
public static void SetupProfileWidget(Widget parent, Session.Client c, OrderManager orderManager, WorldRenderer worldRenderer)
{
var profile = parent.GetOrNull<ImageWidget>("PROFILE");
if (profile != null && c.Bot == null)
{
var imageName = (c != null && c.IsAdmin ? "admin-" : "player-")
+ (c.Fingerprint != null ? "registered" : "anonymous");
profile.GetImageName = () => imageName;
profile.IsVisible = () => true;
}
var profileTooltip = parent.GetOrNull<ClientTooltipRegionWidget>("PROFILE_TOOLTIP");
if (profileTooltip != null && c.Bot == null)
{
if (c != null && c.Fingerprint != null)
profileTooltip.Template = "REGISTERED_PLAYER_TOOLTIP";
profileTooltip.Bind(orderManager, worldRenderer, c);
profileTooltip.IsVisible = () => true;
}
}
public static void SetupEditableNameWidget(Widget parent, Session.Slot s, Session.Client c, OrderManager orderManager, WorldRenderer worldRenderer)
{
var name = parent.Get<TextFieldWidget>("NAME");
@@ -360,6 +374,8 @@ namespace OpenRA.Mods.Common.Widgets.Logic
return true;
};
SetupProfileWidget(name, c, orderManager, worldRenderer);
HideChildWidget(parent, "SLOT_OPTIONS");
}
@@ -370,6 +386,8 @@ namespace OpenRA.Mods.Common.Widgets.Logic
var font = Game.Renderer.Fonts[name.Font];
var label = WidgetUtils.TruncateText(c.Name, name.Bounds.Width, font);
name.GetText = () => label;
SetupProfileWidget(parent, c, orderManager, worldRenderer);
}
public static void SetupEditableSlotWidget(Widget parent, Session.Slot s, Session.Client c,
@@ -404,6 +422,8 @@ namespace OpenRA.Mods.Common.Widgets.Logic
slot.GetText = () => c != null ? c.Name : string.Empty;
slot.OnMouseDown = _ => ShowPlayerActionDropDown(slot, s, c, orderManager, lobby, before, after);
SetupProfileWidget(slot, c, orderManager, worldRenderer);
// Ensure Name selector (if present) is hidden
HideChildWidget(parent, "NAME");
}
@@ -573,12 +593,11 @@ namespace OpenRA.Mods.Common.Widgets.Logic
playerName.GetColor = () => player.Color.RGB;
}
public static string GetExternalIP(int clientIndex, OrderManager orderManager)
public static string GetExternalIP(Session.Client client, OrderManager orderManager)
{
var client = orderManager.LobbyInfo.ClientWithIndex(clientIndex);
var address = client != null ? client.IpAddress : "";
var lc = orderManager.LocalClient;
if (lc != null && lc.Index == clientIndex && address == IPAddress.Loopback.ToString())
if (lc != null && lc.Index == client.Index && address == IPAddress.Loopback.ToString())
{
var externalIP = UPnP.ExternalIP;
if (externalIP != null)

View File

@@ -10,7 +10,11 @@
#endregion
using System;
using System.Linq;
using System.Net;
using System.Text;
using OpenRA.Graphics;
using OpenRA.Network;
using OpenRA.Widgets;
namespace OpenRA.Mods.Common.Widgets.Logic
@@ -18,7 +22,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
public class LocalProfileLogic : ChromeLogic
{
readonly LocalPlayerProfile localProfile;
readonly Widget detailsContainer;
bool notFound;
[ObjectCreator.UseCtor]
@@ -75,8 +78,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
destroyKey.OnClick = localProfile.DeleteKeypair;
destroyKey.IsDisabled = minimalProfile;
detailsContainer = widget.Get("PROFILE_DETAILS");
detailsContainer.IsVisible = () => localProfile.State == LocalPlayerProfile.LinkState.Linked && !minimalProfile();
localProfile.RefreshPlayerData(() => RefreshComplete(false));
}
@@ -88,4 +89,129 @@ namespace OpenRA.Mods.Common.Widgets.Logic
Game.RunAfterTick(Ui.ResetTooltips);
}
}
public class RegisteredProfileTooltipLogic : ChromeLogic
{
readonly PlayerDatabase playerDatabase;
PlayerProfile profile;
bool profileLoaded;
[ObjectCreator.UseCtor]
public RegisteredProfileTooltipLogic(Widget widget, WorldRenderer worldRenderer, ModData modData, Session.Client client)
{
playerDatabase = modData.Manifest.Get<PlayerDatabase>();
var header = widget.Get("HEADER");
var profileHeader = header.Get("PROFILE_HEADER");
var messageHeader = header.Get("MESSAGE_HEADER");
var message = messageHeader.Get<LabelWidget>("MESSAGE");
var messageFont = Game.Renderer.Fonts[message.Font];
profileHeader.IsVisible = () => profileLoaded;
messageHeader.IsVisible = () => !profileLoaded;
var profileWidth = 0;
var messageText = "Loading player profile...";
var messageWidth = messageFont.Measure(messageText).X + 2 * message.Bounds.Left;
Action<DownloadDataCompletedEventArgs> onQueryComplete = i =>
{
try
{
if (i.Error == null)
{
var yaml = MiniYaml.FromString(Encoding.UTF8.GetString(i.Result)).First();
if (yaml.Key == "Player")
{
profile = FieldLoader.Load<PlayerProfile>(yaml.Value);
Game.RunAfterTick(() =>
{
var nameLabel = profileHeader.Get<LabelWidget>("PROFILE_NAME");
var nameFont = Game.Renderer.Fonts[nameLabel.Font];
var rankLabel = profileHeader.Get<LabelWidget>("PROFILE_RANK");
var rankFont = Game.Renderer.Fonts[rankLabel.Font];
var adminContainer = profileHeader.Get("GAME_ADMIN");
var adminLabel = adminContainer.Get<LabelWidget>("LABEL");
var adminFont = Game.Renderer.Fonts[adminLabel.Font];
var headerSizeOffset = profileHeader.Bounds.Height - messageHeader.Bounds.Height;
nameLabel.GetText = () => profile.ProfileName;
rankLabel.GetText = () => profile.ProfileRank;
profileWidth = Math.Max(profileWidth, nameFont.Measure(profile.ProfileName).X + 2 * nameLabel.Bounds.Left);
profileWidth = Math.Max(profileWidth, rankFont.Measure(profile.ProfileRank).X + 2 * rankLabel.Bounds.Left);
header.Bounds.Height += headerSizeOffset;
if (client.IsAdmin)
{
profileWidth = Math.Max(profileWidth, adminFont.Measure(adminLabel.Text).X + 2 * adminLabel.Bounds.Left);
adminContainer.IsVisible = () => true;
profileHeader.Bounds.Height += adminLabel.Bounds.Height;
header.Bounds.Height += adminLabel.Bounds.Height;
}
profileWidth = Math.Min(profileWidth, widget.Bounds.Width);
header.Bounds.Width = widget.Bounds.Width = profileWidth;
widget.Bounds.Height = header.Bounds.Height;
profileLoaded = true;
});
}
}
}
catch (Exception e)
{
Log.Write("debug", "Failed to parse player data result with exception: {0}", e);
}
finally
{
if (profile == null)
{
messageText = "Failed to load player profile.";
messageWidth = messageFont.Measure(messageText).X + 2 * message.Bounds.Left;
header.Bounds.Width = widget.Bounds.Width = messageWidth;
}
}
};
message.GetText = () => messageText;
header.Bounds.Height += messageHeader.Bounds.Height;
header.Bounds.Width = widget.Bounds.Width = messageWidth;
widget.Bounds.Height = header.Bounds.Height;
new Download(playerDatabase.Profile + client.Fingerprint, _ => { }, onQueryComplete);
}
}
public class AnonymousProfileTooltipLogic : ChromeLogic
{
[ObjectCreator.UseCtor]
public AnonymousProfileTooltipLogic(Widget widget, OrderManager orderManager, Session.Client client)
{
var address = LobbyUtils.GetExternalIP(client, orderManager);
var cachedDescriptiveIP = address ?? "Unknown IP";
var nameLabel = widget.Get<LabelWidget>("NAME");
var nameFont = Game.Renderer.Fonts[nameLabel.Font];
widget.Bounds.Width = nameFont.Measure(nameLabel.Text).X + 2 * nameLabel.Bounds.Left;
var ipLabel = widget.Get<LabelWidget>("IP");
ipLabel.GetText = () => cachedDescriptiveIP;
var locationLabel = widget.Get<LabelWidget>("LOCATION");
var cachedCountryLookup = GeoIP.LookupCountry(address);
locationLabel.GetText = () => cachedCountryLookup;
if (client.IsAdmin)
{
var adminLabel = widget.Get("GAME_ADMIN");
adminLabel.IsVisible = () => client.IsAdmin;
widget.Bounds.Height += adminLabel.Bounds.Height;
}
}
}
}

View File

@@ -451,6 +451,10 @@ lobby-bits: chrome.png
kick: 386,115,11,11
protected: 403,97,10,13
protected-disabled: 403,113,10,13
admin-registered: 448,112,16,16
admin-anonymous: 464,112,16,16
player-registered: 480,112,16,16
player-anonymous: 496,112,16,16
reload-icon: chrome.png
enabled: 256,192,16,16

View File

@@ -83,8 +83,22 @@ Container@LOBBY_PLAYER_BIN:
Width: 190
Height: 25
Text: Name
LeftMargin: 24
MaxLength: 16
Visible: false
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
DropDownButton@SLOT_OPTIONS:
X: 15
Width: 190
@@ -170,10 +184,22 @@ Container@LOBBY_PLAYER_BIN:
Height: 25
TooltipContainer: TOOLTIP_CONTAINER
Template: LATENCY_TOOLTIP
Image@PROFILE:
ImageCollection: lobby-bits
X: 18
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 18
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@NAME:
X: 20
X: 39
Y: 0 - 1
Width: 180
Width: 161
Height: 25
DropDownButton@PLAYER_ACTION:
X: 15
@@ -182,6 +208,20 @@ Container@LOBBY_PLAYER_BIN:
Font: Regular
Visible: false
Align: Left
LeftMargin: 24
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
ColorBlock@COLORBLOCK:
X: 215
Y: 6
@@ -285,7 +325,21 @@ Container@LOBBY_PLAYER_BIN:
Width: 190
Height: 25
Text: Name
LeftMargin: 24
MaxLength: 16
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@SPECTATOR:
X: 210
Width: 341
@@ -330,10 +384,22 @@ Container@LOBBY_PLAYER_BIN:
Height: 25
TooltipContainer: TOOLTIP_CONTAINER
Template: LATENCY_TOOLTIP
Image@PROFILE:
ImageCollection: lobby-bits
X: 18
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 18
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@NAME:
X: 20
X: 39
Y: 0 - 1
Width: 180
Width: 161
Height: 25
DropDownButton@PLAYER_ACTION:
X: 15
@@ -342,6 +408,20 @@ Container@LOBBY_PLAYER_BIN:
Font: Regular
Visible: false
Align: Left
LeftMargin: 24
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@SPECTATOR:
X: 210
Width: 341

View File

@@ -202,3 +202,94 @@ Background@LATENCY_TOOLTIP:
Label@LATENCY:
Height: 23
Font: Bold
Background@ANONYMOUS_PLAYER_TOOLTIP:
Logic: AnonymousProfileTooltipLogic
Background: panel-black
Height: 55
Width: 200
Children:
Label@NAME:
X: 5
Text: Anonymous Player
Height: 23
Font: MediumBold
Label@LOCATION:
X: 5
Y: 23
Height: 12
Font: TinyBold
Label@IP:
X: 5
Y: 36
Height: 12
Font: TinyBold
Container@GAME_ADMIN:
X: 5
Y: 49
Height: 12
Visible: False
Children:
Image@ICON:
Y: 5
Width: 7
Height: 5
ImageCollection: lobby-bits
ImageName: admin
Label@LABEL:
X: 10
Height: 12
Text: Game Admin
Font: TinyBold
Container@REGISTERED_PLAYER_TOOLTIP:
Logic: RegisteredProfileTooltipLogic
Width: 270
Height: 137
Children:
Background@HEADER:
Width: PARENT_RIGHT
Background: panel-black
Children:
Container@PROFILE_HEADER:
Width: PARENT_RIGHT
Height: 42
Children:
Label@PROFILE_NAME:
X: 5
Width: PARENT_RIGHT - 20
Height: 23
Font: MediumBold
Label@PROFILE_RANK:
X: 5
Y: 23
Width: PARENT_RIGHT - 20
Height: 12
Font: TinyBold
Container@GAME_ADMIN:
X: 5
Y: 36
Width: PARENT_RIGHT - 20
Height: 12
Visible: False
Children:
Image@ICON:
Y: 5
Width: 7
Height: 5
ImageCollection: lobby-bits
ImageName: admin
Label@LABEL:
X: 10
Height: 12
Text: Game Admin
Font: TinyBold
Container@MESSAGE_HEADER:
Height: 26
Width: PARENT_RIGHT
Children:
Label@MESSAGE:
X: 5
Width: PARENT_RIGHT - 20
Height: 23
Font: Bold

Binary file not shown.

Before

Width:  |  Height:  |  Size: 93 KiB

After

Width:  |  Height:  |  Size: 93 KiB

View File

@@ -82,7 +82,22 @@ Container@LOBBY_PLAYER_BIN:
Width: 165
Height: 25
Text: Name
LeftMargin: 24
MaxLength: 16
Visible: false
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
DropDownButton@SLOT_OPTIONS:
X: 15
Width: 165
@@ -165,10 +180,22 @@ Container@LOBBY_PLAYER_BIN:
Height: 25
TooltipContainer: TOOLTIP_CONTAINER
Template: LATENCY_TOOLTIP
Image@PROFILE:
ImageCollection: lobby-bits
X: 18
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 18
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@NAME:
X: 20
X: 39
Y: 0 - 1
Width: 165
Width: 146
Height: 25
Text: Name
DropDownButton@PLAYER_ACTION:
@@ -178,6 +205,20 @@ Container@LOBBY_PLAYER_BIN:
Font: Regular
Visible: false
Align: Left
LeftMargin: 24
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
ColorBlock@COLORBLOCK:
X: 195
Y: 6
@@ -277,7 +318,21 @@ Container@LOBBY_PLAYER_BIN:
Width: 165
Height: 25
Text: Name
LeftMargin: 24
MaxLength: 16
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@SPECTATOR:
X: 190
Width: 326
@@ -321,11 +376,23 @@ Container@LOBBY_PLAYER_BIN:
Height: 25
TooltipContainer: TOOLTIP_CONTAINER
Template: LATENCY_TOOLTIP
Image@PROFILE:
ImageCollection: lobby-bits
X: 18
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 18
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@NAME:
Width: 160
Height: 25
X: 20
X: 39
Y: 0 - 1
Width: 179
Height: 25
Text: Name
DropDownButton@PLAYER_ACTION:
X: 15

View File

@@ -130,6 +130,95 @@ Background@LATENCY_TOOLTIP:
Height: 23
Font: Bold
Background@ANONYMOUS_PLAYER_TOOLTIP:
Logic: AnonymousProfileTooltipLogic
Background: dialog4
Height: 56
Width: 200
Children:
Label@NAME:
X: 7
Text: Anonymous Player
Height: 24
Font: MediumBold
Label@LOCATION:
X: 7
Y: 23
Height: 12
Font: TinyBold
Label@IP:
X: 7
Y: 36
Height: 12
Font: TinyBold
Container@GAME_ADMIN:
X: 7
Y: 49
Height: 12
Visible: False
Children:
Image@ICON:
Y: 5
Width: 7
Height: 5
ImageCollection: lobby-bits
ImageName: admin
Label@LABEL:
X: 9
Height: 12
Text: Game Admin
Font: TinyBold
Background@REGISTERED_PLAYER_TOOLTIP:
Logic: RegisteredProfileTooltipLogic
Width: 270
Background: dialog4
Children:
Container@HEADER:
Width: PARENT_RIGHT
Children:
Container@PROFILE_HEADER:
Height: 43
Children:
Label@PROFILE_NAME:
X: 7
Width: PARENT_RIGHT - 20
Height: 24
Font: MediumBold
Label@PROFILE_RANK:
X: 7
Y: 23
Width: PARENT_RIGHT - 20
Height: 12
Font: TinyBold
Container@GAME_ADMIN:
X: 7
Y: 36
Width: PARENT_RIGHT - 20
Height: 12
Visible: False
Children:
Image@ICON:
Y: 5
Width: 7
Height: 5
ImageCollection: lobby-bits
ImageName: admin
Label@LABEL:
X: 10
Height: 12
Text: Game Admin
Font: TinyBold
Container@MESSAGE_HEADER:
Height: 26
Width: PARENT_RIGHT
Children:
Label@MESSAGE:
X: 7
Width: PARENT_RIGHT - 14
Height: 23
Font: Bold
Background@PRODUCTION_TOOLTIP:
Logic: ProductionTooltipLogic
Background: dialog4

View File

@@ -212,6 +212,10 @@ lobby-bits: buttons.png
huepicker: 193,0,7,15
protected: 200,0,12,13
protected-disabled: 211,0,12,13
admin-registered: 224,0,16,16
admin-anonymous: 240,0,16,16
player-registered: 224,16,16,16
player-anonymous: 240,16,16,16
reload-icon: chrome.png
enabled: 416,312,16,16

View File

@@ -82,7 +82,22 @@ Container@LOBBY_PLAYER_BIN:
Width: 165
Height: 25
Text: Name
LeftMargin: 24
MaxLength: 16
Visible: false
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
DropDownButton@SLOT_OPTIONS:
X: 15
Width: 165
@@ -165,19 +180,45 @@ Container@LOBBY_PLAYER_BIN:
Height: 25
TooltipContainer: TOOLTIP_CONTAINER
Template: LATENCY_TOOLTIP
Image@PROFILE:
ImageCollection: lobby-bits
X: 18
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 18
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@NAME:
X: 20
X: 39
Y: 0 - 1
Width: 165
Width: 146
Height: 25
Text: Name
DropDownButton@PLAYER_ACTION:
X: 15
Width: 165
Height: 23
Height: 25
Font: Regular
Visible: false
Align: Left
LeftMargin: 24
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
ColorBlock@COLORBLOCK:
X: 195
Y: 6
@@ -277,7 +318,21 @@ Container@LOBBY_PLAYER_BIN:
Width: 165
Height: 25
Text: Name
LeftMargin: 24
MaxLength: 16
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@SPECTATOR:
X: 190
Width: 326
@@ -321,8 +376,20 @@ Container@LOBBY_PLAYER_BIN:
Height: 25
TooltipContainer: TOOLTIP_CONTAINER
Template: LATENCY_TOOLTIP
Image@PROFILE:
ImageCollection: lobby-bits
X: 18
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 18
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@NAME:
X: 20
X: 39
Y: 0 - 1
Width: 160
Height: 25
@@ -330,10 +397,24 @@ Container@LOBBY_PLAYER_BIN:
DropDownButton@PLAYER_ACTION:
X: 15
Width: 165
Height: 23
Height: 25
Font: Regular
Visible: false
Align: Left
LeftMargin: 24
Children:
Image@PROFILE:
ImageCollection: lobby-bits
X: 3
Y: 3
Visible: false
ClientTooltipRegion@PROFILE_TOOLTIP:
X: 3
Y: 3
Width: 16
Height: 16
TooltipContainer: TOOLTIP_CONTAINER
Template: ANONYMOUS_PLAYER_TOOLTIP
Label@SPECTATOR:
X: 190
Width: 326

View File

@@ -130,6 +130,98 @@ Background@LATENCY_TOOLTIP:
Height: 23
Font: Bold
Background@ANONYMOUS_PLAYER_TOOLTIP:
Logic: AnonymousProfileTooltipLogic
Background: dialog3
Height: 57
Width: 200
Children:
Label@NAME:
X: 7
Y: 1
Text: Anonymous Player
Height: 24
Font: MediumBold
Label@LOCATION:
X: 7
Y: 24
Height: 12
Font: TinyBold
Label@IP:
X: 7
Y: 37
Height: 12
Font: TinyBold
Container@GAME_ADMIN:
X: 7
Y: 50
Height: 12
Visible: False
Children:
Image@ICON:
Y: 5
Width: 7
Height: 5
ImageCollection: lobby-bits
ImageName: admin
Label@LABEL:
X: 10
Height: 12
Text: Game Admin
Font: TinyBold
Background@REGISTERED_PLAYER_TOOLTIP:
Logic: RegisteredProfileTooltipLogic
Background: dialog3
Width: 270
Children:
Container@HEADER:
Width: PARENT_RIGHT
Children:
Container@PROFILE_HEADER:
Height: 45
Children:
Label@PROFILE_NAME:
X: 7
Y: 1
Width: PARENT_RIGHT - 20
Height: 24
Font: MediumBold
Label@PROFILE_RANK:
X: 7
Y: 24
Width: PARENT_RIGHT - 20
Height: 12
Font: TinyBold
Container@GAME_ADMIN:
X: 7
Y: 37
Width: PARENT_RIGHT - 20
Height: 12
Visible: False
Children:
Image@ICON:
Y: 5
Width: 7
Height: 5
ImageCollection: lobby-bits
ImageName: admin
Label@LABEL:
X: 10
Height: 12
Text: Game Admin
Font: TinyBold
Container@MESSAGE_HEADER:
Height: 31
Width: PARENT_RIGHT
Children:
Label@MESSAGE:
X: 7
Y: 3
Width: PARENT_RIGHT - 14
Height: 23
Font: Bold
Background@PRODUCTION_TOOLTIP:
Logic: ProductionTooltipLogic
Background: dialog3

Binary file not shown.

Before

Width:  |  Height:  |  Size: 31 KiB

After

Width:  |  Height:  |  Size: 34 KiB

View File

@@ -530,6 +530,10 @@ lobby-bits: buttons.png
huepicker: 194,0,7,15
protected: 202,0,10,13
protected-disabled: 213,0,10,13
admin-registered: 224,0,16,16
admin-anonymous: 240,0,16,16
player-registered: 224,16,16,16
player-anonymous: 240,16,16,16
reload-icon: chrome.png
enabled: 512,80,16,16

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 31 KiB

View File

@@ -377,6 +377,10 @@ lobby-bits: buttons.png
huepicker: 194,0,7,15
protected: 202,0,10,13
protected-disabled: 213,0,10,13
admin-registered: 224,0,16,16
admin-anonymous: 240,0,16,16
player-registered: 224,16,16,16
player-anonymous: 240,16,16,16
reload-icon: dialog.png
enabled: 160,480,16,16

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.8 KiB

After

Width:  |  Height:  |  Size: 11 KiB