Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
M
MDPro2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xiaoye
MDPro2
Commits
57449c95
Commit
57449c95
authored
Jul 18, 2023
by
赤子奈落
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refresh super button state and fix forced effects response error
parent
9b6126ec
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
90 additions
and
161 deletions
+90
-161
Assets/MD/Scripts/CardSelectionHandler.cs
Assets/MD/Scripts/CardSelectionHandler.cs
+6
-40
Assets/MD/Scripts/Shortcuts.cs
Assets/MD/Scripts/Shortcuts.cs
+5
-5
Assets/MD/main.unity
Assets/MD/main.unity
+63
-63
Assets/SibylSystem/Ocgcore/OCGobjects/gameCard.cs
Assets/SibylSystem/Ocgcore/OCGobjects/gameCard.cs
+1
-48
Assets/SibylSystem/Ocgcore/Ocgcore.cs
Assets/SibylSystem/Ocgcore/Ocgcore.cs
+15
-5
No files found.
Assets/MD/Scripts/CardSelectionHandler.cs
View file @
57449c95
...
...
@@ -352,41 +352,6 @@ public class CardSelectionHandler : MonoBehaviour
bool
sendable
=
false
;
switch
(
core
.
currentMessage
)
{
//case GameMessage.SelectSum:
// if (selected == ES_max)
// sendable = true;
// var selectedLevel = 0;
// for (var x = 0; x < core.cardsMustBeSelected.Count; x++)
// selectedLevel += core.cardsMustBeSelected[x].levelForSelect_1;
// for (var x = 0; x < core.cardsSelected.Count; x++)
// selectedLevel += core.cardsSelected[x].levelForSelect_1;
// if (core.ES_overFlow)
// {
// if (selectedLevel >= core.ES_level)
// sendable = true;
// }
// else
// {
// if (selectedLevel == core.ES_level) sendable = true;
// }
// selectedLevel = 0;
// for (var x = 0; x < core.cardsMustBeSelected.Count; x++)
// selectedLevel += core.cardsMustBeSelected[x].levelForSelect_2;
// for (var x = 0; x < core.cardsSelected.Count; x++) selectedLevel += core.cardsSelected[x].levelForSelect_2;
// if (core.ES_overFlow)
// {
// if (selectedLevel >= core.ES_level)
// sendable = true;
// }
// else
// {
// if (selectedLevel == core.ES_level)
// sendable = true;
// }
// if (core.cardsSelectable.Count == 0)
// sendable = true;
// break;
case
GameMessage
.
SelectCard
:
if
(
selected
>=
ES_min
)
sendable
=
true
;
...
...
@@ -411,6 +376,12 @@ public class CardSelectionHandler : MonoBehaviour
else
sendable
=
false
;
break
;
case
GameMessage
.
SelectChain
:
if
(
selected
>=
1
)
sendable
=
true
;
else
sendable
=
false
;
break
;
}
if
(
exitable
)
...
...
@@ -430,11 +401,6 @@ public class CardSelectionHandler : MonoBehaviour
button_confirm_label
.
color
=
new
Color
(
0.2f
,
0.25f
,
0f
,
1f
);
}
//Debug.LogFormat("{3}, selected: {0}, ES_min: {1}, ES_max: {2}", selected, ES_min, ES_max, core.currentMessage);
if
(
core
.
currentMessage
!=
GameMessage
.
SortCard
)
{
if
(
selected
>=
ES_max
)
...
...
Assets/MD/Scripts/Shortcuts.cs
View file @
57449c95
...
...
@@ -190,10 +190,10 @@ public class Shortcuts : MonoBehaviour
}
Time
.
timeScale
=
timescale
;
//
if (message != Program.I().ocgcore.currentMessage)
//
{
//
message = Program.I().ocgcore.currentMessage;
//
Debug.Log(message);
//
}
if
(
message
!=
Program
.
I
().
ocgcore
.
currentMessage
)
{
message
=
Program
.
I
().
ocgcore
.
currentMessage
;
Debug
.
Log
(
message
);
}
}
}
Assets/MD/main.unity
View file @
57449c95
This diff is collapsed.
Click to expand it.
Assets/SibylSystem/Ocgcore/OCGobjects/gameCard.cs
View file @
57449c95
...
...
@@ -714,7 +714,7 @@ public class gameCard : OCGobject
Program
.
I
().
new_ui_cardList
.
hide
();
}
p
rivate
void
ES_exit_clicked
()
p
ublic
void
ES_exit_clicked
()
{
clicked
=
false
;
if
(
highlightOn
)
...
...
@@ -777,53 +777,6 @@ public class gameCard : OCGobject
else
buttons
[
i
].
show
(
vector_of_begin
+
new
Vector3
(
SortLine
(
i
,
buttons
.
Count
,
180
*
Screen
.
height
/
1080f
),
150f
*
Screen
.
height
/
1080f
,
0f
));
}
//if (opMonsterWithBackGroundCard)
//{
// var vector_of_begin = Vector3.zero;
// if ((p.position & (uint)CardPosition.Attack) > 0)
// vector_of_begin = gameObject_face.transform.position + new Vector3(0, 0, -2f);
// else
// vector_of_begin = gameObject_face.transform.position + new Vector3(0, 0, -1.5f);
// vector_of_begin = Program.I().main_camera.WorldToScreenPoint(vector_of_begin);
// for (var i = 0; i < buttons.Count; i++)
// buttons[i].show(vector_of_begin - i * new Vector3(0, 65f * 0.7f * Screen.height / 1080f) - new Vector3(0, 20f * 0.7f * Screen.height / 1080f));
// return;
//}
//if (condition == gameCardCondition.floating_clickable)
//{
// var vector_of_begin = gameObject_face.transform.position + new Vector3(0, 1, 1.732f);
// vector_of_begin = Program.I().main_camera.WorldToScreenPoint(vector_of_begin);
// for (var i = 0; i < buttons.Count; i++)
// buttons[i].show(vector_of_begin + i * new Vector3(0, 65f * 0.7f * Screen.height / 1080f) + new Vector3(0, 35f * 0.7f * Screen.height / 1080f));
// return;
//}
//if (condition == gameCardCondition.verticle_clickable)
//{
// if (VerticleCollider == null)
// {
// Vector3 vector_of_begin;
// if ((p.position & (uint)CardPosition.Attack) > 0)
// vector_of_begin = gameObject_face.transform.position + new Vector3(0, 0, 2);
// else
// vector_of_begin = gameObject_face.transform.position + new Vector3(0, 0, 1.5f);
// vector_of_begin = Program.I().main_camera.WorldToScreenPoint(vector_of_begin);
// for (var i = 0; i < buttons.Count; i++)
// buttons[i].show(vector_of_begin + i * new Vector3(0, 65f * 0.7f * Screen.height / 1080f) + new Vector3(0, 35f * 0.7f * Screen.height / 1080f));
// }
// else
// {
// var h = loaded_verticalDrawingK * 0.618f;
// var vector_of_begin = Vector3.zero;
// var l = 0.5f * game_object_verticle_drawing.transform.localScale.y * (h - 0.5f);
// vector_of_begin = game_object_verticle_drawing.transform.position + new Vector3(0, l, l * 1.732f);
// vector_of_begin = Program.I().main_camera.WorldToScreenPoint(vector_of_begin);
// for (var i = 0; i < buttons.Count; i++)
// buttons[i].show(vector_of_begin + i * new Vector3(0, 65f * 0.7f * Screen.height / 1080f) + new Vector3(0, 35f * 0.7f * Screen.height / 1080f));
// }
//}
}
private
void
ES_excited_handler_event_cookie_card_bed
()
...
...
Assets/SibylSystem/Ocgcore/Ocgcore.cs
View file @
57449c95
...
...
@@ -2820,6 +2820,7 @@ public class Ocgcore : ServantWithCardDescription
{
card
.
set_code
(
code
);
card
.
prefered
=
true
;
card
.
ES_exit_clicked
();
var
eff
=
new
Effect
();
eff
.
ptr
=
(
i
<<
16
)
+
0
;
eff
.
desc
=
desc
;
...
...
@@ -2904,6 +2905,7 @@ public class Ocgcore : ServantWithCardDescription
if
(
card
!=
null
)
{
card
.
set_code
(
code
);
card
.
ES_exit_clicked
();
btn
=
new
gameButton
((
i
<<
16
)
+
0
,
InterString
.
Get
(
"通常召唤@ui"
),
superButtonType
.
summon
);
card
.
add_one_button
(
btn
);
card
.
Highlight
(
true
,
false
,
false
);
...
...
@@ -3497,17 +3499,19 @@ public class Ocgcore : ServantWithCardDescription
if
(
handle_flag
==
3
)
{
//处理强制发动的卡
cardsWaitToSend
.
Clear
();
for
(
var
i
=
0
;
i
<
chainCards
.
Count
;
i
++)
{
if
((
chainCards
[
i
].
p
.
location
&
(
uint
)
CardLocation
.
Onfield
)
>
0
)
chainCards
[
i
].
add_one_decoration
(
Program
.
I
().
mod_ocgcore_decoration_chain_selecting
,
4
,
Vector3
.
zero
,
"chain_selecting"
);
chainCards
[
i
].
forSelect
=
true
;
chainCards
[
i
].
currentFlash
=
gameCard
.
flashType
.
Active
;
cardsWaitToSend
.
Add
(
chainCards
[
i
]);
}
//RMSshow_yesOrNo("autoForceChainHandler", InterString.Get("[?],@n自动处理强制发动的卡?", ES_hint),
// new messageSystemValue {value = "yes", hint = "yes"}
,
// new messageSystemValue {value = "no", hint = "no"});
Program
.
I
().
cardSelection
.
show
(
chainCards
,
true
,
1
,
1
,
InterString
.
Get
(
"[?],@n请选择需要发动的强制效果。"
,
ES_hint
)
);
RMSshow_yesOrNo
(
"autoForceChainHandler"
,
InterString
.
Get
(
"[?],@n自动处理强制发动的卡?"
,
ES_hint
)
,
new
messageSystemValue
{
value
=
"yes"
,
hint
=
"yes"
},
new
messageSystemValue
{
value
=
"no"
,
hint
=
"no"
}
);
if
(
condition
==
Condition
.
record
)
Sleep
(
60
);
}
...
...
@@ -8384,6 +8388,8 @@ public class Ocgcore : ServantWithCardDescription
}
}
public
List
<
gameCard
>
cardsWaitToSend
=
new
List
<
gameCard
>();
public
override
void
ES_RMS
(
string
hashCode
,
List
<
messageSystemValue
>
result
)
{
base
.
ES_RMS
(
hashCode
,
result
);
...
...
@@ -8422,7 +8428,11 @@ public class Ocgcore : ServantWithCardDescription
}
}
if
(
result
[
0
].
value
==
"no"
)
autoForceChainHandler
=
autoForceChainHandlerType
.
afterClickManDo
;
if
(
result
[
0
].
value
==
"no"
)
{
autoForceChainHandler
=
autoForceChainHandlerType
.
afterClickManDo
;
Program
.
I
().
cardSelection
.
show
(
cardsWaitToSend
,
false
,
1
,
1
,
InterString
.
Get
(
"[?],@n请选择需要发动或处理的强制效果,或者选择快速效果发动。"
,
ES_hint
));
}
}
break
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment