Commit 2f07a747 authored by SherryChaos's avatar SherryChaos

fix bugs

parent d93da2fc
...@@ -874,23 +874,23 @@ namespace MDPro3 ...@@ -874,23 +874,23 @@ namespace MDPro3
AddStringTail(InterString.Get("帤淏寞腎部")); AddStringTail(InterString.Get("帤淏寞腎部"));
else else
RemoveStringTail(InterString.Get("帤淏寞腎部")); RemoveStringTail(InterString.Get("帤淏寞腎部"));
if ((data.Type & (uint)CardType.Xyz) > 0 && (gps.location & (uint)CardLocation.MonsterZone) > 0)
overlays = Program.I().ocgcore.GCS_GetOverlays(this); overlays = Program.I().ocgcore.GCS_GetOverlays(this);
else
overlays = new List<GameCard>();
cacheP = p; cacheP = p;
p = gps; p = gps;
//Debug.LogFormat("reason: {0:X}", p.reason);
//Debug.LogFormat("{0}: reason: {1:X} location: {2:X}", data.Name, p.reason, p.location);
foreach (var overlay in overlays) for (int i = 0; i < overlays.Count; i++)
{ {
overlay.overlayParent = this; overlays[i].overlayParent = this;
overlay.p.controller = gps.controller; overlays[i].p.controller = gps.controller;
overlay.p.location = gps.location | (uint)CardLocation.Overlay; overlays[i].p.location = gps.location | (uint)CardLocation.Overlay;
overlay.p.sequence = gps.sequence; overlays[i].p.sequence = gps.sequence;
overlay.p.position = (int)CardPosition.FaceUpAttack; overlays[i].p.position = i;
} }
Program.I().ocgcore.ArrangeCards();
if (Program.I().ocgcore.currentMessage == GameMessage.Move if (Program.I().ocgcore.currentMessage == GameMessage.Move
&& cacheP.location != p.location && cacheP.location != p.location
......
...@@ -1903,13 +1903,15 @@ namespace MDPro3 ...@@ -1903,13 +1903,15 @@ namespace MDPro3
uint reason = r.ReadUInt32(); uint reason = r.ReadUInt32();
card = GCS_Get(from); card = GCS_Get(from);
if (card == null) if (card != null)
card = GCS_Create(from); {
card.CacheData(); card.CacheData();
card.SetCode(code); card.SetCode(code);
to.reason = reason; to.reason = reason;
Sleep((int)(card.Move(to) * 100)); Sleep((int)(card.Move(to) * 100));
ArrangeCards(); }
else
Debug.LogFormat("GCS_Get: not found, location: {0:X}, sequence: {1:X}, position: {2:X}", from.location, from.sequence, from.position);
break; break;
case GameMessage.PosChange: case GameMessage.PosChange:
ES_hint = StringHelper.GetUnsafe(1600);//卡片改变了表示形式 ES_hint = StringHelper.GetUnsafe(1600);//卡片改变了表示形式
...@@ -2199,8 +2201,6 @@ namespace MDPro3 ...@@ -2199,8 +2201,6 @@ namespace MDPro3
cardsInChain.Add(card); cardsInChain.Add(card);
Sleep(100); Sleep(100);
ES_hint = InterString.Get("「[?]」被发动时", card.GetData().Name); ES_hint = InterString.Get("「[?]」被发动时", card.GetData().Name);
if (GetAutoInfo())
description.Show(card, null);
} }
if (gps.controller == 0) if (gps.controller == 0)
{ {
...@@ -2212,6 +2212,8 @@ namespace MDPro3 ...@@ -2212,6 +2212,8 @@ namespace MDPro3
if (!opActivated.Contains(code)) if (!opActivated.Contains(code))
opActivated.Add(code); opActivated.Add(code);
} }
if (card != null && GetAutoInfo())
description.Show(card, null);
break; break;
case GameMessage.Chained: case GameMessage.Chained:
var currentChainCard = cardsInChain[cardsInChain.Count - 1]; var currentChainCard = cardsInChain[cardsInChain.Count - 1];
......
...@@ -66,6 +66,8 @@ namespace MDPro3 ...@@ -66,6 +66,8 @@ namespace MDPro3
Clear(); Clear();
btnDelete.SwitchOffWithoutAction(); btnDelete.SwitchOffWithoutAction();
btnPickup.OnSwitchOff(); btnPickup.OnSwitchOff();
if (!Directory.Exists("Deck"))
Directory.CreateDirectory("Deck");
var files = Directory.GetFiles("Deck", "*.ydk"); var files = Directory.GetFiles("Deck", "*.ydk");
List<string> fileList = files.ToList(); List<string> fileList = files.ToList();
foreach (var file in files) foreach (var file in files)
......
...@@ -134,7 +134,7 @@ PlayerSettings: ...@@ -134,7 +134,7 @@ PlayerSettings:
16:10: 1 16:10: 1
16:9: 1 16:9: 1
Others: 1 Others: 1
bundleVersion: 0.5.1 bundleVersion: 0.5.2
preloadedAssets: [] preloadedAssets: []
metroInputSource: 0 metroInputSource: 0
wsaTransparentSwapchain: 0 wsaTransparentSwapchain: 0
...@@ -529,7 +529,7 @@ PlayerSettings: ...@@ -529,7 +529,7 @@ PlayerSettings:
m_APIs: 0b000000 m_APIs: 0b000000
m_Automatic: 1 m_Automatic: 1
- m_BuildTarget: WindowsStandaloneSupport - m_BuildTarget: WindowsStandaloneSupport
m_APIs: 0b000000020000001200000015000000 m_APIs: 0200000012000000150000000b000000
m_Automatic: 0 m_Automatic: 0
m_BuildTargetVRSettings: m_BuildTargetVRSettings:
- m_BuildTarget: Standalone - m_BuildTarget: Standalone
......
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