Commit d3490d93 authored by nanahira's avatar nanahira

fix query

parent db9e674d
...@@ -715,17 +715,6 @@ public static class BinaryExtensions ...@@ -715,17 +715,6 @@ public static class BinaryExtensions
{ {
l2 = r.ReadInt32(); l2 = r.ReadInt32();
} }
if (((flag & (int)Query.Level) != 0) || ((flag & (int)Query.Rank) != 0))
{
if (l1 > l2)
{
data.Level = l1;
}
else
{
data.Level = l2;
}
}
if ((flag & (int)Query.Attribute) != 0) if ((flag & (int)Query.Attribute) != 0)
data.Attribute = r.ReadInt32(); data.Attribute = r.ReadInt32();
...@@ -741,8 +730,8 @@ public static class BinaryExtensions ...@@ -741,8 +730,8 @@ public static class BinaryExtensions
r.ReadInt32(); r.ReadInt32();
if ((flag & (int)Query.Reason) != 0) if ((flag & (int)Query.Reason) != 0)
r.ReadInt32(); r.ReadInt32();
//if ((flag & (int)Query.ReasonCard) != 0) if ((flag & (int)Query.ReasonCard) != 0)
// r.ReadInt32(); r.ReadInt32();
if ((flag & (int)Query.EquipCard) != 0) if ((flag & (int)Query.EquipCard) != 0)
{ {
cardToRefresh.addTarget(Program.I().ocgcore.GCS_cardGet(r.ReadGPS(), false)); cardToRefresh.addTarget(Program.I().ocgcore.GCS_cardGet(r.ReadGPS(), false));
...@@ -788,6 +777,26 @@ public static class BinaryExtensions ...@@ -788,6 +777,26 @@ public static class BinaryExtensions
data.LScale = r.ReadInt32(); data.LScale = r.ReadInt32();
if ((flag & (int)Query.RScale) != 0) if ((flag & (int)Query.RScale) != 0)
data.RScale = r.ReadInt32(); data.RScale = r.ReadInt32();
int l3 = 0;
if ((flag & (int)Query.Link) != 0)
{
l3 = r.ReadInt32(); //link value
data.rDefense = r.ReadInt32(); //link marker
}
if (((flag & (int)Query.Level) != 0) || ((flag & (int)Query.Rank) != 0) || ((flag & (int)Query.Link) != 0))
{
if (l1 > l2)
{
data.Level = l1;
}
else
{
data.Level = l2;
}
if(l3 > data.Level)
data.Level = l3;
}
cardToRefresh.set_data(data); cardToRefresh.set_data(data);
// //
} }
...@@ -891,4 +900,4 @@ public class TcpClientWithTimeout ...@@ -891,4 +900,4 @@ public class TcpClientWithTimeout
exception = ex; exception = ex;
} }
} }
} }
\ No newline at end of file
...@@ -23,6 +23,7 @@ ...@@ -23,6 +23,7 @@
Owner = 0x40000, Owner = 0x40000,
Status = 0x80000, Status = 0x80000,
LScale = 0x200000, LScale = 0x200000,
RScale = 0x400000 RScale = 0x400000,
Link = 0x800000
} }
} }
\ No newline at end of file
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