Skip to content

Commit

Permalink
Misc++, bot$weapon
Browse files Browse the repository at this point in the history
- ozCore
  * Log: indenting with substring of INDENT_BUFFER
- client
  * SDL_main inclusion avoided
- builder
  * '_weapon.' -> '$' for weapon names
- ports
  * attempt to build LuaJIT
- scripts
  * SDK paths sourced from ./sdkPaths
- 2013 update
  • Loading branch information
ducakar committed Dec 28, 2012
1 parent 9208320 commit c0f2f87
Show file tree
Hide file tree
Showing 434 changed files with 658 additions and 633 deletions.
12 changes: 6 additions & 6 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,15 @@ else()
endif()

if( ANDROID )
set( CMAKE_SYSTEM_NAME Android )
set( OZ_SDL2 ON )
elseif( NACL )
set( CMAKE_SYSTEM_NAME NaCl )
set( OZ_NET OFF )
set( OZ_SDL2 OFF )
elseif( WIN32 )
set( OZ_STANDALONE ON )
endif()

set( OZ_PLATFORM_NAME "${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}" )
set( OZ_PLATFORM_NAME "${PLATFORM_NAME}-${CMAKE_SYSTEM_PROCESSOR}" )

if( OZ_STANDALONE )
set( CMAKE_INSTALL_PREFIX "/OpenZone-${OZ_VERSION}" )
Expand Down Expand Up @@ -192,11 +190,11 @@ if( ${CMAKE_CXX_COMPILER_ID} STREQUAL Clang )
# AddressSanitizer.
# set( flags "${flags} -fsanitize=address" )
elseif( ${CMAKE_CXX_COMPILER_VERSION} VERSION_LESS 4.5 )
set( flags "-pipe -std=gnu++0x" )
set( flags "-std=gnu++0x" )
elseif( ANDROID )
set( flags "-pipe -std=gnu++0x -pedantic -fstrict-enums" )
set( flags "-std=gnu++0x -pedantic -fstrict-enums" )
else()
set( flags "-pipe -std=c++0x -pedantic -fstrict-enums" )
set( flags "-std=c++0x -pedantic -fstrict-enums" )
endif()

set( flags "${flags} -fvisibility-inlines-hidden -fno-exceptions -fno-rtti -ffast-math" )
Expand All @@ -216,6 +214,8 @@ else()
endif()

set( CMAKE_CXX_FLAGS "${flags} ${CMAKE_CXX_FLAGS}" )
# set( CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -fdata-sections -ffunction-sections" )
# set( CMAKE_EXE_LINKER_FLAGS_RELEASE "${CMAKE_EXE_LINKER_FLAGS} -Wl,--gc-sections" )

# Strings for BuildInfo class.
string( TOUPPER "CMAKE_CXX_FLAGS_${CMAKE_BUILD_TYPE}" OZ_CXX_FLAGS )
Expand Down
2 changes: 1 addition & 1 deletion ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
+ HashIndex and HashString merged into new HashMap template class with an arbitrary key type
+ new HashSet template class: hashtable of key-only elements instead of key-value pairs
* new Mat33 class
* SIMD support in linear algebra classes
* SIMD support for linear algebra classes
* new SpinLock class
* ALSA and OSS back-ends for System::bell()
* linear algebra classes added as primitives to streams, Log and JSON
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ One of the following commands must be given:
### `ports.sh [clean | fetch | build]` ###

This script is used to build libraries required by OpenZone for some platforms. Currently it builds
zlib, physfs, SDL, SDL_ttf, OpenAL Soft, squish for NaCl-x86_64 and NaCl-i686.
all required libraries for NaCl and Android configurations that are not provided by SDKs.
The following commands may be given (`build` is assumed if none):

- `clean`: Delete everything in `ports` directory except downloaded sources.
Expand Down
2 changes: 2 additions & 0 deletions TODO.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ CURRENT

2.0

