(e7bd8839d) Remove unused parameters.
This commit is contained in:
@@ -280,6 +280,8 @@ namespace Barotrauma
|
||||
|
||||
private GUILayoutGroup subPreviewContainer;
|
||||
|
||||
private GUILayoutGroup subPreviewContainer;
|
||||
|
||||
private GUIButton loadGameButton;
|
||||
|
||||
public Action<Submarine, string, string> StartNewGame;
|
||||
|
||||
@@ -2043,13 +2043,12 @@ namespace Barotrauma
|
||||
GUI.AddMessage(GetCharacterEditorTranslation("RagdollReset"), Color.WhiteSmoke, font: GUI.Font);
|
||||
return true;
|
||||
};
|
||||
Vector2 messageBoxRelSize = new Vector2(0.5f, 0.5f);
|
||||
int messageBoxWidth = GameMain.GraphicsWidth / 2;
|
||||
int messageBoxHeight = GameMain.GraphicsHeight / 2;
|
||||
var saveRagdollButton = new GUIButton(new RectTransform(buttonSize, layoutGroup.RectTransform), GetCharacterEditorTranslation("SaveRagdoll"));
|
||||
saveRagdollButton.OnClicked += (button, userData) =>
|
||||
{
|
||||
var box = new GUIMessageBox(GetCharacterEditorTranslation("SaveRagdoll"), $"{GetCharacterEditorTranslation("ProvideFileName")}: ", new string[] { TextManager.Get("Cancel"), TextManager.Get("Save") }, messageBoxRelSize);
|
||||
var box = new GUIMessageBox(GetCharacterEditorTranslation("SaveRagdoll"), $"{GetCharacterEditorTranslation("ProvideFileName")}: ", new string[] { TextManager.Get("Cancel"), TextManager.Get("Save") }, messageBoxWidth, messageBoxHeight);
|
||||
var inputField = new GUITextBox(new RectTransform(new Point(box.Content.Rect.Width, 30), box.Content.RectTransform, Anchor.Center), RagdollParams.Name);
|
||||
box.Buttons[0].OnClicked += (b, d) =>
|
||||
{
|
||||
@@ -2077,7 +2076,7 @@ namespace Barotrauma
|
||||
var loadRagdollButton = new GUIButton(new RectTransform(buttonSize, layoutGroup.RectTransform), GetCharacterEditorTranslation("LoadRagdoll"));
|
||||
loadRagdollButton.OnClicked += (button, userData) =>
|
||||
{
|
||||
var loadBox = new GUIMessageBox(GetCharacterEditorTranslation("LoadRagdoll"), "", new string[] { TextManager.Get("Cancel"), TextManager.Get("Load"), TextManager.Get("Delete") }, messageBoxRelSize);
|
||||
var loadBox = new GUIMessageBox(GetCharacterEditorTranslation("LoadRagdoll"), "", new string[] { TextManager.Get("Cancel"), TextManager.Get("Load"), TextManager.Get("Delete") }, messageBoxWidth, messageBoxHeight);
|
||||
loadBox.Buttons[0].OnClicked += loadBox.Close;
|
||||
var listBox = new GUIListBox(new RectTransform(new Vector2(0.9f, 0.6f), loadBox.Content.RectTransform, Anchor.TopCenter));
|
||||
var deleteButton = loadBox.Buttons[2];
|
||||
@@ -2123,7 +2122,7 @@ namespace Barotrauma
|
||||
var msgBox = new GUIMessageBox(
|
||||
TextManager.Get("DeleteDialogLabel"),
|
||||
TextManager.Get("DeleteDialogQuestion").Replace("[file]", selectedFile),
|
||||
new string[] { TextManager.Get("Yes"), TextManager.Get("Cancel") });
|
||||
new string[] { TextManager.Get("Yes"), TextManager.Get("Cancel") }, messageBoxWidth - 100, messageBoxHeight - 100);
|
||||
msgBox.Buttons[0].OnClicked += (b, d) =>
|
||||
{
|
||||
try
|
||||
@@ -2164,7 +2163,7 @@ namespace Barotrauma
|
||||
var saveAnimationButton = new GUIButton(new RectTransform(buttonSize, layoutGroup.RectTransform), GetCharacterEditorTranslation("SaveAnimation"));
|
||||
saveAnimationButton.OnClicked += (button, userData) =>
|
||||
{
|
||||
var box = new GUIMessageBox(GetCharacterEditorTranslation("SaveAnimation"), string.Empty, new string[] { TextManager.Get("Cancel"), TextManager.Get("Save") }, messageBoxRelSize);
|
||||
var box = new GUIMessageBox(GetCharacterEditorTranslation("SaveAnimation"), string.Empty, new string[] { TextManager.Get("Cancel"), TextManager.Get("Save") }, messageBoxWidth, messageBoxHeight);
|
||||
var textArea = new GUIFrame(new RectTransform(new Vector2(1, 0.1f), box.Content.RectTransform) { MinSize = new Point(350, 30) }, style: null);
|
||||
var inputLabel = new GUITextBlock(new RectTransform(new Vector2(0.3f, 1), textArea.RectTransform) { MinSize = new Point(250, 30) }, $"{GetCharacterEditorTranslation("ProvideFileName")}: ");
|
||||
var inputField = new GUITextBox(new RectTransform(new Vector2(0.5f, 1), textArea.RectTransform, Anchor.TopRight) { MinSize = new Point(100, 30) }, CurrentAnimation.Name);
|
||||
@@ -2212,7 +2211,7 @@ namespace Barotrauma
|
||||
var loadAnimationButton = new GUIButton(new RectTransform(buttonSize, layoutGroup.RectTransform), GetCharacterEditorTranslation("LoadAnimation"));
|
||||
loadAnimationButton.OnClicked += (button, userData) =>
|
||||
{
|
||||
var loadBox = new GUIMessageBox(GetCharacterEditorTranslation("LoadAnimation"), "", new string[] { TextManager.Get("Cancel"), TextManager.Get("Load"), TextManager.Get("Delete") }, messageBoxRelSize);
|
||||
var loadBox = new GUIMessageBox(GetCharacterEditorTranslation("LoadAnimation"), "", new string[] { TextManager.Get("Cancel"), TextManager.Get("Load"), TextManager.Get("Delete") }, messageBoxWidth, messageBoxHeight);
|
||||
loadBox.Buttons[0].OnClicked += loadBox.Close;
|
||||
var listBox = new GUIListBox(new RectTransform(new Vector2(0.9f, 0.6f), loadBox.Content.RectTransform));
|
||||
var deleteButton = loadBox.Buttons[2];
|
||||
@@ -2274,7 +2273,7 @@ namespace Barotrauma
|
||||
var msgBox = new GUIMessageBox(
|
||||
TextManager.Get("DeleteDialogLabel"),
|
||||
TextManager.Get("DeleteDialogQuestion").Replace("[file]", selectedFile),
|
||||
new string[] { TextManager.Get("Yes"), TextManager.Get("Cancel") });
|
||||
new string[] { TextManager.Get("Yes"), TextManager.Get("Cancel") }, messageBoxWidth - 100, messageBoxHeight - 100);
|
||||
msgBox.Buttons[0].OnClicked += (b, d) =>
|
||||
{
|
||||
try
|
||||
@@ -4426,7 +4425,7 @@ namespace Barotrauma
|
||||
|
||||
protected override GUIMessageBox Create()
|
||||
{
|
||||
var box = new GUIMessageBox(GetCharacterEditorTranslation("CreateNewCharacter"), string.Empty, new string[] { TextManager.Get("Cancel"), TextManager.Get("Next") }, new Vector2(0.5f, 1.0f));
|
||||
var box = new GUIMessageBox(GetCharacterEditorTranslation("CreateNewCharacter"), string.Empty, new string[] { TextManager.Get("Cancel"), TextManager.Get("Next") }, GameMain.GraphicsWidth / 2, GameMain.GraphicsHeight);
|
||||
box.Content.ChildAnchor = Anchor.TopCenter;
|
||||
box.Content.AbsoluteSpacing = 20;
|
||||
int elementSize = 30;
|
||||
@@ -4542,7 +4541,7 @@ namespace Barotrauma
|
||||
|
||||
protected override GUIMessageBox Create()
|
||||
{
|
||||
var box = new GUIMessageBox(GetCharacterEditorTranslation("DefineRagdoll"), string.Empty, new string[] { TextManager.Get("Previous"), TextManager.Get("Create") }, new Vector2(0.5f, 1.0f));
|
||||
var box = new GUIMessageBox(GetCharacterEditorTranslation("DefineRagdoll"), string.Empty, new string[] { TextManager.Get("Previous"), TextManager.Get("Create") }, GameMain.GraphicsWidth / 2, GameMain.GraphicsHeight);
|
||||
box.Content.ChildAnchor = Anchor.TopCenter;
|
||||
box.Content.AbsoluteSpacing = 20;
|
||||
int elementSize = 30;
|
||||
@@ -4622,7 +4621,7 @@ namespace Barotrauma
|
||||
{
|
||||
if (htmlBox == null)
|
||||
{
|
||||
htmlBox = new GUIMessageBox(GetCharacterEditorTranslation("LoadHTML"), string.Empty, new string[] { TextManager.Get("Close"), TextManager.Get("Load") }, new Vector2(0.5f, 1.0f));
|
||||
htmlBox = new GUIMessageBox(GetCharacterEditorTranslation("LoadHTML"), string.Empty, new string[] { TextManager.Get("Close"), TextManager.Get("Load") }, GameMain.GraphicsWidth / 2, GameMain.GraphicsHeight);
|
||||
var element = new GUIFrame(new RectTransform(new Vector2(0.8f, 0.05f), htmlBox.Content.RectTransform), style: null, color: Color.Gray * 0.25f);
|
||||
new GUITextBlock(new RectTransform(new Vector2(0.5f, 1), element.RectTransform), GetCharacterEditorTranslation("HTMLPath"));
|
||||
var htmlPathElement = new GUITextBox(new RectTransform(new Vector2(0.5f, 1), element.RectTransform, Anchor.TopRight), $"Content/Characters/{Name}/{Name}.html");
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Xml.Linq;
|
||||
|
||||
namespace Barotrauma
|
||||
@@ -8,7 +11,7 @@ namespace Barotrauma
|
||||
{
|
||||
private GUIListBox listBox;
|
||||
|
||||
private readonly float scrollSpeed;
|
||||
private float scrollSpeed;
|
||||
|
||||
public CreditsPlayer(RectTransform rectT, string configFile) : base(null, rectT)
|
||||
{
|
||||
|
||||
@@ -602,7 +602,7 @@ namespace Barotrauma
|
||||
public GUIMessageBox Create()
|
||||
{
|
||||
var box = new GUIMessageBox(TextManager.Get("LevelEditorCreateLevelObj"), string.Empty,
|
||||
new string[] { TextManager.Get("Cancel"), TextManager.Get("Done") }, new Vector2(0.5f, 0.8f));
|
||||
new string[] { TextManager.Get("Cancel"), TextManager.Get("Done") }, GameMain.GraphicsWidth / 2, (int)(GameMain.GraphicsHeight * 0.8f));
|
||||
|
||||
box.Content.ChildAnchor = Anchor.TopCenter;
|
||||
box.Content.AbsoluteSpacing = 20;
|
||||
|
||||
@@ -354,12 +354,6 @@ namespace Barotrauma
|
||||
};
|
||||
var creditsContainer = new GUIFrame(new RectTransform(new Vector2(0.75f, 1.5f), menuTabs[(int)Tab.Credits].RectTransform, Anchor.CenterRight), style: "OuterGlow", color: Color.Black * 0.8f);
|
||||
creditsPlayer = new CreditsPlayer(new RectTransform(Vector2.One, creditsContainer.RectTransform), "Content/Texts/Credits.xml");
|
||||
|
||||
new GUIButton(new RectTransform(new Vector2(0.1f, 0.05f), menuTabs[(int)Tab.Credits].RectTransform, Anchor.BottomLeft) { RelativeOffset = new Vector2(0.25f, 0.02f) },
|
||||
TextManager.Get("Back"), style: "GUIButtonLarge")
|
||||
{
|
||||
OnClicked = SelectTab
|
||||
};
|
||||
}
|
||||
#endregion
|
||||
|
||||
@@ -389,9 +383,10 @@ namespace Barotrauma
|
||||
|
||||
private bool SelectTab(GUIButton button, object obj)
|
||||
{
|
||||
titleText.Visible = true;
|
||||
if (obj is Tab)
|
||||
{
|
||||
titleText.Visible = true;
|
||||
|
||||
if (GameMain.Config.UnsavedSettings)
|
||||
{
|
||||
var applyBox = new GUIMessageBox(
|
||||
@@ -789,10 +784,6 @@ namespace Barotrauma
|
||||
|
||||
GUI.Draw(Cam, spriteBatch);
|
||||
|
||||
spriteBatch.Begin(SpriteSortMode.Deferred, null, null, null, GameMain.ScissorTestEnable);
|
||||
|
||||
GUI.Draw(Cam, spriteBatch);
|
||||
|
||||
GUI.Draw(Cam, spriteBatch);
|
||||
|
||||
#if DEBUG
|
||||
|
||||
@@ -1212,7 +1212,7 @@ namespace Barotrauma
|
||||
};
|
||||
infoButton.OnClicked += (component, userdata) =>
|
||||
{
|
||||
((Submarine)userdata).CreatePreviewWindow(new GUIMessageBox("", "", new Vector2(0.25f, 0.25f), new Point(500, 400)));
|
||||
((Submarine)userdata).CreatePreviewWindow(new GUIMessageBox("", "", 550, 600));
|
||||
return true;
|
||||
};
|
||||
}
|
||||
@@ -2005,8 +2005,7 @@ namespace Barotrauma
|
||||
return false;
|
||||
}
|
||||
|
||||
var requestFileBox = new GUIMessageBox(TextManager.Get("DownloadSubLabel"), errorMsg,
|
||||
new string[] { TextManager.Get("Yes"), TextManager.Get("No") })
|
||||
var requestFileBox = new GUIMessageBox(TextManager.Get("DownloadSubLabel"), errorMsg, new string[] { TextManager.Get("Yes"), TextManager.Get("No") }, 400, 300)
|
||||
{
|
||||
UserData = "request" + subName
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user