Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
M
MDPro3
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
Dark_Zane
MDPro3
Commits
3dc972d7
Commit
3dc972d7
authored
Aug 13, 2024
by
SherryChaos
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
new bgm logic
parent
ae4e04cf
Changes
8
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
829 additions
and
196 deletions
+829
-196
Assets/Addressables/Text/UpdateContent.txt
Assets/Addressables/Text/UpdateContent.txt
+1
-1
Assets/Main.unity
Assets/Main.unity
+573
-17
Assets/Scripts/MDPro3/Managers/AudioManager.cs
Assets/Scripts/MDPro3/Managers/AudioManager.cs
+207
-170
Assets/Scripts/MDPro3/Servants/MonsterCutin.cs
Assets/Scripts/MDPro3/Servants/MonsterCutin.cs
+10
-2
Assets/Scripts/MDPro3/Servants/OcgCore.cs
Assets/Scripts/MDPro3/Servants/OcgCore.cs
+4
-4
Assets/Scripts/MDPro3/Servants/Setting.cs
Assets/Scripts/MDPro3/Servants/Setting.cs
+29
-0
Assets/Scripts/MDPro3/UI/New UI/UIEventWithAudio.cs
Assets/Scripts/MDPro3/UI/New UI/UIEventWithAudio.cs
+2
-2
Data/locales/zh-CN/translation.conf
Data/locales/zh-CN/translation.conf
+3
-0
No files found.
Assets/Addressables/Text/UpdateContent.txt
View file @
3dc972d7
...
...
@@ -3,7 +3,7 @@
MDPro3 v1.1.8.3更新:
1.语音功能支持所有支持的语言。
2.修复语音功能部分角色的台词错误。
3.
3.
设置中新增场地背景音乐由哪方决定的选项。
MDPro3 v1.1.8.2更新:
1.语音功能新增全卡语音。
...
...
Assets/Main.unity
View file @
3dc972d7
This diff is collapsed.
Click to expand it.
Assets/Scripts/MDPro3/Managers/AudioManager.cs
View file @
3dc972d7
This diff is collapsed.
Click to expand it.
Assets/Scripts/MDPro3/Servants/MonsterCutin.cs
View file @
3dc972d7
...
...
@@ -14,6 +14,7 @@ using YgomSystem.YGomTMPro;
using
MDPro3.YGOSharp
;
using
MDPro3.YGOSharp.OCGWrapper.Enums
;
using
MDPro3.UI
;
using
static
UnityEngine
.
Rendering
.
DebugUI
;
namespace
MDPro3
{
...
...
@@ -135,6 +136,9 @@ namespace MDPro3
{
StopCoroutine
(
autoPlay
);
autoPlay
=
null
;
foreach
(
var
cutin
in
cutins
)
Destroy
(
cutin
);
cutins
.
Clear
();
UIManager
.
ShowExitButton
(
transitionTime
);
cg
.
alpha
=
1
;
cg
.
blocksRaycasts
=
true
;
...
...
@@ -174,7 +178,7 @@ namespace MDPro3
return
;
playing
=
true
;
if
(
Program
.
I
().
ocgcore
.
isShowed
)
AudioManager
.
PlayB
GMKeyCard
(
Program
.
I
().
ocgcore
.
field1Manager
.
name
);
AudioManager
.
PlayB
gmKeyCard
(
);
DOTween
.
To
(
v
=>
{
},
0
,
0
,
1.6f
).
OnComplete
(()
=>
{
playing
=
false
;
...
...
@@ -340,10 +344,14 @@ namespace MDPro3
StartCoroutine
(
autoPlay
);
}
bool
randomBGMPlayed
;
List
<
GameObject
>
cutins
=
new
List
<
GameObject
>();
IEnumerator
AutoPlayAsync
()
{
while
(
playing
)
yield
return
null
;
if
(!
isShowed
)
yield
break
;
AudioManager
.
PlayRandomKeyCardBGM
();
randomBGMPlayed
=
true
;
cg
.
alpha
=
0f
;
...
...
@@ -361,10 +369,10 @@ namespace MDPro3
ie
=
ABLoader
.
LoadFromFileAsync
(
"MonsterCutin2/"
+
card
.
Id
,
false
,
true
);
diy
=
true
;
}
StartCoroutine
(
ie
);
while
(
ie
.
MoveNext
())
yield
return
null
;
ie
.
Current
.
SetActive
(
false
);
cutins
.
Add
(
ie
.
Current
);
while
(
playing
)
yield
return
null
;
ie
.
Current
.
SetActive
(
true
);
...
...
Assets/Scripts/MDPro3/Servants/OcgCore.cs
View file @
3dc972d7
...
...
@@ -3439,7 +3439,7 @@ namespace MDPro3
cg
.
blocksRaycasts
=
true
;
buttons
.
SetActive
(
true
);
messagePass
=
true
;
AudioManager
.
PlayB
GMNormal
(
field1
.
name
);
AudioManager
.
PlayB
gmNormal
(
Config
.
GetBool
(
"BGMbyMySide"
,
true
)
?
field0
.
name
:
field1
.
name
);
};
};
});
...
...
@@ -3592,7 +3592,7 @@ namespace MDPro3
cg
.
interactable
=
true
;
cg
.
blocksRaycasts
=
true
;
buttons
.
SetActive
(
true
);
AudioManager
.
PlayB
GMNormal
(
field1
.
name
);
AudioManager
.
PlayB
gmNormal
(
Config
.
GetBool
(
"BGMbyMySide"
,
true
)
?
field0
.
name
:
field1
.
name
);
};
for
(
var
i
=
0
;
i
<
cards
.
Count
;
i
++)
...
...
@@ -8768,7 +8768,7 @@ namespace MDPro3
grave0Manager
.
PlayAnimatorTrigger
(
TriggerLabelDefine
.
DamagePhase3ToPhase4
);
if
(
stand0Manager
!=
null
)
stand0Manager
.
PlayAnimatorTrigger
(
TriggerLabelDefine
.
DamagePhase3ToPhase4
);
AudioManager
.
PlayB
GMClimax
(
field1
.
name
);
AudioManager
.
PlayB
gmClimax
(
);
}
if
(
bgPhase0
==
4
&&
life0
<=
0
)
{
...
...
@@ -8812,7 +8812,7 @@ namespace MDPro3
grave1Manager
.
PlayAnimatorTrigger
(
TriggerLabelDefine
.
DamagePhase3ToPhase4
);
if
(
stand1Manager
!=
null
)
stand1Manager
.
PlayAnimatorTrigger
(
TriggerLabelDefine
.
DamagePhase3ToPhase4
);
AudioManager
.
PlayB
GMClimax
(
field1
.
name
);
AudioManager
.
PlayB
gmClimax
(
);
}
if
(
bgPhase1
==
4
&&
life1
<=
0
)
{
...
...
Assets/Scripts/MDPro3/Servants/Setting.cs
View file @
3dc972d7
...
...
@@ -50,6 +50,8 @@ namespace MDPro3
public
Text
uiScaleValue
;
public
Button
background
;
public
Text
backgroundValue
;
public
Button
bgmBy
;
public
Text
bgmByValue
;
public
Button
cardLanguage
;
public
Text
cardLanguageValue
;
public
Button
language
;
...
...
@@ -212,6 +214,7 @@ namespace MDPro3
language
.
onClick
.
AddListener
(
OnLanguageChange
);
confirm
.
onClick
.
AddListener
(
OnConfirmClicked
);
autoRPS
.
onClick
.
AddListener
(
OnAutoRPS
);
bgmBy
.
onClick
.
AddListener
(
OnBgmByClicked
);
duelAppearance
.
onClick
.
AddListener
(
OnDuelAppearcanceClick
);
watchAppearance
.
onClick
.
AddListener
(
OnWatchAppearcanceClick
);
...
...
@@ -323,6 +326,7 @@ namespace MDPro3
InitializeCardLanguage
();
InitializeLanguage
();
InitializeSwitches
();
InitializeBgmBy
();
}
public
override
void
Show
(
int
preDepth
)
...
...
@@ -902,6 +906,31 @@ namespace MDPro3
}
}
public
void
InitializeBgmBy
()
{
var
value
=
Config
.
GetBool
(
"BGMbyMySide"
,
true
);
if
(
value
)
bgmByValue
.
text
=
InterString
.
Get
(
"我方"
);
else
bgmByValue
.
text
=
InterString
.
Get
(
"对方"
);
}
public
void
OnBgmByClicked
()
{
var
value
=
Config
.
GetBool
(
"BGMbyMySide"
,
true
);
if
(
value
)
{
bgmByValue
.
text
=
InterString
.
Get
(
"对方"
);
Config
.
SetBool
(
"BGMbyMySide"
,
false
);
}
else
{
bgmByValue
.
text
=
InterString
.
Get
(
"我方"
);
Config
.
SetBool
(
"BGMbyMySide"
,
true
);
}
}
public
void
OnAutoRPS
()
{
if
(
autoRPSValue
.
text
==
InterString
.
Get
(
"关"
))
...
...
Assets/Scripts/MDPro3/UI/New UI/UIEventWithAudio.cs
View file @
3dc972d7
...
...
@@ -36,12 +36,12 @@ namespace MDPro3.UI
private
void
PlayAudio
(
string
path
)
{
if
(
path
==
""
)
if
(
string
.
IsNullOrEmpty
(
path
)
)
return
;
if
(
audioType
==
AudioType
.
SE
)
AudioManager
.
PlaySE
(
path
);
else
if
(
audioType
==
AudioType
.
Voice
)
AudioManager
.
PlayVoiceByPath
(
path
);
AudioManager
.
PlayVoiceBy
Resource
Path
(
path
);
}
}
...
...
Data/locales/zh-CN/translation.conf
View file @
3dc972d7
...
...
@@ -639,3 +639,6 @@ YDK 内容不合法,主卡组必须满 40 张->YDK 内容不合法,主卡组
自定义游戏->自定义游戏
检测到新版先行卡,请至 [游戏设置]-[扩展卡包]-[更新先行卡] 处进行更新。->检测到新版先行卡,请至 [游戏设置]-[扩展卡包]-[更新先行卡] 处进行更新。
SMAA
High
->
SMAA
High
决斗场地背景音乐->决斗场地背景音乐
场地背景音乐->场地背景音乐
场地背景音乐由哪方决定->场地背景音乐由哪方决定
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