Commit 7261fbe1 authored by keyongyu's avatar keyongyu

2.4.3.2

parent 1d2b200a
...@@ -78,7 +78,21 @@ public static class CardTypes{ ...@@ -78,7 +78,21 @@ public static class CardTypes{
CardType.TYPE_XYZ, CardType.TYPE_XYZ,
CardType.TYPE_SYNCHRO, CardType.TYPE_SYNCHRO,
CardType.TYPE_PENDULUM, CardType.TYPE_PENDULUM,
CardType.TYPE_SPIRIT,
CardType.TYPE_UNION,
CardType.TYPE_DUAL,
CardType.TYPE_FLIP,
CardType.TYPE_TOON,
};
public static readonly CardType[] TYPE1_10 = {
CardType.TYPE_LINK,
CardType.TYPE_RITUAL,
CardType.TYPE_FUSION,
CardType.TYPE_XYZ,
CardType.TYPE_SYNCHRO,
CardType.TYPE_PENDULUM,
CardType.TYPE_SPIRIT, CardType.TYPE_SPIRIT,
CardType.TYPE_UNION, CardType.TYPE_UNION,
CardType.TYPE_DUAL, CardType.TYPE_DUAL,
...@@ -91,6 +105,17 @@ public static class CardTypes{ ...@@ -91,6 +105,17 @@ public static class CardTypes{
CardType.TYPE_SYNCHRO, CardType.TYPE_SYNCHRO,
CardType.TYPE_PENDULUM, CardType.TYPE_PENDULUM,
CardType.TYPE_SPIRIT,
CardType.TYPE_UNION,
CardType.TYPE_DUAL,
CardType.TYPE_FLIP,
CardType.TYPE_TOON,
};
public static readonly CardType[] TYPE2_10 = {
CardType.TYPE_XYZ,
CardType.TYPE_SYNCHRO,
CardType.TYPE_PENDULUM,
CardType.TYPE_SPIRIT, CardType.TYPE_SPIRIT,
CardType.TYPE_UNION, CardType.TYPE_UNION,
CardType.TYPE_DUAL, CardType.TYPE_DUAL,
...@@ -107,22 +132,46 @@ public static class CardTypes{ ...@@ -107,22 +132,46 @@ public static class CardTypes{
CardType.TYPE_DUAL, CardType.TYPE_DUAL,
CardType.TYPE_FLIP, CardType.TYPE_FLIP,
CardType.TYPE_TOON, CardType.TYPE_TOON,
CardType.TYPE_SPSUMMON, };
public static readonly CardType[] TYPE3_10 ={
CardType.TYPE_SYNCHRO,
CardType.TYPE_PENDULUM,
CardType.TYPE_SPIRIT,
CardType.TYPE_UNION,
CardType.TYPE_DUAL,
CardType.TYPE_FLIP,
CardType.TYPE_TOON,
CardType.TYPE_SPSUMMON,
}; };
public static readonly CardType[] TYPE4 ={ public static readonly CardType[] TYPE4 ={
CardType.TYPE_TUNER, CardType.TYPE_TUNER,
CardType.TYPE_EFFECT, CardType.TYPE_EFFECT,
// CardType.TYPE_NORMAL, // CardType.TYPE_NORMAL,
}; };
public static CardType[] GetMonsterTypes(long type){
public static readonly CardType[] TYPE4_10 ={
CardType.TYPE_TUNER,
CardType.TYPE_EFFECT,
CardType.TYPE_NORMAL,
};
public static CardType[] GetMonsterTypes(long type,bool no10=false){
var list = new List<CardType>(5); var list = new List<CardType>(5);
var typeList=new List<CardType[]>(5); var typeList=new List<CardType[]>(5);
typeList.Add(TYPE1); if(no10){
typeList.Add(TYPE2); typeList.Add(TYPE1_10);
typeList.Add(TYPE3); typeList.Add(TYPE2_10);
typeList.Add(TYPE4); typeList.Add(TYPE3_10);
typeList.Add(TYPE4); typeList.Add(TYPE4_10);
typeList.Add(TYPE4_10);
}else{
typeList.Add(TYPE1);
typeList.Add(TYPE2);
typeList.Add(TYPE3);
typeList.Add(TYPE4);
typeList.Add(TYPE4);
}
int count = typeList.Count; int count = typeList.Count;
for(int i=0;i<count;i++){ for(int i=0;i<count;i++){
CardType[] types = typeList[i]; CardType[] types = typeList[i];
......
...@@ -49,6 +49,10 @@ public class MSEConfig ...@@ -49,6 +49,10 @@ public class MSEConfig
public const string TAG_IMAGE = "imagepath"; public const string TAG_IMAGE = "imagepath";
public const string TAG_REPALCE = "replace"; public const string TAG_REPALCE = "replace";
public const string TAG_TEXT = "text"; public const string TAG_TEXT = "text";
public const string TAG_NO_TEN = "no10";
public const string TAG_NO_START_CARDS="no_star_cards";
public const string TAG_REP = "%%"; public const string TAG_REP = "%%";
public const string SEP_LINE = " "; public const string SEP_LINE = " ";
...@@ -109,6 +113,19 @@ public void SetConfig(string config, string path) ...@@ -109,6 +113,19 @@ public void SetConfig(string config, string path)
else if (line.StartsWith(TAG_PEND_HEIGHT)){ else if (line.StartsWith(TAG_PEND_HEIGHT)){
pheight=ConfHelper.getIntegerValue(line,0); pheight=ConfHelper.getIntegerValue(line,0);
} }
else if(line.StartsWith(TAG_NO_TEN)){
no10 = ConfHelper.getBooleanValue(line);
}else if(line.StartsWith(TAG_NO_START_CARDS)){
string val = ConfHelper.getValue(line);
string[] cs = val.Split(',');
noStartCards=new long[cs.Length];
int i=0;
foreach(string str in cs){
long l = 0;
long.TryParse(str, out l);
noStartCards[i++] = l;
}
}
else if (line.StartsWith(TAG_IMAGE)) else if (line.StartsWith(TAG_IMAGE))
{ {
//如果路径不合法,则为后面的路径 //如果路径不合法,则为后面的路径
...@@ -169,6 +186,10 @@ public void init(string path) ...@@ -169,6 +186,10 @@ public void init(string path)
public int pwidth; public int pwidth;
public int pheight; public int pheight;
//没星星的卡
public long[] noStartCards;
//第10期
public bool no10;
//每个存档最大数 //每个存档最大数
public int maxcount; public int maxcount;
//图片路径 //图片路径
......
...@@ -285,7 +285,7 @@ public string[] GetTypes(Card c) ...@@ -285,7 +285,7 @@ public string[] GetTypes(Card c)
} }
if (c.IsType(CardType.TYPE_MONSTER)) if (c.IsType(CardType.TYPE_MONSTER))
{ {
CardType[] cardTypes = CardTypes.GetMonsterTypes(c.type); CardType[] cardTypes = CardTypes.GetMonsterTypes(c.type, cfg.no10);
int count = cardTypes.Length; int count = cardTypes.Length;
for(int i=0; i<count && i<MAX_TYPE; i++){ for(int i=0; i<count && i<MAX_TYPE; i++){
types[i+1] = GetType(cardTypes[i]); types[i+1] = GetType(cardTypes[i]);
...@@ -392,7 +392,18 @@ string getMonster(Card c, string img,CardPack cardpack=null,bool rarity=true) ...@@ -392,7 +392,18 @@ string getMonster(Card c, string img,CardPack cardpack=null,bool rarity=true)
sb.AppendLine(GetLine(TAG_CARDTYPE, types[0])); sb.AppendLine(GetLine(TAG_CARDTYPE, types[0]));
sb.AppendLine(GetLine(TAG_NAME, reItalic(c.name))); sb.AppendLine(GetLine(TAG_NAME, reItalic(c.name)));
sb.AppendLine(GetLine(TAG_ATTRIBUTE, GetAttribute(c.attribute))); sb.AppendLine(GetLine(TAG_ATTRIBUTE, GetAttribute(c.attribute)));
sb.AppendLine(GetLine(TAG_LEVEL, GetStar(c.level))); bool noStar = false;
if(cfg.noStartCards != null){
foreach(long id in cfg.noStartCards){
if(c.alias == id || c.id == id){
noStar = true;
break;
}
}
}
if(!noStar){
sb.AppendLine(GetLine(TAG_LEVEL, GetStar(c.level)));
}
sb.AppendLine(GetLine(TAG_IMAGE, img)); sb.AppendLine(GetLine(TAG_IMAGE, img));
sb.AppendLine(GetLine(TAG_TYPE1, cn2tw(race))); sb.AppendLine(GetLine(TAG_TYPE1, cn2tw(race)));
sb.AppendLine(GetLine(TAG_TYPE2, cn2tw(types[1]))); sb.AppendLine(GetLine(TAG_TYPE2, cn2tw(types[1])));
......
...@@ -28,4 +28,4 @@ ...@@ -28,4 +28,4 @@
// //
// You can specify all the values or you can use the default the Revision and // You can specify all the values or you can use the default the Revision and
// Build Numbers by using the '*' as shown below: // Build Numbers by using the '*' as shown below:
[assembly: AssemblyVersion("2.4.3.1")] [assembly: AssemblyVersion("2.4.3.2")]
★更新历史 ★更新历史
2.4.3.2
卡片种族/分类算法,如果有问题记得反馈
MSE导出,支持不显示星星的卡
2.4.3.1 2.4.3.1
pack.db更新 pack.db更新
2.4.3.0 2.4.3.0
......
...@@ -36,7 +36,9 @@ monster-text = [果|介|述|報]】\n([\S\s]*) ...@@ -36,7 +36,9 @@ monster-text = [果|介|述|報]】\n([\S\s]*)
replace = ([鮟|鱇]) <i>$1</i> replace = ([鮟|鱇]) <i>$1</i>
#replace = [:space:] <sym-auto>^</sym-auto> #replace = [:space:] <sym-auto>^</sym-auto>
#replace = ([A-Z]) <i>$1</i> #replace = ([A-Z]) <i>$1</i>
########################### ########################### no.10's card
no10 = true
no_star_cards = 1686814,52653092,65305468
##race ##race
race 0x1 战士族 race 0x1 战士族
race 0x2 魔法师族 race 0x2 魔法师族
......
...@@ -36,7 +36,9 @@ monster-text = [果|介|述|報]】\n([\S\s]*) ...@@ -36,7 +36,9 @@ monster-text = [果|介|述|報]】\n([\S\s]*)
replace = ([鮟|鱇|・|·]) <i>$1</i> replace = ([鮟|鱇|・|·]) <i>$1</i>
#replace = \s <sym-auto>^</sym-auto> #replace = \s <sym-auto>^</sym-auto>
#replace = ([A-Z]) <i>$1</i> #replace = ([A-Z]) <i>$1</i>
########################### ########################### no.10's card
no10 = false
no_star_cards = 1686814,52653092,65305468
##race ##race
race 0x1 戰士族 race 0x1 戰士族
race 0x2 魔法師族 race 0x2 魔法師族
......
...@@ -27,7 +27,9 @@ monster-text = (?:Monster Effect|Flavor Text) \]\s*\n([\S\s]*) ...@@ -27,7 +27,9 @@ monster-text = (?:Monster Effect|Flavor Text) \]\s*\n([\S\s]*)
########################### Replace ########################### Replace
#replace = \s <sym-auto>^</sym-auto> #replace = \s <sym-auto>^</sym-auto>
#replace = ([A-Z]) <i>$1</i> #replace = ([A-Z]) <i>$1</i>
########################### ########################### no.10's card
no10 = false
no_star_cards = 1686814,52653092,65305468
##race ##race
race 0x1 Warrior race 0x1 Warrior
race 0x2 Spellcaster race 0x2 Spellcaster
......
...@@ -36,7 +36,9 @@ replace = ([·]) ・ ...@@ -36,7 +36,9 @@ replace = ([·]) ・
#replace = ([鮟|鱇|・|·]) <i>$1</i> #replace = ([鮟|鱇|・|·]) <i>$1</i>
#replace = \s <sym-auto>^</sym-auto> #replace = \s <sym-auto>^</sym-auto>
#replace = ([A-Z]) <i>$1</i> #replace = ([A-Z]) <i>$1</i>
########################### ########################### no.10's card
no10 = false
no_star_cards = 1686814,52653092,65305468
##race ##race
race 0x1 戦士族 race 0x1 戦士族
race 0x2 魔法使い族 race 0x2 魔法使い族
......
[DataEditorX]2.4.3.1[DataEditorX] [DataEditorX]2.4.3.2[DataEditorX]
[URL]https://github.com/247321453/DataEditorX/raw/master/win32/win32.zip[URL] [URL]https://github.com/247321453/DataEditorX/raw/master/win32/win32.zip[URL]
★运行环境(Environment) ★运行环境(Environment)
......
★更新历史 ★更新历史
2.4.3.2
卡片种族/分类算法,如果有问题记得反馈
MSE导出,支持不显示星星的卡
2.4.3.1 2.4.3.1
pack.db更新 pack.db更新
2.4.3.0 2.4.3.0
......
[DataEditorX]2.4.3.1[DataEditorX] [DataEditorX]2.4.3.2[DataEditorX]
[URL]https://github.com/247321453/DataEditorX/raw/master/win32/win32.zip[URL] [URL]https://github.com/247321453/DataEditorX/raw/master/win32/win32.zip[URL]
★运行环境(Environment) ★运行环境(Environment)
......
No preview for this file type
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment