fixed party screen translations
This commit is contained in:
1 parent
196a881bcc
commit
632206c317
12 files changed
+123
-23
No files matched your search
@@ -11,7 +11,6 @@ namespace Vocaluxe.PartyModes
|
||||
{
|
||||
// Version number for theme files. Increment it, if you've changed something on the theme files!
|
||||
const int ScreenVersion = 1;
|
||||
private CText Warning;
|
||||
|
||||
public PartyScreenChallengeMain()
|
||||
{
|
||||
@@ -28,17 +27,6 @@ namespace Vocaluxe.PartyModes
|
||||
public override void LoadTheme(string XmlPath)
|
||||
{
|
||||
base.LoadTheme(XmlPath);
|
||||
|
||||
Warning = GetNewText();
|
||||
Warning.Height = 100f;
|
||||
Warning.X = 150;
|
||||
Warning.Y = 300;
|
||||
Warning.Fon = "Outline";
|
||||
Warning.Style = EStyle.Normal;
|
||||
Warning.Color = new SColorF(1f, 0f, 0f, 1f);
|
||||
Warning.SColor = new SColorF(1f, 0f, 0f, 1f);
|
||||
Warning.Text = "CHALLENGE!";
|
||||
AddText(Warning);
|
||||
}
|
||||
|
||||
public override void ReloadTheme()
|
||||
|
||||
@@ -7,5 +7,7 @@
|
||||
<!--General-->
|
||||
<TR_PARTYMODE_NAME>Challenge Modus</TR_PARTYMODE_NAME>
|
||||
<TR_PARTYMODE_DESCRIPTION>Spiele mit bis zu X Spielern einem Wettkampfmodus</TR_PARTYMODE_DESCRIPTION>
|
||||
<!--ScreenMain-->
|
||||
<TR_SCREENMAIN_TITLE>Challenge Modus: Übersicht</TR_SCREENMAIN_TITLE>
|
||||
</Texts>
|
||||
</root>
|
||||
@@ -6,6 +6,8 @@
|
||||
<Texts>
|
||||
<!--General-->
|
||||
<TR_PARTYMODE_NAME>Challenge Mode</TR_PARTYMODE_NAME>
|
||||
<TR_PARTYMODE_DESCRIPTION>Challenge with zp to X Players</TR_PARTYMODE_DESCRIPTION>
|
||||
<TR_PARTYMODE_DESCRIPTION>Challenge with zp to X Players</TR_PARTYMODE_DESCRIPTION>
|
||||
<!--ScreenMain-->
|
||||
<TR_SCREENMAIN_TITLE>Challenge Mode: Overview</TR_SCREENMAIN_TITLE>
|
||||
</Texts>
|
||||
</root>
|
||||
@@ -7,5 +7,7 @@
|
||||
<!--General-->
|
||||
<TR_PARTYMODE_NAME>TODO: Challenge Mode</TR_PARTYMODE_NAME>
|
||||
<TR_PARTYMODE_DESCRIPTION>TODO: Challenge with zp to X Players</TR_PARTYMODE_DESCRIPTION>
|
||||
<!--ScreenMain-->
|
||||
<TR_SCREENMAIN_TITLE>Challenge Mode: Overview</TR_SCREENMAIN_TITLE>
|
||||
</Texts>
|
||||
</root>
|
||||
@@ -7,5 +7,7 @@
|
||||
<!--General-->
|
||||
<TR_PARTYMODE_NAME>TODO: Challenge Mode</TR_PARTYMODE_NAME>
|
||||
<TR_PARTYMODE_DESCRIPTION>TODO: Challenge with zp to X Players</TR_PARTYMODE_DESCRIPTION>
|
||||
<!--ScreenMain-->
|
||||
<TR_SCREENMAIN_TITLE>Challenge Mode: Overview</TR_SCREENMAIN_TITLE>
|
||||
</Texts>
|
||||
</root>
|
||||
@@ -53,7 +53,7 @@
|
||||
<!--<Font>: Text font name-->
|
||||
<Font>Outline</Font>
|
||||
<!--<Text>: Nothing or translation tag-->
|
||||
<Text>TR_SCREEN_PARTY_CHALLENGE_MAIN</Text>
|
||||
<Text>TR_SCREENMAIN_TITLE</Text>
|
||||
<!--<Reflection> If exists:-->
|
||||
<!-- <Space>: Reflection Space-->
|
||||
<!-- <Height>: Reflection Height-->
|
||||
|
||||
@@ -211,7 +211,7 @@
|
||||
<!--<NumVisible>: Number of visible elements in the slide-->
|
||||
<NumVisible>1</NumVisible>
|
||||
</SelectSlideModes>
|
||||
<ButtonExit>
|
||||
<ButtonStart>
|
||||
<!--<Skin>: Texture name-->
|
||||
<Skin>Button</Skin>
|
||||
<!--<SkinSelected>: Texture name for selected button-->
|
||||
@@ -228,6 +228,63 @@
|
||||
<!--<SColor>: Selected button color from ColorScheme (high priority)-->
|
||||
<!--or <SR>, <SG>, <SB>, <SA> (lower priority)-->
|
||||
<SColor>ButtonSColor</SColor>
|
||||
<Text>
|
||||
<!--<X>, <Y>: Text position-->
|
||||
<X>75</X>
|
||||
<Y>10</Y>
|
||||
<!--<H>: Text height-->
|
||||
<H>32</H>
|
||||
<!--<MaxW>: Maximum text width (if exists)-->
|
||||
<MaxW>142</MaxW>
|
||||
<!--<Color>: Text color from ColorScheme (high priority)-->
|
||||
<!--or <R>, <G>, <B>, <A> (lower priority)-->
|
||||
<Color>ButtonTextColor</Color>
|
||||
<!--<SColor>: Selected Text color from ColorScheme (high priority)-->
|
||||
<!--or <SR>, <SG>, <SB>, <SA> (lower priority)-->
|
||||
<SColor>ButtonTextSColor</SColor>
|
||||
<!--<Align>: Text align horizontal: Left, Center, Right-->
|
||||
<Align>Center</Align>
|
||||
<!--<HAlign>: Text align vertical (on downsizing): Top, Center, Bottom-->
|
||||
<HAlign>Center</HAlign>
|
||||
<!--<Style>: Text style: Normal, Italic, Bold, BoldItalic-->
|
||||
<Style>Bold</Style>
|
||||
<!--<Font>: Text font name-->
|
||||
<Font>Outline</Font>
|
||||
<!--<Text>: Nothing or translation tag-->
|
||||
<Text>TR_BUTTON_START</Text>
|
||||
</Text>
|
||||
<!--<Reflection> If exists:-->
|
||||
<!-- <Space>: Reflection Space-->
|
||||
<!-- <Height>: Reflection Height-->
|
||||
<Reflection>
|
||||
<Space>10</Space>
|
||||
<Height>26</Height>
|
||||
</Reflection>
|
||||
<!--<SReflection> If exists:-->
|
||||
<!-- <Space>: Reflection Space of selected button-->
|
||||
<!-- <Height>: Reflection Height of selected button-->
|
||||
<SReflection>
|
||||
<Space>10</Space>
|
||||
<Height>26</Height>
|
||||
</SReflection>
|
||||
</ButtonStart>
|
||||
<ButtonExit>
|
||||
<!--<Skin>: Texture name-->
|
||||
<Skin>Button</Skin>
|
||||
<!--<SkinSelected>: Texture name for selected button-->
|
||||
<SkinSelected>Button</SkinSelected>
|
||||
<!--<X>, <Y>, <Z>, <W>, <H>: Button position, width and height-->
|
||||
<X>145</X>
|
||||
<Y>600</Y>
|
||||
<Z>0,00</Z>
|
||||
<W>150</W>
|
||||
<H>50</H>
|
||||
<!--<Color>: Button color from ColorScheme (high priority)-->
|
||||
<!--or <R>, <G>, <B>, <A> (lower priority)-->
|
||||
<Color>ButtonColor</Color>
|
||||
<!--<SColor>: Selected button color from ColorScheme (high priority)-->
|
||||
<!--or <SR>, <SG>, <SB>, <SA> (lower priority)-->
|
||||
<SColor>ButtonSColor</SColor>
|
||||
<Text>
|
||||
<!--<X>, <Y>: Text position-->
|
||||
<X>75</X>
|
||||
|
||||
@@ -266,7 +266,12 @@ namespace Vocaluxe.Base
|
||||
|
||||
foreach (string screenfile in pm.ScreenFiles)
|
||||
{
|
||||
CMenuParty Screen = GetPartyScreenInstance(Output, screenfile, Path.Combine(Path.Combine(CSettings.sFolderPartyModes, pm.Folder), CSettings.sFolderPartyModeScreens));
|
||||
CMenuParty Screen = GetPartyScreenInstance(
|
||||
Output,
|
||||
screenfile,
|
||||
Path.Combine(Path.Combine(CSettings.sFolderPartyModes, pm.Folder), CSettings.sFolderPartyModeScreens),
|
||||
pm.PartyModeID);
|
||||
|
||||
if (Screen != null)
|
||||
pm.PartyMode.AddScreen(Screen, screenfile);
|
||||
else
|
||||
@@ -323,7 +328,7 @@ namespace Vocaluxe.Base
|
||||
return CompileResult.CompiledAssembly;
|
||||
}
|
||||
|
||||
private static CMenuParty GetPartyScreenInstance(Assembly Assembly, string ScreenName, string XmlPath)
|
||||
private static CMenuParty GetPartyScreenInstance(Assembly Assembly, string ScreenName, string XmlPath, int PartyModeID)
|
||||
{
|
||||
if (Assembly == null)
|
||||
return null;
|
||||
@@ -346,6 +351,7 @@ namespace Vocaluxe.Base
|
||||
return null;
|
||||
}
|
||||
Screen.Initialize(CMain.Base);
|
||||
Screen.SetPartyModeID(PartyModeID);
|
||||
Screen.LoadTheme(XmlPath);
|
||||
return Screen;
|
||||
}
|
||||
|
||||
@@ -14,6 +14,7 @@ namespace Vocaluxe.Screens
|
||||
const int ScreenVersion = 1;
|
||||
|
||||
const string TextDescription = "TextDescription";
|
||||
const string ButtonStart = "ButtonStart";
|
||||
const string ButtonExit = "ButtonExit";
|
||||
const string SelectSlideModes = "SelectSlideModes";
|
||||
|
||||
@@ -30,7 +31,7 @@ namespace Vocaluxe.Screens
|
||||
_ThemeName = "ScreenParty";
|
||||
_ScreenVersion = ScreenVersion;
|
||||
_ThemeTexts = new string[] { TextDescription };
|
||||
_ThemeButtons = new string[] { ButtonExit };
|
||||
_ThemeButtons = new string[] { ButtonStart, ButtonExit };
|
||||
_ThemeSelectSlides = new string[] { SelectSlideModes };
|
||||
}
|
||||
|
||||
@@ -55,16 +56,20 @@ namespace Vocaluxe.Screens
|
||||
case Keys.Escape:
|
||||
CGraphics.FadeTo(EScreens.ScreenMain);
|
||||
break;
|
||||
|
||||
case Keys.C:
|
||||
CParty.SetPartyMode(1);
|
||||
CGraphics.FadeTo(EScreens.ScreenPartyDummy);
|
||||
break;
|
||||
|
||||
case Keys.Enter:
|
||||
if (Buttons[htButtons(ButtonStart)].Selected)
|
||||
StartPartyMode();
|
||||
|
||||
if (Buttons[htButtons(ButtonExit)].Selected)
|
||||
CGraphics.FadeTo(EScreens.ScreenMain);
|
||||
break;
|
||||
|
||||
case Keys.Left:
|
||||
case Keys.Right:
|
||||
if (SelectSlides[htSelectSlides(SelectSlideModes)].Selected)
|
||||
UpdateSelection();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
@@ -76,6 +81,8 @@ namespace Vocaluxe.Screens
|
||||
|
||||
if (MouseEvent.LB && IsMouseOver(MouseEvent))
|
||||
{
|
||||
if (Buttons[htButtons(ButtonStart)].Selected)
|
||||
StartPartyMode();
|
||||
|
||||
if (Buttons[htButtons(ButtonExit)].Selected)
|
||||
CGraphics.FadeTo(EScreens.ScreenMain);
|
||||
@@ -136,5 +143,18 @@ namespace Vocaluxe.Screens
|
||||
Texts[htTexts(TextDescription)].PartyModeID = _PartyModeInfos[index].PartyModeID;
|
||||
Texts[htTexts(TextDescription)].Text = _PartyModeInfos[index].Description;
|
||||
}
|
||||
|
||||
private void StartPartyMode()
|
||||
{
|
||||
if (_PartyModeInfos.Count == 0)
|
||||
return;
|
||||
|
||||
int index = SelectSlides[htSelectSlides(SelectSlideModes)].Selection;
|
||||
if (index >= _PartyModeInfos.Count)
|
||||
return;
|
||||
|
||||
CParty.SetPartyMode(_PartyModeInfos[index].PartyModeID);
|
||||
CGraphics.FadeTo(EScreens.ScreenPartyDummy);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -25,6 +25,7 @@ namespace Vocaluxe.Menu
|
||||
private List<CInteraction> _Interactions;
|
||||
private int _Selection = 0;
|
||||
private string _ThemePath = String.Empty;
|
||||
protected int _PartyModeID = -1;
|
||||
|
||||
private List<CBackground> _Backgrounds;
|
||||
private List<CButton> _Buttons;
|
||||
@@ -233,6 +234,7 @@ namespace Vocaluxe.Menu
|
||||
for (int i = 0; i < _ThemeTexts.Length; i++)
|
||||
{
|
||||
CText text = new CText(_Base);
|
||||
text.PartyModeID = _PartyModeID;
|
||||
if (text.LoadTheme("//root/" + _ThemeName, _ThemeTexts[i], navigator, SkinIndex))
|
||||
{
|
||||
_htTexts.Add(_ThemeTexts[i], AddText(text));
|
||||
@@ -1300,6 +1302,7 @@ namespace Vocaluxe.Menu
|
||||
|
||||
public int AddText(CText text)
|
||||
{
|
||||
text.PartyModeID = _PartyModeID;
|
||||
_Texts.Add(text);
|
||||
_AddInteraction(_Texts.Count - 1, EType.TText);
|
||||
return _Texts.Count - 1;
|
||||
@@ -2311,11 +2314,13 @@ namespace Vocaluxe.Menu
|
||||
|
||||
// Texts
|
||||
CText text = new CText(_Base);
|
||||
text.PartyModeID = _PartyModeID;
|
||||
i = 1;
|
||||
while (text.LoadTheme("//root/" + _ThemeName, "Text" + i.ToString(), navigator, SkinIndex))
|
||||
{
|
||||
AddText(text);
|
||||
text = new CText(_Base);
|
||||
text.PartyModeID = _PartyModeID;
|
||||
i++;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,6 +10,16 @@ namespace Vocaluxe.Menu
|
||||
{
|
||||
}
|
||||
|
||||
public void SetPartyModeID(int PartyModeID)
|
||||
{
|
||||
_PartyModeID = PartyModeID;
|
||||
}
|
||||
|
||||
public int GetPartyModeID()
|
||||
{
|
||||
return _PartyModeID;
|
||||
}
|
||||
|
||||
/*
|
||||
public sealed override void LoadTheme()
|
||||
{
|
||||
|
||||
@@ -43,6 +43,12 @@ namespace Vocaluxe.Menu
|
||||
void ProcessMouseMove(int x, int y);
|
||||
}
|
||||
|
||||
public interface IMenuParty
|
||||
{
|
||||
void SetPartyModeID(int PartyModeID);
|
||||
int GetPartyModeID();
|
||||
}
|
||||
|
||||
public interface IConfig
|
||||
{
|
||||
void SetBackgroundMusicVolume(int NewVolume);
|
||||
|
||||
Reference in new issue
Block a user