Fix prop loading on packaged builds (#1717)
This commit is contained in:
parent
114d54d889
commit
978019be32
|
@ -38,11 +38,11 @@ the project's root.
|
||||||
|
|
||||||
<h4>How to import a map</h4>
|
<h4>How to import a map</h4>
|
||||||
In order to do so, the file generated in the import phase has to be placed in a folder
|
In order to do so, the file generated in the import phase has to be placed in a folder
|
||||||
at the root of the distributed folder called "ExportedMaps". Once the zip is placed there,
|
at the root of the distributed folder called "ExportedAssets". Once the zip is placed there,
|
||||||
by running
|
by running
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
./ImportMaps.sh
|
./ImportAssets.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
the content will get extracted and located properly where the executable can reach it. All
|
the content will get extracted and located properly where the executable can reach it. All
|
||||||
|
|
|
@ -89,6 +89,16 @@ popd >/dev/null
|
||||||
DESTINATION=${BUILD_FOLDER}/${FILE_NAME}.tar.gz
|
DESTINATION=${BUILD_FOLDER}/${FILE_NAME}.tar.gz
|
||||||
SOURCE=${BUILD_FOLDER}/Cooked
|
SOURCE=${BUILD_FOLDER}/Cooked
|
||||||
|
|
||||||
|
FILES=$(find ${CARLAUE4_ROOT_FOLDER}/Content -type f -name "*PropRegistry.json")
|
||||||
|
|
||||||
|
mkdir -p ${SOURCE}/CarlaUE4/Content/Carla/Config
|
||||||
|
for file in $FILES
|
||||||
|
do
|
||||||
|
A="$(echo $file | grep -o 'Content\/.*' | cut -f2 -d/)"
|
||||||
|
mkdir -p ${SOURCE}/CarlaUE4/Content/${A}/Config
|
||||||
|
cp -rf $file ${SOURCE}/CarlaUE4/Content/${A}/Config
|
||||||
|
done
|
||||||
|
|
||||||
pushd "${SOURCE}" >/dev/null
|
pushd "${SOURCE}" >/dev/null
|
||||||
|
|
||||||
log "Packaging build."
|
log "Packaging build."
|
||||||
|
|
|
@ -92,7 +92,7 @@ if $DO_COPY_FILES ; then
|
||||||
|
|
||||||
pushd ${CARLA_ROOT_FOLDER} >/dev/null
|
pushd ${CARLA_ROOT_FOLDER} >/dev/null
|
||||||
|
|
||||||
mkdir -p "${DESTINATION}/ExportedMaps"
|
mkdir -p "${DESTINATION}/ExportedAssets"
|
||||||
|
|
||||||
echo "${REPOSITORY_TAG}" > ${DESTINATION}/VERSION
|
echo "${REPOSITORY_TAG}" > ${DESTINATION}/VERSION
|
||||||
|
|
||||||
|
@ -101,7 +101,7 @@ if $DO_COPY_FILES ; then
|
||||||
copy_if_changed "./Docs/release_readme.md" "${DESTINATION}/README"
|
copy_if_changed "./Docs/release_readme.md" "${DESTINATION}/README"
|
||||||
copy_if_changed "./Docs/python_api.md" "${DESTINATION}/PythonAPI/python_api.md"
|
copy_if_changed "./Docs/python_api.md" "${DESTINATION}/PythonAPI/python_api.md"
|
||||||
copy_if_changed "./Util/Docker/Release.Dockerfile" "${DESTINATION}/Dockerfile"
|
copy_if_changed "./Util/Docker/Release.Dockerfile" "${DESTINATION}/Dockerfile"
|
||||||
copy_if_changed "./Util/ImportMaps.sh" "${DESTINATION}/ImportMaps.sh"
|
copy_if_changed "./Util/ImportAssets.sh" "${DESTINATION}/ImportAssets.sh"
|
||||||
|
|
||||||
copy_if_changed "./PythonAPI/carla/dist/*.egg" "${DESTINATION}/PythonAPI/carla/dist/"
|
copy_if_changed "./PythonAPI/carla/dist/*.egg" "${DESTINATION}/PythonAPI/carla/dist/"
|
||||||
copy_if_changed "./PythonAPI/carla/agents/" "${DESTINATION}/PythonAPI/carla/agents"
|
copy_if_changed "./PythonAPI/carla/agents/" "${DESTINATION}/PythonAPI/carla/agents"
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
# -- Parse arguments -----------------------------------------------------------
|
# -- Parse arguments -----------------------------------------------------------
|
||||||
# ==============================================================================
|
# ==============================================================================
|
||||||
|
|
||||||
DOC_STRING="Unpack and copy over CarlaUE4's Exported Maps"
|
DOC_STRING="Unpack and copy over CarlaUE4's Exported Assets"
|
||||||
|
|
||||||
USAGE_STRING="Usage: $0 [-h|--help] [-d|--dir] <outdir>"
|
USAGE_STRING="Usage: $0 [-h|--help] [-d|--dir] <outdir>"
|
||||||
|
|
||||||
|
@ -32,7 +32,7 @@ while true; do
|
||||||
done
|
done
|
||||||
|
|
||||||
#Tar.gz the stuff
|
#Tar.gz the stuff
|
||||||
for filepath in `find ExportedMaps/ -type f -name "*.tar.gz"`; do
|
for filepath in `find ExportedAssets/ -type f -name "*.tar.gz"`; do
|
||||||
tar --keep-newer-files -xvf ${filepath}
|
tar --keep-newer-files -xvf ${filepath}
|
||||||
done
|
done
|
||||||
|
|
Loading…
Reference in New Issue