forked from FireEmblemUniverse/SkillSystem_FE8
-
Notifications
You must be signed in to change notification settings - Fork 0
/
MAKE_HACK_full.cmd
86 lines (54 loc) · 1.95 KB
/
MAKE_HACK_full.cmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
@echo off
@rem USAGE: "MAKE HACK_full.cmd" [quick]
@rem If first argument is "quick", then this will not update text, tables, maps, or generate a patch
@rem "MACK HACK_quick.cmd" simply calls this but with the quick argument, for convenience
@rem defining buildfile config
set "source_rom=%~dp0FE8_clean.gba"
set "main_event=%~dp0ROMBuildfile.event"
set "target_rom=%~dp0SkillsTest.gba"
set "target_ups=%~dp0SkillsTest.ups"
set "target_sym=%~dp0SkillsTest.sym"
@rem defining tools
set "c2ea=%~dp0Tools\C2EA\c2ea"
set "textprocess=%~dp0Tools\TextProcess\text-process-classic"
set "ups=%~dp0Tools\ups\ups"
set "parsefile=%~dp0EventAssembler\Tools\ParseFile.exe"
set "tmx2ea=%~dp0Tools\tmx2ea\tmx2ea"
set symcombo=%~dp0Tools\sym\SymCombo.exe
@rem set %~dp0 into a variable because batch is stupid and messes with it when using conditionals?
set "base_dir=%~dp0"
@rem do the actual building
echo Copying ROM
copy "%source_rom%" "%target_rom%"
if /I not [%1]==[quick] (
@rem only do the following if this isn't a make hack quick
echo:
echo Processing tables
cd "%base_dir%Tables"
echo: | ("%c2ea%" "%source_rom%" -installer "%base_dir%Tables/TableInstaller.event")
echo:
echo Processing text
cd "%base_dir%Text"
echo: | ("%textprocess%" text_buildfile.txt --parser-exe "%parsefile%" --installer "InstallTextData.event" --definitions "TextDefinitions.event")
echo:
echo Processing maps
cd "%base_dir%Maps"
echo: | ("%tmx2ea%" -s -O "MasterMapInstaller.event")
)
echo:
echo Assembling
cd "%base_dir%EventAssembler"
ColorzCore A FE8 "-output:%target_rom%" "-input:%main_event%" --nocash-sym
if /I not [%1]==[quick] (
@rem only do the following if this isn't a make hack quick
echo:
echo Generating patch
cd "%base_dir%"
"%ups%" diff -b "%source_rom%" -m "%target_rom%" -o "%target_ups%"
)
echo:
echo Generating sym file
echo: | ( "%symcombo%" "%target_sym%" "%target_sym%" "%base_dir%\Tools\sym\VanillaOffsets.sym" )
echo:
echo Done!
pause