Add networked Fighter3D minigame
This commit is contained in:
@@ -30,7 +30,7 @@ namespace XGame
|
||||
private const float LobbyPanelWidth = 520f;
|
||||
private const float LobbyPanelHeight = 296f;
|
||||
private const float LobbyPanelLeft = 24f;
|
||||
private const float LobbyPanelTop = -24f;
|
||||
private const float LobbyPanelMiddleY = 0f;
|
||||
private const float CollapsedPanelWidth = 56f;
|
||||
|
||||
private void Awake()
|
||||
@@ -208,10 +208,10 @@ namespace XGame
|
||||
buttonGo.transform.SetParent(parent, false);
|
||||
|
||||
RectTransform rt = buttonGo.GetComponent<RectTransform>();
|
||||
rt.anchorMin = new Vector2(0f, 1f);
|
||||
rt.anchorMax = new Vector2(0f, 1f);
|
||||
rt.pivot = new Vector2(0f, 1f);
|
||||
rt.anchoredPosition = new Vector2(LobbyPanelLeft + LobbyPanelWidth, LobbyPanelTop);
|
||||
rt.anchorMin = new Vector2(0f, 0.5f);
|
||||
rt.anchorMax = new Vector2(0f, 0.5f);
|
||||
rt.pivot = new Vector2(0f, 0.5f);
|
||||
rt.anchoredPosition = new Vector2(LobbyPanelLeft + LobbyPanelWidth, LobbyPanelMiddleY);
|
||||
rt.sizeDelta = new Vector2(48f, 72f);
|
||||
|
||||
Image img = buttonGo.GetComponent<Image>();
|
||||
@@ -254,18 +254,18 @@ namespace XGame
|
||||
|
||||
if (panelLobby != null)
|
||||
{
|
||||
panelLobby.anchorMin = new Vector2(0f, 1f);
|
||||
panelLobby.anchorMax = new Vector2(0f, 1f);
|
||||
panelLobby.pivot = new Vector2(0f, 1f);
|
||||
panelLobby.anchoredPosition = new Vector2(LobbyPanelLeft, LobbyPanelTop);
|
||||
panelLobby.anchorMin = new Vector2(0f, 0.5f);
|
||||
panelLobby.anchorMax = new Vector2(0f, 0.5f);
|
||||
panelLobby.pivot = new Vector2(0f, 0.5f);
|
||||
panelLobby.anchoredPosition = new Vector2(LobbyPanelLeft, LobbyPanelMiddleY);
|
||||
panelLobby.sizeDelta = new Vector2(LobbyPanelWidth, LobbyPanelHeight);
|
||||
}
|
||||
if (collapseButtonRect != null)
|
||||
{
|
||||
collapseButtonRect.anchorMin = new Vector2(0f, 1f);
|
||||
collapseButtonRect.anchorMax = new Vector2(0f, 1f);
|
||||
collapseButtonRect.pivot = new Vector2(0f, 1f);
|
||||
collapseButtonRect.anchoredPosition = new Vector2(LobbyPanelLeft + LobbyPanelWidth, LobbyPanelTop);
|
||||
collapseButtonRect.anchorMin = new Vector2(0f, 0.5f);
|
||||
collapseButtonRect.anchorMax = new Vector2(0f, 0.5f);
|
||||
collapseButtonRect.pivot = new Vector2(0f, 0.5f);
|
||||
collapseButtonRect.anchoredPosition = new Vector2(LobbyPanelLeft + LobbyPanelWidth, LobbyPanelMiddleY);
|
||||
collapseButtonRect.sizeDelta = new Vector2(48f, 72f);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user