- ozCore
* optional double precision
- ozDynamics
* finish ozDynamics
- matrix
Expand Down
7 changes: 3 additions & 4 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ platforms=(
Linux-x86_64-Clang
Linux-i686
Linux-i686-Clang
# FreeBSD-x86_64-Clang
# FreeBSD-i686-Clang
Windows-i686
NaCl-x86_64
# NaCl-x86_64-glibc
Expand All @@ -29,10 +31,7 @@ platforms=(
Android14-MIPS
)

# Extract path to NaCl SDK from CMake toolchain files.
naclPrefix=`sed -r '/ PLATFORM_PREFIX / !d; s|.*\"(.*)\".*|\1|' cmake/NaCl-x86_64.Toolchain.cmake`
naclGNUPrefix=`sed -r '/ PLATFORM_PREFIX / !d; s|.*\"(.*)\".*|\1|' cmake/NaCl-x86_64-glibc.Toolchain.cmake`
pnaclPrefix=`sed -r '/ PLATFORM_PREFIX / !d; s|.*\"(.*)\".*|\1|' cmake/PNaCl.Toolchain.cmake`
source ./sdkPaths

function clean()
{
Expand Down
1 change: 1 addition & 0 deletions cmake/Android14-ARM.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
set( ANDROID ON )

set( PLATFORM_NAME "Android" )
set( PLATFORM_EMBEDDED ON )
set( PLATFORM_TRIPLET "arm-linux-androideabi" )
set( PLATFORM_PROC_PREFIX "armeabi" )
Expand Down
1 change: 1 addition & 0 deletions cmake/Android14-ARMv7a.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
set( ANDROID ON )

set( PLATFORM_NAME "Android" )
set( PLATFORM_EMBEDDED ON )
set( PLATFORM_TRIPLET "arm-linux-androideabi" )
set( PLATFORM_PROC_PREFIX "armeabi-v7a" )
Expand Down
1 change: 1 addition & 0 deletions cmake/Android14-MIPS.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
set( ANDROID ON )

set( PLATFORM_NAME "Android" )
set( PLATFORM_EMBEDDED ON )
set( PLATFORM_TRIPLET "mipsel-linux-android" )
set( PLATFORM_PROC_PREFIX "mips" )
Expand Down
1 change: 1 addition & 0 deletions cmake/Android14-i686.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
set( ANDROID ON )

set( PLATFORM_NAME "Android" )
set( PLATFORM_EMBEDDED ON )
set( PLATFORM_TRIPLET "i686-linux-android" )
set( PLATFORM_PROC_PREFIX "x86" )
Expand Down
9 changes: 9 additions & 0 deletions cmake/FreeBSD-i686.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
set( PLATFORM_NAME "FreeBSD" )
set( PLATFORM_PREFIX "" )

set( CMAKE_SYSTEM_NAME "Linux" CACHE STRING "Target system." )
set( CMAKE_SYSTEM_PROCESSOR "i686" CACHE STRING "Target processor." )
set( CMAKE_C_COMPILER "/usr/local/bin/clang" )
set( CMAKE_CXX_COMPILER "/usr/local/bin/clang++" )
set( CMAKE_C_FLAGS "-march=i686 -m32 -msse3" CACHE STRING "" )
set( CMAKE_CXX_FLAGS "-march=i686 -m32 -msse3" CACHE STRING "" )
9 changes: 9 additions & 0 deletions cmake/FreeBSD-x86_64.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
set( PLATFORM_NAME "FreeBSD" )
set( PLATFORM_PREFIX "" )

set( CMAKE_SYSTEM_NAME "Linux" CACHE STRING "Target system." )
set( CMAKE_SYSTEM_PROCESSOR "x86_64" CACHE STRING "Target processor." )
set( CMAKE_C_COMPILER "/usr/local/bin/clang" )
set( CMAKE_CXX_COMPILER "/usr/local/bin/clang++" )
set( CMAKE_C_FLAGS "-march=x86-64 -m64 -msse3" CACHE STRING "" )
set( CMAKE_CXX_FLAGS "-march=x86-64 -m64 -msse3" CACHE STRING "" )
1 change: 1 addition & 0 deletions cmake/Linux-i686-Clang.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
set( PLATFORM_NAME "Linux" )
set( PLATFORM_PREFIX "" )

set( CMAKE_SYSTEM_NAME "Linux" CACHE STRING "Target system." )
Expand Down
1 change: 1 addition & 0 deletions cmake/Linux-i686.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
set( PLATFORM_NAME "Linux" )
set( PLATFORM_PREFIX "" )

set( CMAKE_SYSTEM_NAME "Linux" CACHE STRING "Target system." )
Expand Down
1 change: 1 addition & 0 deletions cmake/Linux-x86_64-Clang.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
set( PLATFORM_NAME "Linux" )
set( PLATFORM_PREFIX "" )

set( CMAKE_SYSTEM_NAME "Linux" CACHE STRING "Target system." )
Expand Down
1 change: 1 addition & 0 deletions cmake/Linux-x86_64.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
set( PLATFORM_NAME "Linux" )
set( PLATFORM_PREFIX "" )

set( CMAKE_SYSTEM_NAME "Linux" CACHE STRING "Target system." )
Expand Down
1 change: 1 addition & 0 deletions cmake/NaCl-i686-glibc.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
set( NACL ON )
set( NACL_GLIBC ON )

set( PLATFORM_NAME "NaCl" )
set( PLATFORM_EMBEDDED ON )
set( PLATFORM_TRIPLET "i686-nacl" )
set( PLATFORM_PREFIX "/home/davorin/Projects/nacl_sdk/pepper_23/toolchain/linux_x86_glibc" )
Expand Down
1 change: 1 addition & 0 deletions cmake/NaCl-i686.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
set( NACL ON )

set( PLATFORM_NAME "NaCl" )
set( PLATFORM_EMBEDDED ON )
set( PLATFORM_TRIPLET "i686-nacl" )
set( PLATFORM_PREFIX "/home/davorin/Projects/nacl_sdk/pepper_23/toolchain/linux_x86_newlib" )
Expand Down
1 change: 1 addition & 0 deletions cmake/NaCl-x86_64-glibc.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
set( NACL ON )
set( NACL_GLIBC ON )

set( PLATFORM_NAME "NaCl" )
set( PLATFORM_EMBEDDED ON )
set( PLATFORM_TRIPLET "x86_64-nacl" )
set( PLATFORM_PREFIX "/home/davorin/Projects/nacl_sdk/pepper_23/toolchain/linux_x86_glibc" )
Expand Down
1 change: 1 addition & 0 deletions cmake/NaCl-x86_64.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
set( NACL ON )

set( PLATFORM_NAME "NaCl" )
set( PLATFORM_EMBEDDED ON )
set( PLATFORM_TRIPLET "x86_64-nacl" )
set( PLATFORM_PREFIX "/home/davorin/Projects/nacl_sdk/pepper_23/toolchain/linux_x86_newlib" )
Expand Down
1 change: 1 addition & 0 deletions cmake/PNaCl.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
set( NACL ON )

set( PLATFORM_NAME "PNaCl" )
set( PLATFORM_EMBEDDED ON )
set( PLATFORM_TRIPLET "pnacl" )
set( PLATFORM_PREFIX "/home/davorin/Projects/nacl_sdk/pepper_canary/toolchain/linux_x86_pnacl/newlib" )
Expand Down
1 change: 1 addition & 0 deletions cmake/Windows-i686.Toolchain.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
set( MINGW32 ON )

set( PLATFORM_NAME "Windows" )
set( PLATFORM_TRIPLET "i486-mingw32" )
set( PLATFORM_PREFIX "/usr/${PLATFORM_TRIPLET}" )
set( PLATFORM_TOOL_PREFIX "${PLATFORM_PREFIX}" )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"nFrags": 2,

"imagoType": "MD2Weapon",
"imagoModel": "bauul_weapon.skull",
"imagoModel": "bauul$skull",

"audioType": "Basic",
"audioSounds":
Expand Down
2 changes: 1 addition & 1 deletion data/oz_main/class/bauul.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"nItems": 16,
"defaultItems":
[
"bauul_weapon.skull"
"bauul$skull"
],
"weaponItem": 0,

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"dim": [ 0.17, 0.75, 0.08 ],

"life": 100,
"resistance": 40,
"resistance": 50,

"mass": 5,
"lift": 0.8,
Expand All @@ -26,7 +26,7 @@
"nFrags": 4,

"imagoType": "MD2Weapon",
"imagoModel": "hobgoblin_weapon.plasmagun",
"imagoModel": "hobgoblin$plasmagun",

"audioType": "Basic",
"audioSounds":
Expand Down
2 changes: 1 addition & 1 deletion data/oz_main/class/beast.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"nItems": 8,
"defaultItems":
[
"beast_weapon.plasmagun",
"beast$plasmagun",
"musicPlayer",
"firstAid",
"cvicek"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"dim": [ 0.28, 0.60, 0.135 ],

"life": 100,
"resistance": 40,
"resistance": 50,

"mass": 5,
"lift": 0.8,
Expand All @@ -25,7 +25,7 @@
"nFrags": 4,

"imagoType": "MD2Weapon",
"imagoModel": "ratamahatta_weapon.chaingun",
"imagoModel": "ratamahatta$chaingun",

"audioType": "Basic",
"audioSounds":
Expand Down
2 changes: 1 addition & 1 deletion data/oz_main/class/cyborg.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"nItems": 8,
"defaultItems":
[
"cyborg_weapon.chaingun",
"cyborg$chaingun",
"galileo",
"musicPlayer"
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
"dim": [ 0.13, 0.27, 0.05 ],

"life": 100,
"resistance": 40,
"resistance": 50,

"mass": 10,
"mass": 5,
"lift": 0.8,

"nRounds": -1,
Expand All @@ -24,7 +24,7 @@
"nFrags": 2,

"imagoType": "MD2Weapon",
"imagoModel": "droid_weapon.blaster",
"imagoModel": "droid$blaster",

"audioType": "Basic",
"audioSounds":
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"dim": [ 0.15, 0.48, 0.07 ],

"life": 100,
"resistance": 40,
"resistance": 50,

"mass": 10,
"lift": 0.8,
Expand All @@ -24,7 +24,7 @@
"nFrags": 2,

"imagoType": "MD2Weapon",
"imagoModel": "droid_weapon.chaingun",
"imagoModel": "droid$chaingun",

"audioType": "Basic",
"audioSounds":
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"dim": [ 0.14, 0.32, 0.11 ],

"life": 100,
"resistance": 40,
"resistance": 50,

"mass": 10,
"lift": 0.8,
Expand All @@ -24,7 +24,7 @@
"nFrags": 2,

"imagoType": "MD2Weapon",
"imagoModel": "droid_weapon.grenadeLauncher",
"imagoModel": "droid$grenadeLauncher",

"audioType": "Basic",
"audioSounds":
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"dim": [ 0.15, 0.5, 0.05 ],

"life": 100,
"resistance": 40,
"resistance": 50,

"mass": 10,
"lift": 0.8,
Expand All @@ -24,7 +24,7 @@
"nFrags": 2,

"imagoType": "MD2Weapon",
"imagoModel": "droid_weapon.hyperblaster",
"imagoModel": "droid$hyperblaster",

"audioType": "Basic",
"audioSounds":
Expand Down
2 changes: 1 addition & 1 deletion data/oz_main/class/droid.OOM-9.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"nItems": 8,
"defaultItems":
[
"droid_weapon.blaster"
"droid$blaster"
],
"weaponItem": 0,

Expand Down
4 changes: 2 additions & 2 deletions data/oz_main/class/droid.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@
"nItems": 8,
"defaultItems":
[
"droid_weapon.blaster",
"droid_weapon.hyperblaster",
"droid$blaster",
"droid$hyperblaster",
"bomb"
],
"weaponItem": 1,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,8 @@
"dim": [ 0.18, 0.42, 0.04 ],

"life": 100,
"resistance": 40,

"mass": 10,
"mass": 5,
"lift": 0.7,

"nRounds": -1,
Expand All @@ -22,7 +21,7 @@
"nFrags": 2,

"imagoType": "MD2Weapon",
"imagoModel": "goblin_weapon.axe",
"imagoModel": "goblin$axe",

"audioType": "Basic",
"audioSounds":
Expand Down
2 changes: 1 addition & 1 deletion data/oz_main/class/goblin.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"nItems": 4,
"defaultItems":
[
"goblin_weapon.axe",
"goblin$axe",
"cvicek"
],
"weaponItem": 0,
Expand Down
Loading

0 comments on commit c0f2f87

Please sign in to comment.