Re: [Sexy3D] セクシーモデル<<悪夢の冒険島>> Sexy model <<Adventure Island nightmare>>
You lazy bastards. Here's a batch script that will:
1) backup your original InstallLanguage key (as OriginalInstallLanguage),
2) change your InstallLanguage key to the Japanese code (0411),
3) run the executable of your choice (currently calc.exe).
4) Once the executable is terminated, it will restore the original InstallLanguage key.
Even if the unthinkable happens, (like your power goes out) all you have to do is re-run the script, and it will restore the InstallLanguage key.
You can change the executable from calc.exe to the name of the program you want to wrap.
NOTE: You must run this as administrator (Vista/Win7), since it changes registry keys!!!!!!!!!!!!
------------------------------------------------------
@ECHO OFF
REM This is a nifty little batch file which will change the InstallLanguage
REM registry value, so software written for Japanese Windows Installations will
REM run with other installations. It will not, however, make Japaneese
REM characters work. You'll need to install those character sets youself.
REM It works by looking at the registry value in "InstallLanguage", under
REM HKLM\System\Controlset001\Control\Nls\Language. It will backup that value
REM (only once) and place it in "OriginalInstallLanguage". It will then change
REM "InstallLanguage" to the Japaneese code (0411), and launch the program.
REM When the program ends, original language is restored to "InstallLanguage".
REM On a US-Engligh system, the default is 0409.
REM A few variables
SET keyName="HKLM\System\Controlset001\Control\Nls\Language"
SET valueName="InstallLanguage"
SET backupName="OriginalInstallLanguage"
SET japLangCode=0411
SET query=reg query %keyName%
REM First, see if we already have the original language backed up
FOR /F "tokens=3" %%i IN ('%query% ^| FIND %backupName%') DO (SET origValue=%%i)
REM If the original install language is backed up, we can skip the backup.
IF DEFINED origValue GOTO :switchLang
REM If we're here, we need to back up the original install language.
FOR /F "tokens=3" %%i IN ('%query% ^| FIND %valueName%') DO (SET origValue=%%i)
ECHO Backing up the original %valueName% code %origValue%
reg add %keyName% /v %backupName% /t REG_SZ /d %origValue% /f
ECHO.
REM Change the language code
:switchLang
ECHO Changing %valueName% code from %origValue% to %japLangCode%
reg add %keyName% /v %valueName% /t REG_SZ /d "%japLangCode%" /f
ECHO.
REM Run the program - you'll probably want to change this...
START /WAIT calc.exe
REM Copy the original code back to "InstallLanguage", since we're done with it.
ECHO Restoring original code %origValue% to %valueName%
reg add %keyName% /v %valueName% /t REG_SZ /d %origValue% /f
PAUSE
EXIT