@@ -66,7 +66,7 @@ if [[ ${BASH_VERSINFO[0]} -lt 4 ]] || [[ ${BASH_VERSINFO[0]} -eq 4 && ${BASH_VER
66
66
fi
67
67
68
68
# Game versions for uploading
69
- declare -A game_flavors=( [" retail" ]=" mainline" [" classic" ]=" classic" [" bc " ]=" bcc" )
69
+ declare -A game_flavors=( [" retail" ]=" mainline" [" classic" ]=" classic" [" bcc " ]=" bcc" )
70
70
declare -A game_versions
71
71
toc_version=
72
72
@@ -86,7 +86,7 @@ escape_substr() {
86
86
filename_filter () {
87
87
local classic alpha beta invalid
88
88
[ -n " $skip_invalid " ] && invalid=" &" || invalid=" _"
89
- if [[ " $game_type " != " retail" ]] && [[ " $game_type " != " classic" || " ${si_project_version,,} " != * " -classic" * ]] && [[ " $game_type " != " bc " || " ${si_project_version,,} " != * " -bc " * ]]; then
89
+ if [[ " $game_type " != " retail" ]] && [[ " $game_type " != " classic" || " ${si_project_version,,} " != * " -classic" * ]] && [[ " $game_type " != " bcc " || " ${si_project_version,,} " != * " -bcc " * ]]; then
90
90
# only append the game type if the tag doesn't include it
91
91
classic=" -$game_type "
92
92
fi
@@ -184,9 +184,17 @@ while getopts ":celLzusop:dw:a:r:t:g:m:n:" opt; do
184
184
g) # Set the game type or version
185
185
OPTARG=" ${OPTARG,,} "
186
186
case " $OPTARG " in
187
- retail|classic|bc ) game_type=" $OPTARG " ;; # game_version from toc
187
+ retail|classic|bcc ) game_type=" $OPTARG " ;; # game_version from toc
188
188
mainline) game_type=" retail" ;;
189
- bcc) game_type=" bc" ;;
189
+ bc)
190
+ echo " Invalid argument for option \" -g\" ($OPTARG )" >&2
191
+ echo " " >&2
192
+ echo " The \" bc\" game type has been changed to \" bcc\" to match Blizzard." >&2
193
+ echo " This affects TOC interface lines (Interface-BC -> Interface-BCC) and" >&2
194
+ echo " build keywords (version-bc -> version-bcc)." >&2
195
+ echo " " >&2
196
+ exit 1
197
+ ;;
190
198
* )
191
199
# Set game version (x.y.z)
192
200
# Build game type set from the last value if a list
@@ -200,7 +208,7 @@ while getopts ":celLzusop:dw:a:r:t:g:m:n:" opt; do
200
208
if [[ ${BASH_REMATCH[1]} == " 1" && ${BASH_REMATCH[2]} == " 13" ]]; then
201
209
game_type=" classic"
202
210
elif [[ ${BASH_REMATCH[1]} == " 2" && ${BASH_REMATCH[2]} == " 5" ]]; then
203
- game_type=" bc "
211
+ game_type=" bcc "
204
212
else
205
213
game_type=" retail"
206
214
fi
@@ -972,7 +980,7 @@ if [[ -n "$toc_version" && -z "$game_type" ]]; then
972
980
# toc -> game type
973
981
case $toc_version in
974
982
113* ) game_type=" classic" ;;
975
- 205* ) game_type=" bc " ;;
983
+ 205* ) game_type=" bcc " ;;
976
984
* ) game_type=" retail"
977
985
esac
978
986
else
@@ -988,15 +996,15 @@ else
988
996
# Check for other interface lines
989
997
if [[ -z " $toc_version " ]] || \
990
998
[[ " $game_type " == " classic" && " $toc_version " != " 113" * ]] || \
991
- [[ " $game_type " == " bc " && " $toc_version " != " 205" * ]] || \
999
+ [[ " $game_type " == " bcc " && " $toc_version " != " 205" * ]] || \
992
1000
[[ " $game_type " == " retail" && (" $toc_version " == " 113" * || " $toc_version " == " 205" * ) ]]
993
1001
then
994
1002
toc_version=" $game_type_toc_version "
995
1003
if [[ -z " $toc_version " ]]; then
996
1004
# Check @non-@ blocks
997
1005
case $game_type in
998
1006
classic) toc_version=$( sed -n ' /@non-[-a-z]*@/,/@end-non-[-a-z]*@/{//b;p}' <<< " $toc_file" | awk ' /#[[:blank:]]*## Interface:[[:blank:]]*(113)/ { print $NF; exit }' ) ;;
999
- bc ) toc_version=$( sed -n ' /@non-[-a-z]*@/,/@end-non-[-a-z]*@/{//b;p}' <<< " $toc_file" | awk ' /#[[:blank:]]*## Interface:[[:blank:]]*(205)/ { print $NF; exit }' ) ;;
1007
+ bcc ) toc_version=$( sed -n ' /@non-[-a-z]*@/,/@end-non-[-a-z]*@/{//b;p}' <<< " $toc_file" | awk ' /#[[:blank:]]*## Interface:[[:blank:]]*(205)/ { print $NF; exit }' ) ;;
1000
1008
esac
1001
1009
# This becomes the actual interface version after string replacements
1002
1010
root_toc_version=" $toc_version "
@@ -1457,11 +1465,11 @@ copy_directory_tree() {
1457
1465
if [ -n " $_cdt_classic " ]; then
1458
1466
_cdt_filters+=" |lua_filter retail"
1459
1467
_cdt_filters+=" |lua_filter version-retail"
1460
- [ " $_cdt_classic " = " classic" ] && _cdt_filters+=" |lua_filter version-bc "
1461
- [ " $_cdt_classic " = " bc " ] && _cdt_filters+=" |lua_filter version-classic"
1468
+ [ " $_cdt_classic " = " classic" ] && _cdt_filters+=" |lua_filter version-bcc "
1469
+ [ " $_cdt_classic " = " bcc " ] && _cdt_filters+=" |lua_filter version-classic"
1462
1470
else
1463
1471
_cdt_filters+=" |lua_filter version-classic"
1464
- _cdt_filters+=" |lua_filter version-bc "
1472
+ _cdt_filters+=" |lua_filter version-bcc "
1465
1473
fi
1466
1474
[ -n " $_cdt_localization " ] && _cdt_filters+=" |localization_filter"
1467
1475
;;
@@ -1473,11 +1481,11 @@ copy_directory_tree() {
1473
1481
if [ -n " $_cdt_classic " ]; then
1474
1482
_cdt_filters+=" |xml_filter retail"
1475
1483
_cdt_filters+=" |xml_filter version-retail"
1476
- [ " $_cdt_classic " = " classic" ] && _cdt_filters+=" |xml_filter version-bc "
1477
- [ " $_cdt_classic " = " bc " ] && _cdt_filters+=" |xml_filter version-classic"
1484
+ [ " $_cdt_classic " = " classic" ] && _cdt_filters+=" |xml_filter version-bcc "
1485
+ [ " $_cdt_classic " = " bcc " ] && _cdt_filters+=" |xml_filter version-classic"
1478
1486
else
1479
1487
_cdt_filters+=" |xml_filter version-classic"
1480
- _cdt_filters+=" |xml_filter version-bc "
1488
+ _cdt_filters+=" |xml_filter version-bcc "
1481
1489
fi
1482
1490
;;
1483
1491
* .toc)
@@ -1487,8 +1495,8 @@ copy_directory_tree() {
1487
1495
_cdt_filters+=" |toc_filter debug ${_cdt_debug} "
1488
1496
_cdt_filters+=" |toc_filter retail ${_cdt_classic: +true} "
1489
1497
_cdt_filters+=" |toc_filter version-retail ${_cdt_classic: +true} "
1490
- _cdt_filters+=" |toc_filter version-classic $( [[ -z " $_cdt_classic " || " $_cdt_classic " == " bc " ]] && echo " true" ) "
1491
- _cdt_filters+=" |toc_filter version-bc $( [[ -z " $_cdt_classic " || " $_cdt_classic " == " classic" ]] && echo " true" ) "
1498
+ _cdt_filters+=" |toc_filter version-classic $( [[ -z " $_cdt_classic " || " $_cdt_classic " == " bcc " ]] && echo " true" ) "
1499
+ _cdt_filters+=" |toc_filter version-bcc $( [[ -z " $_cdt_classic " || " $_cdt_classic " == " classic" ]] && echo " true" ) "
1492
1500
_cdt_filters+=" |toc_interface_filter"
1493
1501
[ -n " $_cdt_localization " ] && _cdt_filters+=" |localization_filter"
1494
1502
;;
@@ -2154,7 +2162,7 @@ if [ -z "$skip_zipfile" ]; then
2154
2162
if [[ " ${file_name} " == * " {game-type}" * ]] || [[ " $game_type " != " retail" && " ${file_name} " == * " {classic}" * ]]; then
2155
2163
# append the game-type for clarity
2156
2164
archive_label=" $archive_version -$game_type "
2157
- if [[ " $game_type " == " classic" && " ${project_version,,} " == * " -classic" * ]] || [[ " $game_type " == " bc " && " ${project_version,,} " == * " -bc " * ]]; then
2165
+ if [[ " $game_type " == " classic" && " ${project_version,,} " == * " -classic" * ]] || [[ " $game_type " == " bcc " && " ${project_version,,} " == * " -bcc " * ]]; then
2158
2166
# this is mostly for BigWigs projects that tag classic separately (eg, v10-classic)
2159
2167
# to prevent the extra -classic without changing all our workflows
2160
2168
archive_label=" $archive_version "
@@ -2255,7 +2263,7 @@ if [ -z "$skip_zipfile" ]; then
2255
2263
case $game_type in
2256
2264
retail) _cf_game_type_id=517 ;;
2257
2265
classic) _cf_game_type_id=67408 ;;
2258
- bc ) _cf_game_type_id=73246 ;;
2266
+ bcc ) _cf_game_type_id=73246 ;;
2259
2267
esac
2260
2268
_cf_game_version_id=$( echo " $_cf_versions " | jq -c --argjson v " $_cf_game_type_id " ' map(select(.gameVersionTypeID == $v)) | max_by(.id) | [.id]' 2> /dev/null )
2261
2269
_cf_game_version=$( echo " $_cf_versions " | jq -r --argjson v " $_cf_game_type_id " ' map(select(.gameVersionTypeID == $v)) | max_by(.id) | .name' 2> /dev/null )
@@ -2420,7 +2428,11 @@ if [ -z "$skip_zipfile" ]; then
2420
2428
if [ -n " $upload_wago " ] ; then
2421
2429
_wago_support_property=" "
2422
2430
for type in " ${! game_versions[@]} " ; do
2423
- _wago_support_property+=" \" supported_${type} _patch\" : \" ${game_versions[$type]} \" , "
2431
+ if [[ " $type " == " bcc" ]]; then
2432
+ _wago_support_property+=" \" supported_bc_patch\" : \" ${game_versions[$type]} \" , "
2433
+ else
2434
+ _wago_support_property+=" \" supported_${type} _patch\" : \" ${game_versions[$type]} \" , "
2435
+ fi
2424
2436
done
2425
2437
2426
2438
_wago_stability=" $file_type "
0 commit comments