Remove unnecessary database files and code
This commit is contained in:
parent
24b5152f76
commit
4a3aef6cb0
@ -6,17 +6,6 @@ namespace TJAPlayer3
|
||||
{
|
||||
class DBCharacter
|
||||
{
|
||||
|
||||
public void tDBCharacter()
|
||||
{
|
||||
if (!File.Exists(@".\Databases\Character.json"))
|
||||
tSaveFile();
|
||||
|
||||
tLoadFile();
|
||||
}
|
||||
|
||||
#region [Auxiliary classes]
|
||||
|
||||
public class CharacterData
|
||||
{
|
||||
public CharacterData()
|
||||
@ -44,22 +33,5 @@ namespace TJAPlayer3
|
||||
public string Author;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
public Dictionary<int, CharacterData> data = new Dictionary<int, CharacterData>();
|
||||
|
||||
#region [private]
|
||||
|
||||
private void tSaveFile()
|
||||
{
|
||||
ConfigManager.SaveConfig(data, @".\Databases\Character.json");
|
||||
}
|
||||
|
||||
private void tLoadFile()
|
||||
{
|
||||
data = ConfigManager.GetConfig<Dictionary<int, CharacterData>>(@".\Databases\Character.json");
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
@ -6,17 +6,6 @@ namespace TJAPlayer3
|
||||
{
|
||||
class DBPuchichara
|
||||
{
|
||||
|
||||
public void tDBPuchichara()
|
||||
{
|
||||
if (!File.Exists(@".\Databases\Puchichara.json"))
|
||||
tSaveFile();
|
||||
|
||||
tLoadFile();
|
||||
}
|
||||
|
||||
#region [Auxiliary classes]
|
||||
|
||||
public class PuchicharaData
|
||||
{
|
||||
public PuchicharaData()
|
||||
@ -44,22 +33,5 @@ namespace TJAPlayer3
|
||||
public string Author;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
public Dictionary<int, PuchicharaData> data = new Dictionary<int, PuchicharaData>();
|
||||
|
||||
#region [private]
|
||||
|
||||
private void tSaveFile()
|
||||
{
|
||||
ConfigManager.SaveConfig(data, @".\Databases\Puchichara.json");
|
||||
}
|
||||
|
||||
private void tLoadFile()
|
||||
{
|
||||
data = ConfigManager.GetConfig<Dictionary<int, PuchicharaData>>(@".\Databases\Puchichara.json");
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
@ -6,17 +6,7 @@ namespace TJAPlayer3
|
||||
{
|
||||
class DBUnlockables
|
||||
{
|
||||
public void tDBUnlockables()
|
||||
{
|
||||
if (!File.Exists(@".\Databases\Unlockables.json"))
|
||||
tSaveFile();
|
||||
|
||||
tLoadFile();
|
||||
}
|
||||
|
||||
#region [Auxilliary classes]
|
||||
|
||||
public Dictionary<string, int> RequiredArgs = new Dictionary<string, int>()
|
||||
public static Dictionary<string, int> RequiredArgs = new Dictionary<string, int>()
|
||||
{
|
||||
["ch"] = 1,
|
||||
["cs"] = 1,
|
||||
@ -104,8 +94,8 @@ namespace TJAPlayer3
|
||||
*/
|
||||
public (bool, string) tConditionMet(int[] inputValues)
|
||||
{
|
||||
if (RequiredArgCount < 0 && TJAPlayer3.Databases.DBUnlockables.RequiredArgs.ContainsKey(Condition))
|
||||
RequiredArgCount = TJAPlayer3.Databases.DBUnlockables.RequiredArgs[Condition];
|
||||
if (RequiredArgCount < 0 && RequiredArgs.ContainsKey(Condition))
|
||||
RequiredArgCount = RequiredArgs[Condition];
|
||||
|
||||
if (this.Values.Length < this.RequiredArgCount)
|
||||
return (false, CLangManager.LangInstance.GetString(90005) + this.Condition + " requires " + this.RequiredArgCount.ToString() + " values.");
|
||||
@ -126,8 +116,8 @@ namespace TJAPlayer3
|
||||
|
||||
public string tConditionMessage()
|
||||
{
|
||||
if (RequiredArgCount < 0 && TJAPlayer3.Databases.DBUnlockables.RequiredArgs.ContainsKey(Condition))
|
||||
RequiredArgCount = TJAPlayer3.Databases.DBUnlockables.RequiredArgs[Condition];
|
||||
if (RequiredArgCount < 0 && RequiredArgs.ContainsKey(Condition))
|
||||
RequiredArgCount = RequiredArgs[Condition];
|
||||
|
||||
if (this.Values.Length < this.RequiredArgCount)
|
||||
return (CLangManager.LangInstance.GetString(90005) + this.Condition + " requires " + this.RequiredArgCount.ToString() + " values.");
|
||||
@ -144,30 +134,6 @@ namespace TJAPlayer3
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
public class CUnlockables
|
||||
{
|
||||
[JsonProperty("puchichara")]
|
||||
public Dictionary<int, CUnlockConditions> Puchichara = new Dictionary<int, CUnlockConditions>();
|
||||
}
|
||||
|
||||
public CUnlockables data = new CUnlockables();
|
||||
|
||||
#region [private]
|
||||
|
||||
private void tSaveFile()
|
||||
{
|
||||
ConfigManager.SaveConfig(data, @".\Databases\Unlockables.json");
|
||||
}
|
||||
|
||||
private void tLoadFile()
|
||||
{
|
||||
data = ConfigManager.GetConfig<CUnlockables>(@".\Databases\Unlockables.json");
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
|
||||
|
||||
|
@ -7,20 +7,11 @@ namespace TJAPlayer3
|
||||
{
|
||||
public void tDatabases()
|
||||
{
|
||||
//DBPuchichara = new DBPuchichara();
|
||||
DBUnlockables = new DBUnlockables();
|
||||
//DBCharacter = new DBCharacter();
|
||||
DBCDN = new DBCDN();
|
||||
|
||||
//DBPuchichara.tDBPuchichara();
|
||||
DBUnlockables.tDBUnlockables();
|
||||
//DBCharacter.tDBCharacter();
|
||||
DBCDN.tDBCDN();
|
||||
}
|
||||
|
||||
//public DBPuchichara DBPuchichara;
|
||||
public DBUnlockables DBUnlockables;
|
||||
//public DBCharacter DBCharacter;
|
||||
public DBCDN DBCDN;
|
||||
}
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
{
|
||||
0: {
|
||||
"name" : "None",
|
||||
"rarity": "Common",
|
||||
"author": "",
|
||||
},
|
||||
}
|
@ -1,52 +0,0 @@
|
||||
{
|
||||
0: {
|
||||
"name" : "None",
|
||||
"rarity": "Common",
|
||||
"author": "",
|
||||
},
|
||||
1: {
|
||||
"name" : "Placeholder",
|
||||
"rarity": "Common",
|
||||
"author": "[Author]",
|
||||
},
|
||||
2: {
|
||||
"name" : "Placeholder",
|
||||
"rarity": "Poor",
|
||||
"author": "[Author]",
|
||||
},
|
||||
3: {
|
||||
"name" : "Placeholder",
|
||||
"rarity": "Uncommon",
|
||||
"author": "[Author]",
|
||||
},
|
||||
4: {
|
||||
"name" : "Placeholder",
|
||||
"rarity": "Common",
|
||||
"author": "[Author]",
|
||||
},
|
||||
5: {
|
||||
"name" : "Placeholder",
|
||||
"rarity": "Epic",
|
||||
"author": "[Author]",
|
||||
},
|
||||
6: {
|
||||
"name" : "Placeholder",
|
||||
"rarity": "Common",
|
||||
"author": "[Author]",
|
||||
},
|
||||
7: {
|
||||
"name" : "Placeholder",
|
||||
"rarity": "Rare",
|
||||
"author": "[Author]",
|
||||
},
|
||||
8: {
|
||||
"name" : "Placeholder",
|
||||
"rarity": "Uncommon",
|
||||
"author": "[Author]",
|
||||
},
|
||||
9: {
|
||||
"name" : "Placeholder",
|
||||
"rarity": "Legendary",
|
||||
"author": "[Author]",
|
||||
},
|
||||
}
|
@ -1,26 +0,0 @@
|
||||
{
|
||||
"puchichara": {
|
||||
7: {
|
||||
"condition": "ch",
|
||||
"type": "me",
|
||||
"values": [
|
||||
450,
|
||||
],
|
||||
},
|
||||
5: {
|
||||
"condition": "ch",
|
||||
"type": "me",
|
||||
"values": [
|
||||
1400,
|
||||
],
|
||||
},
|
||||
9: {
|
||||
"condition": "cs",
|
||||
"type": "me",
|
||||
"values": [
|
||||
5000,
|
||||
],
|
||||
},
|
||||
},
|
||||
|
||||
}
|
0
Test/Encyclopedia/Menus.json
Normal file
0
Test/Encyclopedia/Menus.json
Normal file
Binary file not shown.
After Width: | Height: | Size: 603 KiB |
BIN
Test/System/SimpleStyle/Graphics/15_OpenEncyclopedia/Context.png
Normal file
BIN
Test/System/SimpleStyle/Graphics/15_OpenEncyclopedia/Context.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 10 KiB |
Binary file not shown.
After Width: | Height: | Size: 16 KiB |
Loading…
Reference in New Issue
Block a user