R3EXS 1.0.2 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +13 -0
- data/README.md +260 -260
- data/README_EN.md +260 -260
- data/bin/R3EXS +20 -14
- data/ext/rgss3a_rvdata2/rgss3a_rvdata2.c +616 -565
- data/lib/R3EXS/RGSS3.rb +1456 -1456
- data/lib/R3EXS/RGSS3_R3EXS.rb +95 -95
- data/lib/R3EXS/ast.rb +7 -7
- data/lib/R3EXS/error.rb +17 -0
- data/lib/R3EXS/extract_strings.rb +79 -79
- data/lib/R3EXS/json_rvdata2.rb +104 -104
- data/lib/R3EXS/rvdata2_json.rb +10 -11
- data/lib/R3EXS/utils.rb +970 -970
- data/lib/R3EXS/version.rb +1 -1
- metadata +7 -7
data/README_EN.md
CHANGED
@@ -1,260 +1,260 @@
|
|
1
|
-
# R3EXS
|
2
|
-
|
3
|
-
RGSS3_Extract_Strings_Tool
|
4
|
-
|
5
|
-
<p style="text-align: center;">A tool for extracting and translating strings from the RGSS3 game engine.</p>
|
6
|
-
|
7
|
-
[**English**](README_EN.md) [**简体中文**](README.md)
|
8
|
-
|
9
|
-
## Contents
|
10
|
-
|
11
|
-
- [Synopsis](#synopsis)
|
12
|
-
- [Features](#features)
|
13
|
-
- [Function List](#function-list)
|
14
|
-
- [Installation](#installation)
|
15
|
-
- [Usage](#usage)
|
16
|
-
- [Project Build](#project-build)
|
17
|
-
- [Documentation](#documentation)
|
18
|
-
- [Links](#links)
|
19
|
-
|
20
|
-
## [Synopsis](#contents)
|
21
|
-
|
22
|
-
R3EXS is a gem built using Ruby, designed to extract and translate strings in RGSS3 games.
|
23
|
-
|
24
|
-
## [Features](#contents)
|
25
|
-
|
26
|
-
It uses [Prism](https://github.com/ruby/prism) to accurately extract strings and symbols from Ruby scripts.
|
27
|
-
|
28
|
-
## [Function List](#contents)
|
29
|
-
|
30
|
-
1. [Unpack Game.rgss3a file](#unpack-
|
31
|
-
2. [Serialize rvdata2 files to JSON file](#serialize-rvdata2-files-to-json-file)
|
32
|
-
3. [Deserialize JSON files to rvdata2 file](#deserialize-json-files-to-rvdata2-file)
|
33
|
-
4. [Extract all strings](#extract-all-strings)
|
34
|
-
5. [Inject all strings](#inject-all-strings)
|
35
|
-
|
36
|
-
## [Installation](#contents)
|
37
|
-
|
38
|
-
### Install using RubyGems
|
39
|
-
|
40
|
-
1. Install [Ruby](https://www.ruby-lang.org/en
|
41
|
-
2. Install the [R3EXS](https://rubygems.org/gems/R3EXS) gem
|
42
|
-
|
43
|
-
```bash
|
44
|
-
gem install R3EXS
|
45
|
-
```
|
46
|
-
|
47
|
-
### Download executable file directly
|
48
|
-
|
49
|
-
Click to download [R3EXS.exe](https://github.com/LuoTat/R3EXS/releases)
|
50
|
-
|
51
|
-
Since the R3EXS.exe file is packaged using [Ocran](https://github.com/Largo/ocran) and [Tebako](https://github.com/tamatebako/tebako)
|
52
|
-
|
53
|
-
The `Windows` environment provides `R3EXS-windows_Ocran` and `R3EXS-windows_Tebako`
|
54
|
-
|
55
|
-
The `Linux (GLIBC >= 2.31)` environment provides `R3EXS-linux_Tebako`
|
56
|
-
|
57
|
-
it will extract the Ruby environment the first time it runs, so the first run may be slower.
|
58
|
-
|
59
|
-
## [Usage](#contents)
|
60
|
-
|
61
|
-
The following commands assume they are run in the game’s root directory, ensuring the `./Game.rgss3a` file exists or has already been unpacked into the `./Data` folder.
|
62
|
-
|
63
|
-
~~If you enjoy a crazy amount of console output or feel like the execution is too fast~~, please enable the `--verbose` option.
|
64
|
-
|
65
|
-
### [Unpack Game.rgss3a file](#function-list)
|
66
|
-
|
67
|
-
```bash
|
68
|
-
NAME
|
69
|
-
decrypt - Decrypt the Game.rgss3a file
|
70
|
-
|
71
|
-
SYNOPSIS
|
72
|
-
|
73
|
-
R3EXS [global options] decrypt [command options] <Game.rgss3a file path>
|
74
|
-
|
75
|
-
COMMAND OPTIONS
|
76
|
-
-o, --output_dir=DIRECTORY - The *.rvdata2 output dir (default: ./)
|
77
|
-
```
|
78
|
-
|
79
|
-
Example code:
|
80
|
-
|
81
|
-
```bash
|
82
|
-
R3EXS decrypt ./Game.rgss3a
|
83
|
-
```
|
84
|
-
|
85
|
-
### [Serialize rvdata2 files to JSON file](#function-list)
|
86
|
-
|
87
|
-
```bash
|
88
|
-
NAME
|
89
|
-
rvdata2_json - Serialize rvdata2 files into JSON
|
90
|
-
|
91
|
-
SYNOPSIS
|
92
|
-
|
93
|
-
R3EXS [global options] rvdata2_json [command options] <the *.rvdata2 dir>
|
94
|
-
|
95
|
-
COMMAND OPTIONS
|
96
|
-
-c, --[no-]complete - Enable complete serialization
|
97
|
-
-n, --[no-]with_notes - Enable notes attribute serialization
|
98
|
-
-o, --output_dir=DIRECTORY - The *.json output dir (default: ./JSON)
|
99
|
-
-s, --[no-]with_scripts - Enable Scripts.rvdata2 serialization
|
100
|
-
```
|
101
|
-
|
102
|
-
Example code:
|
103
|
-
|
104
|
-
```bash
|
105
|
-
// Serialize only translatable parts
|
106
|
-
R3EXS rvdata2_json ./Data
|
107
|
-
|
108
|
-
// Complete serialization
|
109
|
-
R3EXS rvdata2_json -c ./Data
|
110
|
-
```
|
111
|
-
|
112
|
-
### [Deserialize JSON files to rvdata2 file](#function-list)
|
113
|
-
|
114
|
-
```bash
|
115
|
-
NAME
|
116
|
-
json_rvdata2 - Deserialize JSON files back into rvdata2
|
117
|
-
|
118
|
-
SYNOPSIS
|
119
|
-
|
120
|
-
R3EXS [global options] json_rvdata2 [command options] <the *.json dir>
|
121
|
-
|
122
|
-
COMMAND OPTIONS
|
123
|
-
-c, --[no-]complete - Enable complete deserialization
|
124
|
-
-o, --output_dir=DIRECTORY - The NEW *.rvdata2 output dir (default: ./Data_NEW)
|
125
|
-
-r, --original_dir=DIRECTORY - The ORIGINAL *.rvdata2 dir (default: ./Data)
|
126
|
-
-s, --[no-]with_scripts - Enable Scripts JSON deserialization
|
127
|
-
```
|
128
|
-
|
129
|
-
Example code:
|
130
|
-
|
131
|
-
```bash
|
132
|
-
// If --complete was not enabled in rvdata2_json
|
133
|
-
// Provide --original_dir or ensure ./Data folder exists in the current directory
|
134
|
-
R3EXS json_rvdata2 ./JSON
|
135
|
-
|
136
|
-
// If --complete was enabled in rvdata2_json
|
137
|
-
// --original_dir is not required
|
138
|
-
R3EXS json_rvdata2 -c ./JSON
|
139
|
-
```
|
140
|
-
|
141
|
-
### [Extract all strings](#function-list)
|
142
|
-
|
143
|
-
```bash
|
144
|
-
NAME
|
145
|
-
ex_strings - Extract all strings
|
146
|
-
|
147
|
-
SYNOPSIS
|
148
|
-
|
149
|
-
R3EXS [global options] ex_strings [command options] <the *.json dir>
|
150
|
-
|
151
|
-
COMMAND OPTIONS
|
152
|
-
-o, --output_dir=DIRECTORY - The ManualTransFile.json or ManualTransFile_scripts.json output dir (default: ./)
|
153
|
-
-p, --[no-]with_scripts_separate - Enable Scripts extraction into a separate ManualTransFile_scripts.json
|
154
|
-
-s, --[no-]with_scripts - Enable Scripts extraction
|
155
|
-
-y, --[no-]with_symbol - Enable Symbol extraction in Scripts extraction
|
156
|
-
```
|
157
|
-
|
158
|
-
Example code:
|
159
|
-
|
160
|
-
```bash
|
161
|
-
// Do not extract Scripts
|
162
|
-
R3EXS ex_strings ./JSON
|
163
|
-
|
164
|
-
// Extract Scripts
|
165
|
-
R3EXS ex_strings -s ./JSON
|
166
|
-
|
167
|
-
// Extract Scripts and separate them into ManualTransFile_scripts.json
|
168
|
-
R3EXS ex_strings -s -p ./JSON
|
169
|
-
```
|
170
|
-
|
171
|
-
### [Inject all strings](#function-list)
|
172
|
-
|
173
|
-
```bash
|
174
|
-
NAME
|
175
|
-
in_strings - Inject all strings
|
176
|
-
|
177
|
-
SYNOPSIS
|
178
|
-
|
179
|
-
R3EXS [global options] in_strings [command options] <the *.json dir>
|
180
|
-
|
181
|
-
COMMAND OPTIONS
|
182
|
-
-m, --manualtransfile_path=FILE - The ManualTransFile.json path (default: ./ManualTransFile.json)
|
183
|
-
-o, --output_dir=DIRECTORY - The NEW *.json output dir (default: ./JSON_NEW)
|
184
|
-
-s, --[no-]with_scripts - Enable Scripts Injection
|
185
|
-
```
|
186
|
-
|
187
|
-
Example code:
|
188
|
-
|
189
|
-
```bash
|
190
|
-
// Do not inject into Scripts
|
191
|
-
R3EXS in_strings ./JSON
|
192
|
-
|
193
|
-
// Inject into Scripts
|
194
|
-
R3EXS in_strings -s ./JSON
|
195
|
-
```
|
196
|
-
|
197
|
-
---
|
198
|
-
|
199
|
-
For more information, use
|
200
|
-
|
201
|
-
```bash
|
202
|
-
R3EXS help
|
203
|
-
```
|
204
|
-
|
205
|
-
## [Project Build](#contents)
|
206
|
-
|
207
|
-
To build and run the project, first clone the entire repository:
|
208
|
-
|
209
|
-
```bash
|
210
|
-
git clone git@github.com:LuoTat/R3EXS.git
|
211
|
-
```
|
212
|
-
|
213
|
-
Then use `bundle` to install dependencies:
|
214
|
-
|
215
|
-
```bash
|
216
|
-
bundle install
|
217
|
-
```
|
218
|
-
|
219
|
-
Finally, compile the C extension:
|
220
|
-
|
221
|
-
```bash
|
222
|
-
rake compile
|
223
|
-
```
|
224
|
-
|
225
|
-
---
|
226
|
-
|
227
|
-
Build the local documentation:
|
228
|
-
|
229
|
-
```bash
|
230
|
-
yardoc
|
231
|
-
```
|
232
|
-
|
233
|
-
Build the `R3EXS_Ocran.exe` file:
|
234
|
-
|
235
|
-
```bash
|
236
|
-
rake ocran
|
237
|
-
```
|
238
|
-
|
239
|
-
View all rake tasks:
|
240
|
-
|
241
|
-
```bash
|
242
|
-
rake -T
|
243
|
-
```
|
244
|
-
|
245
|
-
## [Documentation](#contents)
|
246
|
-
|
247
|
-
[R3EXS Api Documentation](https://rubydoc.info/gems/R3EXS)
|
248
|
-
|
249
|
-
## [Links](#contents)
|
250
|
-
|
251
|
-
- [oj](https://github.com/ohler55/oj)
|
252
|
-
- [gli](https://github.com/davetron5000/gli)
|
253
|
-
- [Prism](https://github.com/ruby/prism)
|
254
|
-
- [Ocran](https://github.com/Largo/ocran)
|
255
|
-
- [Tebako](https://github.com/tamatebako/tebako)
|
256
|
-
- [RGSS3](https://github.com/taroxd/RGSS3)
|
257
|
-
- [rvdata2json](https://github.com/DICE2000/rvdata2json)
|
258
|
-
- [VX-Ace-Translator](https://github.com/AhmedAhmedEG/VX-Ace-Translator)
|
259
|
-
- [RPGMakerDecrypter](https://github.com/uuksu/RPGMakerDecrypter)
|
260
|
-
- [RPGMaker VX Ace F1-Manual](https://miaowm5.github.io/RMVA-F1)
|
1
|
+
# R3EXS
|
2
|
+
|
3
|
+
RGSS3_Extract_Strings_Tool
|
4
|
+
|
5
|
+
<p style="text-align: center;">A tool for extracting and translating strings from the RGSS3 game engine.</p>
|
6
|
+
|
7
|
+
[**English**](README_EN.md) [**简体中文**](README.md)
|
8
|
+
|
9
|
+
## Contents
|
10
|
+
|
11
|
+
- [Synopsis](#synopsis)
|
12
|
+
- [Features](#features)
|
13
|
+
- [Function List](#function-list)
|
14
|
+
- [Installation](#installation)
|
15
|
+
- [Usage](#usage)
|
16
|
+
- [Project Build](#project-build)
|
17
|
+
- [Documentation](#documentation)
|
18
|
+
- [Links](#links)
|
19
|
+
|
20
|
+
## [Synopsis](#contents)
|
21
|
+
|
22
|
+
R3EXS is a gem built using Ruby, designed to extract and translate strings in RGSS3 games.
|
23
|
+
|
24
|
+
## [Features](#contents)
|
25
|
+
|
26
|
+
It uses [Prism](https://github.com/ruby/prism) to accurately extract strings and symbols from Ruby scripts.
|
27
|
+
|
28
|
+
## [Function List](#contents)
|
29
|
+
|
30
|
+
1. [Unpack Game.rgss3a file](#unpack-gamergss3a-file)
|
31
|
+
2. [Serialize rvdata2 files to JSON file](#serialize-rvdata2-files-to-json-file)
|
32
|
+
3. [Deserialize JSON files to rvdata2 file](#deserialize-json-files-to-rvdata2-file)
|
33
|
+
4. [Extract all strings](#extract-all-strings)
|
34
|
+
5. [Inject all strings](#inject-all-strings)
|
35
|
+
|
36
|
+
## [Installation](#contents)
|
37
|
+
|
38
|
+
### Install using RubyGems
|
39
|
+
|
40
|
+
1. Install [Ruby](https://www.ruby-lang.org/en) (make sure to install Devkit to support compiling C extensions)
|
41
|
+
2. Install the [R3EXS](https://rubygems.org/gems/R3EXS) gem
|
42
|
+
|
43
|
+
```bash
|
44
|
+
gem install R3EXS
|
45
|
+
```
|
46
|
+
|
47
|
+
### Download executable file directly
|
48
|
+
|
49
|
+
Click to download [R3EXS.exe](https://github.com/LuoTat/R3EXS/releases)
|
50
|
+
|
51
|
+
Since the R3EXS.exe file is packaged using [Ocran](https://github.com/Largo/ocran) and [Tebako](https://github.com/tamatebako/tebako)
|
52
|
+
|
53
|
+
The `Windows` environment provides `R3EXS-windows_Ocran` and `R3EXS-windows_Tebako`
|
54
|
+
|
55
|
+
The `Linux (GLIBC >= 2.31)` environment provides `R3EXS-linux_Tebako`
|
56
|
+
|
57
|
+
it will extract the Ruby environment the first time it runs, so the first run may be slower.
|
58
|
+
|
59
|
+
## [Usage](#contents)
|
60
|
+
|
61
|
+
The following commands assume they are run in the game’s root directory, ensuring the `./Game.rgss3a` file exists or has already been unpacked into the `./Data` folder.
|
62
|
+
|
63
|
+
~~If you enjoy a crazy amount of console output or feel like the execution is too fast~~, please enable the `--verbose` option.
|
64
|
+
|
65
|
+
### [Unpack Game.rgss3a file](#function-list)
|
66
|
+
|
67
|
+
```bash
|
68
|
+
NAME
|
69
|
+
decrypt - Decrypt the Game.rgss3a file
|
70
|
+
|
71
|
+
SYNOPSIS
|
72
|
+
|
73
|
+
R3EXS [global options] decrypt [command options] <Game.rgss3a file path>
|
74
|
+
|
75
|
+
COMMAND OPTIONS
|
76
|
+
-o, --output_dir=DIRECTORY - The *.rvdata2 output dir (default: ./)
|
77
|
+
```
|
78
|
+
|
79
|
+
Example code:
|
80
|
+
|
81
|
+
```bash
|
82
|
+
R3EXS decrypt ./Game.rgss3a
|
83
|
+
```
|
84
|
+
|
85
|
+
### [Serialize rvdata2 files to JSON file](#function-list)
|
86
|
+
|
87
|
+
```bash
|
88
|
+
NAME
|
89
|
+
rvdata2_json - Serialize rvdata2 files into JSON
|
90
|
+
|
91
|
+
SYNOPSIS
|
92
|
+
|
93
|
+
R3EXS [global options] rvdata2_json [command options] <the *.rvdata2 dir>
|
94
|
+
|
95
|
+
COMMAND OPTIONS
|
96
|
+
-c, --[no-]complete - Enable complete serialization
|
97
|
+
-n, --[no-]with_notes - Enable notes attribute serialization
|
98
|
+
-o, --output_dir=DIRECTORY - The *.json output dir (default: ./JSON)
|
99
|
+
-s, --[no-]with_scripts - Enable Scripts.rvdata2 serialization
|
100
|
+
```
|
101
|
+
|
102
|
+
Example code:
|
103
|
+
|
104
|
+
```bash
|
105
|
+
// Serialize only translatable parts
|
106
|
+
R3EXS rvdata2_json ./Data
|
107
|
+
|
108
|
+
// Complete serialization
|
109
|
+
R3EXS rvdata2_json -c ./Data
|
110
|
+
```
|
111
|
+
|
112
|
+
### [Deserialize JSON files to rvdata2 file](#function-list)
|
113
|
+
|
114
|
+
```bash
|
115
|
+
NAME
|
116
|
+
json_rvdata2 - Deserialize JSON files back into rvdata2
|
117
|
+
|
118
|
+
SYNOPSIS
|
119
|
+
|
120
|
+
R3EXS [global options] json_rvdata2 [command options] <the *.json dir>
|
121
|
+
|
122
|
+
COMMAND OPTIONS
|
123
|
+
-c, --[no-]complete - Enable complete deserialization
|
124
|
+
-o, --output_dir=DIRECTORY - The NEW *.rvdata2 output dir (default: ./Data_NEW)
|
125
|
+
-r, --original_dir=DIRECTORY - The ORIGINAL *.rvdata2 dir (default: ./Data)
|
126
|
+
-s, --[no-]with_scripts - Enable Scripts JSON deserialization
|
127
|
+
```
|
128
|
+
|
129
|
+
Example code:
|
130
|
+
|
131
|
+
```bash
|
132
|
+
// If --complete was not enabled in rvdata2_json
|
133
|
+
// Provide --original_dir or ensure ./Data folder exists in the current directory
|
134
|
+
R3EXS json_rvdata2 ./JSON
|
135
|
+
|
136
|
+
// If --complete was enabled in rvdata2_json
|
137
|
+
// --original_dir is not required
|
138
|
+
R3EXS json_rvdata2 -c ./JSON
|
139
|
+
```
|
140
|
+
|
141
|
+
### [Extract all strings](#function-list)
|
142
|
+
|
143
|
+
```bash
|
144
|
+
NAME
|
145
|
+
ex_strings - Extract all strings
|
146
|
+
|
147
|
+
SYNOPSIS
|
148
|
+
|
149
|
+
R3EXS [global options] ex_strings [command options] <the *.json dir>
|
150
|
+
|
151
|
+
COMMAND OPTIONS
|
152
|
+
-o, --output_dir=DIRECTORY - The ManualTransFile.json or ManualTransFile_scripts.json output dir (default: ./)
|
153
|
+
-p, --[no-]with_scripts_separate - Enable Scripts extraction into a separate ManualTransFile_scripts.json
|
154
|
+
-s, --[no-]with_scripts - Enable Scripts extraction
|
155
|
+
-y, --[no-]with_symbol - Enable Symbol extraction in Scripts extraction
|
156
|
+
```
|
157
|
+
|
158
|
+
Example code:
|
159
|
+
|
160
|
+
```bash
|
161
|
+
// Do not extract Scripts
|
162
|
+
R3EXS ex_strings ./JSON
|
163
|
+
|
164
|
+
// Extract Scripts
|
165
|
+
R3EXS ex_strings -s ./JSON
|
166
|
+
|
167
|
+
// Extract Scripts and separate them into ManualTransFile_scripts.json
|
168
|
+
R3EXS ex_strings -s -p ./JSON
|
169
|
+
```
|
170
|
+
|
171
|
+
### [Inject all strings](#function-list)
|
172
|
+
|
173
|
+
```bash
|
174
|
+
NAME
|
175
|
+
in_strings - Inject all strings
|
176
|
+
|
177
|
+
SYNOPSIS
|
178
|
+
|
179
|
+
R3EXS [global options] in_strings [command options] <the *.json dir>
|
180
|
+
|
181
|
+
COMMAND OPTIONS
|
182
|
+
-m, --manualtransfile_path=FILE - The ManualTransFile.json path (default: ./ManualTransFile.json)
|
183
|
+
-o, --output_dir=DIRECTORY - The NEW *.json output dir (default: ./JSON_NEW)
|
184
|
+
-s, --[no-]with_scripts - Enable Scripts Injection
|
185
|
+
```
|
186
|
+
|
187
|
+
Example code:
|
188
|
+
|
189
|
+
```bash
|
190
|
+
// Do not inject into Scripts
|
191
|
+
R3EXS in_strings ./JSON
|
192
|
+
|
193
|
+
// Inject into Scripts
|
194
|
+
R3EXS in_strings -s ./JSON
|
195
|
+
```
|
196
|
+
|
197
|
+
---
|
198
|
+
|
199
|
+
For more information, use
|
200
|
+
|
201
|
+
```bash
|
202
|
+
R3EXS help
|
203
|
+
```
|
204
|
+
|
205
|
+
## [Project Build](#contents)
|
206
|
+
|
207
|
+
To build and run the project, first clone the entire repository:
|
208
|
+
|
209
|
+
```bash
|
210
|
+
git clone git@github.com:LuoTat/R3EXS.git
|
211
|
+
```
|
212
|
+
|
213
|
+
Then use `bundle` to install dependencies:
|
214
|
+
|
215
|
+
```bash
|
216
|
+
bundle install
|
217
|
+
```
|
218
|
+
|
219
|
+
Finally, compile the C extension:
|
220
|
+
|
221
|
+
```bash
|
222
|
+
rake compile
|
223
|
+
```
|
224
|
+
|
225
|
+
---
|
226
|
+
|
227
|
+
Build the local documentation:
|
228
|
+
|
229
|
+
```bash
|
230
|
+
yardoc
|
231
|
+
```
|
232
|
+
|
233
|
+
Build the `R3EXS_Ocran.exe` file:
|
234
|
+
|
235
|
+
```bash
|
236
|
+
rake ocran
|
237
|
+
```
|
238
|
+
|
239
|
+
View all rake tasks:
|
240
|
+
|
241
|
+
```bash
|
242
|
+
rake -T
|
243
|
+
```
|
244
|
+
|
245
|
+
## [Documentation](#contents)
|
246
|
+
|
247
|
+
[R3EXS Api Documentation](https://rubydoc.info/gems/R3EXS)
|
248
|
+
|
249
|
+
## [Links](#contents)
|
250
|
+
|
251
|
+
- [oj](https://github.com/ohler55/oj)
|
252
|
+
- [gli](https://github.com/davetron5000/gli)
|
253
|
+
- [Prism](https://github.com/ruby/prism)
|
254
|
+
- [Ocran](https://github.com/Largo/ocran)
|
255
|
+
- [Tebako](https://github.com/tamatebako/tebako)
|
256
|
+
- [RGSS3](https://github.com/taroxd/RGSS3)
|
257
|
+
- [rvdata2json](https://github.com/DICE2000/rvdata2json)
|
258
|
+
- [VX-Ace-Translator](https://github.com/AhmedAhmedEG/VX-Ace-Translator)
|
259
|
+
- [RPGMakerDecrypter](https://github.com/uuksu/RPGMakerDecrypter)
|
260
|
+
- [RPGMaker VX Ace F1-Manual](https://miaowm5.github.io/RMVA-F1)
|
data/bin/R3EXS
CHANGED
@@ -32,9 +32,11 @@ class App
|
|
32
32
|
begin
|
33
33
|
R3EXS.rgss3a_rvdata2(args[0], options[:output_dir], global_options[:verbose])
|
34
34
|
puts "#{R3EXS::Utils::GREEN_COLOR}All rvdata2 files have been written to #{options[:output_dir]}#{R3EXS::Utils::RESET_COLOR}"
|
35
|
-
rescue
|
36
|
-
puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
37
|
-
puts '
|
35
|
+
rescue R3EXS::RGSS3AFileError => e
|
36
|
+
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
37
|
+
$stderr.puts 'Unknown RGSS3A file decrypted type'
|
38
|
+
rescue SystemCallError => e
|
39
|
+
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.class}: #{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
38
40
|
end
|
39
41
|
end
|
40
42
|
end
|
@@ -59,7 +61,7 @@ class App
|
|
59
61
|
c.action do |global_options, options, args|
|
60
62
|
begin
|
61
63
|
R3EXS.rvdata2_json(args[0], options[:output_dir], options[:complete], options[:with_scripts], options[:with_notes])
|
62
|
-
|
64
|
+
puts "#{R3EXS::Utils::GREEN_COLOR}All JSON files have been written to #{options[:output_dir]}#{R3EXS::Utils::RESET_COLOR}"
|
63
65
|
rescue R3EXS::Rvdata2FileError => e
|
64
66
|
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
65
67
|
$stderr.puts 'Please make sure the rvdata2 files are not corrupted.'
|
@@ -91,7 +93,7 @@ class App
|
|
91
93
|
c.action do |global_options, options, args|
|
92
94
|
begin
|
93
95
|
R3EXS.json_rvdata2(args[0], options[:output_dir], options[:original_dir], options[:complete], options[:with_scripts])
|
94
|
-
|
96
|
+
puts "#{R3EXS::Utils::GREEN_COLOR}All new rvdata2 files have been written to #{options[:output_dir]}#{R3EXS::Utils::RESET_COLOR}"
|
95
97
|
rescue R3EXS::RPGJsonFileError => e
|
96
98
|
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
97
99
|
$stderr.puts 'Your JSON files are not in RPG module'
|
@@ -144,16 +146,20 @@ class App
|
|
144
146
|
c.action do |global_options, options, args|
|
145
147
|
begin
|
146
148
|
R3EXS.ex_strings(args[0], options[:output_dir], options[:with_scripts], options[:with_symbol], options[:with_scripts_separate])
|
147
|
-
|
149
|
+
if options[:with_scripts_separate]
|
150
|
+
puts "#{R3EXS::Utils::GREEN_COLOR}All strings have been extracted to #{File.join(options[:output_dir], 'ManualTransFile.json')} and #{File.join(options[:output_dir], 'ManualTransFile_scripts.json')}#{R3EXS::Utils::RESET_COLOR}"
|
151
|
+
else
|
152
|
+
puts "#{R3EXS::Utils::GREEN_COLOR}All strings have been extracted to #{File.join(options[:output_dir], 'ManualTransFile.json')}#{R3EXS::Utils::RESET_COLOR}"
|
153
|
+
end
|
148
154
|
rescue R3EXS::R3EXSJsonFileError => e
|
149
|
-
puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
155
|
+
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
150
156
|
$stderr.puts 'Your JSON files are not in R3EXS module'
|
151
157
|
$stderr.puts "You are #{R3EXS::Utils::RED_COLOR}NOT#{R3EXS::Utils::RESET_COLOR} supposed to use '#{R3EXS::Utils::GREEN_COLOR}-c#{R3EXS::Utils::RESET_COLOR}' or '#{R3EXS::Utils::GREEN_COLOR}--complete#{R3EXS::Utils::RESET_COLOR}' to enable complete serialization in #{R3EXS::Utils::GREEN_COLOR}rvdata2_json#{R3EXS::Utils::RESET_COLOR} subcommand"
|
152
158
|
$stderr.puts "For more information, please enter '#{R3EXS::Utils::GREEN_COLOR}R3EXS help json_rvdata2#{R3EXS::Utils::RESET_COLOR}'"
|
153
159
|
rescue R3EXS::JsonDirError => e
|
154
|
-
puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
160
|
+
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
155
161
|
rescue R3EXS::ScriptsDirError => e
|
156
|
-
puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
162
|
+
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
157
163
|
$stderr.puts "You are supposed to use '#{R3EXS::Utils::GREEN_COLOR}-s#{R3EXS::Utils::RESET_COLOR}' or '#{R3EXS::Utils::GREEN_COLOR}--scripts#{R3EXS::Utils::RESET_COLOR}' to enable serialization of Scripts in #{R3EXS::Utils::GREEN_COLOR}rvdata2_json#{R3EXS::Utils::RESET_COLOR} subcommand"
|
158
164
|
$stderr.puts "For more information, please enter '#{R3EXS::Utils::GREEN_COLOR}R3EXS help rvdata2_json#{R3EXS::Utils::RESET_COLOR}'"
|
159
165
|
end
|
@@ -181,18 +187,18 @@ class App
|
|
181
187
|
R3EXS.in_strings(args[0], options[:output_dir], options[:manualtransfile_path], options[:with_scripts])
|
182
188
|
puts "#{R3EXS::Utils::GREEN_COLOR}All new JSON files have been written to #{options[:output_dir]}#{R3EXS::Utils::RESET_COLOR}"
|
183
189
|
rescue R3EXS::R3EXSJsonFileError => e
|
184
|
-
puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
190
|
+
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
185
191
|
$stderr.puts 'Your JSON files are not in R3EXS module'
|
186
192
|
$stderr.puts "You are #{R3EXS::Utils::RED_COLOR}NOT#{R3EXS::Utils::RESET_COLOR} supposed to use '#{R3EXS::Utils::GREEN_COLOR}-c#{R3EXS::Utils::RESET_COLOR}' or '#{R3EXS::Utils::GREEN_COLOR}--complete#{R3EXS::Utils::RESET_COLOR}' to enable complete serialization in #{R3EXS::Utils::GREEN_COLOR}rvdata2_json#{R3EXS::Utils::RESET_COLOR} subcommand"
|
187
193
|
$stderr.puts "For more information, please enter '#{R3EXS::Utils::GREEN_COLOR}R3EXS help json_rvdata2#{R3EXS::Utils::RESET_COLOR}'"
|
188
194
|
rescue R3EXS::JsonDirError => e
|
189
|
-
puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
195
|
+
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
190
196
|
rescue R3EXS::ScriptsDirError => e
|
191
|
-
puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
197
|
+
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
192
198
|
$stderr.puts "You are supposed to use '#{R3EXS::Utils::GREEN_COLOR}-s#{R3EXS::Utils::RESET_COLOR}' or '#{R3EXS::Utils::GREEN_COLOR}--scripts#{R3EXS::Utils::RESET_COLOR}' to enable serialization of Scripts in #{R3EXS::Utils::GREEN_COLOR}rvdata2_json#{R3EXS::Utils::RESET_COLOR} subcommand"
|
193
199
|
$stderr.puts "For more information, please enter '#{R3EXS::Utils::GREEN_COLOR}R3EXS help rvdata2_json#{R3EXS::Utils::RESET_COLOR}'"
|
194
200
|
rescue R3EXS::ManualTransFilePathError => e
|
195
|
-
puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
201
|
+
$stderr.puts "#{R3EXS::Utils::RED_COLOR}#{e.message}#{R3EXS::Utils::RESET_COLOR}"
|
196
202
|
$stderr.puts "You are supposed to use #{R3EXS::Utils::GREEN_COLOR}ex_strings#{R3EXS::Utils::RESET_COLOR} subcommand to generate the ManualTransFile.json"
|
197
203
|
$stderr.puts "For more information, please enter '#{R3EXS::Utils::GREEN_COLOR}R3EXS help ex_strings#{R3EXS::Utils::RESET_COLOR}'"
|
198
204
|
end
|
@@ -214,4 +220,4 @@ class App
|
|
214
220
|
end
|
215
221
|
end
|
216
222
|
|
217
|
-
exit App.run(ARGV)
|
223
|
+
exit App.run(ARGV)
|