Skip to content

Commit

Permalink
Add usage and build script.
Browse files Browse the repository at this point in the history
  • Loading branch information
LiarOnce committed May 5, 2023
1 parent 26c77a3 commit df1d2fc
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 0 deletions.
26 changes: 26 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,32 @@ Currently only Simplified Chinese and English.

Require [omegat-gms2-ide-csv-filter](https://github.com/GamemakerChina/omegat-gms2-ide-csv-filter) plugin.

## Usage

### IDE 目录

根据不同来源不同版本,IDE 目录可能有以下几个名称:

```text
GameMaker Studio 2
GameMaker Studio 2-Beta
GameMaker
GameMaker-Beta
GameMaker-LTS
GameMaker Studio 2 Desktop (限 Steam)
GameMaker Studio 2 Web (限 Steam)
GameMaker Studio 2 Mobile (限 Steam)
GameMaker Studio 2 UWP (限 Steam)
```

### 2023.4.0.84 - 最新

下载 `chinese.zip` 并解压,其中 `chinese_startup.csv` 粘贴到 IDE 目录的 `Language` 文件夹下,`Chinese` 文件夹内的文件(包含该文件夹)粘贴并覆盖到 IDE 目录的 `Plugins\GMBaseIDELanguages\Languages` 文件夹下。

### 2.0.6.136 - 2023.2.0.71

下载 `chinese.csv``chinese_dnd.csv`(如果有),粘贴到 IDE 目录的 `Language` 文件夹下。

## Machine Translation Plugin reference

- Google Translation (built-in or [https://sourceforge.net/projects/omegat-gt-without-api-key/](https://sourceforge.net/projects/omegat-gt-without-api-key/))
Expand Down
28 changes: 28 additions & 0 deletions makelanguage.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
@echo off
setlocal EnableDelayedExpansion

::These variables can be change by yourself
set SEVENZIP_HOME="C:\Program Files\7-Zip"
set TRANSLATION_LANGUAGE=Chinese
::End

set TARGET_FOLDER=target
set TRANSLATION_LANGUAGE_NAME=%TRANSLATION_LANGUAGE%

for %%a in (a b c d e f g h i j k l m n o p q r s t u v w x y z) do (
set "TRANSLATION_LANGUAGE_NAME=!TRANSLATION_LANGUAGE_NAME:%%a=%%a!"
)

cd %TARGET_FOLDER%
if exist "English" ren English %TRANSLATION_LANGUAGE%
if exist "english_startup.csv" ren english_startup.csv %TRANSLATION_LANGUAGE_NAME%_startup.csv
cd %TRANSLATION_LANGUAGE%
if exist "english.csv" ren english.csv %TRANSLATION_LANGUAGE_NAME%.csv
if exist "english_dnd.csv" ren english_dnd.csv %TRANSLATION_LANGUAGE_NAME%_dnd.csv

cd ..
if not exist "README.md" copy ..\README.md .\
if not exist "%TRANSLATION_LANGUAGE_NAME%.zip" %SEVENZIP_HOME%\7z.exe a %TRANSLATION_LANGUAGE_NAME%.zip *

@echo Finished!
pause

0 comments on commit df1d2fc

Please sign in to comment.