Rename SScores
This commit is contained in:
1 parent
3fbc5994b1
commit
9bfedf3cf0
3 files changed
+10
-10
No files matched your search
@@ -243,13 +243,13 @@ namespace Vocaluxe.Base
|
||||
return lastInsertID;
|
||||
}
|
||||
|
||||
public static void LoadScore(out List<SScores> scores, SPlayer player)
|
||||
public static void LoadScore(out List<SDBScoreEntry> scores, SPlayer player)
|
||||
{
|
||||
using (var connection = new SQLiteConnection())
|
||||
{
|
||||
connection.ConnectionString = "Data Source=" + _HighscoreFilePath;
|
||||
|
||||
scores = new List<SScores>();
|
||||
scores = new List<SDBScoreEntry>();
|
||||
|
||||
try
|
||||
{
|
||||
@@ -290,13 +290,13 @@ namespace Vocaluxe.Base
|
||||
{
|
||||
while (reader.Read())
|
||||
{
|
||||
var score = new SScores
|
||||
var score = new SDBScoreEntry
|
||||
{
|
||||
Name = reader.GetString(0),
|
||||
Score = reader.GetInt32(1),
|
||||
Date = new DateTime(reader.GetInt64(2)).ToString("dd/MM/yyyy"),
|
||||
Difficulty = (EGameDifficulty)reader.GetInt32(3),
|
||||
LineNr = reader.GetInt32(4),
|
||||
VoiceNr = reader.GetInt32(4),
|
||||
ID = reader.GetInt32(5)
|
||||
};
|
||||
|
||||
|
||||
@@ -44,7 +44,7 @@ namespace Vocaluxe.Screens
|
||||
private string[] _TextDate;
|
||||
private string[] _ParticleEffectNew;
|
||||
|
||||
private List<SScores>[] _Scores;
|
||||
private List<SDBScoreEntry>[] _Scores;
|
||||
private List<int> _NewEntryIDs;
|
||||
private int _Round;
|
||||
private int _Pos;
|
||||
@@ -169,7 +169,7 @@ namespace Vocaluxe.Screens
|
||||
string name = _Scores[_Round][_Pos + p].Name;
|
||||
name += " [" + CLanguage.Translate(Enum.GetName(typeof(EGameDifficulty), _Scores[_Round][_Pos + p].Difficulty)) + "]";
|
||||
if (_IsDuet)
|
||||
name += " (P" + (_Scores[_Round][_Pos + p].LineNr + 1) + ")";
|
||||
name += " (P" + (_Scores[_Round][_Pos + p].VoiceNr + 1) + ")";
|
||||
_Texts[_TextName[p]].Text = name;
|
||||
|
||||
_Texts[_TextScore[p]].Text = _Scores[_Round][_Pos + p].Score.ToString("00000");
|
||||
@@ -195,9 +195,9 @@ namespace Vocaluxe.Screens
|
||||
_Round = 0;
|
||||
_Pos = 0;
|
||||
CPoints points = CGame.GetPoints();
|
||||
_Scores = new List<SScores>[points.NumRounds];
|
||||
_Scores = new List<SDBScoreEntry>[points.NumRounds];
|
||||
for (int i = 0; i < _Scores.Length; i++)
|
||||
_Scores[i] = new List<SScores>();
|
||||
_Scores[i] = new List<SDBScoreEntry>();
|
||||
_NewEntryIDs.Clear();
|
||||
_AddScoresToDB();
|
||||
_LoadScores();
|
||||
|
||||
@@ -197,13 +197,13 @@ namespace VocaluxeLib
|
||||
public bool SongFinished;
|
||||
}
|
||||
|
||||
public struct SScores
|
||||
public struct SDBScoreEntry
|
||||
{
|
||||
public string Name;
|
||||
public int Score;
|
||||
public string Date;
|
||||
public EGameDifficulty Difficulty;
|
||||
public int LineNr;
|
||||
public int VoiceNr;
|
||||
public int ID;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user