diff --git a/Server/SQL/ConsumableItemData.cs b/Server/SQL/ConsumableItemData.cs new file mode 100644 index 0000000..6996dd5 --- /dev/null +++ b/Server/SQL/ConsumableItemData.cs @@ -0,0 +1,49 @@ +using Server.Git; +using System.ComponentModel.DataAnnotations; + +namespace Server.SQL +{ + public class ConsumableItemData + { + [Key] + public long index { get; set; } + public string name { get; set; } + public eItemType item_type { get; set; } + public string reward { get; set; } + } + + public enum eItemType + { + exp = 1, + package, + random + } + + public class ConsumableItemDataExcel + { + private Dictionary consumableItemData; + + public string sheetName = "ConsumableItemData"; + + public ConsumableItemData getConsumableItemData(long key) + { + return consumableItemData[key]; + } + + public List getConsumableItemData() + { + return consumableItemData.Values.ToList(); + } + public void init(sheet data) + { + this.consumableItemData = new Dictionary(); + foreach (var item in data.dicViewer) + { + //ConsumableItemData ConsumableItemData = new ConsumableItemData(); + //ConsumableItemData.index = item.Key; + //ConsumableItemData.part = (int)item.Value["part"]; + //this.ConsumableItemData.Add(item.Key, ConsumableItemData); + } + } + } +} diff --git a/Server/SQL/RandomRewardData.cs b/Server/SQL/RandomRewardData.cs new file mode 100644 index 0000000..71a0b59 --- /dev/null +++ b/Server/SQL/RandomRewardData.cs @@ -0,0 +1,42 @@ +using Server.Git; +using System.ComponentModel.DataAnnotations; + +namespace Server.SQL +{ + public class RandomRewardData + { + [Key] + public long index { get; set; } + public int group { get; set; } + public long reward { get; set; } + public int prob { get; set; } + } + + public class RandomRewardDataExcel + { + private Dictionary randomRewardData; + + public string sheetName = "RandomRewardData"; + + public RandomRewardData getRandomRewardData(long key) + { + return randomRewardData[key]; + } + + public List getRandomRewardData() + { + return randomRewardData.Values.ToList(); + } + public void init(sheet data) + { + this.randomRewardData = new Dictionary(); + foreach (var item in data.dicViewer) + { + //RandomRewardData RandomRewardData = new RandomRewardData(); + //RandomRewardData.index = item.Key; + //RandomRewardData.part = (int)item.Value["part"]; + //this.RandomRewardData.Add(item.Key, RandomRewardData); + } + } + } +} diff --git a/Server/SQL/RewardData.cs b/Server/SQL/RewardData.cs new file mode 100644 index 0000000..3ccf279 --- /dev/null +++ b/Server/SQL/RewardData.cs @@ -0,0 +1,52 @@ +using Server.Git; +using System.ComponentModel.DataAnnotations; + +namespace Server.SQL +{ + public class RewardData + { + [Key] + public long index { get; set; } + public eBuyType buy_type { get; set; } + public long return_item { get; set; } + } + + public enum eRewardItemType + { + gold = 1, + freecash, + paycash, + character, + equipment, + consumable, + etc + } + + public class RewardDataExcel + { + private Dictionary rewardData; + + public string sheetName = "RewardData"; + + public RewardData getRewardData(long key) + { + return rewardData[key]; + } + + public List getRewardData() + { + return rewardData.Values.ToList(); + } + public void init(sheet data) + { + this.rewardData = new Dictionary(); + foreach (var item in data.dicViewer) + { + //RewardData RewardData = new RewardData(); + //RewardData.index = item.Key; + //RewardData.part = (int)item.Value["part"]; + //this.RewardData.Add(item.Key, RewardData); + } + } + } +} diff --git a/Server/SQL/ShopItemData.cs b/Server/SQL/ShopItemData.cs new file mode 100644 index 0000000..f1ba7d9 --- /dev/null +++ b/Server/SQL/ShopItemData.cs @@ -0,0 +1,49 @@ +using Server.Git; +using System.ComponentModel.DataAnnotations; + +namespace Server.SQL +{ + public class ShopItemData + { + [Key] + public long index { get; set; } + public eBuyType buy_type { get; set; } + public int buy { get; set; } + public long reward { get; set; } + } + + public enum eBuyType + { + gold = 1, + cash, + money + } + + public class ShopItemDataExcel + { + private Dictionary shopItemData; + + public string sheetName = "ShopItemData"; + + public ShopItemData getShopItemData(long key) + { + return shopItemData[key]; + } + + public List getShopItemData() + { + return shopItemData.Values.ToList(); + } + public void init(sheet data) + { + this.shopItemData = new Dictionary(); + foreach (var item in data.dicViewer) + { + //ShopItemData ShopItemData = new ShopItemData(); + //ShopItemData.index = item.Key; + //ShopItemData.part = (int)item.Value["part"]; + //this.ShopItemData.Add(item.Key, ShopItemData); + } + } + } +}