Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Donald Haase
WiiVC Injector
Commits
f4f04a45
Commit
f4f04a45
authored
Apr 29, 2023
by
Amyn Bennamane
Browse files
Include game name in output folder name
parent
c55a2b81
Changes
1
Hide whitespace changes
Inline
Side-by-side
TeconMoon's WiiVC Injector/Form1.cs
View file @
f4f04a45
...
...
@@ -2211,7 +2211,8 @@ namespace TeconMoon_s_WiiVC_Injector
BuildStatus
.
Text
=
"Encrypting contents into installable WUP Package..."
;
BuildStatus
.
Refresh
();
Directory
.
SetCurrentDirectory
(
TempRootPath
);
string
outputPath
=
selectedOutputPath
+
"\\WUP-N-"
+
TitleIDText
+
"_"
+
PackedTitleIDLine
.
Text
;
string
sanitizedGameName
=
SanitizeFilename
(
PackedTitleLine1
.
Text
);
string
outputPath
=
selectedOutputPath
+
"\\"
+
sanitizedGameName
+
" WUP-N-"
+
TitleIDText
+
"_"
+
PackedTitleIDLine
.
Text
;
LauncherExeFile
=
TempToolsPath
+
"JAR\\NUSPacker.exe"
;
LauncherExeArgs
=
"-in BUILDDIR -out \""
+
outputPath
+
"\" -encryptKeyWith "
+
WiiUCommonKey
.
Text
;
LaunchProgram
();
...
...
@@ -2254,6 +2255,12 @@ namespace TeconMoon_s_WiiVC_Injector
/////
}
private
string
SanitizeFilename
(
string
str
)
{
var
invalids
=
Path
.
GetInvalidFileNameChars
();
return
string
.
Join
(
"_"
,
str
.
Split
(
invalids
,
StringSplitOptions
.
RemoveEmptyEntries
)).
TrimEnd
(
'.'
);
}
private
static
string
GetMD5Checksum
(
string
file
)
{
using
(
FileStream
stream
=
File
.
OpenRead
(
file
))
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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