File tree Expand file tree Collapse file tree 2 files changed +22
-1
lines changed Expand file tree Collapse file tree 2 files changed +22
-1
lines changed Original file line number Diff line number Diff line change 17
17
18
18
ext {
19
19
// the build number that this mod is made for
20
- mindustryVersion = ' v145 '
20
+ mindustryVersion = ' v146 '
21
21
jabelVersion = " 93fde537c7"
22
22
// windows sucks
23
23
isWindows = System . getProperty(" os.name" ). toLowerCase(). contains(" windows" )
Original file line number Diff line number Diff line change 4
4
import arc .files .Fi ;
5
5
import arc .util .Log ;
6
6
import mindustry .Vars ;
7
+ import mindustry .ai .UnitCommand ;
7
8
import mindustry .mod .Mod ;
8
9
import mindustry .world .Block ;
9
10
import mindustry .world .blocks .distribution .ItemBridge ;
@@ -34,6 +35,7 @@ public void init() {
34
35
writeItems ();
35
36
writeLiquids ();
36
37
writeUnits ();
38
+ writeCommands ();
37
39
}
38
40
39
41
private void writeIcons () {
@@ -176,6 +178,25 @@ private void writeUnits() {
176
178
Log .info ("Created local file " + fi .absolutePath ());
177
179
}
178
180
181
+
182
+ private void writeCommands () {
183
+ StringBuilder sbr = new StringBuilder ();
184
+
185
+ sbr .append ("// DO NOT EDIT! Generated by mimex - Mindustry Metadata Extractor" ).append (newLine );
186
+
187
+ sbr .append ("name" )
188
+ .append (';' ).append ("id" )
189
+ .append (newLine );
190
+
191
+ UnitCommand .all .each (command -> sbr .append (command .name )
192
+ .append (';' ).append (command .id )
193
+ .append (newLine ));
194
+
195
+ Fi fi = Core .files .local ("mimex-commands.txt" );
196
+ fi .writeString (sbr .toString ());
197
+ Log .info ("Created local file " + fi .absolutePath ());
198
+ }
199
+
179
200
private final Map <BuildVisibility , String > visibilityMap = new IdentityHashMap <>(); {
180
201
visibilityMap .put (BuildVisibility .hidden , "hidden" );
181
202
visibilityMap .put (BuildVisibility .shown , "shown" );
You can’t perform that action at this time.
0 commit comments