mirror of
https://github.com/minetest/minetest.git
synced 2024-11-20 14:43:45 +01:00
4b90e582b4
The new header intentionally isn't in MTG stone design (or any other MTG-esque design), since we want to distance Luanti and MTG from each other. The font "undefined medium" (https://undefined-medium.com/) was used. ASCII art generated by https://patorjk.com/software/taag/#p=display&f=Graffiti&t=luanti https://github.com/minetest/minetest/pull/11952#issuecomment-1013364703 --------- Co-authored-by: sfan5 <sfan5@live.de>
31 lines
808 B
Bash
Executable File
31 lines
808 B
Bash
Executable File
#!/bin/bash
|
|
dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
|
gameid=${gameid:-devtest}
|
|
executable=$dir/../bin/luanti
|
|
testspath=$dir/../tests
|
|
conf_server=$testspath/server.conf
|
|
worldpath=$testspath/world
|
|
|
|
run () {
|
|
if [ -n "$PERF" ]; then
|
|
perf record -z --call-graph dwarf -- "$@"
|
|
else
|
|
"$@"
|
|
fi
|
|
}
|
|
|
|
[ -e "$executable" ] || { echo "executable $executable missing"; exit 1; }
|
|
|
|
rm -rf "$worldpath"
|
|
mkdir -p "$worldpath/worldmods"
|
|
|
|
settings=(sqlite_synchronous=0 helper_mode=mapgen)
|
|
[ -n "$PROFILER" ] && settings+=(profiler_print_interval=15)
|
|
printf '%s\n' "${settings[@]}" >"$testspath/server.conf" \
|
|
|
|
ln -s "$dir/helper_mod" "$worldpath/worldmods/"
|
|
|
|
args=(--config "$conf_server" --world "$worldpath" --gameid $gameid)
|
|
[ -n "$PROFILER" ] && args+=(--verbose)
|
|
run "$executable" --server "${args[@]}"
|