Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
jobily
VPet
提交
9bbd78e3
V
VPet
项目概览
jobily
/
VPet
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
V
VPet
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
9bbd78e3
编写于
8月 15, 2023
作者:
Z
ZouJin
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修复无默认项导致桌宠启动失败的错误
上级
c7118bb5
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
41 addition
and
19 deletion
+41
-19
VPet-Simulator.Windows/Function/CoreMOD.cs
VPet-Simulator.Windows/Function/CoreMOD.cs
+14
-0
VPet-Simulator.Windows/MainWindow.xaml.cs
VPet-Simulator.Windows/MainWindow.xaml.cs
+12
-4
VPet-Simulator.Windows/WinDesign/winGameSetting.xaml.cs
VPet-Simulator.Windows/WinDesign/winGameSetting.xaml.cs
+15
-15
未找到文件。
VPet-Simulator.Windows/Function/CoreMOD.cs
浏览文件 @
9bbd78e3
...
...
@@ -4,6 +4,7 @@ using LinePutScript.Dictionary;
using
LinePutScript.Localization.WPF
;
using
System
;
using
System.Collections.Generic
;
using
System.Diagnostics
;
using
System.IO
;
using
System.Linq
;
using
System.Reflection
;
...
...
@@ -268,6 +269,19 @@ namespace VPet_Simulator.Windows
}
public
static
class
ExtensionSetting
{
public
static
void
StartURL
(
string
url
)
{
try
{
Process
.
Start
(
url
);
}
catch
{
Process
.
Start
(
"explorer.exe"
,
url
);
}
}
/// <summary>
/// 吃食物 附带倍率
/// </summary>
...
...
VPet-Simulator.Windows/MainWindow.xaml.cs
浏览文件 @
9bbd78e3
...
...
@@ -456,7 +456,15 @@ namespace VPet_Simulator.Windows
m_menu
=
new
ContextMenu
();
m_menu
.
MenuItems
.
Add
(
new
MenuItem
(
"鼠标穿透"
.
Translate
(),
(
x
,
y
)
=>
{
SetTransparentHitThrough
();
})
{
});
m_menu
.
MenuItems
.
Add
(
new
MenuItem
(
"操作教程"
.
Translate
(),
(
x
,
y
)
=>
{
Process
.
Start
(
AppDomain
.
CurrentDomain
.
BaseDirectory
+
@"\Tutorial.html"
);
}));
m_menu
.
MenuItems
.
Add
(
new
MenuItem
(
"操作教程"
.
Translate
(),
(
x
,
y
)
=>
{
if
(
LocalizeCore
.
CurrentCulture
==
"zh-Hans"
)
ExtensionSetting
.
StartURL
(
AppDomain
.
CurrentDomain
.
BaseDirectory
+
@"\Tutorial.html"
);
else
if
(
LocalizeCore
.
CurrentCulture
==
"zh-Hant"
)
ExtensionSetting
.
StartURL
(
AppDomain
.
CurrentDomain
.
BaseDirectory
+
@"\Tutorial_zht.html"
);
else
ExtensionSetting
.
StartURL
(
AppDomain
.
CurrentDomain
.
BaseDirectory
+
@"\Tutorial_en.html"
);
}));
m_menu
.
MenuItems
.
Add
(
new
MenuItem
(
"重置状态"
.
Translate
(),
(
x
,
y
)
=>
{
Main
.
CleanState
();
...
...
@@ -498,11 +506,11 @@ namespace VPet_Simulator.Windows
{
Set
[
"SingleTips"
].
SetDateTime
(
"tutorial"
,
DateTime
.
Now
);
if
(
LocalizeCore
.
CurrentCulture
==
"zh-Hans"
)
Process
.
Start
(
AppDomain
.
CurrentDomain
.
BaseDirectory
+
@"\Tutorial.html"
);
ExtensionSetting
.
StartURL
(
AppDomain
.
CurrentDomain
.
BaseDirectory
+
@"\Tutorial.html"
);
else
if
(
LocalizeCore
.
CurrentCulture
==
"zh-Hant"
)
Process
.
Start
(
AppDomain
.
CurrentDomain
.
BaseDirectory
+
@"\Tutorial_zht.html"
);
ExtensionSetting
.
StartURL
(
AppDomain
.
CurrentDomain
.
BaseDirectory
+
@"\Tutorial_zht.html"
);
else
Process
.
Start
(
AppDomain
.
CurrentDomain
.
BaseDirectory
+
@"\Tutorial_en.html"
);
ExtensionSetting
.
StartURL
(
AppDomain
.
CurrentDomain
.
BaseDirectory
+
@"\Tutorial_en.html"
);
}
if
(!
Set
[
"SingleTips"
].
GetBool
(
"helloworld"
))
{
...
...
VPet-Simulator.Windows/WinDesign/winGameSetting.xaml.cs
浏览文件 @
9bbd78e3
...
...
@@ -500,7 +500,7 @@ namespace VPet_Simulator.Windows
//await result.SubmitAsync(new ProgressClass(ProgressBarUpload));
if
(
MessageBoxX
.
Show
(
"{0} 成功上传至WorkShop服务器\n是否跳转至创意工坊页面进行编辑详细介绍和图标?"
.
Translate
(
mod
.
Name
),
"MOD上传成功"
.
Translate
(),
MessageBoxButton
.
YesNo
,
MessageBoxIcon
.
Success
)
==
MessageBoxResult
.
Yes
)
{
System
.
Diagnostics
.
Process
.
Start
(
"https://steamcommunity.com/sharedfiles/filedetails/?id="
+
r
.
FileId
);
ExtensionSetting
.
StartURL
(
"https://steamcommunity.com/sharedfiles/filedetails/?id="
+
r
.
FileId
);
}
}
else
...
...
@@ -527,7 +527,7 @@ namespace VPet_Simulator.Windows
mod
.
WriteFile
();
if
(
MessageBoxX
.
Show
(
"{0} 成功上传至WorkShop服务器\n是否跳转至创意工坊页面进行编辑新内容?"
.
Translate
(
mod
.
Name
)
,
"MOD更新成功"
.
Translate
(),
MessageBoxButton
.
YesNo
,
MessageBoxIcon
.
Success
)
==
MessageBoxResult
.
Yes
)
System
.
Diagnostics
.
Process
.
Start
(
"https://steamcommunity.com/sharedfiles/filedetails/?id="
+
r
.
FileId
);
ExtensionSetting
.
StartURL
(
"https://steamcommunity.com/sharedfiles/filedetails/?id="
+
r
.
FileId
);
}
else
MessageBoxX
.
Show
(
"{0} 上传至WorkShop服务器失败\n请检查网络后重试\n请注意:上传和下载工坊物品可能需要良好的网络条件\n失败原因:{1}"
...
...
@@ -542,7 +542,7 @@ namespace VPet_Simulator.Windows
{
if
(!
AllowChange
)
return
;
System
.
Diagnostics
.
Process
.
Start
(
"https://steamcommunity.com/sharedfiles/filedetails/?id="
+
mod
.
ItemID
);
ExtensionSetting
.
StartURL
(
"https://steamcommunity.com/sharedfiles/filedetails/?id="
+
mod
.
ItemID
);
}
private
void
ButtonAllow_Click
(
object
sender
,
RoutedEventArgs
e
)
...
...
@@ -567,7 +567,7 @@ namespace VPet_Simulator.Windows
private
void
hyper_moreInfo
(
object
sender
,
RoutedEventArgs
e
)
{
Process
.
Start
(
"https://www.exlb.net/Diagnosis"
);
ExtensionSetting
.
StartURL
(
"https://www.exlb.net/Diagnosis"
);
}
public
new
void
Show
()
...
...
@@ -633,48 +633,48 @@ namespace VPet_Simulator.Windows
#
region
Link
private
void
Git_Click
(
object
sender
,
RoutedEventArgs
e
)
{
Process
.
Start
(
"https://github.com/LorisYounger/VPet/graphs/contributors"
);
ExtensionSetting
.
StartURL
(
"https://github.com/LorisYounger/VPet/graphs/contributors"
);
}
private
void
Steam_Click
(
object
sender
,
RoutedEventArgs
e
)
{
Process
.
Start
(
"https://store.steampowered.com/app/1920960/_/"
);
ExtensionSetting
.
StartURL
(
"https://store.steampowered.com/app/1920960/_/"
);
}
private
void
Github_Click
(
object
sender
,
RoutedEventArgs
e
)
{
Process
.
Start
(
"https://github.com/LorisYounger/VPet"
);
ExtensionSetting
.
StartURL
(
"https://github.com/LorisYounger/VPet"
);
}
private
void
LB_Click
(
object
sender
,
RoutedEventArgs
e
)
{
Process
.
Start
(
"https://www.exlb.net/VPet"
);
ExtensionSetting
.
StartURL
(
"https://www.exlb.net/VPet"
);
}
private
void
VPET_Click
(
object
sender
,
RoutedEventArgs
e
)
{
Process
.
Start
(
"https://www.exlb.net/"
);
ExtensionSetting
.
StartURL
(
"https://www.exlb.net/"
);
}
private
void
VUP_Click
(
object
sender
,
RoutedEventArgs
e
)
{
Process
.
Start
(
"https://store.steampowered.com/app/1352140/_/"
);
ExtensionSetting
.
StartURL
(
"https://store.steampowered.com/app/1352140/_/"
);
}
private
void
Group_Click
(
object
sender
,
RoutedEventArgs
e
)
{
if
(
LocalizeCore
.
CurrentCulture
.
StartsWith
(
"zh"
))
Process
.
Start
(
"https://jq.qq.com/?_wv=1027&k=zmeWNHyI"
);
ExtensionSetting
.
StartURL
(
"https://jq.qq.com/?_wv=1027&k=zmeWNHyI"
);
else
Process
.
Start
(
"https://github.com/LorisYounger/VPet"
);
ExtensionSetting
.
StartURL
(
"https://github.com/LorisYounger/VPet"
);
}
private
void
sendkey_click
(
object
sender
,
RoutedEventArgs
e
)
{
if
(
LocalizeCore
.
CurrentCulture
.
StartsWith
(
"zh"
))
Process
.
Start
(
"https://www.exlb.net/SendKeys"
);
ExtensionSetting
.
StartURL
(
"https://www.exlb.net/SendKeys"
);
else
if
(
LocalizeCore
.
CurrentCulture
==
"null"
)
Process
.
Start
(
"https://learn.microsoft.com/en-us/dotnet/api/system.windows.forms.sendkeys?view=windowsdesktop-7.0#remarks"
);
ExtensionSetting
.
StartURL
(
"https://learn.microsoft.com/en-us/dotnet/api/system.windows.forms.sendkeys?view=windowsdesktop-7.0#remarks"
);
else
Process
.
Start
(
$"https://learn.microsoft.com/
{
LocalizeCore
.
CurrentCulture
}
/dotnet/api/system.windows.forms.sendkeys?view=windowsdesktop-7.0#remarks"
);
ExtensionSetting
.
StartURL
(
$"https://learn.microsoft.com/
{
LocalizeCore
.
CurrentCulture
}
/dotnet/api/system.windows.forms.sendkeys?view=windowsdesktop-7.0#remarks"
);
}
#
endregion
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录