Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9ef1b65eba | ||
|
|
4d10a680c1 | ||
|
|
b8e4aa589d |
@@ -1,66 +0,0 @@
|
||||
environment:
|
||||
DEPS_DIR: c:\\projects\dependencies
|
||||
DEPS_BRANCH: master
|
||||
ASSETS_DIR: c:\\projects\stk-assets
|
||||
APPVEYOR_CACHE_ENTRY_ZIP_ARGS: -t7z -m0=lzma2 -mx=9
|
||||
IRC_NOTIFY_SCRIPT: c:\\projects\stk-code\tools\appveyor-irc-notify.py
|
||||
|
||||
os: Visual Studio 2015
|
||||
clone_depth: 1
|
||||
shallow_clone: true
|
||||
|
||||
platform:
|
||||
# - x86
|
||||
- x64
|
||||
|
||||
configuration:
|
||||
- Debug
|
||||
- Release
|
||||
|
||||
matrix:
|
||||
fast_finish: true
|
||||
|
||||
#cache:
|
||||
# - '%DEPS_DIR%'
|
||||
#- '%ASSETS_DIR%'
|
||||
|
||||
install:
|
||||
- ps: >-
|
||||
If(!(Test-Path "$env:DEPS_DIR")) {
|
||||
Write-Host "Downloading dependencies";
|
||||
Start-Process -FilePath "git" -ArgumentList "clone --branch $env:DEPS_BRANCH --single-branch --depth 1 https://github.com/supertuxkart/dependencies.git $env:DEPS_DIR" -Wait;
|
||||
}
|
||||
Else {
|
||||
Write-Host "Updating dependencies";
|
||||
Start-Process -FilePath "git" -ArgumentList "fetch --depth 1" -WorkingDirectory "$env:DEPS_DIR" -Wait;
|
||||
}
|
||||
Get-ChildItem $env:DEPS_DIR | Measure-Object -property length -sum
|
||||
#- ps: >-
|
||||
#If(!(Test-Path "$env:ASSETS_DIR")) {
|
||||
# Write-Host "Downloading assets";
|
||||
# Start-Process -FilePath "svn" -ArgumentList "checkout https://svn.code.sf.net/p/supertuxkart/code/stk-assets $env:ASSETS_DIR" -Wait;
|
||||
#}
|
||||
#Else {
|
||||
# Write-Host "Updating assets";
|
||||
# Start-Process -FilePath "svn" -ArgumentList "update" -WorkingDirectory "$env:ASSETS_DIR" -Wait;
|
||||
#}
|
||||
#Get-ChildItem $env:ASSETS_DIR | Measure-Object -property length -sum
|
||||
|
||||
before_build:
|
||||
- ps: Copy-Item "${env:DEPS_DIR}\windows_64bit\dependencies" c:\projects\stk-code\dependencies-64bit –Recurse
|
||||
- cmd: |
|
||||
md build
|
||||
cd build
|
||||
if "%platform%"=="x64" set CMAKE_GENERATOR_NAME="Visual Studio 14 2015 Win64"
|
||||
cmake -G %CMAKE_GENERATOR_NAME% -DCMAKE_BUILD_TYPE="%configuration%" .. -DCHECK_ASSETS=OFF
|
||||
|
||||
build:
|
||||
parallel: true
|
||||
project: build\ALL_BUILD.vcxproj
|
||||
|
||||
|
||||
on_success:
|
||||
- "python %IRC_NOTIFY_SCRIPT% supertuxkart [{author}:{branch}] {short_commit}: {message} {color_green}Succeeded,Details: {build_url},Commit: {commit_url}"
|
||||
|
||||
on_failure:
|
||||
- "python %IRC_NOTIFY_SCRIPT% supertuxkart [{author}:{branch}] {short_commit}: {message} {color_red}Failed,Details: {build_url},Commit: {commit_url}"
|
||||
25
.gitignore
vendored
@@ -1,15 +1,14 @@
|
||||
bld*/
|
||||
build*/
|
||||
cmake_build/
|
||||
cmake_build*/
|
||||
dependencies*/
|
||||
dependencies/
|
||||
CMakeFiles/
|
||||
stk-editor/
|
||||
.vscode/
|
||||
|
||||
.config/
|
||||
supertuxkart-64
|
||||
make*.bat
|
||||
__pycache__
|
||||
|
||||
data/editor
|
||||
data/karts
|
||||
@@ -52,23 +51,3 @@ packets_log.txt
|
||||
history.dat
|
||||
README.dependencies
|
||||
xx
|
||||
|
||||
android/android-ndk*
|
||||
android/android-sdk*
|
||||
android/assets
|
||||
android/bin
|
||||
android/build
|
||||
android/libs
|
||||
android/obj
|
||||
android/.gradle
|
||||
android-*
|
||||
*.apk
|
||||
*.keystore
|
||||
|
||||
lib/curl
|
||||
lib/freetype
|
||||
lib/ifaddrs
|
||||
lib/libogg
|
||||
lib/libvorbis
|
||||
lib/openal
|
||||
lib/openssl
|
||||
|
||||
79
.travis.yml
@@ -1,65 +1,44 @@
|
||||
# Travis-CI configuration file for SuperTuxKart
|
||||
# Travis-CI configuration file for SuperTuxKart
|
||||
#
|
||||
# Configuration manual:
|
||||
# http://docs.travis-ci.com/user/build-configuration/
|
||||
#
|
||||
sudo: false
|
||||
language: cpp
|
||||
compiler:
|
||||
- gcc
|
||||
- clang
|
||||
|
||||
matrix:
|
||||
fast_finish: true
|
||||
|
||||
env:
|
||||
matrix:
|
||||
- BUILD_TYPE="Debug" SERVER_ONLY="OFF"
|
||||
- BUILD_TYPE="Debug" SERVER_ONLY="ON"
|
||||
- BUILD_TYPE="Release" SERVER_ONLY="OFF"
|
||||
- BUILD_TYPE="Release" SERVER_ONLY="ON"
|
||||
|
||||
addons:
|
||||
apt:
|
||||
packages:
|
||||
- build-essential
|
||||
- cmake
|
||||
- libbluetooth-dev
|
||||
- libcurl4-gnutls-dev
|
||||
- libfreetype6-dev
|
||||
- libfribidi-dev
|
||||
- libgl1-mesa-dev
|
||||
- libjpeg-dev
|
||||
- libogg-dev
|
||||
- libopenal-dev
|
||||
- libpng-dev
|
||||
- libvorbis-dev
|
||||
- libxrandr-dev
|
||||
- mesa-common-dev
|
||||
- pkg-config
|
||||
- zlib1g-dev
|
||||
|
||||
before_script:
|
||||
# Unfortunately using all threads crashes g++: "g++: internal compiler error: Killed (program cc1plus)"
|
||||
# Use half of the available threads, gcc is memory hungry
|
||||
- 'if [ ${CC} = "gcc" ]; then
|
||||
export THREADS=$((`nproc` / 2));
|
||||
else
|
||||
export THREADS=$((`nproc` + 1));
|
||||
fi'
|
||||
- echo "THREADS = $THREADS"
|
||||
- free -mt
|
||||
|
||||
# - clang
|
||||
#branches:
|
||||
# only:
|
||||
# - master
|
||||
before_install:
|
||||
# Update repos
|
||||
- sudo apt-get update -qq
|
||||
# Install dependencies
|
||||
- sudo apt-get install build-essential libogg-dev libvorbis-dev libopenal-dev libxxf86vm-dev libcurl4-openssl-dev libfribidi-dev libbluetooth-dev
|
||||
# Install mesa from an other repo (a newer version is required). Quantal is not supported anymore, saucy is only supported till July 2014,
|
||||
# so we try to use trusty (precise which is what traiv uses a too old mesa version which doesn't link)
|
||||
- sudo apt-add-repository "deb http://archive.ubuntu.com/ubuntu trusty main restricted"
|
||||
- sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 3B4FE6ACC0B21F32
|
||||
- sudo apt-get update -qq
|
||||
- sudo apt-get install libgl1-mesa-dev libglu1-mesa-dev libglew-dev cmake
|
||||
script:
|
||||
- mkdir "build"
|
||||
- cd "build"
|
||||
- cmake .. -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DSERVER_ONLY=$SERVER_ONLY -DCHECK_ASSETS=off -DBUILD_RECORDER=off
|
||||
- make VERBOSE=1 -j $THREADS
|
||||
# First a debug build:
|
||||
- mkdir build-debug
|
||||
- cd build-debug
|
||||
- cmake .. -DCMAKE_BUILD_TYPE=Debug -DCHECK_ASSETS=off
|
||||
- make VERBOSE=1 -j 4
|
||||
|
||||
# Then a release build:
|
||||
- cd ..
|
||||
- mkdir build-release
|
||||
- cd build-release
|
||||
- cmake .. -DCMAKE_BUILD_TYPE=Release -DCHECK_ASSETS=off
|
||||
- make VERBOSE=1 -j 4
|
||||
|
||||
notifications:
|
||||
irc:
|
||||
channels:
|
||||
- "irc.freenode.org#supertuxkart"
|
||||
- "irc.freenode.org#stk"
|
||||
skip_join: false
|
||||
use_notice: true
|
||||
template:
|
||||
|
||||
45
CHANGELOG.md
@@ -1,48 +1,3 @@
|
||||
## SuperTuxKart 0.9.3
|
||||
* Reduced RAM and VRAM usage, reducing load times by Auria and Benau
|
||||
* New mesh format optimized for space and hardware skinning
|
||||
* Code refactoring of both render pipeline by Benau and Elderme
|
||||
* New kart Wilber and Hexley by Jymis
|
||||
* New kart Kiki and updated Konqi by Benau
|
||||
* New tracks Candela City, Cornfield Crossing and Las Dunas Arena by samuncle
|
||||
* Physics improvements and various physics bugfixes by hiker
|
||||
* Kart GFX improvements (exhaust and headlight)
|
||||
* In-game screen recording powered by libopenglrecorder
|
||||
* High quality mipmap generation by Stragus
|
||||
* New smoother camera by Auria
|
||||
* New grand prix win scene
|
||||
* Gamepad configuration bugfixes
|
||||
* 3 Strikes Battles : added spare tire karts
|
||||
* Various improvements (wall driving fixes, parachutes, GP points, cannon fixes, colorization shader)
|
||||
|
||||
## SuperTuxKart 0.9.2
|
||||
* Ghost replay races by Benau
|
||||
* Battle mode AI by Benau
|
||||
* Soccer mode AI by Benau
|
||||
* New icy soccer field by samuncle and Benau
|
||||
* New subsea track by samuncle
|
||||
* New volcano track by Ponzino
|
||||
* TTF font rendering by Benau
|
||||
* Kart properties refactor by Flakebi
|
||||
* Scripting work under the hood
|
||||
* Work on the track editor by mhp
|
||||
* Tweak to challenges
|
||||
* New farm track song by 0zone0ne and Krobonil
|
||||
* Bugfixes
|
||||
|
||||
## SuperTuxKart 0.9.1
|
||||
* Many bug fixes
|
||||
* Started to use scripting in tracks
|
||||
* Significant audio performance improvements
|
||||
* Smaller tweaks and improvements to several tracks including
|
||||
** Math class
|
||||
** XR591
|
||||
** Fort Magma
|
||||
** Gran Paradiso
|
||||
** Subsea
|
||||
* Tweak to challenges
|
||||
* Better support for driving tracks in reverse
|
||||
|
||||
## SupertTuxKart 0.9 (April 2015)
|
||||
* Fully shader-based rendering engine
|
||||
* New tracks Cocoa Temple and Gran Paradiso
|
||||
|
||||
259
CMakeLists.txt
@@ -1,6 +1,6 @@
|
||||
# root CMakeLists for the SuperTuxKart project
|
||||
project(SuperTuxKart)
|
||||
set(PROJECT_VERSION "0.9.3")
|
||||
set(PROJECT_VERSION "0.8.1")
|
||||
|
||||
cmake_minimum_required(VERSION 2.8.4)
|
||||
if(NOT (CMAKE_MAJOR_VERSION VERSION_LESS 3))
|
||||
@@ -8,14 +8,6 @@ if(NOT (CMAKE_MAJOR_VERSION VERSION_LESS 3))
|
||||
endif()
|
||||
|
||||
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PROJECT_SOURCE_DIR}/cmake")
|
||||
include(CMakeDependentOption)
|
||||
|
||||
set(DEPENDENCIES "dependencies")
|
||||
# In case of 64-bit windows, use a different path for dependencies
|
||||
# so that both dependencies can be installed next to each other
|
||||
if ( WIN32 AND (CMAKE_SIZEOF_VOID_P EQUAL 8 ) )
|
||||
set(DEPENDENCIES "dependencies-64bit")
|
||||
endif()
|
||||
|
||||
include(BuildTypeSTKRelease)
|
||||
if (NOT CMAKE_BUILD_TYPE)
|
||||
@@ -23,24 +15,12 @@ if (NOT CMAKE_BUILD_TYPE)
|
||||
set(CMAKE_BUILD_TYPE "STKRelease")
|
||||
endif()
|
||||
|
||||
option(SERVER_ONLY "Create a server only (i.e. no graphics or sound)" OFF)
|
||||
option(USE_WIIUSE "Support for wiimote input devices" ON)
|
||||
option(USE_FRIBIDI "Support for right-to-left languages" ON)
|
||||
option(CHECK_ASSETS "Check if assets are installed in ../stk-assets" ON)
|
||||
option(USE_SYSTEM_ANGELSCRIPT "Use system angelscript instead of built-in angelscript. If you enable this option, make sure to use a compatible version." OFF)
|
||||
option(ENABLE_WAYLAND_DEVICE "Enable Wayland device for linux build" OFF)
|
||||
|
||||
CMAKE_DEPENDENT_OPTION(BUILD_RECORDER "Build opengl recorder" ON
|
||||
"NOT SERVER_ONLY;NOT USE_GLES2;NOT APPLE" OFF)
|
||||
|
||||
if (UNIX AND NOT APPLE)
|
||||
option(USE_GLES2 "Use OpenGL ES2 renderer" OFF)
|
||||
endif()
|
||||
|
||||
if(UNIX OR MINGW)
|
||||
option(DEBUG_SYMBOLS "Compile with debug symbols" OFF)
|
||||
endif()
|
||||
|
||||
if(MSVC AND (MSVC_VERSION LESS 1900))
|
||||
if(MSVC)
|
||||
# Normally hide the option to build wiiuse on VS, since it depends
|
||||
# on the installation of the Windows DDK (Driver Developer Kit),
|
||||
# which also needs an absolute path :(
|
||||
@@ -50,15 +30,13 @@ else()
|
||||
set(WIIUSE_BUILD ON)
|
||||
endif()
|
||||
|
||||
if(MINGW OR CYGWIN OR SERVER_ONLY)
|
||||
option(USE_WIIUSE "Support for wiimote input devices" OFF)
|
||||
else()
|
||||
option(USE_WIIUSE "Support for wiimote input devices" ON)
|
||||
if(MINGW OR CYGWIN)
|
||||
set(USE_WIIUSE OFF)
|
||||
endif()
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
option(USE_XRANDR "Use xrandr instead of vidmode" ON)
|
||||
option(USE_ASAN "Build with Leak/Address sanitizer" OFF)
|
||||
option(USE_LIBBFD "Use libbfd for crash reporting and leak check" OFF)
|
||||
endif()
|
||||
|
||||
set(STK_SOURCE_DIR "src")
|
||||
@@ -73,32 +51,10 @@ set(STK_INSTALL_DATA_DIR "share/supertuxkart" CACHE
|
||||
|
||||
# These variables enable MSVC to find libraries located in "dependencies"
|
||||
if(WIN32)
|
||||
set(ENV{PATH} "$ENV{PATH};${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/include")
|
||||
set(ENV{LIB} ${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib)
|
||||
set(ENV{OPENALDIR} ${PROJECT_SOURCE_DIR}/${DEPENDENCIES})
|
||||
set(ENV{PATH} "$ENV{PATH};${PROJECT_SOURCE_DIR}/dependencies/include")
|
||||
set(ENV{LIB} ${PROJECT_SOURCE_DIR}/dependencies/lib)
|
||||
set(ENV{OPENALDIR} ${PROJECT_SOURCE_DIR}/dependencies)
|
||||
add_definitions(-D_IRR_STATIC_LIB_)
|
||||
add_definitions(-DNO_IRR_COMPILE_WITH_X11_)
|
||||
endif()
|
||||
|
||||
if(USE_GLES2)
|
||||
add_definitions(-DUSE_GLES2)
|
||||
add_definitions(-D_IRR_COMPILE_WITH_OGLES2_ -DNO_IRR_COMPILE_WITH_OPENGL_)
|
||||
endif()
|
||||
|
||||
if(SERVER_ONLY)
|
||||
add_definitions(-DSERVER_ONLY)
|
||||
add_definitions(-DNO_IRR_COMPILE_WITH_X11_)
|
||||
endif()
|
||||
|
||||
#if(DISABLE_VPX)
|
||||
# add_definitions(-DNO_VPX)
|
||||
#endif()
|
||||
|
||||
if(UNIX OR MINGW)
|
||||
if(DEBUG_SYMBOLS)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -g")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Build the Bullet physics library
|
||||
@@ -110,13 +66,10 @@ add_subdirectory("${PROJECT_SOURCE_DIR}/lib/enet")
|
||||
include_directories("${PROJECT_SOURCE_DIR}/lib/enet/include")
|
||||
|
||||
# Build glew library
|
||||
if(NOT USE_GLES2 AND NOT SERVER_ONLY)
|
||||
add_definitions(-DGLEW_NO_GLU)
|
||||
add_subdirectory("${PROJECT_SOURCE_DIR}/lib/glew")
|
||||
include_directories("${PROJECT_SOURCE_DIR}/lib/glew/include")
|
||||
endif()
|
||||
add_subdirectory("${PROJECT_SOURCE_DIR}/lib/glew")
|
||||
include_directories("${PROJECT_SOURCE_DIR}/lib/glew/include")
|
||||
|
||||
if(MSVC OR APPLE)
|
||||
if((WIN32 AND NOT MINGW) OR APPLE)
|
||||
if (NOT APPLE)
|
||||
# Build zlib library
|
||||
add_subdirectory("${PROJECT_SOURCE_DIR}/lib/zlib")
|
||||
@@ -127,54 +80,22 @@ if(MSVC OR APPLE)
|
||||
endif()
|
||||
|
||||
# Build png library
|
||||
set(SKIP_INSTALL_ALL TRUE)
|
||||
set(PNG_STATIC TRUE CACHE BOOL "Build static lib")
|
||||
set(PNG_TESTS FALSE CACHE BOOL "Build libpng tests")
|
||||
set(PNG_SHARED FALSE CACHE BOOL "Build shared lib")
|
||||
set (SKIP_INSTALL_ALL TRUE)
|
||||
set (PNG_STATIC TRUE)
|
||||
set (PNG_TESTS FALSE)
|
||||
set (PNG_SHARED FALSE)
|
||||
add_subdirectory("${PROJECT_SOURCE_DIR}/lib/libpng")
|
||||
include_directories("${PROJECT_SOURCE_DIR}/lib/libpng")
|
||||
|
||||
set(PNG_PNG_INCLUDE_DIR "${PROJECT_SOURCE_DIR}/lib/libpng/")
|
||||
set(PNG_LIBRARY png_static)
|
||||
endif()
|
||||
|
||||
# Add jpeg library
|
||||
if (APPLE)
|
||||
#build jpeg library
|
||||
add_subdirectory("${PROJECT_SOURCE_DIR}/lib/jpeglib")
|
||||
include_directories("${PROJECT_SOURCE_DIR}/lib/jpeglib")
|
||||
|
||||
set(PNG_PNG_INCLUDE_DIR "${PROJECT_SOURCE_DIR}/lib/libpng/")
|
||||
set(PNG_LIBRARY png15_static)
|
||||
set(JPEG_INCLUDE_DIR "${PROJECT_SOURCE_DIR}/lib/jpeglib/")
|
||||
set(JPEG_LIBRARY jpeglib)
|
||||
else()
|
||||
find_package(JPEG REQUIRED)
|
||||
include_directories(${JPEG_INCLUDE_DIR})
|
||||
endif()
|
||||
|
||||
if (BUILD_RECORDER)
|
||||
find_library(OPENGLRECORDER_LIBRARY NAMES openglrecorder libopenglrecorder PATHS "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib")
|
||||
find_path(OPENGLRECORDER_INCLUDEDIR NAMES openglrecorder.h PATHS "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/include")
|
||||
if (NOT OPENGLRECORDER_LIBRARY OR NOT OPENGLRECORDER_INCLUDEDIR)
|
||||
if(PROJECT_VERSION STREQUAL "git")
|
||||
message(WARNING "libopenglrecorder not found, disabling in-game recorder. "
|
||||
"To use recorder, install libopenglrecorder.")
|
||||
set(OPENGLRECORDER_LIBRARY CACHE INTERNAL "")
|
||||
set(OPENGLRECORDER_INCLUDEDIR CACHE INTERNAL "")
|
||||
set(BUILD_RECORDER OFF)
|
||||
else()
|
||||
message(FATAL_ERROR "libopenglrecorder not found. "
|
||||
"Either install libopenglrecorder or disable in-game recorder with -DBUILD_RECORDER=0")
|
||||
endif()
|
||||
else()
|
||||
include_directories(${OPENGLRECORDER_INCLUDEDIR})
|
||||
mark_as_advanced(OPENGLRECORDER_LIBRARY OPENGLRECORDER_INCLUDEDIR)
|
||||
add_definitions(-DENABLE_RECORDER)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(NOT SERVER_ONLY AND NOT USE_GLES2)
|
||||
add_subdirectory("${PROJECT_SOURCE_DIR}/lib/graphics_utils")
|
||||
include_directories("${PROJECT_SOURCE_DIR}/lib/graphics_utils")
|
||||
endif()
|
||||
|
||||
# Build the irrlicht library
|
||||
add_subdirectory("${PROJECT_SOURCE_DIR}/lib/irrlicht")
|
||||
include_directories("${PROJECT_SOURCE_DIR}/lib/irrlicht/include")
|
||||
@@ -194,23 +115,17 @@ endif()
|
||||
include_directories(${STK_SOURCE_DIR})
|
||||
|
||||
if(APPLE)
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch x86_64")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch x86_64 -F/Library/Frameworks")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch i386")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch i386 -F/Library/Frameworks")
|
||||
elseif(MSVC)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP") # Enable multi-processor compilation (faster)
|
||||
endif()
|
||||
|
||||
|
||||
# Build the angelscript library if not in system
|
||||
if(USE_SYSTEM_ANGELSCRIPT)
|
||||
find_package(Angelscript)
|
||||
if(ANGELSCRIPT_FOUND)
|
||||
include_directories(${Angelscript_INCLUDE_DIRS})
|
||||
else()
|
||||
message(FATAL_ERROR "Angelscript not found. "
|
||||
"Either install angelscript or use built-in version using "
|
||||
"-DUSE_SYSTEM_ANGELSCRIPT=0")
|
||||
endif()
|
||||
find_package(Angelscript)
|
||||
if(USE_SYSTEM_ANGELSCRIPT AND ANGELSCRIPT_FOUND)
|
||||
include_directories(${Angelscript_INCLUDE_DIRS})
|
||||
else()
|
||||
add_subdirectory("${PROJECT_SOURCE_DIR}/lib/angelscript/projects/cmake")
|
||||
include_directories("${PROJECT_SOURCE_DIR}/lib/angelscript/include")
|
||||
@@ -242,15 +157,6 @@ else()
|
||||
include_directories(${OGGVORBIS_INCLUDE_DIRS})
|
||||
endif()
|
||||
|
||||
# Freetype
|
||||
find_package(Freetype)
|
||||
if(FREETYPE_FOUND)
|
||||
include_directories(${FREETYPE_INCLUDE_DIRS})
|
||||
else()
|
||||
message(FATAL_ERROR "Freetype not found. "
|
||||
"Freetype is required to display characters in SuperTuxKart. ")
|
||||
endif()
|
||||
|
||||
# Fribidi
|
||||
if(USE_FRIBIDI)
|
||||
find_package(Fribidi)
|
||||
@@ -263,27 +169,36 @@ if(USE_FRIBIDI)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# OpenGL
|
||||
if(NOT USE_GLES2 AND NOT SERVER_ONLY)
|
||||
find_package(OpenGL REQUIRED)
|
||||
include_directories(${OPENGL_INCLUDE_DIR})
|
||||
# OpenMP
|
||||
find_package(OpenMP)
|
||||
if (OPENMP_FOUND)
|
||||
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}")
|
||||
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS}")
|
||||
endif()
|
||||
|
||||
if(USE_LIBBFD)
|
||||
find_package(Libbfd)
|
||||
if(LIBBFD_FOUND)
|
||||
add_definitions(-DENABLE_LIBBFD)
|
||||
include_directories(${LIBBFD_INCLUDE_DIRS})
|
||||
# OpenGL
|
||||
find_package(OpenGL REQUIRED)
|
||||
include_directories(${OPENGL_INCLUDE_DIR})
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
find_package(X11 REQUIRED)
|
||||
include_directories(${X11_INCLUDE_DIR})
|
||||
|
||||
if(USE_XRANDR)
|
||||
find_package(Xrandr REQUIRED)
|
||||
if(NOT XRANDR_FOUND)
|
||||
message(FATAL_ERROR "XRANDR not found.")
|
||||
endif()
|
||||
else()
|
||||
set(USE_LIBBFD OFF CACHE BOOL "Use libbfd for crash reporting and leak check" FORCE)
|
||||
message(WARNING "Libbfd not found, disable integrated stack trace.")
|
||||
find_library(IRRLICHT_XF86VM_LIBRARY Xxf86vm)
|
||||
mark_as_advanced(IRRLICHT_XF86VM_LIBRARY)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Set some compiler options
|
||||
if(UNIX OR MINGW)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++0x")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wno-unused-function")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall")
|
||||
endif()
|
||||
|
||||
if(MINGW AND CMAKE_BUILD_TYPE MATCHES Release)
|
||||
@@ -296,11 +211,6 @@ if(WIN32)
|
||||
|
||||
# And shut up about unsafe stuff
|
||||
add_definitions(-D_CRT_SECURE_NO_WARNINGS)
|
||||
|
||||
# Avoid timespec structure redeclaration on Visual Studio 2015
|
||||
if (NOT (MSVC_VERSION LESS 1900))
|
||||
add_definitions(-DHAVE_STRUCT_TIMESPEC)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(MSVC)
|
||||
@@ -321,7 +231,7 @@ endif()
|
||||
add_definitions(-DHAVE_OGGVORBIS)
|
||||
|
||||
if(WIN32)
|
||||
configure_file("${STK_SOURCE_DIR}/../tools/windows_installer/icon_rc.template" "${PROJECT_BINARY_DIR}/tmp/icon.rc")
|
||||
configure_file("${STK_SOURCE_DIR}/windows_installer/icon_rc.template" "${PROJECT_BINARY_DIR}/tmp/icon.rc")
|
||||
endif()
|
||||
|
||||
# Provides list of source and header files (STK_SOURCES and STK_HEADERS)
|
||||
@@ -371,7 +281,7 @@ else()
|
||||
elseif(MINGW)
|
||||
set(PTHREAD_NAMES "winpthread-1" "libwinpthread-1" "pthreadGC2")
|
||||
endif()
|
||||
find_library(PTHREAD_LIBRARY NAMES pthread ${PTHREAD_NAMES} PATHS ${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib)
|
||||
find_library(PTHREAD_LIBRARY NAMES pthread ${PTHREAD_NAMES} PATHS ${PROJECT_SOURCE_DIR}/dependencies/lib)
|
||||
mark_as_advanced(PTHREAD_LIBRARY)
|
||||
|
||||
# Set data dir (absolute or relative to CMAKE_INSTALL_PREFIX)
|
||||
@@ -392,10 +302,8 @@ else()
|
||||
endif()
|
||||
|
||||
# CURL
|
||||
if(MSVC)
|
||||
target_link_libraries(supertuxkart ${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib/libcurl.lib)
|
||||
elseif(MINGW)
|
||||
target_link_libraries(supertuxkart ${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib/libcurldll.a)
|
||||
if(WIN32)
|
||||
target_link_libraries(supertuxkart ${PROJECT_SOURCE_DIR}/dependencies/lib/libcurldll.a)
|
||||
else()
|
||||
find_package(CURL REQUIRED)
|
||||
include_directories(${CURL_INCLUDE_DIRS})
|
||||
@@ -407,28 +315,21 @@ target_link_libraries(supertuxkart
|
||||
bulletcollision
|
||||
bulletmath
|
||||
enet
|
||||
glew
|
||||
stkirrlicht
|
||||
${Angelscript_LIBRARIES}
|
||||
${CURL_LIBRARIES}
|
||||
${OGGVORBIS_LIBRARIES}
|
||||
${OPENAL_LIBRARY}
|
||||
${FREETYPE_LIBRARIES}
|
||||
${JPEG_LIBRARIES}
|
||||
${TURBOJPEG_LIBRARY}
|
||||
#${VPX_LIBRARIES}
|
||||
${OPENGL_LIBRARIES}
|
||||
)
|
||||
|
||||
if(NOT SERVER_ONLY)
|
||||
if(NOT USE_GLES2)
|
||||
target_link_libraries(supertuxkart ${OPENGL_gl_LIBRARY} glew graphics_utils)
|
||||
else()
|
||||
target_link_libraries(supertuxkart GLESv2)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
if(USE_LIBBFD)
|
||||
target_link_libraries(supertuxkart ${LIBBFD_LIBRARIES})
|
||||
target_link_libraries(supertuxkart ${X11_LIBRARIES})
|
||||
if(USE_XRANDR)
|
||||
target_link_libraries(supertuxkart ${XRANDR_LIBRARIES})
|
||||
else()
|
||||
target_link_libraries(supertuxkart ${IRRLICHT_XF86VM_LIBRARY})
|
||||
endif()
|
||||
if(USE_ASAN)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address -fno-omit-frame-pointer")
|
||||
@@ -436,21 +337,12 @@ if(UNIX AND NOT APPLE)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(BUILD_RECORDER)
|
||||
target_link_libraries(supertuxkart ${OPENGLRECORDER_LIBRARY})
|
||||
endif()
|
||||
|
||||
# FreeBSD does not search in /usr/local/lib, but at least Freetype is installed there :(
|
||||
if(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD")
|
||||
SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -L/usr/local/lib")
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
||||
# In theory it would be cleaner to let CMake detect the right dependencies. In practice, this means that if a OSX user has
|
||||
# unix-style installs of Vorbis/Ogg/OpenAL/etc. they will be picked up over our frameworks. This is blocking when I make releases :
|
||||
# the mac I use to make STK releases does have other installs of vorbis/ogg/etc. which aren't compatible with STK, so letting
|
||||
# CMake pick the library it wants essentially means I can't build.
|
||||
set_target_properties(supertuxkart PROPERTIES LINK_FLAGS "-arch x86_64 -F/Library/Frameworks -framework OpenAL -framework Ogg -framework Vorbis")
|
||||
set_target_properties(supertuxkart PROPERTIES LINK_FLAGS "-arch i386 -F/Library/Frameworks -framework OpenAL -framework Ogg -framework Vorbis")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -I/Library/Frameworks/OpenAL.framework/Versions/A/Headers")
|
||||
endif()
|
||||
|
||||
@@ -470,7 +362,7 @@ if(USE_WIIUSE)
|
||||
if(WIIUSE_BUILD)
|
||||
target_link_libraries(supertuxkart wiiuse)
|
||||
else()
|
||||
target_link_libraries(supertuxkart ${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib/wiiuse.lib)
|
||||
target_link_libraries(supertuxkart ${PROJECT_SOURCE_DIR}/dependencies/lib/wiiuse.lib)
|
||||
endif()
|
||||
else()
|
||||
target_link_libraries(supertuxkart wiiuse bluetooth)
|
||||
@@ -483,13 +375,13 @@ if(MSVC OR MINGW)
|
||||
target_link_libraries(supertuxkart iphlpapi.lib)
|
||||
add_custom_command(TARGET supertuxkart POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory
|
||||
"${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/dll"
|
||||
"${PROJECT_SOURCE_DIR}/dependencies/dll"
|
||||
$<TARGET_FILE_DIR:supertuxkart>)
|
||||
add_custom_target(stkshaders SOURCES ${STK_SHADERS})
|
||||
endif()
|
||||
|
||||
if(MINGW)
|
||||
find_library(LIBGCC NAMES "libgcc_s_dw2-1.dll" "libgcc_s_sjlj-1.dll" "libgcc_s_seh-1.dll" PATHS ${CMAKE_FIND_ROOT_PATH})
|
||||
find_library(LIBGCC NAMES "libgcc_s_dw2-1.dll" "libgcc_s_sjlj-1.dll" PATHS ${CMAKE_FIND_ROOT_PATH})
|
||||
if(LIBGCC)
|
||||
file(COPY ${LIBGCC} DESTINATION ${CMAKE_BINARY_DIR}/bin/)
|
||||
endif()
|
||||
@@ -497,12 +389,37 @@ if(MINGW)
|
||||
if(LIBSTDCPP)
|
||||
file(COPY ${LIBSTDCPP} DESTINATION ${CMAKE_BINARY_DIR}/bin/)
|
||||
endif()
|
||||
find_library(LIBOPENMP NAMES "libgomp-1.dll" PATHS ${CMAKE_FIND_ROOT_PATH})
|
||||
if(LIBOPENMP)
|
||||
file(COPY ${LIBOPENMP} DESTINATION ${CMAKE_BINARY_DIR}/bin/)
|
||||
endif()
|
||||
find_library(LIBPTHREAD NAMES "winpthread-1.dll" "libwinpthread-1.dll" "pthreadGC2.dll" PATHS ${CMAKE_FIND_ROOT_PATH})
|
||||
if(LIBPTHREAD)
|
||||
file(COPY ${LIBPTHREAD} DESTINATION ${CMAKE_BINARY_DIR}/bin/)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Optional tools
|
||||
add_subdirectory(tools/font_tool)
|
||||
|
||||
|
||||
# ==== Make dist target ====
|
||||
if(MSVC OR MINGW)
|
||||
# Don't create a dist target for VS
|
||||
else()
|
||||
add_custom_target(dist
|
||||
COMMAND rm -rf ${CMAKE_BINARY_DIR}/SuperTuxKart-${PROJECT_VERSION} && rm -f ${CMAKE_BINARY_DIR}/SuperTuxKart-${PROJECT_VERSION}.tar.bz2
|
||||
&& echo "Exporting..."
|
||||
&& svn export ${PROJECT_SOURCE_DIR} ${CMAKE_BINARY_DIR}/SuperTuxKart-${PROJECT_VERSION}
|
||||
&& echo "Compressing..."
|
||||
&& cd ${CMAKE_BINARY_DIR}
|
||||
&& tar -cjf ${CMAKE_BINARY_DIR}/SuperTuxKart-${PROJECT_VERSION}.tar.bz2 ./SuperTuxKart-${PROJECT_VERSION}
|
||||
&& echo "Done, cleaning up"
|
||||
&& rm -rf ${CMAKE_BINARY_DIR}/SuperTuxKart-${PROJECT_VERSION}
|
||||
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
|
||||
)
|
||||
endif()
|
||||
|
||||
|
||||
# ==== Checking if data folder exists ====
|
||||
if(NOT IS_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/data)
|
||||
@@ -540,9 +457,9 @@ if(STK_ASSETS_DIR AND CHECK_ASSETS)
|
||||
install(DIRECTORY ${STK_ASSETS_DIR} DESTINATION ${STK_INSTALL_DATA_DIR}/data PATTERN ".svn" EXCLUDE PATTERN ".git" EXCLUDE)
|
||||
endif()
|
||||
install(FILES ${STK_DATA_DIR}/supertuxkart.desktop DESTINATION share/applications)
|
||||
install(FILES data/supertuxkart_48.png DESTINATION share/icons/hicolor/48x48/apps RENAME supertuxkart.png)
|
||||
install(FILES data/supertuxkart_32.png DESTINATION share/icons/hicolor/32x32/apps RENAME supertuxkart.png)
|
||||
install(FILES data/supertuxkart_128.png DESTINATION share/icons/hicolor/128x128/apps RENAME supertuxkart.png)
|
||||
install(FILES data/supertuxkart_48.png DESTINATION share/pixmaps RENAME supertuxkart.png)
|
||||
install(FILES data/supertuxkart_32.png data/supertuxkart_128.png DESTINATION share/pixmaps)
|
||||
install(FILES data/supertuxkart.appdata.xml DESTINATION share/appdata)
|
||||
|
||||
if(MINGW)
|
||||
|
||||
2
COPYING
@@ -12,7 +12,7 @@ GNU GENERAL PUBLIC LICENSE
|
||||
|
||||
Version 3, 29 June 2007
|
||||
|
||||
Copyright (c) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||
Copyright © 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||
|
||||
Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.
|
||||
|
||||
|
||||
74
INSTALL.md
Normal file
@@ -0,0 +1,74 @@
|
||||
#SuperTuxKart Installation Instructions
|
||||
|
||||
Note : If you obtained this source code from github, you also need to download the game assets from sourceforge using SVN.
|
||||
|
||||
`svn checkout https://svn.code.sf.net/p/supertuxkart/code/stk-assets stk-assets`
|
||||
|
||||
Place the `stk-assets` folder next to the source root `stk-code` folder.
|
||||
See <http://supertuxkart.sourceforge.net/Source_control> for more information
|
||||
|
||||
|
||||
##Building STK on Linux
|
||||
|
||||
First, make sure that you have the following packages installed:
|
||||
|
||||
* OpenGL (mesa)
|
||||
* OpenAL (recommended: openal-soft-devel)
|
||||
* Ogg (libogg-dev)
|
||||
* Vorbis (libvorbis-dev)
|
||||
* libcurl (libcurl-devel)
|
||||
* libbluetooth (bluez-devel)
|
||||
* libpng (libpng-devel)
|
||||
* zlib (zlib-devel)
|
||||
* jpeg (libjpeg-turbo-devel)
|
||||
|
||||
Ubuntu command:
|
||||
|
||||
```
|
||||
sudo apt-get install autoconf automake build-essential cmake libogg-dev libvorbis-dev libopenal-dev libxxf86vm-dev \
|
||||
libgl1-mesa-dev libglu1-mesa-dev libcurl4-openssl-dev libfribidi-dev libbluetooth-dev libxrandr-dev
|
||||
```
|
||||
|
||||
Unpack the files from the tarball like this:
|
||||
|
||||
```
|
||||
tar xzf supertuxkart-*.tar.gz
|
||||
cd supertuxkart-*
|
||||
```
|
||||
|
||||
where `*` is the version of SuperTuxkart you downloaded - eg `0.8.0`. Then:
|
||||
|
||||
|
||||
Compile SuperTuxKart:
|
||||
|
||||
```
|
||||
mkdir cmake_build
|
||||
cd cmake_build
|
||||
cmake ..
|
||||
make VERBOSE=1 -j2
|
||||
```
|
||||
|
||||
To create a debug version of STK, use:
|
||||
|
||||
`cmake .. -DCMAKE_BUILD_TYPE=Debug`
|
||||
|
||||
To test the compilation, supertuxkart can be run from the build
|
||||
directory by ./bin/supertuxkart
|
||||
|
||||
To install the file, as root execute:
|
||||
|
||||
`make install`
|
||||
|
||||
The default install location is `/usr/local`, i.e. the data files will
|
||||
be written to `/usr/local/share/games/supertuxkart`, the executable
|
||||
will be copied to `/usr/local/bin`. To change the default installation
|
||||
location, specify `CMAKE_INSTALL_PREFIX` when running cmake, e.g.:
|
||||
`cmake .. -DCMAKE_INSTALL_PREFIX=/opt/stk`
|
||||
|
||||
|
||||
##Building STK on OS X
|
||||
See <http://supertuxkart.sourceforge.net/Building_and_packaging_on_OSX>
|
||||
|
||||
|
||||
##Building STK on Windows
|
||||
See <http://supertuxkart.sourceforge.net/How_to_build_the_Windows_version>
|
||||
270
README.md
@@ -1,225 +1,67 @@
|
||||
# SuperTuxKart
|
||||
[](https://travis-ci.org/supertuxkart/stk-code)
|
||||
[](https://ci.appveyor.com/project/supertuxkart/stk-code)
|
||||
[](https://webchat.freenode.net/?channels=supertuxkart)
|
||||
#SuperTuxKart
|
||||
[](https://travis-ci.org/supertuxkart/stk-code)
|
||||
|
||||
SuperTuxKart is a free kart racing game. It focuses on fun and not on realistic kart physics. Instructions can be found on the in-game help page.
|
||||
SuperTuxKart is a free kart racing game. It is focusing on fun and
|
||||
not on realistic kart physics. Instruction can be found on the
|
||||
in-game help page.
|
||||
|
||||
The SuperTuxKart homepage can be found at <https://supertuxkart.net/>. There is also our [FAQ](https://supertuxkart.net/FAQ) and information on how get in touch with the [community](https://supertuxkart.net/Community)
|
||||
The SuperTuxKart homepage can be found at: <http://supertuxkart.sourceforge.net>
|
||||
|
||||
## Hardware Requirements
|
||||
To run SuperTuxKart, make sure that your computer's specifications are equal or higher than the following specifications:
|
||||
The official SuperTuxKart forum is at <http://supertuxkart.sourceforge.net/forum>. If you need support,
|
||||
this would be the best place to start.
|
||||
|
||||
* A graphics card capable of 3D rendering - NVIDIA GeForce 8 series and newer (GeForce 8100 or newer), AMD/ATI Radeon HD 4000 series and newer, Intel HD Graphics 3000 and newer. OpenGL >= 3.1
|
||||
* You should have a CPU that's running at 1 GHz or faster.
|
||||
Hope you enjoy the game.
|
||||
|
||||
-- The SuperTuxKart development team.
|
||||
|
||||
|
||||
##Hardware Requirements
|
||||
* You need a 3D graphics card. (NVIDIA GeForce 8xxx and higher, ATI Radeon HD 4xxx and higher or Intel HD 3000 and higher)
|
||||
* You should have a CPU that's running at 1GHz or better.
|
||||
* You'll need at least 512 MB of free VRAM (video memory).
|
||||
* Minimum disk space: 800 MB
|
||||
* Ideally, you'll want a joystick with at least 6 buttons.
|
||||
* Disk space: 400MB
|
||||
* Ideally, you want a joystick with at least 6 buttons.
|
||||
|
||||
## License
|
||||
The software is released under the GNU General Public License (GPL) which can be found in the file [`COPYING`](/COPYING) in the same directory as this file. Information about the licenses for the artwork is contained in `data/licenses`.
|
||||
|
||||
## 3D coordinates
|
||||
A reminder for those who are looking at the code and 3D models:
|
||||
##Compiling SuperTuxKart
|
||||
|
||||
SuperTuxKart: X right, Y up, Z forwards
|
||||
###Windows
|
||||
1. Install VS 2013 (or later). The free express versions work fine.
|
||||
2. Download and install a source package - either a released package or from our [git/svn repositories](http://supertuxkart.sourceforge.net/Source_control)
|
||||
3. Download the latest dependency package depdendencies_for_0.8.2.zip from [here](https://sourceforge.net/projects/supertuxkart/files/SuperTuxKart%20Dependencies/Windows/). Unzip it in the root directory, so that the dependencies directory is next to the src and data directory (if you are updating from a previous dependency package, you can delete the .dll files in the root directory, they are not needed anymore).
|
||||
4. Download cmake and install it. Then start cmake-gui and select the STK root directory as 'Where is the source code', and a new directory in the root directory (next to src, data etc) as build directory (for now I assume that this directory is called bld).
|
||||
5. Click on configure. You will be asked to create the directory (yes), then for your VS version. Make sure to select the right version (be aware of the easy to confuse version numbers: VS 2013 = version 12). Click on configure, then generate. This will create the directory 'bld', and a VS solution in that directory.
|
||||
6. In Visual Studio open the project file generated in the 'bld' folder
|
||||
7. Right click on the supertuxkart project in the solution explorer, and select "Set as StartUp Project".
|
||||
8. Select Build->Build Solution (or press F7) to compile.
|
||||
|
||||
Compilation with cygwin is not officially supported, but
|
||||
this has been done (check with the forum for details).
|
||||
|
||||
###Mac OS X
|
||||
The latest information about compilation on Mac are on our wiki:
|
||||
<http://supertuxkart.sourceforge.net/Building_and_packaging_on_OSX>
|
||||
The Xcode project file is in `/src/ide/Xcode/`, but it still
|
||||
requires that all dependencies are installed as explained on the wiki.
|
||||
|
||||
###UNIX
|
||||
See `INSTALL` for details.
|
||||
|
||||
|
||||
##License
|
||||
This software is released under the GNU General Public License (GPL) which
|
||||
can be found in the file `LICENSE` in the same directory as this file.
|
||||
Information about the licenses for artwork are contained in
|
||||
`data/licenses`.
|
||||
|
||||
|
||||
##3D coordinates
|
||||
A reminder for those looking at the code and 3d models:
|
||||
|
||||
STK : X right, Y up, Z forwards
|
||||
|
||||
Blender: X right, Y forwards, Z up
|
||||
|
||||
The export utilities perform the needed transformation, so in Blender you just work with the XY plane as ground, and things will appear fine in STK (using XZ as ground in the code, obviously).
|
||||
|
||||
## Building from source
|
||||
|
||||
In order to build SuperTuxKart from source, you'll need both the code and the assets (See <https://supertuxkart.net/Source_control> for more information):
|
||||
|
||||
```bash
|
||||
git clone https://github.com/supertuxkart/stk-code stk-code
|
||||
svn co https://svn.code.sf.net/p/supertuxkart/code/stk-assets stk-assets
|
||||
```
|
||||
|
||||
## Building SuperTuxKart on Linux
|
||||
|
||||
### Dependencies
|
||||
|
||||
To build SuperTuxKart from source, you'll need to install the following packages:
|
||||
|
||||
* OpenGL (mesa)
|
||||
* OpenAL (recommended: openal-soft-devel)
|
||||
* Ogg (libogg-dev)
|
||||
* Vorbis (libvorbis-dev)
|
||||
* Freetype (libfreetype6-dev)
|
||||
* libcurl (libcurl-devel)
|
||||
* libbluetooth (bluez-devel)
|
||||
* libpng (libpng-devel)
|
||||
* zlib (zlib-devel)
|
||||
* jpeg (libjpeg-turbo-devel)
|
||||
|
||||
Ubuntu command:
|
||||
|
||||
```bash
|
||||
sudo apt-get install build-essential cmake libbluetooth-dev \
|
||||
libcurl4-gnutls-dev libfreetype6-dev libfribidi-dev libgl1-mesa-dev \
|
||||
libjpeg-dev libogg-dev libopenal-dev libpng-dev libvorbis-dev libxrandr-dev \
|
||||
mesa-common-dev pkg-config zlib1g-dev
|
||||
```
|
||||
### In-game recorder
|
||||
|
||||
In order to build the in-game recorder for STK, you have to install
|
||||
libopenglrecorder from your distribution, or compile it yourself from [here](https://github.com/Benau/libopenglrecorder).
|
||||
Compilation instruction is explained there. If you don't need this feature, pass `-DBUILD_RECORDER=off` to cmake.
|
||||
|
||||
### Compiling
|
||||
|
||||
Run the following commands inside `stk-code` directory to compile SuperTuxKart:
|
||||
|
||||
```bash
|
||||
mkdir cmake_build
|
||||
cd cmake_build
|
||||
cmake ..
|
||||
make -j4
|
||||
```
|
||||
STK can then be run from the build directory with `bin/supertuxkart`
|
||||
|
||||
### Further options
|
||||
|
||||
To create a debug version of STK, run:
|
||||
|
||||
```bash
|
||||
cmake .. -DCMAKE_BUILD_TYPE=Debug
|
||||
```
|
||||
|
||||
You can install your build system-wide:
|
||||
|
||||
```bash
|
||||
sudo make install
|
||||
```
|
||||
|
||||
The default install location is `/usr/local`, i.e. the data files will
|
||||
be written to `/usr/local/share/games/supertuxkart`, the executable
|
||||
will be copied to `/usr/local/bin`. To change the default installation
|
||||
location, specify `CMAKE_INSTALL_PREFIX` when running cmake, e.g.:
|
||||
`cmake .. -DCMAKE_INSTALL_PREFIX=/opt/stk`
|
||||
|
||||
|
||||
|
||||
## Building SuperTuxKart on Windows
|
||||
To Build SuperTuxKart on Windows, follow these instructions:
|
||||
|
||||
1. Download and install Visual Studio from here: [Visual Studio - Download](https://www.visualstudio.com/downloads/). The free Visual Studio Community edition works fine.
|
||||
2. Download the SuperTuxKart source package from either [SuperTuxKart download area - SourceForge.net](https://sourceforge.net/projects/supertuxkart/files/SuperTuxKart/0.9.2) or [SuperTuxKart.net - Source Control](https://supertuxkart.net/Source_control), and unpack it.
|
||||
*Note: If you downloaded the source package from here: [SuperTuxKart.net - Source Control](https://supertuxkart.net/Source_control), then both `stk-code` and `stk-assets` **must** be in the same directory, otherwise the build can result in failure*
|
||||
3. Download the Windows dependencies package from either [SuperTuxKart download area: Dependecies - SourceForge.net](https://sourceforge.net/projects/supertuxkart/files/SuperTuxKart%20Dependencies/Windows/)
|
||||
or [SuperTuxKart on GitHub - Dependencies](https://github.com/supertuxkart/dependencies), and unpack it; then, copy the `dependencies` directory from either the `windows` or the `windows_64bit` directories into the `stk-code` directory, rename it to `dependencies-64bit` if you want to compile a 64bit build.
|
||||
4. Download CMake from here: [CMake - download page](https://cmake.org/download/), install it; once CMake is installed, double click on the CMake icon on your desktop, and point it towards your `stk-code` directory in the 'Where is the source code' field, and point it to a directory called `build` or `bld` inside the stk-code directory.
|
||||
5. Press 'Configure'; CMake will ask you if it is OK to create the aformentioned directory, press `Yes`. CMake will then ask you about your version of Visual Studio.
|
||||
Confirm your selection; *Please look at the table below to avoid confusion between version numbers and releases of Visual Studio*;
|
||||
CMake will begin creating the required files for the build in the directory.
|
||||
6. Navigate to your build directory and open the `SuperTuxKart.sln` file; Visual Studio will now load the solution.
|
||||
7. In the 'Solution Explorer', right click on the `supertuxkart` project and select "Set as StartUp project"
|
||||
8. Open the 'Build' menu and select 'Build Solution'; or, press the default keyboard shortcut: `CTRL + SHIFT + B` to build the solution.
|
||||
|
||||
*Note: To avoid confusion between releases and versions, refer to this table:*
|
||||
|
||||
Visual Studio Release | Version
|
||||
----------------------|------------
|
||||
Visual Studio 2017| 15
|
||||
Visual Studio 2015| 14
|
||||
Visual Studio 2013| 13
|
||||
|
||||
## Building SuperTuxKart on Windows (from PowerShell/Command line)
|
||||
1. Download and install Visual Studio from here: [Visual Studio - Download](https://www.visualstudio.com/downloads/), the free Visual Studio Community edition works fine.
|
||||
|
||||
2. Download a source package from either [SuperTuxKart 0.9.2 download area - SourceForge.net](https://sourceforge.net/projects/supertuxkart/files/SuperTuxKart/0.9.2) or [SuperTuxKart.net - Source Control](https://supertuxkart.net/Source_control)
|
||||
NOTE: the `stk-code` and `stk-assets` directories **must** be in the same directory
|
||||
3. Download the Windows dependencies package from either [SuperTuxKart download area - SourceForge.net](https://sourceforge.net/projects/supertuxkart/files/SuperTuxKart%20Dependencies/Windows/)
|
||||
or [SuperTuxKart on GitHub - Dependencies](https://github.com/supertuxkart/dependencies)
|
||||
and unpack the archive; once unpacked, copy the `dependencies` directory from either the `windows` or the `windows_64bit` directories into the `stk-code` directory
|
||||
4. Download CMake from here: [CMake - download page](https://cmake.org/download/); and install it. Navigate to the `stk-code` directory; and create an directory called "build":
|
||||
```cmd
|
||||
mkdir build
|
||||
cd build
|
||||
```
|
||||
5. Once inside the build directory; run CMake to start the compilation process:
|
||||
```cmd
|
||||
cmake ..
|
||||
```
|
||||
6. Now that CMake finished configuring and creating the necessary files for the build, run the build command in the same directory:
|
||||
```cmd
|
||||
msbuild.exe SuperTuxKart.sln
|
||||
```
|
||||
SuperTuxKart can now be run as `bin\Debug\supertuxkart.exe` or `bin\Release\supertuxkart.exe`
|
||||
|
||||
## Building SuperTuxKart on macOS
|
||||
|
||||
### Getting Started
|
||||
|
||||
Install the developer tools, either from the OS X Install DVD or from Apple's website.
|
||||
|
||||
If you have never built anything before, you have create `/usr/local/include/` first:
|
||||
|
||||
```bash
|
||||
sudo mkdir -p /usr/local/include/
|
||||
```
|
||||
|
||||
Symlink the `include`-folder of OpenGL framework to `/usr/local/include/GL` (Unix programs have an easier time finding it this way):
|
||||
|
||||
```bash
|
||||
sudo ln -s /System/Library/Frameworks/OpenGL.framework/Versions/A/Headers/ /usr/local/include/GL
|
||||
```
|
||||
|
||||
On OS X 10.9.5, you might need the following workaround:
|
||||
|
||||
```bash
|
||||
sudo ln -s `xcrun --show-sdk-path`/usr/include/ /usr/include
|
||||
sudo ln -s `xcrun --show-sdk-path`/System/Library/Frameworks/OpenGL.framework/Headers/ /usr/local/include/OpenGL
|
||||
```
|
||||
|
||||
The first link is required in order to find libcurl, the second to find opengl.
|
||||
|
||||
Download pre-built dependencies from [here](https://sourceforge.net/projects/supertuxkart/files/SuperTuxKart%20Dependencies/OSX/) and put the frameworks in [hard disk root]/Library/Frameworks
|
||||
|
||||
### CMake
|
||||
|
||||
CMake is used to build STK. At this time CMake will not make a binary that is ready for distribution.
|
||||
|
||||
You'll have to run these commands inside your stk-code directory.
|
||||
|
||||
### Building
|
||||
|
||||
With clang:
|
||||
|
||||
```bash
|
||||
mkdir cmake_build
|
||||
cd cmake_build
|
||||
cmake ..
|
||||
make
|
||||
```
|
||||
|
||||
With GCC:
|
||||
```bash
|
||||
mkdir cmake_build
|
||||
cd cmake_build
|
||||
cmake .. -DCMAKE_CXX_COMPILER=/usr/bin/g++ -DCMAKE_C_COMPILER=/usr/bin/gcc
|
||||
make
|
||||
```
|
||||
|
||||
Building on 10.10 with 10.9 compatibility:
|
||||
```bash
|
||||
cmake .. -DCMAKE_OSX_SYSROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk -DCMAKE_OSX_DEPLOYMENT_TARGET=10.9
|
||||
```
|
||||
|
||||
### Xcode
|
||||
|
||||
Place an additional copy of the dependencies into `Users/<YOUR_USERNAME>/Library/Frameworks`.
|
||||
Then cd to your cloned stk-code directory and execute the following commands:
|
||||
|
||||
```bash
|
||||
mkdir xcode_build && cd xcode_build
|
||||
cmake .. -GXcode
|
||||
```
|
||||
|
||||
Use Finder to navigate to your stk-code/xcode_build folder and open the newly generated Xcode project (`SuperTuxKart.xcodeproj`).
|
||||
|
||||
You can then build the project in Xcode using Product -> Build
|
||||
|
||||
Note: Xcode is much less well tested than makefiles, so there may be issues when trying to use Xcode.
|
||||
The exporters perform the needed transform, so in Blender you just work
|
||||
with XY plane as ground, and things will appear fine in STK (using XZ
|
||||
as ground in the code, obviously).
|
||||
|
||||
34
SVN-CONFIG
Normal file
@@ -0,0 +1,34 @@
|
||||
# Please, make sure your SVN client uses something that matches the
|
||||
# following config. Specially the autoprops part, that way new files
|
||||
# will be added with the right settings. Default config for command line
|
||||
# svn is in ~/.subversion/config. If you use SVN for multiple projects
|
||||
# simultaneously, remember you can use different configs, at least in
|
||||
# cmd line (via --config-dir and for example ~/.subversion/supertuxkart/
|
||||
# with a new config file inside).
|
||||
|
||||
[miscellany]
|
||||
global-ignores = *.o *.lo *.la #*# .*.rej *.rej .*~ *~ .#* ._* .DS_Store *.blend1 *.blend2
|
||||
enable-auto-props = yes
|
||||
|
||||
[auto-props]
|
||||
*.c = svn:eol-style=native;svn:keywords=Author Date Id Revision
|
||||
*.cpp = svn:eol-style=native;svn:keywords=Author Date Id Revision
|
||||
*.h = svn:eol-style=native;svn:keywords=Author Date Id Revision
|
||||
*.hpp = svn:eol-style=native;svn:keywords=Author Date Id Revision
|
||||
*.dsp = svn:eol-style=CRLF
|
||||
*.dsw = svn:eol-style=CRLF
|
||||
*.sh = svn:eol-style=native;svn:executable;svn:keywords=Author Date Id Revision
|
||||
*.txt = svn:eol-style=native
|
||||
*.png = svn:mime-type=image/png
|
||||
*.jpg = svn:mime-type=image/jpeg
|
||||
Makefile = svn:eol-style=native;svn:keywords=Author Date Id Revision
|
||||
*.jpeg = svn:mime-type=image/jpeg
|
||||
*.gif = svn:mime-type=image/gif
|
||||
*.svg = svn:mime-type=image/svg+xml
|
||||
*.htm = svn:mime-type=text/html
|
||||
*.html = svn:mime-type=text/html
|
||||
*.css = svn:mime-type=text/css
|
||||
*.pdf = svn:mime-type=application/pdf
|
||||
SConstruct = svn:eol-style=native;svn:keywords=Author Date Id Revision
|
||||
*.xml = svn:eol-style=LF;svn:mime-type=text/xml
|
||||
*.py = svn:eol-style=native;svn:keywords=Author Date Id Revision
|
||||
33
TODO.md
Normal file
@@ -0,0 +1,33 @@
|
||||
##TODO
|
||||
|
||||
SuperTuxKart is looking for additional man power to make this
|
||||
one of the best free linux games out there :) We need (in
|
||||
no particular order):
|
||||
|
||||
1. Musicians/sound engineers
|
||||
- Create additional background soundtrack
|
||||
- Create sound effects
|
||||
2. Artists and track designer
|
||||
- Create additional tracks
|
||||
- Create additional art work for tracks,
|
||||
background images
|
||||
3. Developers
|
||||
- Check our bug and enhancement request tracker on
|
||||
https://github.com/supertuxkart/stk-code/issues
|
||||
- Extend the current web page, keep it up to date
|
||||
4. Tester
|
||||
- For just about everything
|
||||
- Esp. different platforms and graphics cards
|
||||
5. Writers
|
||||
- Write documentation, ranging from man page, to
|
||||
a description for the web, to a design document, ...
|
||||
|
||||
If you want to help the SuperTuxKart - Project, please
|
||||
contact us on the email list: [supertuxkart-devel@lists.sourceforge.net](mailto:supertuxkart-devel@lists.sourceforge.net)
|
||||
|
||||
Thanks in advance!
|
||||
|
||||
-- The SuperTuxKart-Team
|
||||
|
||||
|
||||
For details, see <http://supertuxkart.sourceforge.net/Get_involved>
|
||||
@@ -1,174 +0,0 @@
|
||||
LOCAL_PATH := $(call my-dir)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# OpenAL
|
||||
LOCAL_MODULE := openal
|
||||
LOCAL_SRC_FILES := obj/openal/libopenal.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# OGG
|
||||
LOCAL_MODULE := ogg
|
||||
LOCAL_SRC_FILES := obj/libogg/src/.libs/libogg.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# Vorbis
|
||||
LOCAL_MODULE := vorbis
|
||||
LOCAL_SRC_FILES := obj/libvorbis/lib/.libs/libvorbis.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# Vorbisfile
|
||||
LOCAL_MODULE := vorbisfile
|
||||
LOCAL_SRC_FILES := obj/libvorbis/lib/.libs/libvorbisfile.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# CURL
|
||||
LOCAL_MODULE := curl
|
||||
LOCAL_SRC_FILES := obj/curl/lib/.libs/libcurl.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# libcrypto
|
||||
LOCAL_MODULE := libcrypto
|
||||
LOCAL_SRC_FILES := obj/openssl/libcrypto.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# libssl
|
||||
LOCAL_MODULE := libssl
|
||||
LOCAL_SRC_FILES := obj/openssl/libssl.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# JPEG
|
||||
LOCAL_MODULE := jpeglib
|
||||
LOCAL_SRC_FILES := obj/jpeglib/libjpeglib.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# Freetype
|
||||
LOCAL_MODULE := freetype
|
||||
LOCAL_SRC_FILES := obj/freetype/objs/.libs/libfreetype.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# zlib
|
||||
LOCAL_MODULE := zlib
|
||||
LOCAL_SRC_FILES := obj/zlib/libz.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# PNG
|
||||
LOCAL_MODULE := png
|
||||
LOCAL_SRC_FILES := obj/libpng/libpng.a
|
||||
include $(PREBUILT_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# ifaddrs
|
||||
LOCAL_MODULE := ifaddrs
|
||||
LOCAL_PATH := .
|
||||
LOCAL_SRC_FILES := ../lib/ifaddrs/ifaddrs.c
|
||||
LOCAL_CFLAGS := -I../lib/ifaddrs
|
||||
include $(BUILD_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# AngelScript
|
||||
LOCAL_MODULE := angelscript
|
||||
LOCAL_PATH := .
|
||||
LOCAL_CPP_FEATURES += rtti exceptions
|
||||
LOCAL_SRC_FILES := $(wildcard ../lib/angelscript/source/*.S) \
|
||||
$(wildcard ../lib/angelscript/source/*.cpp)
|
||||
LOCAL_CFLAGS := -I../lib/angelscript/source/
|
||||
include $(BUILD_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# ENET
|
||||
LOCAL_MODULE := enet
|
||||
LOCAL_PATH := .
|
||||
LOCAL_CPP_FEATURES += rtti
|
||||
LOCAL_SRC_FILES := $(wildcard ../lib/enet/*.c)
|
||||
LOCAL_CFLAGS := -I../lib/enet/include/ -DHAS_SOCKLEN_T
|
||||
include $(BUILD_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# Bullet
|
||||
LOCAL_MODULE := bullet
|
||||
LOCAL_PATH := .
|
||||
LOCAL_CPP_FEATURES += rtti
|
||||
LOCAL_SRC_FILES := $(wildcard ../lib/bullet/src/*/*.cpp) \
|
||||
$(wildcard ../lib/bullet/src/*/*/*.cpp)
|
||||
LOCAL_CFLAGS := -I../lib/bullet/src/
|
||||
include $(BUILD_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# Irrlicht
|
||||
LOCAL_MODULE := irrlicht
|
||||
LOCAL_PATH := .
|
||||
LOCAL_CPP_FEATURES += rtti
|
||||
LOCAL_SRC_FILES := $(wildcard ../lib/irrlicht/source/Irrlicht/*.cpp) \
|
||||
$(wildcard ../lib/irrlicht/source/Irrlicht/Android/*.cpp)
|
||||
LOCAL_CFLAGS := -I../lib/irrlicht/source/Irrlicht/ \
|
||||
-I../lib/irrlicht/include/ \
|
||||
-Iobj/jpeglib/ \
|
||||
-Iobj/libpng/ \
|
||||
-Iobj/zlib/ \
|
||||
-I$(call my-dir)/../../sources/android/native_app_glue
|
||||
-std=gnu++0x
|
||||
LOCAL_STATIC_LIBRARIES := jpeglib png zlib
|
||||
include $(BUILD_STATIC_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
# STK
|
||||
LOCAL_MODULE := main
|
||||
LOCAL_PATH := .
|
||||
LOCAL_CPP_FEATURES += rtti exceptions
|
||||
LOCAL_SRC_FILES := $(wildcard ../src/*.cpp) \
|
||||
$(wildcard ../src/*/*.cpp) \
|
||||
$(wildcard ../src/*/*/*.cpp)
|
||||
LOCAL_LDLIBS := -llog -landroid -lEGL -lGLESv3 -lOpenSLES
|
||||
LOCAL_CFLAGS := -I../lib/angelscript/include \
|
||||
-I../lib/bullet/src \
|
||||
-I../lib/enet/include \
|
||||
-I../lib/ifaddrs \
|
||||
-I../lib/irrlicht/include \
|
||||
-I../lib/irrlicht/source/Irrlicht \
|
||||
-I../src \
|
||||
-Iobj/curl/include \
|
||||
-Iobj/freetype/include \
|
||||
-Iobj/libogg/include \
|
||||
-Iobj/libvorbis/include \
|
||||
-Iobj/openal/include \
|
||||
-I$(call my-dir)/../../sources/android/native_app_glue \
|
||||
-DUSE_GLES2 \
|
||||
-DHAVE_OGGVORBIS \
|
||||
-DNDEBUG \
|
||||
-std=gnu++0x
|
||||
|
||||
LOCAL_STATIC_LIBRARIES := irrlicht bullet enet freetype ifaddrs angelscript \
|
||||
vorbisfile vorbis ogg openal curl libssl libcrypto \
|
||||
gnustl_static android_native_app_glue
|
||||
|
||||
include $(BUILD_SHARED_LIBRARY)
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
$(call import-module,android/native_app_glue)
|
||||
@@ -1,38 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="org.supertuxkart.stk"
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0"
|
||||
android:installLocation="auto">
|
||||
|
||||
<!-- This .apk has no Java code itself, so set hasCode to false. -->
|
||||
<application android:label="@string/app_name"
|
||||
android:icon="@drawable/icon"
|
||||
android:hasCode="false"
|
||||
android:theme="@android:style/Theme.NoTitleBar.Fullscreen"
|
||||
android:hardwareAccelerated="true">
|
||||
|
||||
<activity android:name="android.app.NativeActivity"
|
||||
android:label="@string/app_name"
|
||||
android:configChanges="fontScale|keyboard|keyboardHidden|layoutDirection|locale|mcc|mnc|navigation|orientation|screenLayout|screenSize|uiMode"
|
||||
android:screenOrientation="sensorLandscape">
|
||||
|
||||
<!-- Tell NativeActivity the name of or .so -->
|
||||
<meta-data android:name="android.app.lib_name"
|
||||
android:value="main" />
|
||||
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
</application>
|
||||
|
||||
<uses-sdk android:minSdkVersion="19" />
|
||||
<uses-feature android:glEsVersion="0x00020000" />
|
||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
||||
<uses-permission android:name="android.permission.READ_MEDIA_STORAGE" />
|
||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
||||
<uses-permission android:name="android.permission.WRITE_MEDIA_STORAGE" />
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
</manifest>
|
||||
@@ -1,180 +0,0 @@
|
||||
================================================================================
|
||||
|
||||
SUPERTUXKART
|
||||
|
||||
================================================================================
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
SYSTEM REQUIREMENTS
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
To run SuperTuxKart on Android, you need a device that meets following
|
||||
requirements:
|
||||
|
||||
- Android 4.4 or later
|
||||
- Processor compatible with armv7 or x86
|
||||
- GPU that supports OpenGL ES 3.0
|
||||
- 1 GB RAM (STK uses ~150 MB in minimal configuration)
|
||||
- 300 MB of free space on internal storage
|
||||
- Touch screen or external keyboard
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
COMPILATION
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
The build scripts are designed to run under linux. They may work under cygwin
|
||||
after some tweaks, but atm. only linux is supported.
|
||||
|
||||
Dependencies list (may be incomplete):
|
||||
|
||||
autoconf, automake, make, python, gradle, ant, imagemagick, cmake,
|
||||
vorbis-tools
|
||||
|
||||
Additionally some dependencies for optimize_data script:
|
||||
|
||||
advancecomp, libjpeg-progs, optipng
|
||||
|
||||
Before compilation you must download the package with dependencies from:
|
||||
https://github.com/supertuxkart/dependencies
|
||||
and extract it to stk-code/lib. It contains sources of libraries that are used
|
||||
in STK, but are not availiable in stk-code repository (curl, freetype, openal).
|
||||
|
||||
You need also Android SDK for android-19 platform (the API for Android 4.4) and
|
||||
Android NDK. Note that NDK >= r15b is atm. not supported. Version r12b is
|
||||
strongly recommended, because it's known that it works without issues.
|
||||
|
||||
You need to create proper "android-sdk" and "android-ndk" symlinks in the
|
||||
directory with Android project, so that the compilation script will have access
|
||||
to the SDK and NDK. These paths can be also set in SDK_PATH and NDK_PATH
|
||||
environmental variables.
|
||||
|
||||
Before running the compilation, run the generate_assets script, so that
|
||||
selected assets will be copied to "assets" directory, and then included in the
|
||||
apk file.
|
||||
|
||||
You can select different karts and tracks by setting KARTS and TRACKS variables
|
||||
in the generate_assets.sh script at the beginning of file.
|
||||
|
||||
When you are creating the assets directory manually, note that the
|
||||
directories.txt file is urgently needed and it is used by the application for
|
||||
extracting assets.
|
||||
|
||||
If the assets directory is already prepared, you can run "./make.sh" command to
|
||||
build the project and create an apk file. Note that all arguments are passed to
|
||||
the make command, so that you can run "./make.sh -j5" for multi-threaded build.
|
||||
|
||||
If you want to prepare a package for particular architecture, you can choose it
|
||||
by setting the COMPILE_ARCH environmental variable. At this stage, supported
|
||||
architectures are "armv7", "x86" and "aarch64". The default is "armv7".
|
||||
|
||||
You can choose build type by setting BUILD_TYPE environment variable to "debug"
|
||||
or "release". The default is debug build. Note that if you choose release build,
|
||||
you have to manually sign the apk with your key and run zipalign.
|
||||
|
||||
Additionally you can choose the build tool by setting BUILD_TOOL environment
|
||||
variable to "gradle" or "ant". Note that ant has been already removed from
|
||||
Android SDK, so you have to use SDK <= 25.2.5 for building with ant. By default
|
||||
the BUILD_TOOL is set to "gradle".
|
||||
|
||||
You can override the SDK build-tools version by setting the BUILD_TOOLS_VER
|
||||
environment variable.
|
||||
|
||||
Basically if all dependencies are installed in the system, it should be enough
|
||||
to just run:
|
||||
|
||||
export SDK_PATH=/path/to/your/android/sdk
|
||||
export NDK_PATH=/path/to/your/android/ndk
|
||||
./generate_assets.sh
|
||||
./make.sh -j5
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
RELEASE BUILD
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
Making a release build is similar to typical compilation, but there are few
|
||||
additional things to do.
|
||||
|
||||
You have to change version numbers. This is important, because assets manager
|
||||
in STK checks these numbers and detects if already extracted data files are
|
||||
up to date. So that when you will install new STK version, this will force new
|
||||
data extraction automatically.
|
||||
|
||||
So that you have to:
|
||||
|
||||
1. Change "data/supertuxkart.git" to "data/supertuxkart.VERSION_NUMBER"
|
||||
|
||||
2. Open "src/utils/constants.cpp" and change:
|
||||
|
||||
const char STK_VERSION[] = "git";
|
||||
|
||||
to
|
||||
|
||||
const char STK_VERSION[] = "VERSION_NUMBER";
|
||||
|
||||
where "VERSION_NUMBER" is for example "0.9.3" or "git20170409" or whatever.
|
||||
|
||||
3. You can also update these lines in "android/AndroidManifest.xml":
|
||||
android:versionCode="1"
|
||||
android:versionName="1.0"
|
||||
|
||||
|
||||
Before compilation you have to set:
|
||||
|
||||
export BUILD_TYPE=release
|
||||
|
||||
and then you make standard compilation with:
|
||||
|
||||
./generate_assets.sh
|
||||
./make.sh -j5
|
||||
|
||||
|
||||
The compiled apk is unsigned, so you have to sign it with your key. To sign it,
|
||||
you have to run:
|
||||
|
||||
jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore \
|
||||
my-release-key.keystore SuperTuxKart-release-unsigned.apk alias_name
|
||||
|
||||
and then:
|
||||
|
||||
zipalign -v 4 SuperTuxKart-release-unsigned.apk SuperTuxKart-release.apk
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
KNOWN ISSUES
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
1. It's not possible to compile STK for Android < 4.4 due to missing GLES 3.0
|
||||
functions. It is technically possible to do - check GLES context version,
|
||||
load OpenGL functions dynamically using EGL, and if they are not loaded
|
||||
properly, then fallback to GLES 2.0.
|
||||
|
||||
2. It never ocurred for me, but it's possible that EGL context is lost in some
|
||||
cases. SuperTuxKart is not designed to re-create all textures at any moment,
|
||||
so this is a "Wontfix", at least for now.
|
||||
|
||||
3. We use "exit(0)" at the end of main function. We shouldn't do it and we
|
||||
should just return from the main function. But STK uses some global
|
||||
variables and their values are remembered when the game is restarted. We
|
||||
should properly clear them or re-initialize on startup. Using the "exit(0)"
|
||||
is not-that-bad workaround, but it may cause a crash on exit sometimes.
|
||||
It seems to affect only Android 5.0. More information about the crash:
|
||||
https://code.google.com/p/android/issues/detail?id=160824
|
||||
|
||||
4. STK crashes on startup on some devices when aarch64 build is made using
|
||||
Android r13 NDK. The r13 version has rather big modifications (it uses clang
|
||||
instead of gcc by default). This is probably a bug in NDK/compiler/OS, but
|
||||
for this reason using NDK r12 for 64-bit arm compilation is preferred.
|
||||
|
||||
5. Angelscript doesn't have full support for aarch64 builds, so that scripting
|
||||
won't work on this platform.
|
||||
|
||||
6. Turning left/right using accelerometer is available, but at this stage the
|
||||
default screen orientation is not automatically detected and user must
|
||||
manually choose if he needs "phone" or "tablet" accelerometer.
|
||||
@@ -1,31 +0,0 @@
|
||||
buildscript
|
||||
{
|
||||
repositories
|
||||
{
|
||||
jcenter()
|
||||
}
|
||||
|
||||
dependencies
|
||||
{
|
||||
classpath 'com.android.tools.build:gradle:2.2.3'
|
||||
}
|
||||
}
|
||||
|
||||
apply plugin: 'com.android.application'
|
||||
|
||||
android
|
||||
{
|
||||
compileSdkVersion sdk_version.toInteger()
|
||||
buildToolsVersion build_tools_ver
|
||||
|
||||
sourceSets
|
||||
{
|
||||
main
|
||||
{
|
||||
manifest.srcFile 'AndroidManifest.xml'
|
||||
jniLibs.srcDirs = ['libs']
|
||||
res.srcDirs = ['res']
|
||||
assets.srcDirs = ['assets']
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project name="SuperTuxKart" default="help">
|
||||
|
||||
<import file="${sdk.dir}/tools/ant/build.xml" />
|
||||
|
||||
</project>
|
||||
@@ -1,598 +0,0 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# (C) 2016-2017 Dawid Gan, under the GPLv3
|
||||
#
|
||||
# A script that generates data files for Android apk
|
||||
|
||||
|
||||
# Below you can find some simple configuration variables.
|
||||
# It's allowed to set "all" for KARTS and TRACKS if it's intended to create
|
||||
# package with full data.
|
||||
# The karts and tracks directories shouldn't exist in ASSETS_DIRS variable
|
||||
# because they are handled separately.
|
||||
# The TEXTURE_SIZE and SOUND_QUALITY take effect only if DECREASE_QUALITY has
|
||||
# value greater than 0.
|
||||
# The CONVERT_TO_JPG variable enables converting all images that are safe to
|
||||
# convert and keeps other images untouched.
|
||||
# The script needs imagemagick and ogg utils installed to use DECREASE_QUALITY
|
||||
# feature
|
||||
|
||||
################################################################################
|
||||
|
||||
export KARTS="all"
|
||||
export TRACKS="abyss battleisland cave cornfield_crossing endcutscene \
|
||||
featunlocked fortmagma gplose gpwin hacienda icy_soccer_field \
|
||||
introcutscene introcutscene2 lighthouse mines olivermath \
|
||||
overworld sandtrack scotland snowmountain snowtuxpeak \
|
||||
soccer_field stadium tutorial zengarden"
|
||||
|
||||
export ASSETS_PATHS="../data \
|
||||
../../stk-assets \
|
||||
../../supertuxkart-assets"
|
||||
|
||||
export ASSETS_DIRS="library models music sfx textures"
|
||||
|
||||
export TEXTURE_SIZE=256
|
||||
export JPEG_QUALITY=85
|
||||
export PNG_QUALITY=95
|
||||
export SOUND_QUALITY=42
|
||||
export SOUND_MONO=1
|
||||
export SOUND_SAMPLE=32000
|
||||
|
||||
export RUN_OPTIMIZE_SCRIPT=0
|
||||
export DECREASE_QUALITY=1
|
||||
export CONVERT_TO_JPG=1
|
||||
|
||||
export CONVERT_TO_JPG_BLACKLIST="data/karts/hexley/hexley_kart_diffuse.png"
|
||||
|
||||
export BLACKLIST_FILES="data/music/cocoa_river_fast.ogg2"
|
||||
|
||||
################################################################################
|
||||
|
||||
export LANG=C
|
||||
|
||||
cd "`dirname "$0"`"
|
||||
|
||||
# Find assets path
|
||||
for ASSETS_PATH in $ASSETS_PATHS; do
|
||||
if [ -d $ASSETS_PATH ] && [ `ls $ASSETS_PATH | grep -c tracks` -gt 0 ]; then
|
||||
echo "Assets found in $ASSETS_PATH"
|
||||
ASSETS_PATH_FOUND=1
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -z $ASSETS_PATH_FOUND ]; then
|
||||
echo "Couldn't find assets path"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -d "../data" ]; then
|
||||
echo "Couldn't find data directory"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
||||
# Clear previous assets directory
|
||||
echo "Clear previous assets directory"
|
||||
rm -rf assets
|
||||
|
||||
|
||||
# Copy all assets
|
||||
echo "Copy all assets"
|
||||
|
||||
mkdir -p assets/data
|
||||
|
||||
for DIR in `ls $ASSETS_PATH`; do
|
||||
CAN_BE_COPIED=0
|
||||
|
||||
for ASSETS_DIR in $ASSETS_DIRS; do
|
||||
if [ $DIR = $ASSETS_DIR ]; then
|
||||
CAN_BE_COPIED=1
|
||||
break
|
||||
fi
|
||||
done;
|
||||
|
||||
# Don't copy karts and tracks. It will be handled later
|
||||
BLACKLIST_ASSETS="karts tracks"
|
||||
for ASSETS_DIR in $BLACKLIST_ASSETS; do
|
||||
if [ $DIR = $ASSETS_DIR ]; then
|
||||
CAN_BE_COPIED=0
|
||||
break
|
||||
fi
|
||||
done;
|
||||
|
||||
if [ $CAN_BE_COPIED -gt 0 ]; then
|
||||
cp -a "$ASSETS_PATH/$DIR" assets/data/
|
||||
fi
|
||||
done;
|
||||
|
||||
|
||||
# Copy selected tracks
|
||||
echo "Copy selected tracks"
|
||||
|
||||
mkdir -p assets/data/tracks
|
||||
|
||||
for DIR in `ls $ASSETS_PATH/tracks`; do
|
||||
CAN_BE_COPIED=0
|
||||
|
||||
if [ "$TRACKS" != "all" ]; then
|
||||
for TRACK in $TRACKS; do
|
||||
if [ $DIR = $TRACK ]; then
|
||||
CAN_BE_COPIED=1
|
||||
break
|
||||
fi
|
||||
done;
|
||||
else
|
||||
CAN_BE_COPIED=1
|
||||
fi
|
||||
|
||||
if [ $CAN_BE_COPIED -gt 0 ]; then
|
||||
cp -a "$ASSETS_PATH/tracks/$DIR" assets/data/tracks/
|
||||
fi
|
||||
done
|
||||
|
||||
|
||||
# Copy selected karts
|
||||
echo "Copy selected karts"
|
||||
|
||||
mkdir -p assets/data/karts
|
||||
|
||||
for DIR in `ls $ASSETS_PATH/karts`; do
|
||||
CAN_BE_COPIED=0
|
||||
|
||||
if [ "$KARTS" != "all" ]; then
|
||||
for KART in $KARTS; do
|
||||
if [ $DIR = $KART ]; then
|
||||
CAN_BE_COPIED=1
|
||||
break
|
||||
fi
|
||||
done;
|
||||
else
|
||||
CAN_BE_COPIED=1
|
||||
fi
|
||||
|
||||
if [ $CAN_BE_COPIED -gt 0 ]; then
|
||||
cp -a "$ASSETS_PATH/karts/$DIR" assets/data/karts/
|
||||
fi
|
||||
done
|
||||
|
||||
|
||||
# Decrease assets quality in order to save some disk space and RAM
|
||||
echo "Decrease assets quality"
|
||||
|
||||
convert_image()
|
||||
{
|
||||
FILE="$1"
|
||||
FILE_TYPE="$2"
|
||||
echo "Convert file: $FILE"
|
||||
|
||||
if [ ! -f "$FILE" ]; then
|
||||
echo " File doesn't exist."
|
||||
return
|
||||
fi
|
||||
|
||||
W=`identify -format "%[fx:w]" "$FILE"`
|
||||
H=`identify -format "%[fx:h]" "$FILE"`
|
||||
|
||||
if [ -z $W ] || [ -z $H ]; then
|
||||
echo "Couldn't convert $FILE file"
|
||||
return
|
||||
fi
|
||||
|
||||
if [ $W -gt $TEXTURE_SIZE ] || [ $H -gt $TEXTURE_SIZE ]; then
|
||||
if [ $W -gt $H ]; then
|
||||
SCALED_W=$TEXTURE_SIZE
|
||||
SCALED_H=$(($TEXTURE_SIZE * $H / $W))
|
||||
else
|
||||
SCALED_W=$(($TEXTURE_SIZE * $W / $H))
|
||||
SCALED_H=$TEXTURE_SIZE
|
||||
fi
|
||||
|
||||
SCALE_CMD="-scale ${SCALED_W}x${SCALED_H}"
|
||||
fi
|
||||
|
||||
if [ "$FILE_TYPE" = "jpg" ]; then
|
||||
QUALITY_CMD="-quality $JPEG_QUALITY"
|
||||
elif [ "$FILE_TYPE" = "png" ]; then
|
||||
QUALITY_CMD="-quality $PNG_QUALITY"
|
||||
fi
|
||||
|
||||
convert $SCALE_CMD $QUALITY_CMD "$FILE" "tmp.$FILE_TYPE"
|
||||
|
||||
if [ -s "tmp.$FILE_TYPE" ]; then
|
||||
SIZE_OLD=`du -k "$FILE" | cut -f1`
|
||||
SIZE_NEW=`du -k "tmp.$FILE_TYPE" | cut -f1`
|
||||
|
||||
if [ $SIZE_NEW -lt $SIZE_OLD ]; then
|
||||
mv "tmp.$FILE_TYPE" "$FILE"
|
||||
fi
|
||||
fi
|
||||
|
||||
rm -f "tmp.$FILE_TYPE"
|
||||
}
|
||||
|
||||
convert_sound()
|
||||
{
|
||||
FILE="$1"
|
||||
echo "Convert file: $FILE"
|
||||
|
||||
if [ ! -f "$FILE" ]; then
|
||||
echo " File doesn't exist."
|
||||
return
|
||||
fi
|
||||
|
||||
oggdec "$FILE" -o tmp.wav
|
||||
|
||||
if [ -s tmp.wav ]; then
|
||||
OGGENC_CMD=""
|
||||
|
||||
if [ "$SOUND_MONO" -gt 0 ]; then
|
||||
OGGENC_CMD="$OGGENC_CMD --downmix"
|
||||
fi
|
||||
|
||||
OGG_RATE=`ogginfo "$FILE" | grep "Rate: " | cut -f 2 -d " " \
|
||||
| grep -o '[0-9]*'`
|
||||
|
||||
if [ ! -z "$OGG_RATE" ] && [ "$OGG_RATE" -gt "$SOUND_SAMPLE" ]; then
|
||||
OGGENC_CMD="$OGGENC_CMD --resample $SOUND_SAMPLE"
|
||||
fi
|
||||
|
||||
OGGENC_CMD="$OGGENC_CMD -b $SOUND_QUALITY"
|
||||
|
||||
oggenc $OGGENC_CMD tmp.wav -o tmp.ogg
|
||||
fi
|
||||
|
||||
if [ -s tmp.ogg ]; then
|
||||
SIZE_OLD=`du -k "$FILE" | cut -f1`
|
||||
SIZE_NEW=`du -k "tmp.ogg" | cut -f1`
|
||||
|
||||
if [ $SIZE_NEW -lt $SIZE_OLD ]; then
|
||||
mv tmp.ogg "$FILE"
|
||||
fi
|
||||
fi
|
||||
|
||||
rm -f tmp.wav tmp.ogg
|
||||
}
|
||||
|
||||
convert_to_jpg()
|
||||
{
|
||||
FILE="$1"
|
||||
echo "Convert file: $FILE"
|
||||
|
||||
if [ ! -f "$FILE" ]; then
|
||||
echo " File doesn't exist."
|
||||
return
|
||||
fi
|
||||
|
||||
ALREADY_CONVERTED=0
|
||||
|
||||
if [ -s "./converted_textures" ]; then
|
||||
while read -r CONVERTED_TEXTURE; do
|
||||
if [ "$FILE" = "$CONVERTED_TEXTURE" ]; then
|
||||
ALREADY_CONVERTED=1
|
||||
break
|
||||
fi
|
||||
done < "./converted_textures"
|
||||
fi
|
||||
|
||||
if [ $ALREADY_CONVERTED -eq 1 ]; then
|
||||
return
|
||||
fi
|
||||
|
||||
BLACKLISTED=0
|
||||
|
||||
for BLACKLIST_FILE in $CONVERT_TO_JPG_BLACKLIST; do
|
||||
if [ "$FILE" = "assets/$BLACKLIST_FILE" ]; then
|
||||
BLACKLISTED=1
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if [ $BLACKLISTED -eq 1 ]; then
|
||||
#echo " File is blacklisted. Ignore..."
|
||||
continue
|
||||
fi
|
||||
|
||||
FILE_EXTENSION=`echo "$FILE" | tail -c 5`
|
||||
|
||||
if [ `echo "$FILE_EXTENSION" | head -c 1` != "." ]; then
|
||||
#echo " Unsupported file extension. Ignore..."
|
||||
continue
|
||||
fi
|
||||
|
||||
FILE_FORMAT=`identify -format %m "$FILE"`
|
||||
|
||||
if [ "$FILE_FORMAT" = "JPEG" ]; then
|
||||
#echo " File is already JPEG. Ignore..."
|
||||
continue
|
||||
fi
|
||||
|
||||
IS_OPAQUE=`identify -format '%[opaque]' "$FILE"`
|
||||
#HAS_ALPHA=`identify -format '%A' "$FILE"`
|
||||
|
||||
if [ "$IS_OPAQUE" = "False" ] || [ "$IS_OPAQUE" = "false" ]; then
|
||||
#echo " File has alpha channel. Ignore..."
|
||||
continue
|
||||
fi
|
||||
|
||||
DIRNAME="`dirname "$FILE"`"
|
||||
BASENAME="`basename "$FILE"`"
|
||||
IS_GLOSS_MAP=`find "$DIRNAME" -iname "*.xml" -exec cat {} \; \
|
||||
| grep -c "gloss-map=\"$BASENAME\""`
|
||||
|
||||
if [ $IS_GLOSS_MAP -gt 0 ]; then
|
||||
#echo " File is a gloss-map. Ignore..."
|
||||
continue
|
||||
fi
|
||||
|
||||
NEW_FILE="`echo $FILE | head -c -5`.jpg"
|
||||
|
||||
if [ -f "$NEW_FILE" ]; then
|
||||
#echo " There is already a file with .jpg extension. Ignore..."
|
||||
continue
|
||||
fi
|
||||
|
||||
# We can check if new file is smaller
|
||||
convert -quality $JPEG_QUALITY "$FILE" "$NEW_FILE"
|
||||
rm -f "$FILE"
|
||||
|
||||
echo "$FILE" >> "./converted_textures"
|
||||
}
|
||||
|
||||
convert_to_jpg_extract_b3dz()
|
||||
{
|
||||
FILE="$1"
|
||||
echo "Convert file: $FILE"
|
||||
|
||||
if [ ! -f "$FILE" ]; then
|
||||
echo " File doesn't exist."
|
||||
return
|
||||
fi
|
||||
|
||||
DIRNAME="`dirname "$FILE"`"
|
||||
|
||||
unzip "$FILE" -d "$DIRNAME"
|
||||
rm -f "$FILE"
|
||||
|
||||
TEXNAME="`basename "$FILE"`"
|
||||
NEWNAME="`echo $TEXNAME | head -c -6`.b3d"
|
||||
|
||||
sed -i "s/\"$TEXNAME\"/\"$NEWNAME\"/g" "$DIRNAME/kart.xml"
|
||||
}
|
||||
|
||||
convert_to_jpg_update_b3d()
|
||||
{
|
||||
FILE="$1"
|
||||
echo "Convert file: $FILE"
|
||||
|
||||
if [ ! -f "$1" ]; then
|
||||
echo " File doesn't exist."
|
||||
return
|
||||
fi
|
||||
|
||||
HEX_FILE=`hexdump -ve '1/1 "%.2x"' "$FILE"`
|
||||
|
||||
TEXS_CHUNK="54455853"
|
||||
TEXS_CHUNK_POS=24
|
||||
|
||||
FOUND_CHUNK=`echo $HEX_FILE | head -c $(($TEXS_CHUNK_POS + 8)) \
|
||||
| tail -c +$(($TEXS_CHUNK_POS + 1))`
|
||||
|
||||
if [ -z "$FOUND_CHUNK" ] || [ "$FOUND_CHUNK" != "$TEXS_CHUNK" ]; then
|
||||
echo " File has no textures."
|
||||
return
|
||||
fi
|
||||
|
||||
TEXS_SIZE=`echo $HEX_FILE | head -c $(($TEXS_CHUNK_POS + 16)) | tail -c 8`
|
||||
|
||||
TEXS_SIZE_CONVERTED=`echo $TEXS_SIZE | cut -c7-8`
|
||||
TEXS_SIZE_CONVERTED=$TEXS_SIZE_CONVERTED`echo $TEXS_SIZE | cut -c5-6`
|
||||
TEXS_SIZE_CONVERTED=$TEXS_SIZE_CONVERTED`echo $TEXS_SIZE | cut -c3-4`
|
||||
TEXS_SIZE_CONVERTED=$TEXS_SIZE_CONVERTED`echo $TEXS_SIZE | cut -c1-2`
|
||||
TEXS_SIZE_CONVERTED=`echo $((0x$TEXS_SIZE_CONVERTED))`
|
||||
|
||||
if [ $TEXS_SIZE_CONVERTED -le 0 ]; then
|
||||
echo " Invalid TEXS size value."
|
||||
return
|
||||
fi
|
||||
|
||||
TEXS_BEGIN=$(($TEXS_CHUNK_POS + 16))
|
||||
TEXS_END=$(($TEXS_BEGIN + $TEXS_SIZE_CONVERTED * 2))
|
||||
HEX_TEXS=`echo $HEX_FILE | head -c $TEXS_END | tail -c +$(($TEXS_BEGIN+1))`
|
||||
CURR_POS=0
|
||||
|
||||
while [ $CURR_POS -lt $TEXS_END ]; do
|
||||
NULL_POS=`echo $HEX_TEXS | tail -c +$(($CURR_POS+1)) | grep -b -o "00" \
|
||||
| head -n 1 | cut -f1 -d":"`
|
||||
|
||||
if [ -z $NULL_POS ]; then
|
||||
#echo " Done."
|
||||
break
|
||||
fi
|
||||
|
||||
if [ $NULL_POS -lt 4 ]; then
|
||||
echo " Something went wrong..."
|
||||
break
|
||||
fi
|
||||
|
||||
TEXNAME_BEGIN=$((($TEXS_BEGIN + $CURR_POS) / 2))
|
||||
TEXNAME_END=$((($TEXS_BEGIN + $CURR_POS + $NULL_POS) / 2))
|
||||
CURR_POS=$(($CURR_POS + $NULL_POS + 58))
|
||||
|
||||
TEXTURE_NAME=`dd if="$FILE" bs=1 skip=$TEXNAME_BEGIN \
|
||||
count=$(($TEXNAME_END - $TEXNAME_BEGIN)) 2> /dev/null`
|
||||
DIRNAME="`dirname "$FILE"`"
|
||||
TEXTURE_PATH="$DIRNAME/$TEXTURE_NAME"
|
||||
|
||||
IS_CONVERTED=0
|
||||
|
||||
while read -r CONVERTED_TEXTURE; do
|
||||
if [ "$TEXTURE_PATH" = "$CONVERTED_TEXTURE" ]; then
|
||||
IS_CONVERTED=1
|
||||
break
|
||||
fi
|
||||
done < "./converted_textures"
|
||||
|
||||
if [ $IS_CONVERTED -eq 1 ]; then
|
||||
echo -n ".jpg" | dd of="$FILE" bs=1 seek=$(($TEXNAME_END - 4)) \
|
||||
conv=notrunc 2> /dev/null
|
||||
fi;
|
||||
done
|
||||
}
|
||||
|
||||
convert_to_jpg_update_spm()
|
||||
{
|
||||
FILE="$1"
|
||||
echo "Convert file: $FILE"
|
||||
|
||||
if [ ! -f "$1" ]; then
|
||||
echo " File doesn't exist."
|
||||
return
|
||||
fi
|
||||
|
||||
HEX_FILE=`hexdump -ve '1/1 "%.2x"' "$FILE"`
|
||||
|
||||
SP_HEADER="5350"
|
||||
SP_FOUND=`echo $HEX_FILE | head -c 4`
|
||||
|
||||
if [ -z "$SP_FOUND" ] || [ "$SP_FOUND" != "$SP_HEADER" ]; then
|
||||
echo " Unsupported format."
|
||||
return
|
||||
fi
|
||||
|
||||
TEXS_BEGIN=60
|
||||
TEXS_COUNT=`echo $HEX_FILE | head -c $TEXS_BEGIN | tail -c 4`
|
||||
|
||||
TEXS_COUNT_CONVERTED=`echo $TEXS_COUNT | cut -c3-4`
|
||||
TEXS_COUNT_CONVERTED=$TEXS_COUNT_CONVERTED`echo $TEXS_COUNT | cut -c1-2`
|
||||
TEXS_COUNT_CONVERTED=`echo $((0x$TEXS_COUNT_CONVERTED))`
|
||||
TEXS_COUNT_CONVERTED=$(($TEXS_COUNT_CONVERTED * 2))
|
||||
|
||||
if [ $TEXS_COUNT_CONVERTED -le 0 ]; then
|
||||
echo " Invalid textures count value."
|
||||
return
|
||||
fi
|
||||
|
||||
CURR_POS=$(($TEXS_BEGIN + 2))
|
||||
|
||||
while [ $TEXS_COUNT_CONVERTED -gt 0 ]; do
|
||||
TEXS_COUNT_CONVERTED=$(($TEXS_COUNT_CONVERTED - 1))
|
||||
|
||||
TEX_LEN=`echo $HEX_FILE | head -c $(($CURR_POS)) | tail -c 2`
|
||||
TEX_LEN=`echo $((0x$TEX_LEN))`
|
||||
|
||||
TEXNAME_BEGIN=$(($CURR_POS / 2))
|
||||
TEXNAME_END=$(($CURR_POS / 2 + $TEX_LEN))
|
||||
CURR_POS=$(($CURR_POS + 2 + $TEX_LEN * 2))
|
||||
|
||||
if [ $TEX_LEN -eq 0 ]; then
|
||||
#echo " Empty texture name, ignore..."
|
||||
continue
|
||||
fi
|
||||
|
||||
TEXTURE_NAME=`dd if="$FILE" bs=1 skip=$TEXNAME_BEGIN \
|
||||
count=$(($TEXNAME_END - $TEXNAME_BEGIN)) 2> /dev/null`
|
||||
|
||||
DIRNAME="`dirname "$FILE"`"
|
||||
TEXTURE_PATH="$DIRNAME/$TEXTURE_NAME"
|
||||
|
||||
IS_CONVERTED=0
|
||||
|
||||
while read -r CONVERTED_TEXTURE; do
|
||||
if [ "$TEXTURE_PATH" = "$CONVERTED_TEXTURE" ]; then
|
||||
IS_CONVERTED=1
|
||||
break
|
||||
fi
|
||||
done < "./converted_textures"
|
||||
|
||||
if [ $IS_CONVERTED -eq 1 ]; then
|
||||
echo -n ".jpg" | dd of="$FILE" bs=1 seek=$(($TEXNAME_END - 4)) \
|
||||
conv=notrunc 2> /dev/null
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
convert_to_jpg_update_xml()
|
||||
{
|
||||
FILE="$1"
|
||||
echo "Convert file: $FILE"
|
||||
|
||||
if [ ! -f "$FILE" ]; then
|
||||
echo " File doesn't exist."
|
||||
return
|
||||
fi
|
||||
|
||||
DIRNAME="`dirname "$FILE"`"
|
||||
|
||||
while read -r CONVERTED_TEXTURE; do
|
||||
DIRNAME_TEX="`dirname "$CONVERTED_TEXTURE"`"
|
||||
|
||||
if [ "$DIRNAME_TEX" != "$DIRNAME" ]; then
|
||||
continue;
|
||||
fi
|
||||
|
||||
TEXNAME="`basename "$CONVERTED_TEXTURE" | head -c -5`"
|
||||
|
||||
sed -i "s/\"$TEXNAME.[pP][nN][gG]/\"$TEXNAME.jpg/g" "$FILE"
|
||||
sed -i "s/ $TEXNAME.[pP][nN][gG]/ $TEXNAME.jpg/g" "$FILE"
|
||||
done < "./converted_textures"
|
||||
}
|
||||
|
||||
|
||||
if [ $DECREASE_QUALITY -gt 0 ]; then
|
||||
find assets/data -iname "*.png" | while read f; do convert_image "$f" "png"; done
|
||||
find assets/data -iname "*.jpg" | while read f; do convert_image "$f" "jpg"; done
|
||||
find assets/data -iname "*.ogg" | while read f; do convert_sound "$f"; done
|
||||
fi
|
||||
|
||||
|
||||
if [ $CONVERT_TO_JPG -gt 0 ]; then
|
||||
rm -f "./converted_textures"
|
||||
|
||||
find assets/data -not -path "assets/data/textures/*" -iname "*.png" | while read f; do convert_to_jpg "$f"; done
|
||||
|
||||
find assets/data -iname "*.b3dz" | while read f; do convert_to_jpg_extract_b3dz "$f"; done
|
||||
find assets/data -iname "*.b3d" | while read f; do convert_to_jpg_update_b3d "$f"; done
|
||||
find assets/data -iname "*.spm" | while read f; do convert_to_jpg_update_spm "$f"; done
|
||||
find assets/data -iname "*.xml" | while read f; do convert_to_jpg_update_xml "$f"; done
|
||||
|
||||
if [ -s "./converted_textures" ]; then
|
||||
echo "Converted textures:"
|
||||
cat "./converted_textures"
|
||||
rm -f "./converted_textures"
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
# Copy data directory
|
||||
echo "Copy data directory"
|
||||
cp -a ../data/* assets/data/
|
||||
|
||||
|
||||
# Remove unused files
|
||||
for BLACKLIST_FILE in $BLACKLIST_FILES; do
|
||||
rm -f "assets/$BLACKLIST_FILE"
|
||||
done
|
||||
|
||||
|
||||
# Run optimize_data.sh script
|
||||
if [ $RUN_OPTIMIZE_SCRIPT -gt 0 ]; then
|
||||
echo "Run optimize_data.sh script"
|
||||
sh -c 'cd assets/data; ../../../data/optimize_data.sh'
|
||||
fi
|
||||
|
||||
|
||||
# Generate directories list
|
||||
echo "Generate directories list"
|
||||
find assets/* -type d > assets/directories.txt
|
||||
sed -i s/'.\/assets\/'// assets/directories.txt
|
||||
sed -i s/'assets\/'// assets/directories.txt
|
||||
|
||||
|
||||
# It will be probably ignored by ant, but create it anyway...
|
||||
touch assets/.nomedia
|
||||
|
||||
|
||||
echo "Done."
|
||||
exit 0
|
||||
360
android/make.sh
@@ -1,360 +0,0 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# (C) 2016-2017 Dawid Gan, under the GPLv3
|
||||
#
|
||||
# A script that creates the apk build
|
||||
|
||||
|
||||
export DIRNAME=$(realpath "$(dirname "$0")")
|
||||
|
||||
export NDK_PATH_DEFAULT="$DIRNAME/android-ndk"
|
||||
export SDK_PATH_DEFAULT="$DIRNAME/android-sdk"
|
||||
|
||||
export NDK_TOOLCHAIN_PATH="$DIRNAME/obj/bin"
|
||||
export NDK_BUILD_SCRIPT="$DIRNAME/Android.mk"
|
||||
export PATH="$DIRNAME/obj/bin:$PATH"
|
||||
export CROSS_SYSROOT="$DIRNAME/obj/sysroot"
|
||||
|
||||
#export NDK_CCACHE=ccache
|
||||
export NDK_CPPFLAGS="-O3 -g"
|
||||
|
||||
export NDK_ABI_ARMV7=armeabi-v7a
|
||||
export ARCH_ARMV7=arm
|
||||
export HOST_ARMV7=arm-linux-androideabi
|
||||
export NDK_PLATFORM_ARMV7=android-19
|
||||
export SDK_VERSION_ARMV7=19
|
||||
|
||||
export NDK_ABI_X86=x86
|
||||
export ARCH_X86=x86
|
||||
export HOST_X86=i686-linux-android
|
||||
export NDK_PLATFORM_X86=android-19
|
||||
export SDK_VERSION_X86=19
|
||||
|
||||
export NDK_ABI_AARCH64=arm64-v8a
|
||||
export ARCH_AARCH64=arm64
|
||||
export HOST_AARCH64=aarch64-linux-android
|
||||
export NDK_PLATFORM_AARCH64=android-21
|
||||
export SDK_VERSION_AARCH64=21
|
||||
|
||||
|
||||
# A helper function that checks if error ocurred
|
||||
check_error()
|
||||
{
|
||||
if [ $? -gt 0 ]; then
|
||||
echo "Error ocurred."
|
||||
exit
|
||||
fi
|
||||
}
|
||||
|
||||
# Handle clean command
|
||||
if [ ! -z "$1" ] && [ "$1" = "clean" ]; then
|
||||
rm -rf bin
|
||||
rm -rf build
|
||||
rm -rf libs
|
||||
rm -rf obj
|
||||
rm -rf .gradle
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check if compilation for different platform has been started before
|
||||
if [ -f "$DIRNAME/obj/compile_arch" ]; then
|
||||
PROJECT_ARCH=$(cat "$DIRNAME/obj/compile_arch")
|
||||
|
||||
if [ -z "$COMPILE_ARCH" ]; then
|
||||
COMPILE_ARCH="$PROJECT_ARCH"
|
||||
elif [ "$PROJECT_ARCH" != "$COMPILE_ARCH" ]; then
|
||||
echo "Error: Compilation for different platform has been already made."
|
||||
echo "Run './make.sh clean' first or set COMPILE_ARCH variable" \
|
||||
"to '$PROJECT_ARCH.'"
|
||||
exit
|
||||
fi
|
||||
fi
|
||||
|
||||
# Update variables for selected architecture
|
||||
if [ -z "$COMPILE_ARCH" ]; then
|
||||
COMPILE_ARCH="armv7"
|
||||
fi
|
||||
|
||||
if [ "$COMPILE_ARCH" = "armv7" ]; then
|
||||
export NDK_PLATFORM=$NDK_PLATFORM_ARMV7
|
||||
export NDK_ABI=$NDK_ABI_ARMV7
|
||||
export ARCH=$ARCH_ARMV7
|
||||
export HOST=$HOST_ARMV7
|
||||
export SDK_VERSION=$SDK_VERSION_ARMV7
|
||||
elif [ "$COMPILE_ARCH" = "x86" ]; then
|
||||
export NDK_PLATFORM=$NDK_PLATFORM_X86
|
||||
export NDK_ABI=$NDK_ABI_X86
|
||||
export ARCH=$ARCH_X86
|
||||
export HOST=$HOST_X86
|
||||
export SDK_VERSION=$SDK_VERSION_X86
|
||||
elif [ "$COMPILE_ARCH" = "aarch64" ]; then
|
||||
export NDK_PLATFORM=$NDK_PLATFORM_AARCH64
|
||||
export NDK_ABI=$NDK_ABI_AARCH64
|
||||
export ARCH=$ARCH_AARCH64
|
||||
export HOST=$HOST_AARCH64
|
||||
export SDK_VERSION=$SDK_VERSION_AARCH64
|
||||
else
|
||||
echo "Unknow COMPILE_ARCH: $COMPILE_ARCH. Possible values are: " \
|
||||
"armv7, aarch64, x86"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Update variables for selected build type
|
||||
if [ -z "$BUILD_TYPE" ]; then
|
||||
BUILD_TYPE="debug"
|
||||
fi
|
||||
|
||||
if [ "$BUILD_TYPE" = "debug" ] || [ "$BUILD_TYPE" = "Debug" ]; then
|
||||
export ANT_BUILD_TYPE="debug"
|
||||
export GRADLE_BUILD_TYPE="assembleDebug"
|
||||
export IS_DEBUG_BUILD=1
|
||||
elif [ "$BUILD_TYPE" = "release" ] || [ "$BUILD_TYPE" = "Release" ]; then
|
||||
export ANT_BUILD_TYPE="release"
|
||||
export GRADLE_BUILD_TYPE="assembleRelease"
|
||||
export IS_DEBUG_BUILD=0
|
||||
else
|
||||
echo "Unsupported BUILD_TYPE: $BUILD_TYPE. Possible values are: " \
|
||||
"debug, release"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check selected build tool
|
||||
if [ -z "$BUILD_TOOL" ]; then
|
||||
BUILD_TOOL="gradle"
|
||||
fi
|
||||
|
||||
if [ "$BUILD_TOOL" != "gradle" ] && [ "$BUILD_TOOL" != "ant" ]; then
|
||||
echo "Unsupported BUILD_TOOL: $BUILD_TOOL. Possible values are: " \
|
||||
"gradle, ant"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check if we have access to the Android NDK and SDK
|
||||
if [ -z "$NDK_PATH" ]; then
|
||||
export NDK_PATH="$NDK_PATH_DEFAULT"
|
||||
fi
|
||||
|
||||
if [ -z "$SDK_PATH" ]; then
|
||||
export SDK_PATH="$SDK_PATH_DEFAULT"
|
||||
fi
|
||||
|
||||
NDK_PATH=$(realpath "$NDK_PATH")
|
||||
SDK_PATH=$(realpath "$SDK_PATH")
|
||||
|
||||
if [ ! -d "$NDK_PATH" ]; then
|
||||
echo "Error: Couldn't find $NDK_PATH directory. Please create a symlink" \
|
||||
"to your Android NDK installation in the $NDK_PATH_DEFAULT or set" \
|
||||
"proper path in the NDK_PATH variable"
|
||||
exit
|
||||
fi
|
||||
|
||||
if [ ! -d "$SDK_PATH" ]; then
|
||||
echo "Error: Couldn't find $SDK_PATH directory. Please create a symlink" \
|
||||
"to your Android SDK installation in the $SDK_PATH_DEFAULT or set" \
|
||||
"proper path in the SDK_PATH variable"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Find newest build-tools version
|
||||
if [ -z "$BUILD_TOOLS_VER" ]; then
|
||||
BUILD_TOOLS_DIRS=`ls -1 "$SDK_PATH/build-tools" | sort -V -r`
|
||||
|
||||
for DIR in $BUILD_TOOLS_DIRS; do
|
||||
if [ "$DIR" = `echo $DIR | sed 's/[^0-9,.]//g'` ]; then
|
||||
BUILD_TOOLS_VER="$DIR"
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
if [ -z "$BUILD_TOOLS_VER" ] || [ ! -d "$SDK_PATH/build-tools/$BUILD_TOOLS_VER" ]; then
|
||||
echo "Error: Couldn't detect build-tools version."
|
||||
exit
|
||||
fi
|
||||
|
||||
|
||||
# Standalone toolchain
|
||||
if [ ! -f "$DIRNAME/obj/make_standalone_toolchain.stamp" ]; then
|
||||
echo "Creating standalone toolchain"
|
||||
rm -rf "$DIRNAME/obj"
|
||||
${NDK_PATH}/build/tools/make-standalone-toolchain.sh \
|
||||
--platform=$NDK_PLATFORM \
|
||||
--install-dir="$DIRNAME/obj/" \
|
||||
--arch=$ARCH
|
||||
check_error
|
||||
touch "$DIRNAME/obj/make_standalone_toolchain.stamp"
|
||||
echo $COMPILE_ARCH > "$DIRNAME/obj/compile_arch"
|
||||
fi
|
||||
|
||||
# Freetype
|
||||
if [ ! -f "$DIRNAME/obj/freetype.stamp" ]; then
|
||||
echo "Compiling freetype"
|
||||
mkdir -p "$DIRNAME/obj/freetype"
|
||||
cp -a -f "$DIRNAME/../lib/freetype/"* "$DIRNAME/obj/freetype"
|
||||
|
||||
cd "$DIRNAME/obj/freetype"
|
||||
./configure --host=$HOST \
|
||||
--without-zlib \
|
||||
--without-png \
|
||||
--without-harfbuzz &&
|
||||
make $@
|
||||
check_error
|
||||
touch "$DIRNAME/obj/freetype.stamp"
|
||||
fi
|
||||
|
||||
# Zlib
|
||||
if [ ! -f "$DIRNAME/obj/zlib.stamp" ]; then
|
||||
echo "Compiling zlib"
|
||||
mkdir -p "$DIRNAME/obj/zlib"
|
||||
cp -a -f "$DIRNAME/../lib/zlib/"* "$DIRNAME/obj/zlib"
|
||||
|
||||
cd "$DIRNAME/obj/zlib"
|
||||
cmake . -DCMAKE_TOOLCHAIN_FILE=../../../cmake/Toolchain-android.cmake \
|
||||
-DHOST=$HOST &&
|
||||
make $@
|
||||
check_error
|
||||
touch "$DIRNAME/obj/zlib.stamp"
|
||||
fi
|
||||
|
||||
# Libpng
|
||||
if [ ! -f "$DIRNAME/obj/libpng.stamp" ]; then
|
||||
echo "Compiling libpng"
|
||||
mkdir -p "$DIRNAME/obj/libpng"
|
||||
mkdir -p "$DIRNAME/obj/libpng/lib"
|
||||
cp -a -f "$DIRNAME/../lib/libpng/"* "$DIRNAME/obj/libpng"
|
||||
|
||||
cd "$DIRNAME/obj/libpng"
|
||||
cmake . -DCMAKE_TOOLCHAIN_FILE=../../../cmake/Toolchain-android.cmake \
|
||||
-DHOST=$HOST \
|
||||
-DZLIB_LIBRARY="$DIRNAME/obj/zlib/libz.a" \
|
||||
-DZLIB_INCLUDE_DIR="$DIRNAME/obj/zlib/" \
|
||||
-DPNG_TESTS=0 &&
|
||||
make $@
|
||||
check_error
|
||||
touch "$DIRNAME/obj/libpng.stamp"
|
||||
fi
|
||||
|
||||
# Openal
|
||||
if [ ! -f "$DIRNAME/obj/openal.stamp" ]; then
|
||||
echo "Compiling openal"
|
||||
mkdir -p "$DIRNAME/obj/openal"
|
||||
cp -a -f "$DIRNAME/../lib/openal/"* "$DIRNAME/obj/openal"
|
||||
|
||||
cd "$DIRNAME/obj/openal"
|
||||
cmake . -DCMAKE_TOOLCHAIN_FILE=../../../cmake/Toolchain-android.cmake \
|
||||
-DHOST=$HOST \
|
||||
-DALSOFT_UTILS=0 \
|
||||
-DALSOFT_EXAMPLES=0 \
|
||||
-DALSOFT_TESTS=0 \
|
||||
-DLIBTYPE=STATIC &&
|
||||
make $@
|
||||
check_error
|
||||
touch "$DIRNAME/obj/openal.stamp"
|
||||
fi
|
||||
|
||||
# OpenSSL
|
||||
if [ ! -f "$DIRNAME/obj/openssl.stamp" ]; then
|
||||
echo "Compiling openssl"
|
||||
mkdir -p "$DIRNAME/obj/openssl"
|
||||
cp -a -f "$DIRNAME/../lib/openssl/"* "$DIRNAME/obj/openssl"
|
||||
|
||||
cd "$DIRNAME/obj/openssl"
|
||||
./Configure android --cross-compile-prefix="$HOST-"
|
||||
make $@
|
||||
check_error
|
||||
touch "$DIRNAME/obj/openssl.stamp"
|
||||
fi
|
||||
|
||||
# Curl
|
||||
if [ ! -f "$DIRNAME/obj/curl.stamp" ]; then
|
||||
echo "Compiling curl"
|
||||
mkdir -p "$DIRNAME/obj/curl"
|
||||
cp -a -f "$DIRNAME/../lib/curl/"* "$DIRNAME/obj/curl"
|
||||
|
||||
cd "$DIRNAME/obj/curl"
|
||||
CPPFLAGS="-I$DIRNAME/obj/openssl/include $CPPFLAGS" \
|
||||
LDFLAGS="-L$DIRNAME/obj/openssl/ $LDFLAGS" \
|
||||
./configure --host=$HOST \
|
||||
--with-ssl \
|
||||
--disable-shared \
|
||||
--enable-static \
|
||||
--enable-threaded-resolver &&
|
||||
make $@
|
||||
check_error
|
||||
touch "$DIRNAME/obj/curl.stamp"
|
||||
fi
|
||||
|
||||
# Jpeglib
|
||||
if [ ! -f "$DIRNAME/obj/jpeglib.stamp" ]; then
|
||||
echo "Compiling jpeglib"
|
||||
mkdir -p "$DIRNAME/obj/jpeglib"
|
||||
cp -a -f "$DIRNAME/../lib/jpeglib/"* "$DIRNAME/obj/jpeglib"
|
||||
|
||||
cd "$DIRNAME/obj/jpeglib"
|
||||
cmake . -DCMAKE_TOOLCHAIN_FILE=../../../cmake/Toolchain-android.cmake \
|
||||
-DHOST=$HOST &&
|
||||
make $@
|
||||
check_error
|
||||
touch "$DIRNAME/obj/jpeglib.stamp"
|
||||
fi
|
||||
|
||||
# Libogg
|
||||
if [ ! -f "$DIRNAME/obj/libogg.stamp" ]; then
|
||||
echo "Compiling libogg"
|
||||
mkdir -p "$DIRNAME/obj/libogg"
|
||||
cp -a -f "$DIRNAME/../lib/libogg/"* "$DIRNAME/obj/libogg"
|
||||
|
||||
cd "$DIRNAME/obj/libogg"
|
||||
./configure --host=$HOST &&
|
||||
make $@
|
||||
check_error
|
||||
touch "$DIRNAME/obj/libogg.stamp"
|
||||
fi
|
||||
|
||||
# Libvorbis
|
||||
if [ ! -f "$DIRNAME/obj/libvorbis.stamp" ]; then
|
||||
echo "Compiling libvorbis"
|
||||
mkdir -p "$DIRNAME/obj/libvorbis"
|
||||
cp -a -f "$DIRNAME/../lib/libvorbis/"* "$DIRNAME/obj/libvorbis"
|
||||
|
||||
cd "$DIRNAME/obj/libvorbis"
|
||||
CPPFLAGS="-I$DIRNAME/obj/libogg/include $CPPFLAGS" \
|
||||
LDFLAGS="-L$DIRNAME/obj/libogg/src/.libs $LDFLAGS" \
|
||||
./configure --host=$HOST &&
|
||||
make $@
|
||||
check_error
|
||||
touch "$DIRNAME/obj/libvorbis.stamp"
|
||||
fi
|
||||
|
||||
# STK
|
||||
echo "Compiling STK"
|
||||
cd "$DIRNAME"
|
||||
${NDK_PATH}/ndk-build $@ \
|
||||
APP_BUILD_SCRIPT="$NDK_BUILD_SCRIPT" \
|
||||
APP_ABI="$NDK_ABI" \
|
||||
APP_PLATFORM="$NDK_PLATFORM" \
|
||||
APP_CPPFLAGS="$NDK_CPPFLAGS" \
|
||||
APP_STL=gnustl_static \
|
||||
NDK_DEBUG=$IS_DEBUG_BUILD
|
||||
|
||||
check_error
|
||||
|
||||
# Build apk
|
||||
echo "Building APK"
|
||||
|
||||
sed -i "s/minSdkVersion=\".*\"/minSdkVersion=\"$SDK_VERSION\"/g" \
|
||||
"$DIRNAME/AndroidManifest.xml"
|
||||
|
||||
|
||||
if [ "$BUILD_TOOL" = "gradle" ]; then
|
||||
export ANDROID_HOME="$SDK_PATH"
|
||||
gradle -Psdk_version=$SDK_VERSION \
|
||||
-Pbuild_tools_ver="$BUILD_TOOLS_VER" \
|
||||
$GRADLE_BUILD_TYPE
|
||||
elif [ "$BUILD_TOOL" = "ant" ]; then
|
||||
ant -Dsdk.dir="$SDK_PATH" \
|
||||
-Dtarget=$NDK_PLATFORM \
|
||||
$ANT_BUILD_TYPE
|
||||
fi
|
||||
|
||||
check_error
|
||||
|
Before Width: | Height: | Size: 5.7 KiB |
|
Before Width: | Height: | Size: 3.1 KiB |
|
Before Width: | Height: | Size: 8.9 KiB |
|
Before Width: | Height: | Size: 17 KiB |
|
Before Width: | Height: | Size: 37 KiB |
@@ -1,4 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="app_name">SuperTuxKart</string>
|
||||
</resources>
|
||||
@@ -14,11 +14,11 @@ FIND_PATH(Angelscript_INCLUDE_DIRS angelscript.h
|
||||
)
|
||||
|
||||
FIND_LIBRARY(Angelscript_LIBRARY
|
||||
NAMES angelscript angelscript_s
|
||||
NAMES angelscript
|
||||
PATHS
|
||||
/usr/local
|
||||
/usr
|
||||
PATH_SUFFIXES lib lib64 lib32
|
||||
PATH_SUFFIXES lib
|
||||
)
|
||||
|
||||
# handle the QUIETLY and REQUIRED arguments and set ANGELSCRIPT_FOUND to TRUE if
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
# - Find EGL
|
||||
# Find the EGL includes and libraries
|
||||
#
|
||||
# Following variables are provided:
|
||||
# EGL_FOUND
|
||||
# True if EGL has been found
|
||||
# EGL_INCLUDE_DIR
|
||||
# The include directory of EGL
|
||||
# EGL_LIBRARY
|
||||
# EGL library list
|
||||
|
||||
find_path(EGL_INCLUDE_DIR EGL/egl.h)
|
||||
find_library(EGL_LIBRARY NAMES EGL)
|
||||
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(EGL DEFAULT_MSG EGL_LIBRARY EGL_INCLUDE_DIR)
|
||||
|
||||
mark_as_advanced(EGL_LIBRARY EGL_INCLUDE_DIR)
|
||||
@@ -1,29 +0,0 @@
|
||||
# - Find Freetype
|
||||
# Find the Freetype includes and libraries
|
||||
#
|
||||
# Following variables are provided:
|
||||
# FREETYPE_FOUND
|
||||
# True if Freetype has been found
|
||||
# FREETYPE_INCLUDE_DIRS
|
||||
# The include directories of Freetype
|
||||
# FREETYPE_LIBRARIES
|
||||
# Freetype library list
|
||||
|
||||
if(WIN32)
|
||||
find_path(FREETYPE_INCLUDE_DIRS NAMES freetype/freetype.h PATHS "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/include")
|
||||
find_library(FREETYPE_LIBRARY NAMES freetype PATHS "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib")
|
||||
set(FREETYPE_FOUND 1)
|
||||
set(FREETYPE_LIBRARIES ${FREETYPE_LIBRARY})
|
||||
elseif(APPLE)
|
||||
find_path(FREETYPE_INCLUDE_DIRS NAMES freetype/freetype.h PATHS "/Library/Frameworks/FreeType.Framework/Versions/2.4/unix/include")
|
||||
find_library(FREETYPE_LIBRARY NAMES freetype PATHS "/Library/Frameworks/FreeType.Framework/Versions/2.4/")
|
||||
include_directories(/Library/Frameworks/FreeType.Framework/Versions/2.4/unix/include)
|
||||
set(FREETYPE_FOUND 1)
|
||||
set(FREETYPE_LIBRARIES ${FREETYPE_LIBRARY})
|
||||
elseif(UNIX)
|
||||
include(FindPkgConfig)
|
||||
pkg_check_modules(FREETYPE freetype2)
|
||||
else()
|
||||
set(FREETYPE_FOUND 0)
|
||||
endif()
|
||||
|
||||
@@ -24,8 +24,8 @@ else()
|
||||
endif()
|
||||
|
||||
if(NOT FRIBIDI_FOUND)
|
||||
find_path(FRIBIDI_INCLUDE_DIR NAMES fribidi/fribidi.h PATHS /Library/Frameworks/fribidi.framework/Headers "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/include")
|
||||
find_library(FRIBIDI_LIBRARY NAMES fribidi PATHS /Library/Frameworks/fribidi.framework "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib")
|
||||
find_path(FRIBIDI_INCLUDE_DIR NAMES fribidi/fribidi.h PATHS /Library/Frameworks/fribidi.framework/Headers "${PROJECT_SOURCE_DIR}/dependencies/include")
|
||||
find_library(FRIBIDI_LIBRARY NAMES fribidi PATHS /Library/Frameworks/fribidi.framework "${PROJECT_SOURCE_DIR}/dependencies/lib")
|
||||
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(Fribidi DEFAULT_MSG FRIBIDI_INCLUDE_DIR FRIBIDI_LIBRARY)
|
||||
|
||||
@@ -1,89 +0,0 @@
|
||||
# - Try to find libbfd
|
||||
# Once done this will define
|
||||
#
|
||||
# LIBBFD_FOUND - system has libbfd
|
||||
# LIBBFD_INCLUDE_DIRS - the libbfd include directory
|
||||
# LIBBFD_LIBRARIES - Link these to use libbfd
|
||||
# LIBBFD_DEFINITIONS - Compiler switches required for using libbfd
|
||||
#
|
||||
# Based on:
|
||||
#
|
||||
# Copyright (c) 2008 Bernhard Walle <bernhard.walle@gmx.de>
|
||||
#
|
||||
# Redistribution and use is allowed according to the terms of the New
|
||||
# BSD license.
|
||||
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
|
||||
#
|
||||
|
||||
|
||||
if (LIBBFD_LIBRARIES AND LIBBFD_INCLUDE_DIRS)
|
||||
set (LIBBFD_FIND_QUIETLY TRUE)
|
||||
endif ()
|
||||
|
||||
find_path (LIBBFD_INCLUDE_DIRS
|
||||
NAMES
|
||||
bfd.h
|
||||
dis-asm.h
|
||||
PATHS
|
||||
/usr/include
|
||||
/usr/local/include
|
||||
/opt/local/include
|
||||
/opt/include
|
||||
ENV CPATH)
|
||||
|
||||
# Ugly, yes ugly...
|
||||
find_library (LIBBFD_BFD_LIBRARY
|
||||
NAMES
|
||||
bfd
|
||||
PATHS
|
||||
/usr/lib
|
||||
/usr/lib64
|
||||
/usr/local/lib
|
||||
/usr/local/lib64
|
||||
/usr/include
|
||||
/opt/local/lib
|
||||
/opt/usr/lib64
|
||||
ENV LIBRARY_PATH
|
||||
ENV LD_LIBRARY_PATH)
|
||||
|
||||
#find_library (LIBBFD_IBERTY_LIBRARY
|
||||
# NAMES
|
||||
# iberty
|
||||
# PATHS
|
||||
# /usr/lib
|
||||
# /usr/lib64
|
||||
# /usr/local/lib
|
||||
# /usr/local/lib64
|
||||
# /usr/include
|
||||
# /opt/local/lib
|
||||
# /opt/usr/lib64
|
||||
# ENV LIBRARY_PATH
|
||||
# ENV LD_LIBRARY_PATH)
|
||||
|
||||
#find_library (LIBBFD_OPCODES_LIBRARY
|
||||
# NAMES
|
||||
# opcodes
|
||||
# PATHS
|
||||
# /usr/lib
|
||||
# /usr/lib64
|
||||
# /usr/local/lib
|
||||
# /usr/local/lib64
|
||||
# /usr/include
|
||||
# /opt/local/lib
|
||||
# /opt/usr/lib64
|
||||
# ENV LIBRARY_PATH
|
||||
# ENV LD_LIBRARY_PATH)
|
||||
|
||||
|
||||
include (FindPackageHandleStandardArgs)
|
||||
|
||||
|
||||
# handle the QUIETLY and REQUIRED arguments and set LIBBFD_FOUND to TRUE if all listed variables are TRUE
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(LIBBFD DEFAULT_MSG
|
||||
LIBBFD_BFD_LIBRARY
|
||||
# LIBBFD_IBERTY_LIBRARY
|
||||
# LIBBFD_OPCODES_LIBRARY
|
||||
LIBBFD_INCLUDE_DIRS)
|
||||
|
||||
set(LIBBFD_LIBRARIES "${LIBBFD_BFD_LIBRARY}")
|
||||
mark_as_advanced(LIBBFD_INCLUDE_DIRS LIBBFD_LIBRARIES LIBBFD_BFD_LIBRARY)
|
||||
@@ -10,12 +10,11 @@
|
||||
# OggVorbis library list
|
||||
|
||||
|
||||
find_path(OGGVORBIS_OGG_INCLUDE_DIR NAMES ogg/ogg.h PATHS "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/include")
|
||||
find_path(OGGVORBIS_VORBIS_INCLUDE_DIR NAMES vorbis/vorbisfile.h PATHS "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/include")
|
||||
find_library(OGGVORBIS_OGG_LIBRARY NAMES ogg Ogg libogg PATHS "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib")
|
||||
find_library(OGGVORBIS_VORBIS_LIBRARY NAMES vorbis Vorbis libvorbis PATHS "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib")
|
||||
find_library(OGGVORBIS_VORBISFILE_LIBRARY NAMES vorbisfile libvorbisfile PATHS "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib")
|
||||
find_library(OGGVORBIS_VORBISENC_LIBRARY NAMES vorbisenc libvorbisenc PATHS "${PROJECT_SOURCE_DIR}/${DEPENDENCIES}/lib")
|
||||
find_path(OGGVORBIS_OGG_INCLUDE_DIR NAMES ogg/ogg.h PATHS "${PROJECT_SOURCE_DIR}/dependencies/include")
|
||||
find_path(OGGVORBIS_VORBIS_INCLUDE_DIR NAMES vorbis/vorbisfile.h PATHS "${PROJECT_SOURCE_DIR}/dependencies/include")
|
||||
find_library(OGGVORBIS_OGG_LIBRARY NAMES ogg Ogg libogg PATHS "${PROJECT_SOURCE_DIR}/dependencies/lib")
|
||||
find_library(OGGVORBIS_VORBIS_LIBRARY NAMES vorbis Vorbis libvorbis PATHS "${PROJECT_SOURCE_DIR}/dependencies/lib")
|
||||
find_library(OGGVORBIS_VORBISFILE_LIBRARY NAMES vorbisfile libvorbisfile PATHS "${PROJECT_SOURCE_DIR}/dependencies/lib")
|
||||
|
||||
if (APPLE)
|
||||
set(OGGVORBIS_OGG_INCLUDE_DIR "/Library/Frameworks/Ogg.framework/Headers/")
|
||||
@@ -27,11 +26,6 @@ if(APPLE AND NOT OGGVORBIS_VORBISFILE_LIBRARY)
|
||||
set(OGGVORBIS_VORBISFILE_LIBRARY ${OGGVORBIS_VORBIS_LIBRARY})
|
||||
endif()
|
||||
|
||||
if(APPLE AND NOT OGGVORBIS_VORBISENC_LIBRARY)
|
||||
# Seems to be the same on Apple systems
|
||||
set(OGGVORBIS_VORBISENC_LIBRARY ${OGGVORBIS_VORBIS_LIBRARY})
|
||||
endif()
|
||||
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(OggVorbis DEFAULT_MSG
|
||||
OGGVORBIS_OGG_INCLUDE_DIR OGGVORBIS_VORBIS_INCLUDE_DIR
|
||||
@@ -39,8 +33,8 @@ find_package_handle_standard_args(OggVorbis DEFAULT_MSG
|
||||
|
||||
# Publish variables
|
||||
set(OGGVORBIS_INCLUDE_DIRS ${OGGVORBIS_OGG_INCLUDE_DIR} ${OGGVORBIS_VORBIS_INCLUDE_DIR})
|
||||
set(OGGVORBIS_LIBRARIES ${OGGVORBIS_OGG_LIBRARY} ${OGGVORBIS_VORBIS_LIBRARY} ${OGGVORBIS_VORBISFILE_LIBRARY} ${OGGVORBIS_VORBISENC_LIBRARY})
|
||||
set(OGGVORBIS_LIBRARIES ${OGGVORBIS_OGG_LIBRARY} ${OGGVORBIS_VORBIS_LIBRARY} ${OGGVORBIS_VORBISFILE_LIBRARY})
|
||||
list(REMOVE_DUPLICATES OGGVORBIS_INCLUDE_DIRS)
|
||||
list(REMOVE_DUPLICATES OGGVORBIS_LIBRARIES)
|
||||
mark_as_advanced(OGGVORBIS_OGG_INCLUDE_DIR OGGVORBIS_VORBIS_INCLUDE_DIR)
|
||||
mark_as_advanced(OGGVORBIS_OGG_LIBRARY OGGVORBIS_VORBIS_LIBRARY OGGVORBIS_VORBISFILE_LIBRARY OGGVORBIS_VORBISENC_LIBRARY)
|
||||
mark_as_advanced(OGGVORBIS_OGG_LIBRARY OGGVORBIS_VORBIS_LIBRARY OGGVORBIS_VORBISFILE_LIBRARY)
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
# - Find Wayland
|
||||
# Find the Wayland includes and libraries
|
||||
#
|
||||
# Following variables are provided:
|
||||
# WAYLAND_FOUND
|
||||
# True if Wayland has been found
|
||||
# WAYLAND_INCLUDE_DIRS
|
||||
# The include directories of Wayland
|
||||
# WAYLAND_LIBRARIES
|
||||
# Wayland library list
|
||||
|
||||
find_path(WAYLAND_CLIENT_INCLUDE_DIR wayland-client.h)
|
||||
find_path(WAYLAND_CURSOR_INCLUDE_DIR wayland-cursor.h)
|
||||
find_path(WAYLAND_EGL_INCLUDE_DIR wayland-egl.h)
|
||||
find_path(XKBCOMMON_INCLUDE_DIR xkbcommon/xkbcommon.h)
|
||||
|
||||
find_library(WAYLAND_CLIENT_LIBRARY NAMES wayland-client)
|
||||
find_library(WAYLAND_CURSOR_LIBRARY NAMES wayland-cursor)
|
||||
find_library(WAYLAND_EGL_LIBRARY NAMES wayland-egl)
|
||||
find_library(XKBCOMMON_LIBRARY NAMES xkbcommon)
|
||||
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(Wayland DEFAULT_MSG WAYLAND_CLIENT_LIBRARY
|
||||
WAYLAND_CURSOR_LIBRARY
|
||||
WAYLAND_EGL_LIBRARY
|
||||
XKBCOMMON_LIBRARY
|
||||
WAYLAND_CLIENT_INCLUDE_DIR
|
||||
WAYLAND_CURSOR_INCLUDE_DIR
|
||||
WAYLAND_EGL_INCLUDE_DIR
|
||||
XKBCOMMON_INCLUDE_DIR)
|
||||
|
||||
set(WAYLAND_INCLUDE_DIRS ${WAYLAND_CLIENT_INCLUDE_DIR}
|
||||
${WAYLAND_CURSOR_INCLUDE_DIR}
|
||||
${WAYLAND_EGL_INCLUDE_DIR}
|
||||
${XKBCOMMON_INCLUDE_DIR})
|
||||
|
||||
set(WAYLAND_LIBRARIES ${WAYLAND_CLIENT_LIBRARY}
|
||||
${WAYLAND_CURSOR_LIBRARY}
|
||||
${WAYLAND_EGL_LIBRARY}
|
||||
${XKBCOMMON_LIBRARY})
|
||||
|
||||
list(REMOVE_DUPLICATES WAYLAND_INCLUDE_DIRS)
|
||||
list(REMOVE_DUPLICATES WAYLAND_LIBRARIES)
|
||||
|
||||
mark_as_advanced(WAYLAND_CLIENT_LIBRARY
|
||||
WAYLAND_CURSOR_LIBRARY
|
||||
WAYLAND_EGL_LIBRARY
|
||||
XKBCOMMON_LIBRARY
|
||||
WAYLAND_CLIENT_INCLUDE_DIR
|
||||
WAYLAND_CURSOR_INCLUDE_DIR
|
||||
WAYLAND_EGL_INCLUDE_DIR
|
||||
XKBCOMMON_INCLUDE_DIR)
|
||||
18
cmake/FindXrandr.cmake
Normal file
@@ -0,0 +1,18 @@
|
||||
find_path(XRANDR_INCLUDE_DIR NAMES X11/extensions/Xrandr.h
|
||||
PATH_SUFFIXES X11/extensions
|
||||
DOC "The XRANDR include directory"
|
||||
)
|
||||
|
||||
find_library(XRANDR_LIBRARY NAMES Xrandr
|
||||
DOC "The XRANDR library"
|
||||
)
|
||||
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(XRANDR DEFAULT_MSG XRANDR_LIBRARY XRANDR_INCLUDE_DIR)
|
||||
|
||||
if(XRANDR_FOUND)
|
||||
set( XRANDR_LIBRARIES ${XRANDR_LIBRARY} )
|
||||
set( XRANDR_INCLUDE_DIRS ${XRANDR_INCLUDE_DIR} )
|
||||
endif()
|
||||
|
||||
mark_as_advanced(XRANDR_INCLUDE_DIR XRANDR_LIBRARY)
|
||||
@@ -1,32 +0,0 @@
|
||||
# Cross-compiling requires CMake 2.6 or newer. Example:
|
||||
# cmake .. -DCMAKE_TOOLCHAIN_FILE=../XCompile-Android.txt -DHOST=arm-linux-androideabi
|
||||
# Where 'arm-linux-androideabi' is the host prefix for the cross-compiler. If
|
||||
# you already have a toolchain file setup, you may use that instead of this
|
||||
# file. Make sure to set CMAKE_FIND_ROOT_PATH to where the NDK toolchain was
|
||||
# installed (e.g. "$ENV{HOME}/toolchains/arm-linux-androideabi-r10c-21").
|
||||
|
||||
# the name of the target operating system
|
||||
SET(CMAKE_SYSTEM_NAME Linux)
|
||||
|
||||
# which compilers to use for C and C++
|
||||
SET(CMAKE_C_COMPILER "${HOST}-gcc")
|
||||
SET(CMAKE_CXX_COMPILER "${HOST}-g++")
|
||||
SET(CMAKE_RC_COMPILER "${HOST}-windres")
|
||||
|
||||
# here is the target environment located
|
||||
SET(CMAKE_FIND_ROOT_PATH $ENV{NDK_TOOLCHAIN_PATH})
|
||||
|
||||
# here is where stuff gets installed to
|
||||
SET(CMAKE_INSTALL_PREFIX "${CMAKE_FIND_ROOT_PATH}" CACHE STRING "Install path prefix, prepended onto install directories." FORCE)
|
||||
|
||||
# adjust the default behaviour of the FIND_XXX() commands:
|
||||
# search headers and libraries in the target environment, search
|
||||
# programs in the host environment
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
||||
|
||||
# set env vars so that pkg-config will look in the appropriate directory for
|
||||
# .pc files (as there seems to be no way to force using ${HOST}-pkg-config)
|
||||
set(ENV{PKG_CONFIG_LIBDIR} "${CMAKE_INSTALL_PREFIX}/lib/pkgconfig")
|
||||
set(ENV{PKG_CONFIG_PATH} "")
|
||||
@@ -1,23 +0,0 @@
|
||||
# Usage:
|
||||
# cmake .. -DCMAKE_TOOLCHAIN_FILE=../cmake/Toolchain-mingw-64bit.cmake
|
||||
|
||||
# the name of the target operating system
|
||||
SET(CMAKE_SYSTEM_NAME Windows)
|
||||
|
||||
# which compilers to use for C and C++
|
||||
SET(CMAKE_C_COMPILER x86_64-w64-mingw32-gcc-posix)
|
||||
SET(CMAKE_CXX_COMPILER x86_64-w64-mingw32-g++-posix)
|
||||
SET(CMAKE_RC_COMPILER x86_64-w64-mingw32-windres)
|
||||
|
||||
# figure out folder to look in
|
||||
execute_process(COMMAND sh -c "ls /usr/lib/gcc/x86_64-w64-mingw32/ | grep posix | tr -d '\n'" OUTPUT_VARIABLE MINGW_DEPS_FOLDER)
|
||||
|
||||
# here is the target environment located
|
||||
SET(CMAKE_FIND_ROOT_PATH /usr/x86_64-w64-mingw32 /usr/lib/gcc/x86_64-w64-mingw32/${MINGW_DEPS_FOLDER}/ ${PROJECT_SOURCE_DIR}/dependencies-64bit)
|
||||
|
||||
# adjust the default behaviour of the FIND_XXX() commands:
|
||||
# search headers and libraries in the target environment, search
|
||||
# programs in the host environment
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ALWAYS)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
||||
@@ -1,6 +1,3 @@
|
||||
# Usage:
|
||||
# cmake .. -DCMAKE_TOOLCHAIN_FILE=../cmake/Toolchain-mingw.cmake
|
||||
|
||||
# the name of the target operating system
|
||||
SET(CMAKE_SYSTEM_NAME Windows)
|
||||
|
||||
@@ -9,11 +6,8 @@ SET(CMAKE_C_COMPILER i686-w64-mingw32-gcc-posix)
|
||||
SET(CMAKE_CXX_COMPILER i686-w64-mingw32-g++-posix)
|
||||
SET(CMAKE_RC_COMPILER i686-w64-mingw32-windres)
|
||||
|
||||
# figure out folder to look in
|
||||
execute_process(COMMAND sh -c "ls /usr/lib/gcc/i686-w64-mingw32/ | grep posix | tr -d '\n'" OUTPUT_VARIABLE MINGW_DEPS_FOLDER)
|
||||
|
||||
# here is the target environment located
|
||||
SET(CMAKE_FIND_ROOT_PATH /usr/i686-w64-mingw32 /usr/lib/gcc/i686-w64-mingw32/${MINGW_DEPS_FOLDER}/ ${PROJECT_SOURCE_DIR}/dependencies)
|
||||
SET(CMAKE_FIND_ROOT_PATH /usr/i686-w64-mingw32 /usr/lib/gcc/i686-w64-mingw32/4.9-posix ${PROJECT_SOURCE_DIR}/dependencies)
|
||||
|
||||
# adjust the default behaviour of the FIND_XXX() commands:
|
||||
# search headers and libraries in the target environment, search
|
||||
|
||||
BIN
data/CREDITS
@@ -17,11 +17,11 @@
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>0.9.3</string>
|
||||
<string>0.8.1</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>SPTK</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>0.9.3</string>
|
||||
<string>0.8.1</string>
|
||||
<key>CSResourcesFileMapped</key>
|
||||
<true/>
|
||||
<key>LSMinimumSystemVersion</key>
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<achievements>
|
||||
<achievement id="1" check-type="all-at-least" reset-type="never"
|
||||
name="Christoffel Columbus" description="Play every official track at least once." >
|
||||
<candela_city goal="1"/>
|
||||
<city goal="1"/>
|
||||
<cocoa_temple goal="1"/>
|
||||
<cornfield_crossing goal="1"/>
|
||||
<farm goal="1"/>
|
||||
<fortmagma goal="1"/>
|
||||
<gran_paradiso_island goal="1"/>
|
||||
<greenvalley goal="1"/>
|
||||
@@ -19,10 +19,9 @@
|
||||
<snowmountain goal="1"/>
|
||||
<snowtuxpeak goal="1"/>
|
||||
<stk_enterprise goal="1"/>
|
||||
<abyss goal="1"/>
|
||||
<subsea goal="1"/>
|
||||
<xr591 goal="1"/>
|
||||
<zengarden goal="1"/>
|
||||
<volcano_island goal="1"/>
|
||||
</achievement>
|
||||
<achievement id="2" check-type="all-at-least" reset-type="never"
|
||||
name="Strike!" description="Hit 10 karts with a bowling-ball.">
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0"?>
|
||||
<challenge version="2">
|
||||
<track id="candela_city" laps="3"/>
|
||||
<track id="city" laps="3"/>
|
||||
<mode major="single" minor="quickrace"/>
|
||||
<requirements trophies="70"/>
|
||||
|
||||
@@ -16,6 +16,4 @@
|
||||
<karts number="3"/>
|
||||
<requirements position="1"/>
|
||||
</easy>
|
||||
|
||||
<unlock kart="sara_the_wizard"/>
|
||||
</challenge>
|
||||
|
||||
@@ -1,19 +1,19 @@
|
||||
<?xml version="1.0"?>
|
||||
<challenge version="2">
|
||||
<track id="abyss" laps="3"/>
|
||||
<track id="farm" laps="3"/>
|
||||
<mode major="single" minor="quickrace"/>
|
||||
<requirements trophies="0"/>
|
||||
|
||||
<hard>
|
||||
<karts number="5"/>
|
||||
<requirements position="1" time="160"/>
|
||||
<requirements position="1" time="110"/>
|
||||
</hard>
|
||||
<medium>
|
||||
<karts number="4"/>
|
||||
<requirements time="197"/>
|
||||
<requirements time="125"/>
|
||||
</medium>
|
||||
<easy>
|
||||
<karts number="4"/>
|
||||
<requirements time="270"/>
|
||||
<requirements time="155"/>
|
||||
</easy>
|
||||
</challenge>
|
||||
@@ -10,10 +10,10 @@
|
||||
</hard>
|
||||
<medium>
|
||||
<karts number="4"/>
|
||||
<requirements time="187"/>
|
||||
<requirements time="185"/>
|
||||
</medium>
|
||||
<easy>
|
||||
<karts number="4"/>
|
||||
<requirements time="260"/>
|
||||
<requirements time="220"/>
|
||||
</easy>
|
||||
</challenge>
|
||||
|
||||
@@ -10,11 +10,11 @@
|
||||
</hard>
|
||||
<medium>
|
||||
<karts number="4"/>
|
||||
<requirements position="1"/>
|
||||
<requirements position="2"/>
|
||||
</medium>
|
||||
<easy>
|
||||
<karts number="3"/>
|
||||
<requirements position="1"/>
|
||||
<requirements position="3"/>
|
||||
</easy>
|
||||
</challenge>
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<challenge version="2">
|
||||
<track id="cocoa_temple" laps="3"/>
|
||||
<mode major="single" minor="quickrace"/>
|
||||
<requirements trophies="5"/>
|
||||
<requirements trophies="15"/>
|
||||
|
||||
<hard>
|
||||
<karts number="5"/>
|
||||
|
||||
@@ -6,15 +6,15 @@
|
||||
|
||||
<hard>
|
||||
<karts number="5"/>
|
||||
<requirements position="1" time="65"/>
|
||||
<requirements position="1" time="50"/>
|
||||
</hard>
|
||||
<medium>
|
||||
<karts number="5"/>
|
||||
<requirements position="1" time="85"/>
|
||||
<requirements position="1" time="65"/>
|
||||
</medium>
|
||||
<easy>
|
||||
<karts number="5"/>
|
||||
<requirements position="1" time="130"/>
|
||||
<requirements position="1" time="80"/>
|
||||
</easy>
|
||||
</challenge>
|
||||
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
<?xml version="1.0"?>
|
||||
<challenge version="2">
|
||||
<track id="cornfield_crossing" laps="3"/>
|
||||
<track id="subsea" laps="2"/>
|
||||
<mode major="single" minor="quickrace"/>
|
||||
<requirements trophies="0"/>
|
||||
|
||||
<hard>
|
||||
<karts number="5"/>
|
||||
<requirements position="1" time="165"/>
|
||||
<requirements position="1" time="200"/>
|
||||
</hard>
|
||||
<medium>
|
||||
<karts number="4"/>
|
||||
<requirements time="195"/>
|
||||
<requirements time="225"/>
|
||||
</medium>
|
||||
<easy>
|
||||
<karts number="4"/>
|
||||
@@ -1,19 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<challenge version="2">
|
||||
<track id="volcano_island" laps="2"/>
|
||||
<mode major="single" minor="quickrace"/>
|
||||
<requirements trophies="15"/>
|
||||
|
||||
<hard>
|
||||
<karts number="5"/>
|
||||
<requirements position="1"/>
|
||||
</hard>
|
||||
<medium>
|
||||
<karts number="4"/>
|
||||
<requirements position="1"/>
|
||||
</medium>
|
||||
<easy>
|
||||
<karts number="4"/>
|
||||
<requirements position="1"/>
|
||||
</easy>
|
||||
</challenge>
|
||||
BIN
data/fonts/AR_PL_SungtiL_GB0.png
Normal file
|
After Width: | Height: | Size: 46 KiB |
BIN
data/fonts/BigDigitFont.xml
Executable file
BIN
data/fonts/LayneHansom0.png
Normal file
|
After Width: | Height: | Size: 43 KiB |
BIN
data/fonts/LayneHansomBigDigits.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
data/fonts/Mplus2p_JP0.png
Normal file
|
After Width: | Height: | Size: 47 KiB |
BIN
data/fonts/StkChineseFont.xml
Executable file
BIN
data/fonts/StkFont.xml
Normal file
BIN
data/fonts/StkJapaneseFont.xml
Normal file
BIN
data/fonts/comix.png
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
22
data/fonts/materials.xml
Normal file
@@ -0,0 +1,22 @@
|
||||
<?xml version="1.0"?>
|
||||
<materials>
|
||||
<!-- Fonts -->
|
||||
<material name="title_font.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="title_font_2.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="sigmar0.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="comix.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="LayneHansom0.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="Mplus2p_JP0.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="rasheeq0.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="rasheeq3.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="rasheeq4.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="wqyMicroHei0.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="wqyMicroHei1.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="wqyMicroHei2.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="wqyMicroHei3.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="wqyMicroHei4.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="wqyMicroHei5.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="AR_PL_SungtiL_GB0.png" shader="unlit" lazy-load="Y"/>
|
||||
<material name="LayneHansomBigDigits.png" shader="unlit" lazy-load="Y"/>
|
||||
|
||||
</materials>
|
||||
BIN
data/fonts/rasheeq.xml
Normal file
BIN
data/fonts/rasheeq0.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
data/fonts/rasheeq1.png
Normal file
|
After Width: | Height: | Size: 9.1 KiB |
BIN
data/fonts/rasheeq3.png
Normal file
|
After Width: | Height: | Size: 8.0 KiB |
BIN
data/fonts/rasheeq4.png
Normal file
|
After Width: | Height: | Size: 9.0 KiB |
BIN
data/fonts/sigmar0.png
Executable file
|
After Width: | Height: | Size: 2.9 KiB |
BIN
data/fonts/title_font.png
Normal file
|
After Width: | Height: | Size: 174 KiB |
BIN
data/fonts/title_font.xml
Normal file
BIN
data/fonts/title_font_2.png
Normal file
|
After Width: | Height: | Size: 154 KiB |
BIN
data/fonts/wqyMicroHei0.png
Executable file
|
After Width: | Height: | Size: 61 KiB |
BIN
data/fonts/wqyMicroHei1.png
Executable file
|
After Width: | Height: | Size: 71 KiB |
BIN
data/fonts/wqyMicroHei2.png
Executable file
|
After Width: | Height: | Size: 78 KiB |
BIN
data/fonts/wqyMicroHei3.png
Executable file
|
After Width: | Height: | Size: 82 KiB |
BIN
data/fonts/wqyMicroHei4.png
Executable file
|
After Width: | Height: | Size: 75 KiB |
BIN
data/fonts/wqyMicroHei5.png
Executable file
|
After Width: | Height: | Size: 56 KiB |
BIN
data/fonts/wqyMicroHei6.png
Executable file
|
After Width: | Height: | Size: 41 KiB |
@@ -4,26 +4,27 @@
|
||||
<spreading angle="10" />
|
||||
|
||||
<velocity x="0.0"
|
||||
y="0.003"
|
||||
y="0.002"
|
||||
z="0.0" />
|
||||
|
||||
<material file="smoke_black.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="7"
|
||||
max="12" />
|
||||
<rate min="25"
|
||||
max="50" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="2500"
|
||||
max="5000" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="1.6"
|
||||
max="2.5"
|
||||
x-increase-factor="2.6"
|
||||
y-increase-factor="2.6" />
|
||||
<size min="0.6"
|
||||
max="1.5" />
|
||||
|
||||
<color min="50 50 50"
|
||||
max="100 100 100" />
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="1000" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -1,31 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
<!-- For sky particles, the size of the box is ignored -->
|
||||
<particles emitter="box" randomize-initial-y="true" box_x="100.0" box_y="100" box_z="120.0">
|
||||
|
||||
<spreading angle="3" />
|
||||
|
||||
<velocity x="-0.00"
|
||||
y="-0.005"
|
||||
z="-0.00" />
|
||||
|
||||
<material file="confetti.png" clampu="Y" clampv="Y" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="500"
|
||||
max="1000" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="8500"
|
||||
max="9500" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.10"
|
||||
max="0.30" />
|
||||
|
||||
<color min="40 40 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<wind flips="Y" />
|
||||
|
||||
</particles>
|
||||
@@ -1,31 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
<!-- For sky particles, the size of the box is ignored -->
|
||||
<particles emitter="box" randomize-initial-y="true" box_x="100.0" box_y="100" box_z="120.0">
|
||||
|
||||
<spreading angle="3" />
|
||||
|
||||
<velocity x="-0.00"
|
||||
y="-0.005"
|
||||
z="-0.00" />
|
||||
|
||||
<material file="snowflake.png" clampu="Y" clampv="Y" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="500"
|
||||
max="1000" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="8500"
|
||||
max="9500" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.10"
|
||||
max="0.30" />
|
||||
|
||||
<color min="40 40 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<wind flips="Y" />
|
||||
|
||||
</particles>
|
||||
@@ -26,4 +26,7 @@
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<fadeout time="3000" />
|
||||
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -10,21 +10,24 @@
|
||||
<material file="explode.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="400"
|
||||
max="600" />
|
||||
<rate min="500"
|
||||
max="800" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="1000"
|
||||
max="1200" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.60"
|
||||
max="0.85"
|
||||
<size min="0.65"
|
||||
max="0.95"
|
||||
x-increase-factor="0.6"
|
||||
y-increase-factor="0.6"
|
||||
/>
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="800" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -10,21 +10,24 @@
|
||||
<material file="explode.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="400"
|
||||
max="600" />
|
||||
<rate min="500"
|
||||
max="800" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="1000"
|
||||
max="1200" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.60"
|
||||
max="0.85"
|
||||
<size min="0.65"
|
||||
max="0.95"
|
||||
x-increase-factor="0.6"
|
||||
y-increase-factor="0.6"
|
||||
/>
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="800" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -10,21 +10,24 @@
|
||||
<material file="explode.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="400"
|
||||
max="600" />
|
||||
<rate min="500"
|
||||
max="800" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="1000"
|
||||
max="1200" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.60"
|
||||
max="0.85"
|
||||
<size min="0.65"
|
||||
max="0.95"
|
||||
x-increase-factor="0.6"
|
||||
y-increase-factor="0.6"
|
||||
/>
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="800" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<particles emitter="sphere" radius="0.1">
|
||||
|
||||
<spreading angle="180" />
|
||||
|
||||
<velocity x="0.000"
|
||||
y="0.0035"
|
||||
z="0.000" />
|
||||
|
||||
<material file="explode.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="100"
|
||||
max="150" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="700"
|
||||
max="900" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.8"
|
||||
max="1.0"
|
||||
x-increase-factor="0.6"
|
||||
y-increase-factor="0.6"
|
||||
/>
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
</particles>
|
||||
@@ -18,10 +18,12 @@
|
||||
max="500" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.55"
|
||||
max="0.75" />
|
||||
<size min="0.6"
|
||||
max="0.8" />
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<fadeout time="300" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<particles emitter="sphere" radius="20.5">
|
||||
|
||||
<spreading angle="120" />
|
||||
|
||||
<velocity x="0.002"
|
||||
y="0.000"
|
||||
z="0.000" />
|
||||
|
||||
<material file="stktex_nebulaCloud_a.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="1"
|
||||
max="2" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="20000"
|
||||
max="30000" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="20.5"
|
||||
max="45.0"
|
||||
x-increase-factor="1.6"
|
||||
y-increase-factor="1.6" />
|
||||
|
||||
<color min="0 0 0"
|
||||
max="255 255 255" />
|
||||
|
||||
</particles>
|
||||
@@ -1,29 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<particles emitter="box" box_x="0.5" box_y="0.5" box_z="0.5">
|
||||
|
||||
<spreading angle="45" />
|
||||
|
||||
<velocity x="0.000"
|
||||
y="0.005"
|
||||
z="0.000" />
|
||||
|
||||
<material file="gfx_bubble_a.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="8"
|
||||
max="15" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="2000"
|
||||
max="3000" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.5"
|
||||
max="0.8"
|
||||
x-increase-factor="1.6"
|
||||
y-increase-factor="1.6" />
|
||||
|
||||
<color min="0 0 0"
|
||||
max="255 255 255" />
|
||||
|
||||
</particles>
|
||||
@@ -26,4 +26,7 @@
|
||||
<color min="0 0 0"
|
||||
max="255 255 255" />
|
||||
|
||||
<fadeout time="5000" />
|
||||
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -25,7 +25,11 @@
|
||||
|
||||
<color min="40 40 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="100" />
|
||||
|
||||
<wind flips="Y" />
|
||||
<wind speed="0.16"
|
||||
flips="Y" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<particles emitter="sphere" radius="0.5">
|
||||
|
||||
<spreading angle="180" />
|
||||
|
||||
<velocity x="0.003"
|
||||
y="0.0003"
|
||||
z="0.003" />
|
||||
|
||||
<material file="gfx_sparkFire_a.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="65"
|
||||
max="100" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="1700"
|
||||
max="1700" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.7"
|
||||
max="1.1"
|
||||
x-increase-factor="1.3"
|
||||
y-increase-factor="1.3"
|
||||
/>
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 0 0" />
|
||||
|
||||
</particles>
|
||||
@@ -1,30 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<particles emitter="sphere" radius="0.5">
|
||||
|
||||
<spreading angle="180" />
|
||||
|
||||
<velocity x="0.03"
|
||||
y="0.003"
|
||||
z="0.03" />
|
||||
|
||||
<material file="gfx_sparkGreen_a.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="65"
|
||||
max="100" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="2700"
|
||||
max="2700" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.5"
|
||||
max="0.8"
|
||||
x-increase-factor="1.1"
|
||||
y-increase-factor="1.3"
|
||||
/>
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 0 0" />
|
||||
|
||||
</particles>
|
||||
@@ -27,5 +27,9 @@
|
||||
|
||||
<color min="40 40 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="100" />
|
||||
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -25,5 +25,11 @@
|
||||
|
||||
<color min="40 40 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="100" />
|
||||
|
||||
<wind speed="0.16"
|
||||
flips="Y" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -26,4 +26,7 @@
|
||||
<color min="0 0 0"
|
||||
max="255 255 255" />
|
||||
|
||||
<fadeout time="5000" />
|
||||
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -26,4 +26,7 @@
|
||||
<color min="0 0 0"
|
||||
max="255 255 255" />
|
||||
|
||||
<fadeout time="5000" />
|
||||
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -27,5 +27,9 @@
|
||||
|
||||
<color min="40 40 255"
|
||||
max="255 255 255" />
|
||||
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="1000" />
|
||||
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<particles emitter="sphere" radius="0.5">
|
||||
|
||||
<spreading angle="90" />
|
||||
|
||||
<velocity x="0.000"
|
||||
y="0.003"
|
||||
z="0.000" />
|
||||
|
||||
<material file="gfx_earthJetblast_a.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="900"
|
||||
max="1000" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="300"
|
||||
max="1000" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.3"
|
||||
max="0.7"
|
||||
x-increase-factor="1.2"
|
||||
y-increase-factor="1.2" />
|
||||
|
||||
<color min="0 0 0"
|
||||
max="255 255 255" />
|
||||
|
||||
</particles>
|
||||
@@ -1,29 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<particles emitter="sphere" radius="0.1">
|
||||
|
||||
<spreading angle="12" />
|
||||
|
||||
<velocity x="0.000"
|
||||
y="0.000"
|
||||
z="0.005" />
|
||||
|
||||
<material file="particle_water.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="30"
|
||||
max="50" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="500"
|
||||
max="1000" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.1"
|
||||
max="0.2"
|
||||
x-increase-factor="1.3"
|
||||
y-increase-factor="1.3" />
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
</particles>
|
||||
@@ -18,7 +18,7 @@
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="1000"
|
||||
max="1500" />
|
||||
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.08"
|
||||
max="0.15"
|
||||
@@ -27,5 +27,11 @@
|
||||
|
||||
<color min="40 40 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="100" />
|
||||
|
||||
<wind speed="0.16"
|
||||
flips="Y" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -25,5 +25,11 @@
|
||||
|
||||
<color min="40 40 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="100" />
|
||||
|
||||
<wind speed="0.16"
|
||||
flips="Y" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -26,5 +26,8 @@
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="1000" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<particles emitter="box" box_x="0.05" box_y="0.05" box_z="0.10">
|
||||
|
||||
<spreading angle="2" />
|
||||
|
||||
<velocity x="0.0"
|
||||
y="0.005"
|
||||
z="-0.01" />
|
||||
|
||||
<material file="smoke.png" />
|
||||
|
||||
<!-- Amount of particles emitted per second -->
|
||||
<rate min="200"
|
||||
max="300" />
|
||||
|
||||
<!-- Minimal and maximal lifetime of a particle, in milliseconds. -->
|
||||
<lifetime min="10"
|
||||
max="40" />
|
||||
|
||||
<!-- Size of the particles -->
|
||||
<size min="0.05"
|
||||
max="0.1"
|
||||
x-increase-factor="5"
|
||||
y-increase-factor="5"
|
||||
/>
|
||||
|
||||
<color min="255 255 255"
|
||||
max="0 0 0" />
|
||||
|
||||
</particles>
|
||||
@@ -23,5 +23,8 @@
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="75" />
|
||||
|
||||
</particles>
|
||||
|
||||
@@ -26,5 +26,8 @@
|
||||
|
||||
<color min="255 255 255"
|
||||
max="255 255 255" />
|
||||
|
||||
<!-- How much time in milliseconds before the particle is fully faded out -->
|
||||
<fadeout time="50" />
|
||||
|
||||
</particles>
|
||||
|
||||