-
Notifications
You must be signed in to change notification settings - Fork 33
Expand file tree
/
Copy pathbuild_module.sh
More file actions
executable file
·101 lines (80 loc) · 2.78 KB
/
build_module.sh
File metadata and controls
executable file
·101 lines (80 loc) · 2.78 KB
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
#!/bin/bash
#swy-- this does nothing, just ignore any `title whateverstring` calls from the msys
title() { true; }; export -f title
#swy-- set the ModuleSystem folder as the current directory ($PWD)
cd "$(dirname "$0")" || exit
title 'building tld for [wait for it]--'
PYTHONPATH="$PWD:$PWD/Data:$PWD/Header:$PWD/ID:$PWD/Process"; export PYTHONPATH
clear
#python()
#{
# test -e /usr/bin/python2 && python2 "$@" || python "$@"
#}
#swy-- make it fast by calling the python2 interpreter only once
# goes from 31.4s to 8.2s, a huge improvement in my book.
python -B -OO ./Process/process_all.py
# python -B -OO ./Process/process_init.py
# python -B -OO ./Process/process_global_variables.py
# python -B -OO ./Process/process_strings.py
# python -B -OO ./Process/process_skills.py
# python -B -OO ./Process/process_music.py
# python -B -OO ./Process/process_animations.py
# python -B -OO ./Process/process_meshes.pyddd
# python -B -OO ./Process/process_sounds.py
# python -B -OO ./Process/process_skins.py
# python -B -OO ./Process/process_map_icons.py
# python -B -OO ./Process/process_factions.py
# python -B -OO ./Process/process_items.py
# python -B -OO ./Process/process_scenes.py
# python -B -OO ./Process/process_troops.py
# python -B -OO ./Process/process_particle_sys.py
# python -B -OO ./Process/process_scene_props.py
# python -B -OO ./Process/process_tableau_materials.py
# python -B -OO ./Process/process_presentations.py
# python -B -OO ./Process/process_party_tmps.py
# python -B -OO ./Process/process_parties.py
# python -B -OO ./Process/process_quests.py
# python -B -OO ./Process/process_info_pages.py # <-- just for wb
# python -B -OO ./Process/process_scripts.py
# python -B -OO ./Process/process_mission_tmps.py
# python -B -OO ./Process/process_game_menus.py
# python -B -OO ./Process/process_simple_triggers.py
# python -B -OO ./Process/process_dialogs.py
# python -B -OO ./Process/process_postfx.py # <-- just for wb
# python -B -OO ./Process/process_global_variables_unused.py
# rm *.pyc -- not needed anymore
#
# convert to MS-DOS/Windows newline format (swyter)
# needs this: http://linux.maruhn.com/sec/flip.html
#
if [ -e /usr/bin/flip ]; then
flip -d ID/*.py
flip -d ../*.txt
flip -d ../_wb/*.txt
flip -d ./*.txt
flip -u ../_wb/_tweaks_done_to_the_existing_res_tree.txt
fi
# --
msys_check()
{
cnt=$((`cat "${1}" | wc -l` - 1))
max=${3}
echo -en "${2} count: $cnt/$max ... "
if [ ${cnt} -lt "${max}" ]; then
echo 'ok.'
else
echo 'ERROR ERROR ERROR TOO MANY!!!.'
fi
}
#
# count objects... (mtarini)
#
msys_check ID/ID_items_mb.py 'item' 915
#
# count map_icons... (mtarini)
#
msys_check ID/ID_map_icons.py ' map' 256
echo ______________________________
echo ''
echo Script processing has ended.
echo Press any key to restart. . .