-
-
Notifications
You must be signed in to change notification settings - Fork 394
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 53f09b4
Showing
13 changed files
with
190 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
genshin-gacha-export.danmu9.com |
Binary file not shown.
Binary file not shown.
Large diffs are not rendered by default.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
$logLocation = "%userprofile%\AppData\LocalLow\miHoYo\Genshin Impact\output_log.txt"; | ||
$logLocationChina = "%userprofile%\AppData\LocalLow\miHoYo\$([char]0x539f)$([char]0x795e)\output_log.txt"; | ||
|
||
$reg = $args[0] | ||
if ($reg -eq "china") { | ||
Write-Host "Using China cache location" | ||
$logLocation = $logLocationChina | ||
} | ||
|
||
$tmps = $env:TEMP + '\pm.ps1'; | ||
if ([System.IO.File]::Exists($tmps)) { | ||
ri $tmps | ||
} | ||
|
||
$path = [System.Environment]::ExpandEnvironmentVariables($logLocation); | ||
if (-Not [System.IO.File]::Exists($path)) { | ||
Write-Host "Cannot find the log file! Make sure to open the wish history first!" -ForegroundColor Red | ||
|
||
if (-NOT ([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator")) { | ||
Write-Host "Do you want to try to run the script as Administrator? Press [ENTER] to continue, or any key to cancel." | ||
$keyInput = [Console]::ReadKey($true).Key | ||
if ($keyInput -ne "13") { | ||
return | ||
} | ||
|
||
$myinvocation.mycommand.definition > $tmps | ||
|
||
Start-Process powershell -Verb runAs -ArgumentList "-noexit", $tmps, $reg | ||
break | ||
} | ||
|
||
return | ||
} | ||
|
||
$logs = Get-Content -Path $path | ||
$m = $logs -match "(?m).:/.+(GenshinImpact_Data|YuanShen_Data)" | ||
$m[0] -match "(.:/.+(GenshinImpact_Data|YuanShen_Data))" >$null | ||
|
||
if ($matches.Length -eq 0) { | ||
Write-Host "Cannot find the wish history url! Make sure to open the wish history first!" -ForegroundColor Red | ||
return | ||
} | ||
|
||
$gamedir = $matches[1] | ||
$cachefile = "$gamedir/webCaches/Cache/Cache_Data/data_2" | ||
$tmpfile = "$env:TEMP/ch_data_2" | ||
|
||
Copy-Item $cachefile -Destination $tmpfile | ||
|
||
$content = Get-Content -Encoding UTF8 -Raw $tmpfile | ||
$splitted = $content -split "1/0/" | ||
$found = $splitted -match "https.+?game_biz=hk4e.+?&" | ||
|
||
$found = $found[$found.Length - 1] -match "(https.+?game_biz=hk4e.+?)&" | ||
|
||
Remove-Item $tmpfile | ||
|
||
if (-Not $found) { | ||
Write-Host "Cannot find the wish history url! Make sure to open the wish history first!" -ForegroundColor Red | ||
return | ||
} | ||
|
||
$wishHistoryUrl = $matches[1] | ||
|
||
Write-Host $wishHistoryUrl | ||
Set-Clipboard -Value $wishHistoryUrl | ||
Write-Host "Link copied to clipboard, paste it back to paimon.moe" -ForegroundColor Green | ||
if ($reg -eq "china") { | ||
Write-Host "URL$([char]0x5df2)$([char]0x7ecf)$([char]0x590d)$([char]0x5236)$([char]0x5230)$([char]0x7c98)$([char]0x8d34)$([char]0x677f)" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<meta name="viewport" content="width=device-width,user-scalable=no,initial-scale=1,maximum-scale=1,minimum-scale=1,viewport-fit=cover"> | ||
<title>抽卡记录Excel转JSON</title> | ||
<script type="module" crossorigin src="/assets/index.8db8bcb2.js"></script> | ||
<link rel="modulepreload" href="/assets/vendor.1bca63b3.js"> | ||
<link rel="stylesheet" href="/assets/index.fdad386e.css"> | ||
</head> | ||
<body> | ||
<div id="app"></div> | ||
|
||
|
||
<script nomodule>!function(){var e=document,t=e.createElement("script");if(!("noModule"in t)&&"onbeforeload"in t){var n=!1;e.addEventListener("beforeload",(function(e){if(e.target===t)n=!0;else if(!e.target.hasAttribute("nomodule")||!n)return;e.preventDefault()}),!0),t.type="module",t.src=".",e.head.appendChild(t),t.remove()}}();</script> | ||
<script nomodule src="/assets/polyfills-legacy.7f715cc1.js"></script> | ||
<script nomodule id="vite-legacy-entry" data-src="/assets/index-legacy.4f60c8ed.js">System.import(document.getElementById('vite-legacy-entry').getAttribute('data-src'))</script> | ||
</body> | ||
</html> |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"active":true,"version":"0.9.10","from":"0.1.5","name":"16e42.zip","hash":"599787316e42d3f433853dc064419af348f76da05b20e881703974f24e45fb3c"} |