├── readme.md ├── bin ├── amd64 │ ├── steam_appid.txt │ ├── SDL2.dll │ ├── sndfile.dll │ ├── zlib1.dll │ ├── OpenAL32.dll │ ├── freetype.dll │ ├── libjpeg-9.dll │ ├── libtiff-5.dll │ ├── libwebp-4.dll │ ├── libwebp-7.dll │ ├── soft_oal.dll │ ├── SDL2_image.dll │ ├── discord-rpc.dll │ ├── libavif-16.dll │ ├── libpng16-16.dll │ ├── libsteam_api.so │ ├── steam_api64.dll │ ├── libdiscord-rpc.so │ ├── libwebpdemux-2.dll │ └── libwinpthread-1.dll ├── x86 │ ├── steam_appid.txt │ ├── SDL2.dll │ ├── zlib1.dll │ ├── OpenAL32.dll │ ├── freetype.dll │ ├── libjpeg-9.dll │ ├── libtiff-5.dll │ ├── libwebp-4.dll │ ├── libwebp-7.dll │ ├── sndfile.dll │ ├── soft_oal.dll │ ├── steam_api.dll │ ├── SDL2_image.dll │ ├── discord-rpc.dll │ ├── libavif-16.dll │ ├── libpng16-16.dll │ ├── libsteam_api.so │ ├── libwebpdemux-2.dll │ └── libwinpthread-1.dll ├── LICENSE.SDL.txt ├── LICENSE.tiff.txt ├── LICENSE.dav1d.txt ├── LICENSE.zlib.txt ├── LICENSE.webp.txt └── LICENSE.ogg-vorbis.txt ├── .github ├── CODEOWNERS ├── PULL_REQUEST_TEMPLATE.md ├── FUNDING.yml ├── SUPPORT.md ├── CODE_OF_CONDUCT.md └── ISSUE_TEMPLATE.md ├── src ├── shared │ ├── pch.cpp │ ├── discord_register.h │ ├── genkey.cpp │ └── cube.h ├── redeclipse.ico ├── lib │ ├── x86 │ │ ├── SDL2.lib │ │ ├── enet.lib │ │ ├── zlib1.lib │ │ ├── sndfile.lib │ │ ├── OpenAL32.lib │ │ ├── SDL2_image.lib │ │ ├── freetype.lib │ │ └── steam_api.lib │ └── amd64 │ │ ├── SDL2.lib │ │ ├── enet.lib │ │ ├── zlib1.lib │ │ ├── OpenAL32.lib │ │ ├── freetype.lib │ │ ├── sndfile.lib │ │ ├── SDL2_image.lib │ │ └── steam_api64.lib ├── steam │ ├── isteamvideo.h │ ├── steamhttpenums.h │ ├── isteaminventory.h │ ├── steam_gameserver.h │ ├── isteamgamecoordinator.h │ ├── isteamgameserverstats.h │ ├── isteamps3overlayrenderer.h │ ├── steamencryptedappticket.h │ ├── license.txt │ ├── steamuniverse.h │ ├── isteamappticket.h │ ├── isteamparentalsettings.h │ └── isteammusic.h ├── install │ ├── win │ │ ├── finish.bmp │ │ ├── header.bmp │ │ └── AccessControl.dll │ ├── nix │ │ ├── genkey.am │ │ ├── tessfont.am │ │ ├── redeclipse_x128.png │ │ ├── redeclipse_x16.png │ │ ├── redeclipse_x32.png │ │ ├── redeclipse_x48.png │ │ ├── redeclipse_x64.png │ │ ├── redeclipse.am │ │ ├── redeclipse-server.am │ │ └── redeclipse.desktop.am │ └── steam │ │ ├── depot_build.vdf │ │ └── app_build.vdf ├── vcpp │ └── lib │ │ ├── x86 │ │ ├── steam_api.lib │ │ └── discord-rpc.lib │ │ └── amd64 │ │ ├── discord-rpc.lib │ │ └── steam_api64.lib ├── include │ ├── AL │ │ └── efx-creative.h │ ├── SDL_revision.h │ ├── SDL_opengles2_gl2platform.h │ ├── SDL_copying.h │ ├── SDL_types.h │ ├── SDL_name.h │ ├── ft2build.h │ ├── SDL_opengles.h │ ├── freetype │ │ ├── config │ │ │ └── ftmodule.h │ │ └── ttunpat.h │ ├── close_code.h │ ├── SDL_opengles2.h │ ├── SDL_test_memory.h │ ├── SDL_test_log.h │ ├── SDL_test.h │ ├── SDL_quit.h │ └── SDL_test_compare.h ├── scripts │ ├── cube2font-txt │ ├── servinit-comments │ ├── wiki-guidelines │ ├── install_deploy.sh │ ├── wiki-contributors │ └── servinit-defaults ├── enet │ ├── README │ ├── include │ │ └── enet │ │ │ ├── utility.h │ │ │ ├── types.h │ │ │ ├── time.h │ │ │ ├── callbacks.h │ │ │ ├── list.h │ │ │ ├── unix.h │ │ │ └── win32.h │ ├── Makefile │ ├── LICENSE │ ├── callbacks.c │ ├── check_cflags.sh │ └── list.c ├── semaphore │ ├── deploy.yml │ └── semaphore.yml ├── dpiaware.manifest ├── support │ ├── jsmn.txt │ └── jsmn.h ├── redeclipse.rc └── engine │ ├── world.h │ ├── version.h │ ├── menus.cpp │ └── wind.h ├── config ├── fx │ ├── wind.cfg │ ├── other │ │ ├── other.cfg │ │ ├── drone.cfg │ │ ├── janitor.cfg │ │ └── prize.cfg │ ├── lib.cfg │ ├── light.cfg │ ├── particle.cfg │ ├── weapons │ │ ├── airblast.cfg │ │ ├── splash.cfg │ │ ├── weapons.cfg │ │ ├── flame.cfg │ │ └── muzzle.cfg │ ├── projs │ │ ├── airblast.cfg │ │ ├── casing.cfg │ │ ├── debris.cfg │ │ ├── gib.cfg │ │ ├── shrapnel.cfg │ │ ├── projs.cfg │ │ └── bullet.cfg │ ├── sound.cfg │ └── std.cfg ├── tool │ ├── ents │ │ ├── envmap.cfg │ │ ├── worldcol.cfg │ │ ├── affinity.cfg │ │ ├── playerstart.cfg │ │ ├── checkpoint.cfg │ │ ├── physics.cfg │ │ ├── trigger.cfg │ │ ├── pusher.cfg │ │ ├── weapon.cfg │ │ ├── camera.cfg │ │ ├── wind.cfg │ │ ├── sound.cfg │ │ ├── actor.cfg │ │ ├── route.cfg │ │ ├── rail.cfg │ │ ├── mapui.cfg │ │ ├── decal.cfg │ │ ├── soundenv.cfg │ │ ├── lightfx.cfg │ │ ├── light.cfg │ │ └── teleport.cfg │ ├── binds │ │ ├── legacy.cfg │ │ └── default.cfg │ └── toolphysics.cfg ├── map │ ├── sounds.cfg │ ├── decals.cfg │ ├── default.cfg │ ├── models.cfg │ ├── textures.cfg │ └── material.cfg ├── ui │ ├── dyn │ │ ├── package.cfg │ │ └── builtins.cfg │ ├── tool │ │ ├── ents │ │ │ ├── toolworldcol.cfg │ │ │ ├── toolweapon.cfg │ │ │ ├── toolenvmap.cfg │ │ │ ├── toollight.cfg │ │ │ ├── toolphysics.cfg │ │ │ ├── toollightfx.cfg │ │ │ ├── toolaffinity.cfg │ │ │ ├── toolplayerstart.cfg │ │ │ └── toolwind.cfg │ │ └── toolview │ │ │ └── widgets │ │ │ ├── tooltexinfo.cfg │ │ │ └── toolcollapsegroup.cfg │ ├── package.cfg │ ├── tool.cfg │ ├── game │ │ ├── game.cfg │ │ └── widgets │ │ │ ├── widgets.cfg │ │ │ ├── autoscroll.cfg │ │ │ ├── textinput.cfg │ │ │ ├── group.cfg │ │ │ ├── shadow.cfg │ │ │ └── decortext.cfg │ ├── events │ │ ├── game.cfg │ │ ├── team.cfg │ │ ├── defend.cfg │ │ ├── bomber.cfg │ │ ├── balance.cfg │ │ └── item.cfg │ └── tips.cfg ├── fx.cfg ├── tool.cfg ├── comp │ ├── package.cfg │ ├── noise.cfg │ ├── rainbow.cfg │ ├── texmask.cfg │ ├── caustic.cfg │ ├── feather.cfg │ └── hint.cfg ├── glsl.cfg ├── defaults.cfg ├── legacy.cfg └── glsl │ └── edit.cfg ├── redeclipse_server.sh ├── redeclipse_server.bat ├── .gitattributes ├── .gitignore ├── redeclipse.bat └── doc └── readme_tesseract.txt /readme.md: -------------------------------------------------------------------------------- 1 | readme.txt -------------------------------------------------------------------------------- /bin/amd64/steam_appid.txt: -------------------------------------------------------------------------------- 1 | 967460 -------------------------------------------------------------------------------- /bin/x86/steam_appid.txt: -------------------------------------------------------------------------------- 1 | 967460 -------------------------------------------------------------------------------- /.github/CODEOWNERS: -------------------------------------------------------------------------------- 1 | * @redeclipse/core 2 | -------------------------------------------------------------------------------- /src/shared/pch.cpp: -------------------------------------------------------------------------------- 1 | #include "cube.h" 2 | -------------------------------------------------------------------------------- /bin/x86/SDL2.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/SDL2.dll -------------------------------------------------------------------------------- /config/fx/wind.cfg: -------------------------------------------------------------------------------- 1 | WIND_EMIT_IMPULSE = 1, 2 | WIND_EMIT_VECTORED = (<< 1 1) 3 | -------------------------------------------------------------------------------- /bin/amd64/SDL2.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/SDL2.dll -------------------------------------------------------------------------------- /bin/x86/zlib1.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/zlib1.dll -------------------------------------------------------------------------------- /src/redeclipse.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/redeclipse.ico -------------------------------------------------------------------------------- /bin/amd64/sndfile.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/sndfile.dll -------------------------------------------------------------------------------- /bin/amd64/zlib1.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/zlib1.dll -------------------------------------------------------------------------------- /bin/x86/OpenAL32.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/OpenAL32.dll -------------------------------------------------------------------------------- /bin/x86/freetype.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/freetype.dll -------------------------------------------------------------------------------- /bin/x86/libjpeg-9.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/libjpeg-9.dll -------------------------------------------------------------------------------- /bin/x86/libtiff-5.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/libtiff-5.dll -------------------------------------------------------------------------------- /bin/x86/libwebp-4.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/libwebp-4.dll -------------------------------------------------------------------------------- /bin/x86/libwebp-7.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/libwebp-7.dll -------------------------------------------------------------------------------- /bin/x86/sndfile.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/sndfile.dll -------------------------------------------------------------------------------- /bin/x86/soft_oal.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/soft_oal.dll -------------------------------------------------------------------------------- /bin/x86/steam_api.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/steam_api.dll -------------------------------------------------------------------------------- /src/lib/x86/SDL2.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/x86/SDL2.lib -------------------------------------------------------------------------------- /src/lib/x86/enet.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/x86/enet.lib -------------------------------------------------------------------------------- /src/lib/x86/zlib1.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/x86/zlib1.lib -------------------------------------------------------------------------------- /bin/amd64/OpenAL32.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/OpenAL32.dll -------------------------------------------------------------------------------- /bin/amd64/freetype.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/freetype.dll -------------------------------------------------------------------------------- /bin/amd64/libjpeg-9.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/libjpeg-9.dll -------------------------------------------------------------------------------- /bin/amd64/libtiff-5.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/libtiff-5.dll -------------------------------------------------------------------------------- /bin/amd64/libwebp-4.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/libwebp-4.dll -------------------------------------------------------------------------------- /bin/amd64/libwebp-7.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/libwebp-7.dll -------------------------------------------------------------------------------- /bin/amd64/soft_oal.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/soft_oal.dll -------------------------------------------------------------------------------- /bin/x86/SDL2_image.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/SDL2_image.dll -------------------------------------------------------------------------------- /bin/x86/discord-rpc.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/discord-rpc.dll -------------------------------------------------------------------------------- /bin/x86/libavif-16.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/libavif-16.dll -------------------------------------------------------------------------------- /bin/x86/libpng16-16.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/libpng16-16.dll -------------------------------------------------------------------------------- /bin/x86/libsteam_api.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/libsteam_api.so -------------------------------------------------------------------------------- /src/lib/amd64/SDL2.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/amd64/SDL2.lib -------------------------------------------------------------------------------- /src/lib/amd64/enet.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/amd64/enet.lib -------------------------------------------------------------------------------- /src/lib/amd64/zlib1.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/amd64/zlib1.lib -------------------------------------------------------------------------------- /src/lib/x86/sndfile.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/x86/sndfile.lib -------------------------------------------------------------------------------- /src/steam/isteamvideo.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/steam/isteamvideo.h -------------------------------------------------------------------------------- /bin/amd64/SDL2_image.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/SDL2_image.dll -------------------------------------------------------------------------------- /bin/amd64/discord-rpc.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/discord-rpc.dll -------------------------------------------------------------------------------- /bin/amd64/libavif-16.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/libavif-16.dll -------------------------------------------------------------------------------- /bin/amd64/libpng16-16.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/libpng16-16.dll -------------------------------------------------------------------------------- /bin/amd64/libsteam_api.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/libsteam_api.so -------------------------------------------------------------------------------- /bin/amd64/steam_api64.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/steam_api64.dll -------------------------------------------------------------------------------- /bin/x86/libwebpdemux-2.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/libwebpdemux-2.dll -------------------------------------------------------------------------------- /src/install/win/finish.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/install/win/finish.bmp -------------------------------------------------------------------------------- /src/install/win/header.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/install/win/header.bmp -------------------------------------------------------------------------------- /src/lib/amd64/OpenAL32.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/amd64/OpenAL32.lib -------------------------------------------------------------------------------- /src/lib/amd64/freetype.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/amd64/freetype.lib -------------------------------------------------------------------------------- /src/lib/amd64/sndfile.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/amd64/sndfile.lib -------------------------------------------------------------------------------- /src/lib/x86/OpenAL32.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/x86/OpenAL32.lib -------------------------------------------------------------------------------- /src/lib/x86/SDL2_image.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/x86/SDL2_image.lib -------------------------------------------------------------------------------- /src/lib/x86/freetype.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/x86/freetype.lib -------------------------------------------------------------------------------- /src/lib/x86/steam_api.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/x86/steam_api.lib -------------------------------------------------------------------------------- /src/steam/steamhttpenums.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/steam/steamhttpenums.h -------------------------------------------------------------------------------- /.github/PULL_REQUEST_TEMPLATE.md: -------------------------------------------------------------------------------- 1 | Fixes # 2 | 3 | Changes proposed in this request: 4 | - [description] 5 | -------------------------------------------------------------------------------- /bin/amd64/libdiscord-rpc.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/libdiscord-rpc.so -------------------------------------------------------------------------------- /bin/amd64/libwebpdemux-2.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/libwebpdemux-2.dll -------------------------------------------------------------------------------- /bin/x86/libwinpthread-1.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/x86/libwinpthread-1.dll -------------------------------------------------------------------------------- /src/lib/amd64/SDL2_image.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/amd64/SDL2_image.lib -------------------------------------------------------------------------------- /src/steam/isteaminventory.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/steam/isteaminventory.h -------------------------------------------------------------------------------- /src/steam/steam_gameserver.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/steam/steam_gameserver.h -------------------------------------------------------------------------------- /bin/amd64/libwinpthread-1.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/bin/amd64/libwinpthread-1.dll -------------------------------------------------------------------------------- /src/lib/amd64/steam_api64.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/lib/amd64/steam_api64.lib -------------------------------------------------------------------------------- /src/vcpp/lib/x86/steam_api.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/vcpp/lib/x86/steam_api.lib -------------------------------------------------------------------------------- /src/install/nix/genkey.am: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | cd "@LIBEXECDIR@/@APPNAME@" || exit 1 4 | exec "./@APPNAME@" "$@" 5 | -------------------------------------------------------------------------------- /src/install/nix/tessfont.am: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | cd "@LIBEXECDIR@/@APPNAME@" || exit 1 4 | exec "./@APPNAME@" "$@" 5 | -------------------------------------------------------------------------------- /src/install/win/AccessControl.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/install/win/AccessControl.dll -------------------------------------------------------------------------------- /src/steam/isteamgamecoordinator.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/steam/isteamgamecoordinator.h -------------------------------------------------------------------------------- /src/steam/isteamgameserverstats.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/steam/isteamgameserverstats.h -------------------------------------------------------------------------------- /src/vcpp/lib/x86/discord-rpc.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/vcpp/lib/x86/discord-rpc.lib -------------------------------------------------------------------------------- /src/install/nix/redeclipse_x128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/install/nix/redeclipse_x128.png -------------------------------------------------------------------------------- /src/install/nix/redeclipse_x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/install/nix/redeclipse_x16.png -------------------------------------------------------------------------------- /src/install/nix/redeclipse_x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/install/nix/redeclipse_x32.png -------------------------------------------------------------------------------- /src/install/nix/redeclipse_x48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/install/nix/redeclipse_x48.png -------------------------------------------------------------------------------- /src/install/nix/redeclipse_x64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/install/nix/redeclipse_x64.png -------------------------------------------------------------------------------- /src/steam/isteamps3overlayrenderer.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/steam/isteamps3overlayrenderer.h -------------------------------------------------------------------------------- /src/steam/steamencryptedappticket.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/steam/steamencryptedappticket.h -------------------------------------------------------------------------------- /src/vcpp/lib/amd64/discord-rpc.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/vcpp/lib/amd64/discord-rpc.lib -------------------------------------------------------------------------------- /src/vcpp/lib/amd64/steam_api64.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redeclipse/base/HEAD/src/vcpp/lib/amd64/steam_api64.lib -------------------------------------------------------------------------------- /config/fx/other/other.cfg: -------------------------------------------------------------------------------- 1 | exec "config/fx/other/player.cfg" 2 | exec "config/fx/other/drone.cfg" 3 | exec "config/fx/other/ents.cfg" 4 | exec "config/fx/other/prize.cfg" 5 | -------------------------------------------------------------------------------- /config/fx/lib.cfg: -------------------------------------------------------------------------------- 1 | exec "config/fx/std.cfg" 2 | exec "config/fx/particle.cfg" 3 | exec "config/fx/light.cfg" 4 | exec "config/fx/sound.cfg" 5 | exec "config/fx/wind.cfg" 6 | 7 | 8 | -------------------------------------------------------------------------------- /config/tool/ents/envmap.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_add_attrs_envmap = [ 2 | tool_ent_add_attr envmap radius 0 3 | tool_ent_add_attr envmap size 0 4 | tool_ent_add_attr envmap blur 0 5 | ] 6 | -------------------------------------------------------------------------------- /config/fx/light.cfg: -------------------------------------------------------------------------------- 1 | L_NOSHADOW = 1 2 | L_NODYNSHADOW = (<< 1 1) 3 | L_VOLUMETRIC = (<< 1 2) 4 | L_NOSPEC = (<< 1 3) 5 | L_SMALPHA = (<< 1 4) 6 | L_DYNWORLDCHECK = (<< 1 5) 7 | -------------------------------------------------------------------------------- /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | # These are supported funding model platforms 2 | 3 | github: [qreeves] 4 | open_collective: redeclipse 5 | patreon: redeclipsenet 6 | custom: ["https://www.redeclipse.net/donate"] 7 | -------------------------------------------------------------------------------- /config/map/sounds.cfg: -------------------------------------------------------------------------------- 1 | exec "sounds/ambience/sounds.cfg" 2 | exec "sounds/ambience/bart/sounds.cfg" 3 | exec "sounds/ambience/morph/sounds.cfg" 4 | exec "misc/sounds.cfg" 5 | exec "unixfreak/sounds.cfg" 6 | -------------------------------------------------------------------------------- /src/include/AL/efx-creative.h: -------------------------------------------------------------------------------- 1 | /* The tokens that would be defined here are already defined in efx.h. This 2 | * empty file is here to provide compatibility with Windows-based projects 3 | * that would include it. */ 4 | -------------------------------------------------------------------------------- /config/ui/dyn/package.cfg: -------------------------------------------------------------------------------- 1 | exec "config/ui/dyn/builtins.cfg" 2 | 3 | exec "config/ui/dyn/bomber.cfg" 4 | exec "config/ui/dyn/capture.cfg" 5 | exec "config/ui/dyn/defend.cfg" 6 | exec "config/ui/dyn/entity.cfg" 7 | exec "config/ui/dyn/player.cfg" 8 | -------------------------------------------------------------------------------- /src/install/nix/redeclipse.am: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | for arg in "$@" 3 | do 4 | if [ "$arg" = --help ] 5 | then 6 | exec man "@APPNAME@" 7 | fi 8 | done 9 | 10 | cd "@LIBEXECDIR@/@APPNAME@" || exit 1 11 | exec "./@APPNAME@" "$@" 12 | -------------------------------------------------------------------------------- /src/install/steam/depot_build.vdf: -------------------------------------------------------------------------------- 1 | "DepotBuildConfig" 2 | { 3 | "DepotID" "~REPDEPOT~" 4 | "ContentRoot" "." 5 | "FileMapping" 6 | { 7 | "LocalPath" "*" 8 | "DepotPath" "." 9 | "recursive" "1" 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /redeclipse_server.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | if [ -z "${REDECLIPSE_PATH+isset}" ]; then REDECLIPSE_PATH="$(cd "$(dirname "$0")" && pwd)"; fi 3 | REDECLIPSE_BINARY="redeclipse_server" 4 | export REDECLIPSE_BINARY 5 | REDECLIPSE_CALLED="true" . "${REDECLIPSE_PATH}/redeclipse.sh" $@ 6 | -------------------------------------------------------------------------------- /src/install/nix/redeclipse-server.am: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | for arg in "$@" 3 | do 4 | if [ "$arg" = --help ] 5 | then 6 | exec man "@APPNAME@-server" 7 | fi 8 | done 9 | 10 | cd "@LIBEXECDIR@/@APPNAME@" || exit 1 11 | exec "./@APPNAME@-server" "$@" 12 | -------------------------------------------------------------------------------- /src/scripts/cube2font-txt: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | MANWIDTH=80 man --no-justification --no-hyphenation "$1" \ 4 | | col -b > "$2" 5 | cat <> "$2" 6 | 7 | This text file was automatically generated from tessfont.1 8 | Please do not edit it manually. 9 | EOF 10 | -------------------------------------------------------------------------------- /config/fx/particle.cfg: -------------------------------------------------------------------------------- 1 | FX_PARTTYPE_SINGLE = 0 2 | FX_PARTTYPE_SPLASH = 1 3 | FX_PARTTYPE_SHAPE = 2 4 | FX_PARTTYPE_FLARE = 3 5 | FX_PARTTYPE_TRAIL = 4 6 | FX_PARTTYPE_EXPLODE = 5 7 | FX_PARTTYPE_TEXT = 6 8 | 9 | FX_PARTCOLLIDE_NONE = -1 10 | FX_PARTCOLLIDE_NOSTAIN = -2 11 | -------------------------------------------------------------------------------- /config/fx.cfg: -------------------------------------------------------------------------------- 1 | defvarp fxdetail 0 2 2 reloadfx 2 | 3 | exec "config/fx/lib.cfg" 4 | 5 | reloadfx = [ 6 | fxcleardefs 7 | 8 | exec "config/fx/weapons/weapons.cfg" 9 | exec "config/fx/projs/projs.cfg" 10 | exec "config/fx/other/other.cfg" 11 | ] 12 | reloadfx 13 | -------------------------------------------------------------------------------- /src/include/SDL_revision.h: -------------------------------------------------------------------------------- 1 | /* Generated by updaterev.sh, do not edit */ 2 | #ifdef SDL_VENDOR_INFO 3 | #define SDL_REVISION "SDL-release-2.30.2-0-gf461d91cd (" SDL_VENDOR_INFO ")" 4 | #else 5 | #define SDL_REVISION "SDL-release-2.30.2-0-gf461d91cd" 6 | #endif 7 | #define SDL_REVISION_NUMBER 0 8 | -------------------------------------------------------------------------------- /config/tool/ents/worldcol.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_add_attrs_worldcol = [ 2 | tool_ent_add_attr worldcol type $T_ENT_NODELTA 3 | tool_ent_add_attr worldcol flags 0 4 | tool_ent_add_attr worldcol modes $T_ENT_NODELTA 5 | tool_ent_add_attr worldcol muts $T_ENT_NODELTA 6 | tool_ent_add_attr worldcol variant $T_ENT_NODELTA 7 | ] 8 | -------------------------------------------------------------------------------- /src/install/steam/app_build.vdf: -------------------------------------------------------------------------------- 1 | "appbuild" 2 | { 3 | "appid" "~REPAPPID~" 4 | "desc" "~REPDESC~" 5 | "buildoutput" "output" 6 | "contentroot" "content" 7 | "setlive" "~REPBRANCH~" 8 | "preview" "0" 9 | "local" "" 10 | "depots" 11 | { 12 | "~REPDEPOT~" "depot_build.vdf" 13 | } 14 | } -------------------------------------------------------------------------------- /config/map/decals.cfg: -------------------------------------------------------------------------------- 1 | exec "jojo/decals.cfg" 2 | exec "luckystrike/decals.cfg" 3 | exec "decals/branding/decals.cfg" 4 | exec "decals/nieb/decals.cfg" 5 | exec "decals/pritchard/decals.cfg" 6 | exec "decals/snowy/decals.cfg" 7 | exec "decals/molexted/decals.cfg" 8 | exec "decals/dziq/decals.cfg" 9 | exec "decals/unixfreak/decals.cfg" 10 | -------------------------------------------------------------------------------- /config/map/default.cfg: -------------------------------------------------------------------------------- 1 | // Red Eclipse: Default Map Settings 2 | // This file is executed when you create a new map, or if a map does not supply its own config file. 3 | 4 | exec "config/map/material.cfg" 5 | exec "config/map/textures.cfg" 6 | exec "config/map/decals.cfg" 7 | exec "config/map/models.cfg" 8 | exec "config/map/sounds.cfg" 9 | exec "config/map/soundenvs.cfg" 10 | -------------------------------------------------------------------------------- /src/steam/license.txt: -------------------------------------------------------------------------------- 1 | ================================================================ 2 | 3 | Copyright © 1996-2018, Valve Corporation, All rights reserved. 4 | 5 | ================================================================ 6 | 7 | 8 | Welcome to the Steamworks SDK. For documentation please see our partner 9 | website at: http://partner.steamgames.com 10 | 11 | -------------------------------------------------------------------------------- /.github/SUPPORT.md: -------------------------------------------------------------------------------- 1 | This issue tracker is for **confirmed bugs** and **approved feature requests** only. 2 | 3 | Please review the [Contribution Guidelines](https://redeclipse.net/contribute). 4 | 5 | If you want to chat, have a feature request, or need help and support, you should use our [Discussion Area](https://redeclipse.net/discuss) or [Live Chat](https://redeclipse.net/chat). 6 | -------------------------------------------------------------------------------- /redeclipse_server.bat: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | setlocal enableextensions enabledelayedexpansion 3 | :path 4 | if DEFINED REDECLIPSE_PATH goto init 5 | pushd %~dp0 6 | set REDECLIPSE_PATH=%CD% 7 | popd 8 | :init 9 | set REDECLIPSE_BINARY=redeclipse_server 10 | set REDECLIPSE_START=start 11 | :start 12 | call "%REDECLIPSE_PATH%\redeclipse.bat" %* 13 | -------------------------------------------------------------------------------- /src/enet/README: -------------------------------------------------------------------------------- 1 | Please visit the ENet homepage at http://sauerbraten.org/enet/ for installation 2 | and usage instructions. 3 | 4 | If you obtained this package from github, the quick description on how to build 5 | is: 6 | 7 | # Generate the build system. 8 | 9 | autoreconf -vfi 10 | 11 | # Compile and install the library. 12 | 13 | ./configure && make && make install 14 | 15 | 16 | -------------------------------------------------------------------------------- /src/enet/include/enet/utility.h: -------------------------------------------------------------------------------- 1 | /** 2 | @file utility.h 3 | @brief ENet utility header 4 | */ 5 | #ifndef __ENET_UTILITY_H__ 6 | #define __ENET_UTILITY_H__ 7 | 8 | #define ENET_MAX(x, y) ((x) > (y) ? (x) : (y)) 9 | #define ENET_MIN(x, y) ((x) < (y) ? (x) : (y)) 10 | #define ENET_DIFFERENCE(x, y) ((x) < (y) ? (y) - (x) : (x) - (y)) 11 | 12 | #endif /* __ENET_UTILITY_H__ */ 13 | 14 | -------------------------------------------------------------------------------- /config/tool.cfg: -------------------------------------------------------------------------------- 1 | exec "config/tool/toolcommon.cfg" 2 | exec "config/tool/actions.cfg" 3 | exec "config/tool/tooledit.cfg" 4 | exec "config/tool/toolent.cfg" 5 | exec "config/tool/toolmap.cfg" 6 | exec "config/tool/tooltex.cfg" 7 | exec "config/tool/toolenv.cfg" 8 | exec "config/tool/toolmat.cfg" 9 | exec "config/tool/toolai.cfg" 10 | exec "config/tool/toolphysics.cfg" 11 | exec "config/tool/toolimgedit.cfg" 12 | -------------------------------------------------------------------------------- /config/tool/ents/affinity.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_add_attrs_affinity = [ 2 | tool_ent_add_attr affinity team $T_ENT_NODELTA 3 | tool_ent_add_attr affinity yaw 0 4 | tool_ent_add_attr affinity pitch 0 5 | tool_ent_add_attr affinity modes $T_ENT_NODELTA 6 | tool_ent_add_attr affinity muts $T_ENT_NODELTA 7 | tool_ent_add_attr affinity id 0 8 | tool_ent_add_attr affinity variant $T_ENT_NODELTA 9 | ] 10 | -------------------------------------------------------------------------------- /config/tool/binds/legacy.cfg: -------------------------------------------------------------------------------- 1 | toolbind F1 ta_textures 2 | toolbind F4 ta_recalc 3 | toolbind F8 ta_save 4 | toolbind F8 ta_save_as (kmod SHIFT) 5 | toolbind Z ta_undo 6 | toolbind O ta_redo 7 | toolbind C ta_copy 8 | toolbind C ta_ent_grab (kmod SHIFT) 9 | toolbind V ta_paste 10 | toolbind J ta_tex_get 11 | toolbind Y ta_tex_apply 12 | toolbind X ta_flip 13 | toolbind M ta_toggle_showmat 14 | toolbind M ta_setmat (kmod CTRL) 15 | -------------------------------------------------------------------------------- /src/enet/include/enet/types.h: -------------------------------------------------------------------------------- 1 | /** 2 | @file types.h 3 | @brief type definitions for ENet 4 | */ 5 | #ifndef __ENET_TYPES_H__ 6 | #define __ENET_TYPES_H__ 7 | 8 | typedef unsigned char enet_uint8; /**< unsigned 8-bit type */ 9 | typedef unsigned short enet_uint16; /**< unsigned 16-bit type */ 10 | typedef unsigned int enet_uint32; /**< unsigned 32-bit type */ 11 | 12 | #endif /* __ENET_TYPES_H__ */ 13 | 14 | -------------------------------------------------------------------------------- /config/tool/ents/playerstart.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_add_attrs_playerstart = [ 2 | tool_ent_add_attr playerstart team $T_ENT_NODELTA 3 | tool_ent_add_attr playerstart yaw 0 4 | tool_ent_add_attr playerstart pitch 0 5 | tool_ent_add_attr playerstart modes $T_ENT_NODELTA 6 | tool_ent_add_attr playerstart muts $T_ENT_NODELTA 7 | tool_ent_add_attr playerstart id 0 8 | tool_ent_add_attr playerstart variant $T_ENT_NODELTA 9 | ] 10 | -------------------------------------------------------------------------------- /src/enet/Makefile: -------------------------------------------------------------------------------- 1 | CFLAGS?=-O3 -fomit-frame-pointer 2 | override CFLAGS:= $(CFLAGS) -Iinclude $(shell ./check_cflags.sh $(CC) $(CFLAGS)) 3 | 4 | OBJS= \ 5 | callbacks.o \ 6 | compress.o \ 7 | host.o \ 8 | list.o \ 9 | packet.o \ 10 | peer.o \ 11 | protocol.o \ 12 | unix.o \ 13 | win32.o 14 | 15 | libenet.a: $(OBJS) 16 | $(AR) rcs $@ $(OBJS) 17 | 18 | default: libenet.a 19 | 20 | clean: 21 | -$(RM) libenet.a $(OBJS) 22 | 23 | -------------------------------------------------------------------------------- /config/map/models.cfg: -------------------------------------------------------------------------------- 1 | exec "acerspyro/models.cfg" 2 | exec "dc/models.cfg" 3 | exec "dziq/models.cfg" 4 | exec "john/models.cfg" 5 | exec "jojo/models.cfg" 6 | exec "luckystrike/models.cfg" 7 | exec "mikeplus64/models.cfg" 8 | exec "misc/models.cfg" 9 | exec "nieb/models.cfg" 10 | exec "nobiax/models.cfg" 11 | exec "q009/vegetation/models.cfg" 12 | exec "snipergoth/models.cfg" 13 | exec "unixfreak/models.cfg" 14 | exec "unnamed/models.cfg" 15 | exec "vegetation/models.cfg" 16 | -------------------------------------------------------------------------------- /config/ui/tool/ents/toolworldcol.cfg: -------------------------------------------------------------------------------- 1 | # ui_tool_ent_worldcol = [ 2 | ui_tool_ent_param_group "Type" [ 3 | ui_tool_dropdown #(tool_ent_attr worldcol type) (sublist $WORLDCOL_NAMES 0 $WORLDCOL_MAX) [ 4 | #(ui_tool_ent_attr_props worldcol type) 5 | ] 6 | ] 7 | 8 | @(ui_tool_ent_flags_group worldcol $WORLDCOL_F_LIST $WORLDCOL_F_NAMES) 9 | 10 | @(ui_tool_ent_gamemode_group worldcol) 11 | @(ui_tool_ent_variant_group worldcol) 12 | ] 13 | -------------------------------------------------------------------------------- /config/tool/ents/checkpoint.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_add_attrs_checkpoint = [ 2 | tool_ent_add_attr checkpoint radius 0 3 | tool_ent_add_attr checkpoint yaw 0 4 | tool_ent_add_attr checkpoint pitch 0 5 | tool_ent_add_attr checkpoint modes $T_ENT_NODELTA 6 | tool_ent_add_attr checkpoint muts $T_ENT_NODELTA 7 | tool_ent_add_attr checkpoint id 0 8 | tool_ent_add_attr checkpoint type $T_ENT_NODELTA 9 | tool_ent_add_attr checkpoint variant $T_ENT_NODELTA 10 | ] 11 | -------------------------------------------------------------------------------- /config/ui/package.cfg: -------------------------------------------------------------------------------- 1 | exec "config/ui/style.cfg" 2 | exec "config/ui/lib.cfg" 3 | exec "config/ui/tips.cfg" 4 | 5 | exec "config/ui/console.cfg" // used by hud 6 | 7 | exec "config/ui/game/hud/common.cfg" 8 | exec "config/ui/pointers/package.cfg" 9 | 10 | exec "config/ui/events/package.cfg" 11 | exec "config/ui/hud/package.cfg" 12 | exec "config/ui/progress.cfg" 13 | 14 | exec "config/ui/game/game.cfg" 15 | 16 | exec "config/ui/tool.cfg" 17 | 18 | exec "config/ui/dyn/package.cfg" 19 | -------------------------------------------------------------------------------- /config/ui/tool.cfg: -------------------------------------------------------------------------------- 1 | exec "config/ui/tool/appearance.cfg" 2 | 3 | exec "config/ui/tool/toolview/toolview.cfg" 4 | 5 | exec "config/ui/tool/toolmap.cfg" 6 | exec "config/ui/tool/tooledit.cfg" 7 | exec "config/ui/tool/tooltex.cfg" 8 | exec "config/ui/tool/toolent.cfg" 9 | exec "config/ui/tool/toolenv.cfg" 10 | exec "config/ui/tool/toolmat.cfg" 11 | exec "config/ui/tool/toolai.cfg" 12 | exec "config/ui/tool/toolphysics.cfg" 13 | exec "config/ui/tool/toolimgedit.cfg" 14 | 15 | toolview_init 16 | -------------------------------------------------------------------------------- /bin/LICENSE.SDL.txt: -------------------------------------------------------------------------------- 1 | 2 | Please distribute this file with the SDL runtime environment: 3 | 4 | The Simple DirectMedia Layer (SDL for short) is a cross-platfrom library 5 | designed to make it easy to write multi-media software, such as games and 6 | emulators. 7 | 8 | The Simple DirectMedia Layer library source code is available from: 9 | http://www.libsdl.org/ 10 | 11 | This library is distributed under the terms of the GNU LGPL license: 12 | http://www.gnu.org/copyleft/lesser.html 13 | 14 | -------------------------------------------------------------------------------- /config/fx/weapons/airblast.cfg: -------------------------------------------------------------------------------- 1 | registerfx FX_W_AIRBLAST $FX_TYPE_PARTICLE [ 2 | fxpropi emitlen 200 3 | fxpropi emitrestart 1 4 | fxpropi parttype $FX_PARTTYPE_SINGLE 5 | fxpropi part $PART_HINT 6 | fxpropi fade 1 7 | fxpropf partsize 0.1 8 | fxpropf partsize 0.5 $FX_MOD_RAND 9 | fxpropf partsize 3.33 $FX_MOD_LERP [ 10 | fxpropi lerptime 200 11 | ] 12 | fxpropf blend 0.2 13 | fxpropi fadeout 100 14 | fxpropi posfroment $FX_ENT_POS_MUZZLE 15 | ] 16 | -------------------------------------------------------------------------------- /config/tool/ents/physics.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_add_attrs_physics = [ 2 | tool_ent_add_attr physics type $T_ENT_NODELTA 3 | tool_ent_add_attr physics value 0 4 | tool_ent_add_attr physics width 0 5 | tool_ent_add_attr physics length 0 6 | tool_ent_add_attr physics height 0 7 | tool_ent_add_attr physics falloff 0 8 | tool_ent_add_attr physics modes $T_ENT_NODELTA 9 | tool_ent_add_attr physics muts $T_ENT_NODELTA 10 | tool_ent_add_attr physics variant $T_ENT_NODELTA 11 | ] 12 | -------------------------------------------------------------------------------- /config/ui/game/game.cfg: -------------------------------------------------------------------------------- 1 | exec "config/ui/game/common.cfg" 2 | exec "config/ui/game/main.cfg" 3 | exec "config/ui/game/online.cfg" 4 | exec "config/ui/game/maps.cfg" 5 | exec "config/ui/game/vote.cfg" 6 | exec "config/ui/game/player.cfg" 7 | exec "config/ui/game/editor.cfg" 8 | exec "config/ui/game/settings.cfg" 9 | exec "config/ui/game/variables.cfg" 10 | exec "config/ui/game/support.cfg" 11 | exec "config/ui/game/team.cfg" 12 | exec "config/ui/game/scoreboard.cfg" 13 | exec "config/ui/game/chat.cfg" 14 | exec "config/ui/game/hud/hud.cfg" 15 | -------------------------------------------------------------------------------- /.github/CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | * **Behave**: You are a guest in our community. 2 | * **Patience**: Don't expect everyone to give you what you want immediately. 3 | * **Thoughtful**: Try to answer your own questions before asking us. 4 | * **On Topic**: Ask questions related to Red Eclipse only, we won't help you create a game. 5 | * **Speak English**: One language unifies us, multiple languages creates chaos. 6 | * **No Slander**: Do NOT engage in blatant racism, political or religious debates, or engage in slander over the sex and/or orientation of anyone else. 7 | -------------------------------------------------------------------------------- /config/tool/ents/trigger.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_attr_states = [ 2 | on 3 | routed 4 | ] 5 | 6 | tool_ent_add_attrs_trigger = [ 7 | tool_ent_add_attr trigger id 0 8 | tool_ent_add_attr trigger type $T_ENT_NODELTA 9 | tool_ent_add_attr trigger action $T_ENT_NODELTA 10 | tool_ent_add_attr trigger radius 0 11 | tool_ent_add_attr trigger state $T_ENT_NODELTA 12 | tool_ent_add_attr trigger modes $T_ENT_NODELTA 13 | tool_ent_add_attr trigger muts $T_ENT_NODELTA 14 | tool_ent_add_attr trigger variant $T_ENT_NODELTA 15 | ] 16 | -------------------------------------------------------------------------------- /config/tool/ents/pusher.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_add_attrs_pusher = [ 2 | tool_ent_add_attr pusher yaw 0 3 | tool_ent_add_attr pusher pitch 0 4 | tool_ent_add_attr pusher force 0 5 | tool_ent_add_attr pusher maxrad 0 6 | tool_ent_add_attr pusher minrad 0 7 | tool_ent_add_attr pusher type $T_ENT_NODELTA 8 | tool_ent_add_attr pusher modes $T_ENT_NODELTA 9 | tool_ent_add_attr pusher muts $T_ENT_NODELTA 10 | tool_ent_add_attr pusher id 0 11 | tool_ent_add_attr pusher variant $T_ENT_NODELTA 12 | tool_ent_add_attr pusher sdelay 0 13 | ] 14 | -------------------------------------------------------------------------------- /config/ui/events/game.cfg: -------------------------------------------------------------------------------- 1 | event_game_music = [ 2 | local event_title event_artist 3 | event_title = (geteventlist $event_id "args" "title") 4 | event_artist = (geteventlist $event_id "args" "artist") 5 | 6 | event_image "textures/icons/edit/sound" 0xFFFFFF 7 | 8 | uicolourtext $event_title $colourdarkmagenta $game_hud_event_text_size 9 | 10 | if (!=s $event_artist "") [ 11 | uitext "by" (*f $game_hud_event_text_size 0.75) 12 | uicolourtext $event_artist $colourdarkmagenta $game_hud_event_text_size 13 | ] 14 | ] 15 | -------------------------------------------------------------------------------- /config/tool/ents/weapon.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_weapon_flags = [ 2 | forced 3 | ] 4 | 5 | tool_ent_add_attrs_weapon = [ 6 | tool_ent_add_attr weapon type $T_ENT_NODELTA [ 7 | tool_ent_attr_type = (- $$tool_ent_cur_attr 2) 8 | ] [ 9 | $tool_ent_cur_attr = (+ $tool_ent_attr_type 2) 10 | ] 11 | tool_ent_add_attr weapon flags $T_ENT_NODELTA 12 | tool_ent_add_attr weapon modes $T_ENT_NODELTA 13 | tool_ent_add_attr weapon muts $T_ENT_NODELTA 14 | tool_ent_add_attr weapon id 0 15 | tool_ent_add_attr weapon variant $T_ENT_NODELTA 16 | ] 17 | -------------------------------------------------------------------------------- /config/ui/game/widgets/widgets.cfg: -------------------------------------------------------------------------------- 1 | exec "config/ui/game/widgets/button.cfg" 2 | exec "config/ui/game/widgets/autoscroll.cfg" 3 | exec "config/ui/game/widgets/scrollarea.cfg" 4 | exec "config/ui/game/widgets/textinput.cfg" 5 | exec "config/ui/game/widgets/decortext.cfg" 6 | exec "config/ui/game/widgets/slider.cfg" 7 | exec "config/ui/game/widgets/shadow.cfg" 8 | exec "config/ui/game/widgets/group.cfg" 9 | exec "config/ui/game/widgets/pages.cfg" 10 | exec "config/ui/game/widgets/switch.cfg" 11 | 12 | // Auxiliary state storage for inter-widget interactions 13 | gameui_interact_helper = [] 14 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE.md: -------------------------------------------------------------------------------- 1 | > ONLY report a feature request if it was already discussed at: https://redeclipse.net/world/issues 2 | > PLEASE search the issues before submitting your own. Be sure to rename your `config.cfg` and check if the problem still occurs. 3 | 4 | - Version and build: [version] [build] 5 | - Related discussion: redeclipse/world#ID 6 | - Observation: [what happened?] 7 | - Expected result: [what did you expect to happen?] 8 | - How to reproduce: [what steps can be taken to reliably reproduce the issue?] 9 | 10 | ``` 11 | Insert the contents of your `log.txt` here. 12 | ``` 13 | -------------------------------------------------------------------------------- /config/map/textures.cfg: -------------------------------------------------------------------------------- 1 | exec "textures/textures.cfg" 2 | exec "acerspyro/textures.cfg" 3 | exec "appleflap/textures.cfg" 4 | exec "dc/textures.cfg" 5 | exec "dziq/textures.cfg" 6 | exec "jojo/textures.cfg" 7 | exec "trak/textures.cfg" 8 | exec "luckystrike/textures.cfg" 9 | exec "mikeplus64/textures.cfg" 10 | exec "misc/textures.cfg" 11 | exec "molexted/textures.cfg" 12 | exec "nieb/textures.cfg" 13 | exec "nobiax/textures.cfg" 14 | exec "philipk/textures.cfg" 15 | exec "snipergoth/textures.cfg" 16 | exec "torley/textures.cfg" 17 | exec "unnamed/textures.cfg" 18 | exec "unixfreak/textures.cfg" 19 | -------------------------------------------------------------------------------- /config/comp/package.cfg: -------------------------------------------------------------------------------- 1 | exec "config/comp/bubble.cfg" 2 | exec "config/comp/burn.cfg" 3 | exec "config/comp/cathode.cfg" 4 | exec "config/comp/caustic.cfg" 5 | exec "config/comp/clouds.cfg" 6 | exec "config/comp/distort.cfg" 7 | exec "config/comp/feather.cfg" 8 | exec "config/comp/hint.cfg" 9 | exec "config/comp/misc.cfg" 10 | exec "config/comp/mixer.cfg" 11 | exec "config/comp/noise.cfg" 12 | exec "config/comp/plasmascr.cfg" 13 | exec "config/comp/portal.cfg" 14 | exec "config/comp/rainbow.cfg" 15 | exec "config/comp/scores.cfg" 16 | exec "config/comp/texmask.cfg" 17 | exec "config/comp/ticker.cfg" 18 | -------------------------------------------------------------------------------- /config/fx/projs/airblast.cfg: -------------------------------------------------------------------------------- 1 | registerfx FX_P_AIRBLAST_LIFE $FX_TYPE_PARTICLE [ 2 | fxpropf emitdist 512 3 | fxpropf emitcull 4 4 | fxpropi parttype $FX_PARTTYPE_SINGLE 5 | fxpropi part $PART_HAZE 6 | fxpropf partsize 1 7 | fxpropf partsize 64 $FX_MOD_LERP [ 8 | fxpropi lerptime 500 9 | ] 10 | fxpropi emitlen 500 11 | fxpropi fadeout 500 12 | ] 13 | 14 | if (> $fxdetail 0) [ 15 | registerfx FX_P_AIRBLAST_LIFE_WIND $FX_TYPE_WIND [ 16 | fxpropf emitdist 512 17 | fxpropf emitcull 4 18 | fxparent FX_P_AIRBLAST_LIFE 19 | fxpropf speed 0.5 20 | ] 21 | ] 22 | -------------------------------------------------------------------------------- /src/enet/include/enet/time.h: -------------------------------------------------------------------------------- 1 | /** 2 | @file time.h 3 | @brief ENet time constants and macros 4 | */ 5 | #ifndef __ENET_TIME_H__ 6 | #define __ENET_TIME_H__ 7 | 8 | #define ENET_TIME_OVERFLOW 86400000 9 | 10 | #define ENET_TIME_LESS(a, b) ((a) - (b) >= ENET_TIME_OVERFLOW) 11 | #define ENET_TIME_GREATER(a, b) ((b) - (a) >= ENET_TIME_OVERFLOW) 12 | #define ENET_TIME_LESS_EQUAL(a, b) (! ENET_TIME_GREATER (a, b)) 13 | #define ENET_TIME_GREATER_EQUAL(a, b) (! ENET_TIME_LESS (a, b)) 14 | 15 | #define ENET_TIME_DIFFERENCE(a, b) ((a) - (b) >= ENET_TIME_OVERFLOW ? (b) - (a) : (a) - (b)) 16 | 17 | #endif /* __ENET_TIME_H__ */ 18 | 19 | -------------------------------------------------------------------------------- /src/enet/include/enet/callbacks.h: -------------------------------------------------------------------------------- 1 | /** 2 | @file callbacks.h 3 | @brief ENet callbacks 4 | */ 5 | #ifndef __ENET_CALLBACKS_H__ 6 | #define __ENET_CALLBACKS_H__ 7 | 8 | #include 9 | 10 | typedef struct _ENetCallbacks 11 | { 12 | void * (ENET_CALLBACK * malloc) (size_t size); 13 | void (ENET_CALLBACK * free) (void * memory); 14 | void (ENET_CALLBACK * no_memory) (void); 15 | } ENetCallbacks; 16 | 17 | /** @defgroup callbacks ENet internal callbacks 18 | @{ 19 | @ingroup private 20 | */ 21 | extern void * enet_malloc (size_t); 22 | extern void enet_free (void *); 23 | 24 | /** @} */ 25 | 26 | #endif /* __ENET_CALLBACKS_H__ */ 27 | 28 | -------------------------------------------------------------------------------- /config/tool/ents/camera.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_camera_flags = [ 2 | staticview 3 | ] 4 | 5 | tool_ent_add_attrs_camera = [ 6 | tool_ent_add_attr camera type $T_ENT_NODELTA 7 | tool_ent_add_attr camera flags $T_ENT_NODELTA 8 | tool_ent_add_attr camera yaw 0 9 | tool_ent_add_attr camera pitch 0 10 | tool_ent_add_attr camera maxdist 0 11 | tool_ent_add_attr camera mindist 0 12 | tool_ent_add_attr camera delay 0 13 | tool_ent_add_attr camera modes $T_ENT_NODELTA 14 | tool_ent_add_attr camera muts $T_ENT_NODELTA 15 | tool_ent_add_attr camera id 0 16 | tool_ent_add_attr camera variant $T_ENT_NODELTA 17 | tool_ent_add_attr camera fov 0 18 | ] 19 | -------------------------------------------------------------------------------- /src/semaphore/deploy.yml: -------------------------------------------------------------------------------- 1 | version: v1.0 2 | name: Deploy Pipeline 3 | agent: 4 | machine: 5 | type: e2-standard-2 6 | os_image: ubuntu2404 7 | blocks: 8 | - name: Deployment 9 | task: 10 | jobs: 11 | - name: Steam Depot 12 | commands: 13 | - checkout 14 | - 'curl -H "Cache-Control: no-cache" --fail --output "${HOME}/deploy.sh" "https://raw.githubusercontent.com/redeclipse/base/${SEMAPHORE_GIT_BRANCH}/src/semaphore/deploy.sh"' 15 | - 'chmod +x "${HOME}/deploy.sh"' 16 | - 'cat "${HOME}/deploy.sh"' 17 | - '. "${HOME}/deploy.sh" steam' 18 | secrets: 19 | - name: Steam Token 20 | -------------------------------------------------------------------------------- /config/fx/weapons/splash.cfg: -------------------------------------------------------------------------------- 1 | registerfx FX_W_SPLASH1 $FX_TYPE_PARTICLE [ 2 | fxpropi emitlen 1 3 | fxpropi parttype $FX_PARTTYPE_SINGLE 4 | fxpropi part $PART_SPLASH_SOFT 5 | fxpropi colorized $FX_COLORIZE_PARAM 6 | fxpropi fade 100 7 | fxpropf partsize 0.1 8 | fxpropf partsizechange 0.01 9 | fxpropf blend 0.25 10 | ] 11 | 12 | registerfx FX_W_SPLASH2 $FX_TYPE_PARTICLE [ 13 | fxpropi emitlen 1 14 | fxpropi parttype $FX_PARTTYPE_SINGLE 15 | fxpropi part $PART_SPLASH_SOFT 16 | fxpropi colorized $FX_COLORIZE_PARAM 17 | fxpropi fade 100 18 | fxpropf partsize 0.1 19 | fxpropf partsizechange 0.02 20 | fxpropf blend 1 21 | ] 22 | -------------------------------------------------------------------------------- /config/ui/tool/ents/toolweapon.cfg: -------------------------------------------------------------------------------- 1 | # ui_tool_ent_weapon = [ 2 | ui_tool_ent_param_group "Type" [ 3 | ui_tool_dropdown tool_ent_attr_type $tool_weapon_pickup_names [ 4 | #(ui_tool_ent_attr_props weapon type) 5 | ] 6 | ] 7 | 8 | @(ui_tool_ent_flags_group weapon $tool_ent_weapon_flags [ 9 | "Forced" 10 | ]) 11 | 12 | @(ui_tool_ent_gamemode_group weapon) 13 | @(ui_tool_ent_variant_group weapon) 14 | 15 | ui_tool_ent_param_group "ID" [ 16 | ui_tool_numinput #(tool_ent_attr weapon id) 0 1000 1 [ 17 | #(ui_tool_ent_attr_props weapon id [] 1) 18 | p_val_format = i 19 | ] 20 | ] 21 | ] 22 | -------------------------------------------------------------------------------- /config/fx/sound.cfg: -------------------------------------------------------------------------------- 1 | SND_LOOP = (<< 1 7) 2 | 3 | FX_S_W_PRIMARY = 0 4 | FX_S_W_SECONDARY = 1 5 | FX_S_W_PRIMARY_BEGIN = 2 6 | FX_S_W_PRIMARY_END = 3 7 | FX_S_W_SECONDARY_BEGIN = 4 8 | FX_S_W_SECONDARY_END = 5 9 | FX_S_W_POWER = 6 10 | FX_S_W_POWER2 = 7 11 | FX_S_W_ZOOM = 8 12 | FX_S_W_SWITCH = 9 13 | FX_S_W_RELOAD = 10 14 | FX_S_W_NOTIFY = 11 15 | FX_S_W_EXPLODE = 12 16 | FX_S_W_EXPLODE2 = 13 17 | FX_S_W_DESTROY = 14 18 | FX_S_W_DESTROY2 = 15 19 | FX_S_W_IMPACT = 16 20 | FX_S_W_IMPACT2 = 17 21 | FX_S_W_EXTINGUISH = 18 22 | FX_S_W_EXTINGUISH2 = 19 23 | FX_S_W_TRANSIT = 20 24 | FX_S_W_TRANSIT2 = 21 25 | FX_S_W_BOUNCE = 22 26 | FX_S_W_BOUNCE2 = 23 27 | FX_S_W_USE = 24 28 | FX_S_W_SPAWN = 25 29 | -------------------------------------------------------------------------------- /config/ui/game/widgets/autoscroll.cfg: -------------------------------------------------------------------------------- 1 | gameui_autoscrollh_props = [ 2 | [ p_width 0.5 ] 3 | ] 4 | 5 | // 1: 2: 6 | ui_gameui_autoscrollh = [ 7 | @(props $gameui_autoscrollh_props arg2) 8 | 9 | uiclip $p_width 0 0 0 [ 10 | arg1 11 | uiclipoffsetx (*f $gameui_autoscroll (-f $uiclipvirtw $p_width)) 12 | ] 13 | ] 14 | 15 | gameui_autoscrollv_props = [ 16 | [ p_height 0.5 ] 17 | ] 18 | 19 | // 1: 2: 20 | ui_gameui_autoscrollv = [ 21 | @(props $gameui_autoscrollv_props arg2) 22 | 23 | uiclip 0 $p_height 0 0 [ 24 | arg1 25 | uiclipoffsety (*f $gameui_autoscroll (-f $uiclipvirth $p_height)) 26 | ] 27 | ] 28 | -------------------------------------------------------------------------------- /src/steam/steamuniverse.h: -------------------------------------------------------------------------------- 1 | //========= Copyright � 1996-2008, Valve LLC, All rights reserved. ============ 2 | // 3 | // Purpose: 4 | // 5 | //============================================================================= 6 | 7 | #ifndef STEAMUNIVERSE_H 8 | #define STEAMUNIVERSE_H 9 | #ifdef _WIN32 10 | #pragma once 11 | #endif 12 | 13 | 14 | // Steam universes. Each universe is a self-contained Steam instance. 15 | enum EUniverse 16 | { 17 | k_EUniverseInvalid = 0, 18 | k_EUniversePublic = 1, 19 | k_EUniverseBeta = 2, 20 | k_EUniverseInternal = 3, 21 | k_EUniverseDev = 4, 22 | // k_EUniverseRC = 5, // no such universe anymore 23 | k_EUniverseMax 24 | }; 25 | 26 | 27 | #endif // STEAMUNIVERSE_H 28 | -------------------------------------------------------------------------------- /src/scripts/servinit-comments: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # This script updates the comments of the sv_* variables in servexec.cfg 4 | # 5 | # It reads all sv_* variables in servexec.cfg and adds their comment, if 6 | # present in usage.cfg, to servexec.cfg, replacing the current one. 7 | # 8 | # Usage: update-servexec-comments /path/usage.cfg /path/servexec.cfg 9 | 10 | IFS=$'\n' 11 | for i in $(grep "// sv_" "$2") 12 | do 13 | VAR=$(echo $i | sed -n -e 's%//\ sv_\([a-z0-9]*\) .*%\1%p' -e '/^$/d') 14 | USAGE_DEF=$(grep "^setdesc \"$VAR\"" "$1") 15 | DESC="$(format_desc "$USAGE_DEF")" 16 | if [ -n "$DESC" ] 17 | then 18 | sed 's%^\(//\ sv_'"$VAR"' .*// \).*$%\1'"$DESC"'%' -i "$2" 19 | fi 20 | done 21 | -------------------------------------------------------------------------------- /config/tool/ents/wind.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_wind_flags = [ 2 | mode 3 | dir 4 | ] 5 | 6 | tool_ent_add_attrs_wind = [ 7 | tool_ent_add_attr wind mode $T_ENT_NODELTA 8 | tool_ent_add_attr wind yaw 0 9 | tool_ent_add_attr wind speed 0 10 | tool_ent_add_attr wind radius 0 11 | tool_ent_add_attr wind atten 0 12 | tool_ent_add_attr wind interval 0 13 | tool_ent_add_attr wind implen 0 14 | tool_ent_add_attr wind modes $T_ENT_NODELTA 15 | tool_ent_add_attr wind muts $T_ENT_NODELTA 16 | tool_ent_add_attr wind variant $T_ENT_NODELTA 17 | tool_ent_add_attr wind fxlevel $T_ENT_NODELTA [ 18 | @(tool_ent_fxlevel_getter wind) 19 | ] [ 20 | @(tool_ent_fxlevel_setter wind) 21 | ] 22 | ] 23 | -------------------------------------------------------------------------------- /src/shared/discord_register.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #if defined(DISCORD_DYNAMIC_LIB) 4 | # if defined(_WIN32) 5 | # if defined(DISCORD_BUILDING_SDK) 6 | # define DISCORD_EXPORT __declspec(dllexport) 7 | # else 8 | # define DISCORD_EXPORT __declspec(dllimport) 9 | # endif 10 | # else 11 | # define DISCORD_EXPORT __attribute__((visibility("default"))) 12 | # endif 13 | #else 14 | # define DISCORD_EXPORT 15 | #endif 16 | 17 | #ifdef __cplusplus 18 | extern "C" { 19 | #endif 20 | 21 | DISCORD_EXPORT void Discord_Register(const char* applicationId, const char* command); 22 | DISCORD_EXPORT void Discord_RegisterSteamGame(const char* applicationId, const char* steamId); 23 | 24 | #ifdef __cplusplus 25 | } 26 | #endif 27 | -------------------------------------------------------------------------------- /config/tool/ents/sound.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_sound_flags = [ 2 | noatten 3 | nodelay 4 | priority 5 | nopan 6 | nodist 7 | noenv 8 | clamp 9 | ] 10 | 11 | tool_ent_add_attrs_sound = [ 12 | tool_ent_add_attr sound sound $T_ENT_NODELTA 13 | tool_ent_add_attr sound gain 0 14 | tool_ent_add_attr sound pitch 0 15 | tool_ent_add_attr sound rolloff 0 16 | tool_ent_add_attr sound refdist 0 17 | tool_ent_add_attr sound maxdist 0 18 | tool_ent_add_attr sound flags $T_ENT_NODELTA 19 | tool_ent_add_attr sound modes $T_ENT_NODELTA 20 | tool_ent_add_attr sound muts $T_ENT_NODELTA 21 | tool_ent_add_attr sound variant $T_ENT_NODELTA 22 | tool_ent_add_attr sound offset 0 23 | tool_ent_add_attr sound groupid 0 24 | ] 25 | -------------------------------------------------------------------------------- /config/ui/tool/ents/toolenvmap.cfg: -------------------------------------------------------------------------------- 1 | # ui_tool_ent_envmap = [ 2 | ui_tool_ent_param_group "Radius" [ 3 | ui_tool_numinput #(tool_ent_attr envmap radius) 0 10000 16 [ 4 | #(ui_tool_ent_attr_props envmap radius [] 1) 5 | p_val_format = i 6 | ] 7 | ] 8 | 9 | ui_tool_ent_param_group "Resolution" [ 10 | ui_tool_numinput #(tool_ent_attr envmap size) 0 12 1 [ 11 | #(ui_tool_ent_attr_props envmap size [] 1) 12 | p_val_format = i 13 | ] 14 | ] 15 | 16 | ui_tool_ent_param_group "Blur" [ 17 | ui_tool_numinput #(tool_ent_attr envmap blur) 0 2 1 [ 18 | #(ui_tool_ent_attr_props envmap blur [] 1) 19 | p_val_format = i 20 | ] 21 | ] 22 | ] 23 | -------------------------------------------------------------------------------- /src/shared/genkey.cpp: -------------------------------------------------------------------------------- 1 | #include "cube.h" 2 | 3 | int main(int argc, char **argv) 4 | { 5 | // Generate key pair: genkey 6 | if(argc == 2) 7 | { 8 | vector privkey, pubkey; 9 | genprivkey(argv[1], privkey, pubkey); 10 | printf("private key: %s\n", privkey.getbuf()); 11 | printf("public key: %s\n", pubkey.getbuf()); 12 | return EXIT_SUCCESS; 13 | } 14 | // Print yes/no to match pubkey with privkey: genkey 15 | else if(argc == 3) 16 | { 17 | vector pubkey; 18 | calcpubkey(argv[2], pubkey); 19 | printf("%s\n", !strcmp(argv[1], pubkey.getbuf()) ? "yes" : "no"); 20 | return EXIT_SUCCESS; 21 | } 22 | return EXIT_FAILURE; 23 | } 24 | 25 | -------------------------------------------------------------------------------- /src/include/SDL_opengles2_gl2platform.h: -------------------------------------------------------------------------------- 1 | #ifndef __gl2platform_h_ 2 | #define __gl2platform_h_ 3 | 4 | /* 5 | ** Copyright 2017-2020 The Khronos Group Inc. 6 | ** SPDX-License-Identifier: Apache-2.0 7 | */ 8 | 9 | /* Platform-specific types and definitions for OpenGL ES 2.X gl2.h 10 | * 11 | * Adopters may modify khrplatform.h and this file to suit their platform. 12 | * Please contribute modifications back to Khronos as pull requests on the 13 | * public github repository: 14 | * https://github.com/KhronosGroup/OpenGL-Registry 15 | */ 16 | 17 | /*#include */ 18 | 19 | #ifndef GL_APICALL 20 | #define GL_APICALL KHRONOS_APICALL 21 | #endif 22 | 23 | #ifndef GL_APIENTRY 24 | #define GL_APIENTRY KHRONOS_APIENTRY 25 | #endif 26 | 27 | #endif /* __gl2platform_h_ */ 28 | -------------------------------------------------------------------------------- /src/scripts/wiki-guidelines: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Title 4 | echo "== Guidelines for Connecting to the Red Eclipse Master Server ==" \ 5 | > "$2" 6 | 7 | # Indented headers to wiki-style headers 8 | awk 'BEGIN{ ORS="\n\n"; RS=""; FS="\n" } \ 9 | /^ / { print "===",substr($$0,5),"==="; next };1' \ 10 | "$1" >> "$2" 11 | 12 | # * Delete old title 13 | # * Fix list syntax 14 | # * Fix license link 15 | # * Fix wrapping 16 | sed -e '2d' \ 17 | -e 's,^\ \ -\ ,**\ ,' \ 18 | -e 's,License <\([^>]*\)>,License:\n\n\1,' \ 19 | -ne 'H;$x;$s/^\n//;$s/\n */ /g;$p' \ 20 | -i "$2" 21 | 22 | cat <> "$2" 23 | 24 | This text was automatically generated from guidelines.txt 25 | Please edit only that file and regenerate this wiki text via: 26 | make guidelines-wiki 27 | EOF 28 | -------------------------------------------------------------------------------- /config/glsl.cfg: -------------------------------------------------------------------------------- 1 | exec "config/glsl/shared.cfg" 2 | exec "config/glsl/sdf.cfg" 3 | exec "config/glsl/misc.cfg" 4 | exec "config/glsl/hud.cfg" 5 | exec "config/glsl/world.cfg" 6 | exec "config/glsl/decal.cfg" 7 | exec "config/glsl/grass.cfg" 8 | exec "config/glsl/model.cfg" 9 | exec "config/glsl/ao.cfg" 10 | exec "config/glsl/gi.cfg" 11 | exec "config/glsl/particle.cfg" 12 | exec "config/glsl/stain.cfg" 13 | exec "config/glsl/material.cfg" 14 | exec "config/glsl/smfilter.cfg" 15 | exec "config/glsl/deferred.cfg" 16 | exec "config/glsl/tonemap.cfg" 17 | exec "config/glsl/volumetric.cfg" 18 | exec "config/glsl/sky.cfg" 19 | exec "config/glsl/aa.cfg" 20 | exec "config/glsl/scale.cfg" 21 | exec "config/glsl/blur.cfg" 22 | exec "config/glsl/ui.cfg" 23 | exec "config/glsl/postfx.cfg" 24 | exec "config/glsl/edit.cfg" 25 | 26 | -------------------------------------------------------------------------------- /config/tool/ents/actor.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_add_attrs_actor = [ 2 | tool_ent_add_attr actor type $T_ENT_NODELTA 3 | tool_ent_add_attr actor yaw 0 4 | tool_ent_add_attr actor pitch 0 5 | tool_ent_add_attr actor modes $T_ENT_NODELTA 6 | tool_ent_add_attr actor muts $T_ENT_NODELTA 7 | tool_ent_add_attr actor id 0 8 | tool_ent_add_attr actor weapon $T_ENT_NODELTA [ 9 | if $$tool_ent_cur_attr [ 10 | tool_ent_attr_weapon = (- $$tool_ent_cur_attr 1) 11 | ] [ 12 | tool_ent_attr_weapon = 4 13 | ] 14 | ] [ 15 | $tool_ent_cur_attr = (+ $tool_ent_attr_weapon 1) 16 | ] 17 | tool_ent_add_attr actor health 0 18 | tool_ent_add_attr actor speed 0 19 | tool_ent_add_attr actor scale 0 20 | tool_ent_add_attr actor variant $T_ENT_NODELTA 21 | ] 22 | -------------------------------------------------------------------------------- /src/dpiaware.manifest: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | true/pm 7 | PerMonitorV2 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /config/fx/std.cfg: -------------------------------------------------------------------------------- 1 | FX_TYPE_PARTICLE = 0 2 | FX_TYPE_LIGHT = 1 3 | FX_TYPE_SOUND = 2 4 | FX_TYPE_WIND = 3 5 | FX_TYPE_STAIN = 4 6 | 7 | FX_MOD_RAND = 1 8 | FX_MOD_LERP = 2 9 | FX_MOD_PARAM = 3 10 | 11 | FX_MOD_LERP_ACTIVE = 0 12 | FX_MOD_LERP_EMIT = 1 13 | FX_MOD_LERP_PARAM = 2 14 | FX_MOD_LERP_ITER = 3 15 | FX_MOD_LERP_CAMFACING = 4 16 | FX_MOD_LERP_SPEED = 5 17 | 18 | FX_MOD_LERP_SHAPE_LINEAR = 0 19 | FX_MOD_LERP_SHAPE_SQUARE_IN = 1 20 | FX_MOD_LERP_SHAPE_SQUARE_OUT = 2 21 | FX_MOD_LERP_SHAPE_SMOOTH = 3 22 | 23 | FX_MOD_PARAM_ADD = 0 24 | FX_MOD_PARAM_MUL = 1 25 | 26 | FX_COLORIZE_DISABLED = 0 27 | FX_COLORIZE_PARAM = 1 28 | FX_COLORIZE_PALETTE = 2 29 | 30 | FX_ENT_POS_ORIGIN = 0 31 | FX_ENT_POS_BOTTOM = 1 32 | FX_ENT_POS_MIDDLE = 2 33 | FX_ENT_POS_TOP = 3 34 | FX_ENT_POS_DIR = 4 35 | FX_ENT_POS_MUZZLE = 5 36 | FX_ENT_POS_TAG = 6 37 | -------------------------------------------------------------------------------- /config/tool/ents/route.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_route_actions = [ 2 | primary 3 | secondary 4 | reload 5 | use 6 | jump 7 | walk 8 | crouch 9 | special 10 | drop 11 | affinity 12 | ] 13 | 14 | tool_ent_add_attrs_route = [ 15 | tool_ent_add_attr route num 0 16 | tool_ent_add_attr route yaw 0 17 | tool_ent_add_attr route pitch 0 18 | tool_ent_add_attr route move $T_ENT_NODELTA [ 19 | tool_ent_attr_move = (+ (clamp ($$tool_ent_cur_attr) -1 1) 1) 20 | ] [ 21 | $tool_ent_cur_attr = (- $tool_ent_attr_move 1) 22 | ] 23 | tool_ent_add_attr route strafe $T_ENT_NODELTA [ 24 | tool_ent_attr_strafe = (+ (clamp ($$tool_ent_cur_attr) -1 1) 1) 25 | ] [ 26 | $tool_ent_cur_attr = (- $tool_ent_attr_strafe 1) 27 | ] 28 | tool_ent_add_attr route action $T_ENT_NODELTA 29 | ] 30 | -------------------------------------------------------------------------------- /src/semaphore/semaphore.yml: -------------------------------------------------------------------------------- 1 | version: v1.0 2 | name: Initial Pipeline 3 | agent: 4 | machine: 5 | type: e2-standard-2 6 | os_image: ubuntu2404 7 | auto_cancel: 8 | running: 9 | when: 'true' 10 | blocks: 11 | - name: Start 12 | task: 13 | jobs: 14 | - name: Build 15 | commands: 16 | - checkout 17 | - ls -la 18 | - 'ls -la "${HOME}"' 19 | - 'curl -H "Cache-Control: no-cache" --fail --output "${HOME}/build.sh" "https://raw.githubusercontent.com/redeclipse/base/${SEMAPHORE_GIT_BRANCH}/src/semaphore/build.sh"' 20 | - 'chmod +x "${HOME}/build.sh"' 21 | - 'cat "${HOME}/build.sh"' 22 | - '. "${HOME}/build.sh"' 23 | secrets: 24 | - name: GitHub Token 25 | promotions: 26 | - name: Deploy 27 | pipeline_file: deploy.yml 28 | -------------------------------------------------------------------------------- /config/defaults.cfg: -------------------------------------------------------------------------------- 1 | loopfiles curmod . zip [ addzip $curmod ] 2 | loopfiles curmod maps zip [ addzip (concatword "maps/" $curmod) ] 3 | loopfiles curmod mods zip [ 4 | mntmod = (concatword "mods/" $curmod) 5 | addzip $mntmod $mntmod 6 | exec (concatword "mods/" $curmod "/package.cfg") 7 | ] 8 | 9 | exec "config/keymap.cfg" 10 | 11 | exec "config/engine.cfg" 12 | exec "config/brush.cfg" 13 | exec "config/setup.cfg" 14 | exec "config/legacy.cfg" 15 | 16 | exec "sounds/package.cfg" 17 | exec "vanities/package.cfg" 18 | exec "mixers/package.cfg" 19 | exec "config/fx.cfg" 20 | 21 | // exec "config/compass.cfg" 22 | exec "config/ui/package.cfg" // keep this here, it uses some of the stuff above 23 | exec "config/comp/package.cfg" // composites use UI stuff 24 | exec "config/announcer/announcer.cfg" 25 | 26 | exec "config/tips.cfg" 27 | exec "config/usage.cfg" 28 | -------------------------------------------------------------------------------- /config/fx/projs/casing.cfg: -------------------------------------------------------------------------------- 1 | if (> $fxdetail 1) [ 2 | registerfx FX_P_CASING_LIFE $FX_TYPE_PARTICLE [ 3 | fxpropf emitdist 256 4 | fxpropf emitcull 4 5 | fxpropi parttype $FX_PARTTYPE_SPLASH 6 | fxpropi part $PART_SMOKE 7 | fxpropi fade 100 8 | fxpropf partsize 1 9 | fxpropf partsizechange 0.002 10 | fxpropf vel 0 11 | fxpropi num 2 12 | fxpropf gravity -15 13 | fxpropf blend 0.0175 14 | fxpropf blend 0 $FX_MOD_LERP [ 15 | fxpropi lerptime 2000 16 | ] 17 | ] 18 | ] 19 | 20 | registerfx FX_P_CASING_BOUNCE $FX_TYPE_SOUND [ 21 | fxpropf emitdist 256 22 | fxprops sound S_SHELL 23 | fxpropf gain 0 24 | fxpropf gain 1 $FX_MOD_LERP [ 25 | fxpropi lerpmode $FX_MOD_LERP_PARAM 26 | fxpropi lerpparam $P_FX_BOUNCE_VEL_PARAM 27 | ] 28 | ] 29 | -------------------------------------------------------------------------------- /config/tool/ents/rail.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_rail_flags = [ 2 | followyaw 3 | followpitch 4 | seek 5 | spline 6 | setspeed 7 | prev 8 | next 9 | ] 10 | 11 | tool_ent_rail_collide = [ 12 | touchkill 13 | nopassenger 14 | ] 15 | 16 | tool_ent_add_attrs_rail = [ 17 | tool_ent_add_attr rail time 0 18 | tool_ent_add_attr rail flags $T_ENT_NODELTA 19 | tool_ent_add_attr rail yaw 0 20 | tool_ent_add_attr rail pitch 0 21 | tool_ent_add_attr rail rotlen 0 22 | tool_ent_add_attr rail rotwait 0 23 | tool_ent_add_attr rail collide $T_ENT_NODELTA 24 | tool_ent_add_attr rail anim $T_ENT_NODELTA 25 | tool_ent_add_attr rail aspeed 0 26 | tool_ent_add_attr rail aoffset 0 27 | tool_ent_add_attr rail modes $T_ENT_NODELTA 28 | tool_ent_add_attr rail muts $T_ENT_NODELTA 29 | tool_ent_add_attr rail variant $T_ENT_NODELTA 30 | ] 31 | -------------------------------------------------------------------------------- /config/ui/events/team.cfg: -------------------------------------------------------------------------------- 1 | event_team_request = [ 2 | event_image $infotex 0xFFFFFF 3 | uitext (concatword "Moved to " (getteamname (geteventlist $event_id "args" "team")) " as previously requested") $game_hud_event_text_size [ 4 | uistyle leftmiddle 5 | uitextalign -1 6 | ] 7 | ] 8 | 9 | event_team_moved = [ 10 | event_image $infotex 0xFFFFFF 11 | uitext (concatword "Moved to " (getteamname (geteventlist $event_id "args" "team")) " by " (geteventname $event_id "client" 1)) $game_hud_event_text_size [ 12 | uistyle leftmiddle 13 | uitextalign -1 14 | ] 15 | ] 16 | 17 | event_team_swap = [ 18 | event_image $infotex 0xFFFFFF 19 | uitext (concatword (geteventname $event_id "client" 0) " requests swap to " (getteamname (geteventlist $event_id "args" "team"))) $game_hud_event_text_size [ 20 | uistyle leftmiddle 21 | uitextalign -1 22 | ] 23 | ] 24 | -------------------------------------------------------------------------------- /config/ui/tool/toolview/widgets/tooltexinfo.cfg: -------------------------------------------------------------------------------- 1 | tool_texinfo_props = [ 2 | [ p_disabled 0 ] 3 | [ p_text_size $ui_tool_text_size_s_unscaled ] 4 | [ p_decal 0 ] 5 | ] 6 | 7 | // 1: 2: 8 | ui_tool_texinfo = [ 9 | @(props $tool_texinfo_props arg2) 10 | 11 | @(tool_ui_scale p_text_size) 12 | 13 | local _namefunc _name _nosel 14 | _namefunc = (? $p_decal getdecalname gettexname) 15 | 16 | if $p_disabled [ 17 | uitext "-" $p_text_size 18 | ] [ 19 | if (< $arg1 0) [ 20 | _nosel = 1 21 | ] [ 22 | _name = (tool_path_striptexcmds ($_namefunc $arg1)) 23 | _nosel = (=s $_name "") 24 | ] 25 | 26 | if $_nosel [ 27 | uitext "No texture selected" $p_text_size 28 | ] [ 29 | uitext (format "#%1: %2" $arg1 $_name) $p_text_size 30 | ] 31 | ] 32 | ] 33 | -------------------------------------------------------------------------------- /src/scripts/install_deploy.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | DEPLOY_REPO_DIR=$DIR/deploy 5 | 6 | NEEDS_CLONE=0 7 | 8 | if [ ! -d "${DEPLOY_REPO_DIR}" ]; then 9 | echo "Deploy repo not found, cloning" 10 | NEEDS_CLONE=1 11 | else 12 | cd "${DEPLOY_REPO_DIR}" 13 | if [ -z "$(git remote -v | grep 'https://github.com/redeclipse/deploy.git')" ]; then 14 | echo "Deploy repo invalid, re-cloning" 15 | NEEDS_CLONE=1 16 | fi 17 | fi 18 | 19 | if [ $NEEDS_CLONE -eq 1 ]; then 20 | echo "Cloning deploy repo" 21 | rm -rf "${DEPLOY_REPO_DIR}" 22 | git clone --single-branch -b master --depth 1 https://github.com/redeclipse/deploy.git "${DEPLOY_REPO_DIR}" 23 | else 24 | echo "Updating deploy repo" 25 | cd "${DEPLOY_REPO_DIR}" 26 | git fetch origin --depth 1 && git clean -xfd && git reset --hard origin/master 27 | fi 28 | 29 | cd "${DIR}/../.." 30 | tar xf "${DEPLOY_REPO_DIR}/master/linux.tar.gz" 31 | -------------------------------------------------------------------------------- /config/tool/binds/default.cfg: -------------------------------------------------------------------------------- 1 | toolbind S ta_save (kmod CTRL) 2 | toolbind S ta_save_as (kmod CTRL SHIFT) 3 | toolbind Z ta_undo (kmod CTRL) 4 | toolbind Z ta_redo (kmod CTRL SHIFT) 5 | toolbind C ta_grab 6 | toolbind C ta_ent_cycle_snapmode (kmod SHIFT) 7 | toolbind C ta_copy (kmod CTRL) 8 | toolbind V ta_paste (kmod CTRL) 9 | toolbind T ta_tex_get (kmod SHIFT) 10 | toolbind F ta_ent_search (kmod CTRL) 11 | toolbind T ta_tex_apply 12 | toolbind T ta_tex_apply_allfaces (kmod CTRL) 13 | toolbind N ta_ent_add (kmod CTRL) 14 | toolbind N ta_ent_add_on_camera (kmod CTRL SHIFT) 15 | toolbind L ta_ent_chain_link 16 | toolbind L ta_ent_star_link (kmod SHIFT) 17 | toolbind X ta_flip (kmod CTRL) 18 | toolbind M ta_toggle_showmat (kmod CTRL) 19 | toolbind P ta_toggle_showphyslayers (kmod CTRL) 20 | toolbind M ta_setmat 21 | 22 | toolbind F3 ta_search 23 | toolbind F4 ta_textures 24 | toolbind F8 ta_recalc 25 | 26 | toolbind X ta_focus_axis_x 27 | toolbind Y ta_focus_axis_y 28 | toolbind Z ta_focus_axis_z 29 | -------------------------------------------------------------------------------- /config/tool/ents/mapui.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_add_attrs_mapui = [ 2 | tool_ent_add_attr mapui type 0 3 | tool_ent_add_attr mapui flags 0 4 | tool_ent_add_attr mapui yaw 0 5 | tool_ent_add_attr mapui pitch 0 6 | tool_ent_add_attr mapui radius 0 7 | tool_ent_add_attr mapui scale 0 8 | tool_ent_add_attr mapui yawdet 0 9 | tool_ent_add_attr mapui pitchdet 0 10 | tool_ent_add_attr mapui colour $T_ENT_NODELTA 11 | tool_ent_add_attr mapui blend $T_ENT_NODELTA [ // 18 12 | tool_ent_mapui_blend_val = (? $$tool_ent_cur_attr $$tool_ent_cur_attr 100) 13 | ] [ 14 | $tool_ent_cur_attr = (? (= $tool_ent_mapui_blend_val 100) 0 $tool_ent_mapui_blend_val) 15 | ] 16 | tool_ent_add_attr mapui modes $T_ENT_NODELTA 17 | tool_ent_add_attr mapui muts $T_ENT_NODELTA 18 | tool_ent_add_attr mapui variant $T_ENT_NODELTA 19 | tool_ent_add_attr mapui fxlevel $T_ENT_NODELTA [ 20 | @(tool_ent_fxlevel_getter lightfx) 21 | ] [ 22 | @(tool_ent_fxlevel_setter lightfx) 23 | ] 24 | ] 25 | -------------------------------------------------------------------------------- /src/include/SDL_copying.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2016 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | -------------------------------------------------------------------------------- /config/tool/toolphysics.cfg: -------------------------------------------------------------------------------- 1 | tool_goto_control_Physics = [ 2 | if $arg1 [ 3 | tool_phys_adv = 1 4 | ] 5 | 6 | toolpanel_open tool_phys right [ 7 | p_title = "Map physics" 8 | p_clear_stack = 1 9 | ] 10 | ] 11 | 12 | // 1: 2: 3: 13 | tool_phys_register_control = [ 14 | tool_register_control $arg1 $arg2 "Physics" $arg3 15 | ] 16 | 17 | tool_action ta_physics [ 18 | p_short_desc = "Physics panel" 19 | p_long_desc = "Open the map physics panel" 20 | p_icon = "textures/icons/edit/physics" 21 | p_category = "Physics" 22 | p_code = [ 23 | toolpanel_toggle tool_phys right [ 24 | p_title = "Map physics" 25 | p_clear_stack = 1 26 | ] 27 | ] 28 | ] 29 | 30 | tool_action ta_toggle_showphyslayers [ 31 | p_short_desc = "Toggle physical layer display" 32 | p_icon = "textures/icons/edit/cube" 33 | p_category = "Physics" 34 | p_code = [ showphyslayers (! $showphyslayers) ] 35 | ] 36 | -------------------------------------------------------------------------------- /src/scripts/wiki-contributors: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # "$1" is doc/readme.txt 4 | # "$2" is output file 5 | 6 | cat <> "$2" 7 | This page was automatically generated from the source of Red Eclipse, please do not edit it manually. 8 | 9 | == Red Eclipse Team == 10 | 11 | === Team Lead === 12 | 13 | {| border="1" cellpadding="10" cellspacing="0" 14 | EOF 15 | 16 | # convert to UTF-8 and grab everything from dev tag and onward 17 | iconv -f ISO-8859-1 -t UTF8 "$1" | sed -n '/== Developers ==/,$p;/^$/d' >> "$2" 18 | 19 | # join lines starting with two or more spaces 20 | sed -ne 'H;$x;$s%^\n%%;$s%\n *% %g;$p' -i "$2" 21 | 22 | # delete developers tag 23 | sed '/== Developers ==/d' -i "$2" 24 | 25 | # table end and start developers table after eihrul 26 | sed 's%.*Eihrul.*%&\n|}\n\n== Developers ==\n\n{| border="1" cellpadding="10" cellspacing="0"%' -i "$2" 27 | 28 | # table end at contributors tag 29 | sed 's%.*== Contributors ==.*%|}\n\n&%' -i "$2" 30 | 31 | # tablification of devs 32 | sed 's%^\* \([^-]*\) - \([^-]*\) - \(.*\)%| \1\n| \2\n| \3\n|-%' -i "$2" 33 | -------------------------------------------------------------------------------- /src/enet/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2002-2024 Lee Salzman 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 4 | 5 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 6 | 7 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 8 | -------------------------------------------------------------------------------- /config/fx/projs/debris.cfg: -------------------------------------------------------------------------------- 1 | registerfx FX_P_DEBRIS_LIFE $FX_TYPE_PARTICLE [ 2 | fxpropf emitdist 512 3 | fxpropf emitcull 4 4 | fxpropi parttype $FX_PARTTYPE_SINGLE 5 | fxpropi part $PART_SPARK 6 | fxpropc colour 255 200 100 7 | fxpropf partsize 1.5 8 | fxpropf partsize 1.5 $FX_MOD_RAND 9 | fxpropf blend 0.005 10 | ] 11 | 12 | registerfx FX_P_DEBRIS_LIFE_SMOKE $FX_TYPE_PARTICLE [ 13 | fxparent FX_P_DEBRIS_LIFE 14 | fxpropf emitdist 512 15 | fxpropf emitcull 4 16 | fxpropi parttype $FX_PARTTYPE_SPLASH 17 | fxpropi part $PART_SMOKE 18 | fxpropi fade 250 19 | fxpropf partsize 1 20 | fxpropf partsize 1 $FX_MOD_RAND 21 | fxpropf vel 5 22 | fxpropf gravity -20 23 | fxpropi fadein 500 24 | fxpropf blend 0.05 25 | ] 26 | 27 | registerfx FX_P_DEBRIS_BOUNCE $FX_TYPE_SOUND [ 28 | fxpropf emitdist 512 29 | fxprops sound S_DEBRIS 30 | fxpropf gain 0 31 | fxpropf gain 1 $FX_MOD_LERP [ 32 | fxpropi lerpmode $FX_MOD_LERP_PARAM 33 | fxpropi lerpparam $P_FX_BOUNCE_VEL_PARAM 34 | ] 35 | ] 36 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | * text=auto 2 | *.bat text eol=crlf 3 | *.c text=auto 4 | *.cfg text=auto 5 | *.cpp text=auto 6 | *.css text=auto 7 | *.h text=auto 8 | *.html text=auto 9 | *.js text=auto 10 | *.js.map text=auto 11 | *.json text=auto 12 | *.md text=auto 13 | *.php text=auto 14 | *.txt text=auto 15 | .git* text=auto 16 | *.sh text eol=lf 17 | *.a binary 18 | *.avi binary 19 | *.dds binary 20 | *.dll binary 21 | *.eot binary 22 | *.exe binary 23 | *.gif binary 24 | *.icns binary 25 | *.ico binary 26 | *.iqm binary 27 | *.jpg binary 28 | *.lib binary 29 | *.md2 binary 30 | *.md3 binary 31 | *.md5 binary 32 | *.md5anim binary 33 | *.md5mesh binary 34 | *.mp3 binary 35 | *.mp4 binary 36 | *.nib binary 37 | *.ogg binary 38 | *.png binary 39 | *.smd binary 40 | *.tga binary 41 | *.ttf binary 42 | *.wav binary 43 | *.woff binary 44 | *.woff2 binary 45 | -------------------------------------------------------------------------------- /config/tool/ents/decal.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_add_attrs_decal = [ 2 | tool_ent_add_attr decal type $T_ENT_NODELTA 3 | tool_ent_add_attr decal yaw 0 4 | tool_ent_add_attr decal pitch 0 5 | tool_ent_add_attr decal roll 0 6 | tool_ent_add_attr decal scale 0 7 | tool_ent_add_attr decal blend $T_ENT_NODELTA [ 8 | tool_ent_attr_blend_val = (? $$tool_ent_cur_attr $$tool_ent_cur_attr 100) 9 | ] [ 10 | $tool_ent_cur_attr = (? (= $tool_ent_attr_blend_val 100) 0 $tool_ent_attr_blend_val) 11 | ] 12 | tool_ent_add_attr decal colour $T_ENT_NODELTA 13 | tool_ent_add_attr decal palette $T_ENT_NODELTA 14 | tool_ent_add_attr decal palindex $T_ENT_NODELTA [ 15 | @(tool_ent_palindex_getter decal) 16 | ] [ 17 | @(tool_ent_palindex_setter decal) 18 | ] 19 | tool_ent_add_attr decal modes $T_ENT_NODELTA 20 | tool_ent_add_attr decal muts $T_ENT_NODELTA 21 | tool_ent_add_attr decal variant $T_ENT_NODELTA 22 | tool_ent_add_attr decal fxlevel $T_ENT_NODELTA [ 23 | @(tool_ent_fxlevel_getter decal) 24 | ] [ 25 | @(tool_ent_fxlevel_setter decal) 26 | ] 27 | ] 28 | -------------------------------------------------------------------------------- /src/scripts/servinit-defaults: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # This script updates the default values of the sv_* variables in 4 | # doc/examples/servexec.cfg 5 | # 6 | # It reads all sv_* variables in doc/examples/servexec.cfg, extracts their 7 | # default value by executing them in a Red Eclipse server, then feeds this 8 | # value back to the corresponding variable in doc/examples/servexec.cfg 9 | 10 | DIR="$(cd "$(dirname "$0")" && pwd)" 11 | 12 | get_values () 13 | { 14 | sed -n 's%\/\/\ \(sv_[a-z]*\)\ .*\ //\ .*%\1;%p' "$1" \ 15 | | tr '\n' ' ' \ 16 | | xargs -0 -I '{}' timeout 2 "$DIR"/../../redeclipse_server.sh -g -x''{}'' 2>/dev/null \ 17 | | grep sv_ \ 18 | | grep -v "sv_serverdesc" | grep -v "sv_servermotd" 19 | } 20 | 21 | put_values () 22 | { 23 | IFS=$'\n' 24 | for i in $(get_values "$1") 25 | do 26 | echo "$i" | grep unknown || : 27 | VAR=$(echo $i | sed 's%.* \([^ ]*\) = .*%\1%') 28 | VAL=$(echo $i | sed 's%.*=\ \(.*\)%\1%') 29 | sed 's%//\ '"$VAR"'\ [^/]*\(.*\)%//\ '"$VAR"'\ '"$VAL"'\ \1%' -i "$1" 30 | done 31 | } 32 | 33 | # Main 34 | put_values "$1" 35 | -------------------------------------------------------------------------------- /src/support/jsmn.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2010 Serge A. Zaitsev 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is 8 | furnished to do so, subject to the following conditions: 9 | 10 | The above copyright notice and this permission notice shall be included in 11 | all copies or substantial portions of the Software. 12 | 13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 | THE SOFTWARE. 20 | 21 | -------------------------------------------------------------------------------- /config/fx/projs/gib.cfg: -------------------------------------------------------------------------------- 1 | registerfx FX_P_GIB_LIFE $FX_TYPE_PARTICLE [ 2 | // emit gradually more often to compensate for size decrease over time 3 | fxpropf emitdist 768 4 | fxpropf emitcull 4 5 | fxpropi emittimeliness 0 6 | fxpropi emitinterval 500 7 | fxpropi emitinterval 100 $FX_MOD_LERP [ 8 | fxpropi lerptime 500 9 | ] 10 | fxpropf emitmove 0.1 11 | fxpropi parttype $FX_PARTTYPE_SPLASH 12 | fxpropi part $PART_BLOOD 13 | fxpropi fade 1000 14 | fxpropf partsize 4 15 | fxpropf partsize 0.1 $FX_MOD_LERP [ 16 | fxpropi lerptime 1000 17 | ] 18 | fxpropf partsize 0.5 $FX_MOD_RAND 19 | fxpropf vel 0 20 | fxpropi num 1 21 | fxpropf gravity 80 22 | fxpropc colour 16 200 200 23 | fxpropc envcolour 255 255 255 24 | fxpropf envblend 0.65 25 | fxpropi collide $STAIN_BLOOD 26 | ] 27 | 28 | registerfx FX_P_GIB_BOUNCE $FX_TYPE_SOUND [ 29 | fxpropf emitdist 512 30 | fxprops sound S_SPLOSH 31 | fxpropf gain 0 32 | fxpropf gain 1 $FX_MOD_LERP [ 33 | fxpropi lerpmode $FX_MOD_LERP_PARAM 34 | fxpropi lerpparam $P_FX_BOUNCE_VEL_PARAM 35 | ] 36 | ] 37 | -------------------------------------------------------------------------------- /src/include/SDL_types.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2024 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | 22 | /** 23 | * \file SDL_types.h 24 | * 25 | * \deprecated 26 | */ 27 | 28 | /* DEPRECATED */ 29 | #include "SDL_stdinc.h" 30 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.dbg 2 | *.bin 3 | *.exe 4 | *.pdb 5 | *.tmp 6 | src/redeclipse_* 7 | src/tessfont_* 8 | src/genkey_* 9 | bin/**/redeclipse_* 10 | bin/**/tessfont_* 11 | bin/**/genkey_* 12 | bin/x86/steam_appid.txt 13 | bin/amd64/steam_appid.txt 14 | src/.objs/ 15 | *.o 16 | *.so 17 | *.gch 18 | *.pch 19 | *.dll 20 | *.a 21 | *.lib 22 | *.bak 23 | out 24 | *~ 25 | .directory 26 | .DS_Store 27 | *.orig 28 | *.rej 29 | *.bak 30 | *.kate-swp 31 | *.core 32 | *.diff 33 | *.patch 34 | *.out 35 | home/ 36 | cache/ 37 | src/redeclipse.layout 38 | src/redeclipse.depend 39 | src/redeclipse.res 40 | branch.txt 41 | version.txt 42 | */version.txt 43 | src/redeclipse.cscope_file_list 44 | src/build/ 45 | .kdev/ 46 | .vscode/ 47 | .vs/ 48 | GPATH 49 | GTAGS 50 | GRTAGS 51 | CMakeCache.txt 52 | CMakeFiles/ 53 | cmake_install.cmake 54 | data/bonus/ 55 | extras.txt 56 | src/redeclipse.code-workspace 57 | bin/amd64/redeclipse.exp 58 | src/redeclipse.aps 59 | src/vcpp/.vs/ 60 | src/vcpp/client.vcxproj.user 61 | src/vcpp/server.vcxproj.user 62 | src/vcpp/x64/ 63 | src/vcpp/x86/ 64 | src/vcpp/Win32/ 65 | Block 66 | src/scripts/deploy/ 67 | .github/copilot-instructions.md 68 | GEMINI.md 69 | CLAUDE.md 70 | -------------------------------------------------------------------------------- /config/tool/ents/soundenv.cfg: -------------------------------------------------------------------------------- 1 | // 1: 2 | tool_ent_soundenv_get_fade = [ 3 | local _fadevalattr _fadevalattrname 4 | _fadevalattr = (concatword fadevals (+ (div $arg1 4) 1)) 5 | _fadevalattrname = (tool_ent_attr soundenv $_fadevalattr) 6 | 7 | tool_get_byte $$_fadevalattrname (mod $arg1 4) 8 | ] 9 | 10 | // 1: 2: 11 | tool_ent_soundenv_set_fade = [ 12 | local _fadevalattr _fadevalattrname 13 | _fadevalattr = (concatword fadevals (+ (div $arg1 4) 1)) 14 | _fadevalattrname = (tool_ent_attr soundenv $_fadevalattr) 15 | 16 | $_fadevalattrname = (tool_set_byte $$_fadevalattrname $arg2 (mod $arg1 4)) 17 | tool_ent_force_attr soundenv $_fadevalattr 18 | ] 19 | 20 | tool_ent_add_attrs_soundenv = [ 21 | tool_ent_add_attr soundenv type $T_ENT_NODELTA 22 | tool_ent_add_attr soundenv width 0 23 | tool_ent_add_attr soundenv length 0 24 | tool_ent_add_attr soundenv height 0 25 | tool_ent_add_attr soundenv fadevals1 0 $T_ENT_NODELTA 26 | tool_ent_add_attr soundenv fadevals2 0 $T_ENT_NODELTA 27 | tool_ent_add_attr soundenv fadevals3 0 $T_ENT_NODELTA 28 | tool_ent_add_attr soundenv fadevals4 0 $T_ENT_NODELTA 29 | ] 30 | -------------------------------------------------------------------------------- /src/enet/callbacks.c: -------------------------------------------------------------------------------- 1 | /** 2 | @file callbacks.c 3 | @brief ENet callback functions 4 | */ 5 | #define ENET_BUILDING_LIB 1 6 | #include "enet/enet.h" 7 | 8 | static ENetCallbacks callbacks = { malloc, free, abort }; 9 | 10 | int 11 | enet_initialize_with_callbacks (ENetVersion version, const ENetCallbacks * inits) 12 | { 13 | if (version < ENET_VERSION_CREATE (1, 3, 0)) 14 | return -1; 15 | 16 | if (inits -> malloc != NULL || inits -> free != NULL) 17 | { 18 | if (inits -> malloc == NULL || inits -> free == NULL) 19 | return -1; 20 | 21 | callbacks.malloc = inits -> malloc; 22 | callbacks.free = inits -> free; 23 | } 24 | 25 | if (inits -> no_memory != NULL) 26 | callbacks.no_memory = inits -> no_memory; 27 | 28 | return enet_initialize (); 29 | } 30 | 31 | ENetVersion 32 | enet_linked_version (void) 33 | { 34 | return ENET_VERSION; 35 | } 36 | 37 | void * 38 | enet_malloc (size_t size) 39 | { 40 | void * memory = callbacks.malloc (size); 41 | 42 | if (memory == NULL) 43 | callbacks.no_memory (); 44 | 45 | return memory; 46 | } 47 | 48 | void 49 | enet_free (void * memory) 50 | { 51 | callbacks.free (memory); 52 | } 53 | 54 | -------------------------------------------------------------------------------- /bin/LICENSE.tiff.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 1988-1997 Sam Leffler 2 | Copyright (c) 1991-1997 Silicon Graphics, Inc. 3 | 4 | Permission to use, copy, modify, distribute, and sell this software and 5 | its documentation for any purpose is hereby granted without fee, provided 6 | that (i) the above copyright notices and this permission notice appear in 7 | all copies of the software and related documentation, and (ii) the names of 8 | Sam Leffler and Silicon Graphics may not be used in any advertising or 9 | publicity relating to the software without the specific, prior written 10 | permission of Sam Leffler and Silicon Graphics. 11 | 12 | THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 13 | EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 14 | WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 15 | 16 | IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 17 | ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 18 | OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 19 | WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 20 | LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 21 | OF THIS SOFTWARE. 22 | -------------------------------------------------------------------------------- /src/redeclipse.rc: -------------------------------------------------------------------------------- 1 | #include "winresrc.h" 2 | #include "engine/version.h" 3 | #define IDI_ICON1 1 4 | 5 | CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "dpiaware.manifest" 6 | LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US 7 | IDI_ICON1 ICON "redeclipse.ico" 8 | 9 | VS_VERSION_INFO VERSIONINFO 10 | FILEVERSION VERSION_MAJOR,VERSION_MINOR,VERSION_PATCH,0 11 | PRODUCTVERSION VERSION_MAJOR,VERSION_MINOR,VERSION_PATCH,0 12 | { 13 | BLOCK "StringFileInfo" 14 | { 15 | BLOCK "040904b0" 16 | { 17 | VALUE "CompanyName", VERSION_NAME " Team\0" 18 | VALUE "FileDescription", VERSION_NAME "\0" 19 | VALUE "FileVersion", VERSION_STRING "\0" 20 | VALUE "LegalCopyright", "(C) " VERSION_COPY " " VERSION_NAME " Team\0" 21 | #ifdef STANDALONE 22 | VALUE "OriginalFilename", VERSION_UNAME "_server.exe\0" 23 | #else 24 | VALUE "OriginalFilename", VERSION_UNAME ".exe\0" 25 | #endif 26 | VALUE "ProductName", VERSION_NAME "\0" 27 | VALUE "ProductVersion", VERSION_STRING "\0" 28 | } 29 | } 30 | BLOCK "VarFileInfo" 31 | { 32 | VALUE "Translation", 0x409, 1200 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /config/ui/dyn/builtins.cfg: -------------------------------------------------------------------------------- 1 | entity_builtin_scoreboard = [ 2 | result [ 3 | local _colour _blend 4 | _colour = (getentity $uiarg1 1 8) 5 | if (! $_colour) [ _colour = 0xFFFFFF ] 6 | _blend = (getentity $uiarg1 1 9) 7 | if $_blend [ _blend = (divf $_blend 100) ] [ blend = 1.0 ] 8 | _blend = (*f $_blend (getdarkness 5)) 9 | 10 | uiimage @(format "scoreboard [teamid = %1]" $arg1) $_colour 0 1.0 1.0 11 | 12 | if $_blend [ uipropagate [ uicolourblend $_blend ] ] 13 | ] 14 | ] 15 | 16 | dynui entity_builtin_1 (entity_builtin_scoreboard 0) 17 | dynui entity_builtin_2 (entity_builtin_scoreboard 1) 18 | dynui entity_builtin_3 (entity_builtin_scoreboard 2) 19 | 20 | dynui entity_builtin_4 [ 21 | local _colour _blend 22 | _colour = (getentity $uiarg1 1 8) 23 | if (! $_colour) [ _colour = 0xFFFFFF ] 24 | _blend = (getentity $uiarg1 1 9) 25 | if $_blend [ _blend = (divf $_blend 100) ] [ _blend = 1.0 ] 26 | _blend = (*f $_blend (getdarkness 5)) 27 | 28 | uiclip 0.99 0.12375 0.01 0.01 [ 29 | uiimage "feather [tex = [ticker]]" 0xFFFFFFFF 0 1.0 1.0 30 | ] 31 | 32 | if $_blend [ uipropagate [ uicolourblend $_blend ] ] 33 | ] -------------------------------------------------------------------------------- /src/install/nix/redeclipse.desktop.am: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Type=Application 3 | Version=1.2 4 | Name=Red Eclipse 5 | GenericName=First-person shooter game 6 | GenericName[es]=Juego de tiros en primera persona 7 | GenericName[gl]=Xogo de tiros en primeira persoa 8 | GenericName[it]=Sparatutto in prima persona 9 | GenericName[pt]=Jogo de tiros em primeira pessoa 10 | GenericName[sv]=Förstapersonsskjutare 11 | GenericName[fr]=Jeu de tir à la première personne 12 | Comment=First-person shooter with agile gameplay and built-in editor 13 | Comment[de]=Ego-Shooter-Spiel mit agilem Gameplay und integriertem Editor 14 | Comment[es]=Juego de tiros en primera persona con jugabilidad ágil y editor incorporado 15 | Comment[gl]=Xogo de tiros en primeira persoa con xogo áxil e editor incorporado 16 | Comment[it]=Sparatutto in prima persona con agile gameplay ed editor incorporato 17 | Comment[pt]=Jogo de tiros em primeira pessoa com jogabilidade ágil e editor incorporado 18 | Comment[sv]=Förstapersonsskjutare med rörlig spelstil och inbyggd baneditor 19 | Comment[fr]=Jeu de tir à la première personne avec un éditeur de cartes intégré 20 | Icon=@APPNAME@ 21 | Exec=@APPNAME@ 22 | Categories=Game;ActionGame;Shooter; 23 | Keywords=fps;action;multiplayer;play;arena;mapeditor; 24 | -------------------------------------------------------------------------------- /config/ui/tool/toolview/widgets/toolcollapsegroup.cfg: -------------------------------------------------------------------------------- 1 | tool_collapsegroup_props = [ 2 | [ p_disabled 0 ] 3 | [ p_label "" ] 4 | [ p_label_size $ui_tool_text_size_s_unscaled ] 5 | [ p_force_open 0 ] 6 | [ p_id [] ] 7 | ] 8 | 9 | // 1: 2: 3: 10 | ui_tool_collapsegroup = [ 11 | @(props $tool_collapsegroup_props arg3) 12 | 13 | @(tool_ui_scale p_label_size) 14 | 15 | local _show 16 | _show = (|| $p_force_open [? (getalias $arg1) 1 0]) 17 | 18 | uitablerow [] [ 19 | uistyle clampx 20 | @(ui_tool_interactable 0 0 [ 21 | tool_control_highlight 22 | uistyle clampx 23 | 24 | uispace $ui_padsmall $ui_padsmaller [ 25 | uitext $p_label $p_label_size 26 | ] 27 | 28 | uispace $ui_padsmall $ui_padsmaller [ 29 | uialign 1 30 | uitriangle $ui_tool_accent_colour 0.005 0.005 (? $_show 180 90) 31 | ] 32 | 33 | uirelease [ 34 | $arg1 = (! $_show) 35 | ] 36 | ]) 37 | ] 38 | 39 | if $_show [ 40 | doargs $arg2 41 | ] 42 | ] -------------------------------------------------------------------------------- /src/enet/include/enet/list.h: -------------------------------------------------------------------------------- 1 | /** 2 | @file list.h 3 | @brief ENet list management 4 | */ 5 | #ifndef __ENET_LIST_H__ 6 | #define __ENET_LIST_H__ 7 | 8 | #include 9 | 10 | typedef struct _ENetListNode 11 | { 12 | struct _ENetListNode * next; 13 | struct _ENetListNode * previous; 14 | } ENetListNode; 15 | 16 | typedef ENetListNode * ENetListIterator; 17 | 18 | typedef struct _ENetList 19 | { 20 | ENetListNode sentinel; 21 | } ENetList; 22 | 23 | extern void enet_list_clear (ENetList *); 24 | 25 | extern ENetListIterator enet_list_insert (ENetListIterator, void *); 26 | extern void * enet_list_remove (ENetListIterator); 27 | extern ENetListIterator enet_list_move (ENetListIterator, void *, void *); 28 | 29 | extern size_t enet_list_size (ENetList *); 30 | 31 | #define enet_list_begin(list) ((list) -> sentinel.next) 32 | #define enet_list_end(list) (& (list) -> sentinel) 33 | 34 | #define enet_list_empty(list) (enet_list_begin (list) == enet_list_end (list)) 35 | 36 | #define enet_list_next(iterator) ((iterator) -> next) 37 | #define enet_list_previous(iterator) ((iterator) -> previous) 38 | 39 | #define enet_list_front(list) ((void *) (list) -> sentinel.next) 40 | #define enet_list_back(list) ((void *) (list) -> sentinel.previous) 41 | 42 | #endif /* __ENET_LIST_H__ */ 43 | 44 | -------------------------------------------------------------------------------- /src/include/SDL_name.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2024 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | 22 | #ifndef SDLname_h_ 23 | #define SDLname_h_ 24 | 25 | #if defined(__STDC__) || defined(__cplusplus) 26 | #define NeedFunctionPrototypes 1 27 | #endif 28 | 29 | #define SDL_NAME(X) SDL_##X 30 | 31 | #endif /* SDLname_h_ */ 32 | 33 | /* vi: set ts=4 sw=4 expandtab: */ 34 | -------------------------------------------------------------------------------- /src/engine/world.h: -------------------------------------------------------------------------------- 1 | enum // hardcoded texture numbers 2 | { 3 | DEFAULT_SKY = 0, 4 | DEFAULT_GEOM, 5 | NUMDEFAULTSLOTS 6 | }; 7 | 8 | #define MAPVERSION 56 // bump if map format changes, see worldio.cpp 9 | 10 | struct binary 11 | { 12 | char head[4]; 13 | int version, headersize; 14 | }; 15 | 16 | struct mapz : binary 17 | { 18 | int worldsize, numents, numpvs, blendmap, numvslots; 19 | int gamever, revision; 20 | char gameid[4]; 21 | }; 22 | 23 | struct mapzcompat43 : binary 24 | { 25 | int worldsize, numents, numpvs, lightmaps, blendmap, numvslots; 26 | int gamever, revision; 27 | char gameid[4]; 28 | }; 29 | 30 | #define VOLUME_AMPLITUDE 0.4f 31 | #define VOLUME_OFFSET 1.1f 32 | #define VOLUME_INSET 0.1f 33 | 34 | enum 35 | { 36 | MATSURF_NOT_VISIBLE = 0, 37 | MATSURF_VISIBLE, 38 | MATSURF_EDIT_ONLY 39 | }; 40 | 41 | #define isliquid(mat) ((mat) == MAT_WATER || (mat) == MAT_LAVA) 42 | #define isfogvol(mat) ((mat) == MAT_WATER || (mat) == MAT_LAVA || (mat) == MAT_VOLFOG) 43 | #define isclipped(mat) ((mat) == MAT_GLASS) 44 | #define isdeadly(mat) ((mat) == MAT_LAVA) 45 | #define isladder(mat) (((mat)&MAT_LADDER) != 0) 46 | 47 | #define TEX_SCALE 8.0f 48 | 49 | struct vertex { vec pos; bvec4 norm; vec tc; bvec4 tangent; }; 50 | -------------------------------------------------------------------------------- /src/include/ft2build.h: -------------------------------------------------------------------------------- 1 | /**************************************************************************** 2 | * 3 | * ft2build.h 4 | * 5 | * FreeType 2 build and setup macros. 6 | * 7 | * Copyright (C) 1996-2019 by 8 | * David Turner, Robert Wilhelm, and Werner Lemberg. 9 | * 10 | * This file is part of the FreeType project, and may only be used, 11 | * modified, and distributed under the terms of the FreeType project 12 | * license, LICENSE.TXT. By continuing to use, modify, or distribute 13 | * this file you indicate that you have read the license and 14 | * understand and accept it fully. 15 | * 16 | */ 17 | 18 | 19 | /************************************************************************** 20 | * 21 | * This is the 'entry point' for FreeType header file inclusions. It is 22 | * the only header file which should be included directly; all other 23 | * FreeType header files should be accessed with macro names (after 24 | * including `ft2build.h`). 25 | * 26 | * A typical example is 27 | * 28 | * ``` 29 | * #include 30 | * #include FT_FREETYPE_H 31 | * ``` 32 | * 33 | */ 34 | 35 | 36 | #ifndef FT2BUILD_H_ 37 | #define FT2BUILD_H_ 38 | 39 | #include 40 | 41 | #endif /* FT2BUILD_H_ */ 42 | 43 | 44 | /* END */ 45 | -------------------------------------------------------------------------------- /src/steam/isteamappticket.h: -------------------------------------------------------------------------------- 1 | //====== Copyright 1996-2008, Valve Corporation, All rights reserved. ======= 2 | // 3 | // Purpose: a private, but well versioned, interface to get at critical bits 4 | // of a steam3 appticket - consumed by the simple drm wrapper to let it 5 | // ask about ownership with greater confidence. 6 | // 7 | //============================================================================= 8 | 9 | #ifndef ISTEAMAPPTICKET_H 10 | #define ISTEAMAPPTICKET_H 11 | #pragma once 12 | 13 | //----------------------------------------------------------------------------- 14 | // Purpose: hand out a reasonable "future proof" view of an app ownership ticket 15 | // the raw (signed) buffer, and indices into that buffer where the appid and 16 | // steamid are located. the sizes of the appid and steamid are implicit in 17 | // (each version of) the interface - currently uin32 appid and uint64 steamid 18 | //----------------------------------------------------------------------------- 19 | class ISteamAppTicket 20 | { 21 | public: 22 | virtual uint32 GetAppOwnershipTicketData( uint32 nAppID, void *pvBuffer, uint32 cbBufferLength, uint32 *piAppId, uint32 *piSteamId, uint32 *piSignature, uint32 *pcbSignature ) = 0; 23 | }; 24 | 25 | #define STEAMAPPTICKET_INTERFACE_VERSION "STEAMAPPTICKET_INTERFACE_VERSION001" 26 | 27 | 28 | #endif // ISTEAMAPPTICKET_H 29 | -------------------------------------------------------------------------------- /config/fx/projs/shrapnel.cfg: -------------------------------------------------------------------------------- 1 | registerfx FX_P_SHRAPNEL_LIFE $FX_TYPE_PARTICLE [ 2 | fxpropf emitcull 4 3 | fxpropi parttype $FX_PARTTYPE_SINGLE 4 | fxpropi part $PART_SPARK 5 | fxpropi colorized $FX_COLORIZE_PARAM 6 | fxpropi fade 1 7 | fxpropf partsize 0.5 8 | fxpropf partsize 1.5 $FX_MOD_RAND 9 | fxpropi fadein 100 10 | ] 11 | 12 | registerfx FX_P_SHRAPNEL_TRAIL $FX_TYPE_PARTICLE [ 13 | fxparent FX_P_SHRAPNEL_LIFE 14 | fxpropf emitdist 512 15 | fxpropf emitcull 4 16 | fxpropi parttype $FX_PARTTYPE_SINGLE 17 | fxpropi part $PART_FLAME 18 | fxpropc colour 255 200 100 19 | fxpropi fade 100 20 | fxpropf partsize 1 21 | fxpropf partsize 0.5 $FX_MOD_RAND 22 | fxpropf gravity -20 23 | fxpropi fadein 100 24 | fxpropf blend 0.1 25 | ] 26 | 27 | if (> $fxdetail 1) [ 28 | registerfx FX_P_SHRAPNEL_LIFE_SMOKE $FX_TYPE_PARTICLE [ 29 | fxparent FX_P_SHRAPNEL_LIFE 30 | fxpropf emitdist 512 31 | fxpropf emitcull 4 32 | fxpropi parttype $FX_PARTTYPE_SPLASH 33 | fxpropi part $PART_SMOKE 34 | fxpropi fade 250 35 | fxpropf partsize 1 36 | fxpropf partsize 1 $FX_MOD_RAND 37 | fxpropf vel 5 38 | fxpropf gravity -20 39 | fxpropi fadein 500 40 | fxpropf blend 0.0625 41 | ] 42 | ] 43 | 44 | register_proj_hit_fx FX_P_SHRAPNEL_HIT 45 | -------------------------------------------------------------------------------- /config/ui/tool/ents/toollight.cfg: -------------------------------------------------------------------------------- 1 | # ui_tool_ent_light = [ 2 | ui_tool_ent_param_group "Radius" [ 3 | ui_tool_numinput #(tool_ent_attr light radius) 0 1000 1 [ 4 | #(ui_tool_ent_attr_props light radius [] 1) 5 | p_val_format = i 6 | ] 7 | ] 8 | 9 | ui_tool_ent_param_group "Colour" [ 10 | ui_tool_colour tool_ent_attr_colour [ 11 | #(ui_tool_ent_attr_props light [red green blue]) 12 | ] 13 | ] 14 | 15 | ui_tool_ent_param_group "Flare" [ 16 | ui_tool_dropdown #(tool_ent_attr light flare) [ 17 | "None" 18 | "Simple" 19 | "Shimmer small" 20 | "Shimmer" 21 | ] [ 22 | #(ui_tool_ent_attr_props light flare) 23 | p_label = "Type" 24 | ] 25 | 26 | ui_tool_numinput #(tool_ent_attr light fscale) 0 1000 10 [ 27 | #(ui_tool_ent_attr_props light fscale [] 1) 28 | p_label = "Scale" 29 | p_val_format = i 30 | ] 31 | ] 32 | 33 | @(ui_tool_ent_flags_group light $tool_ent_light_flags [ 34 | "No shadow" 35 | "Static" 36 | "Volumetric" 37 | "No specular" 38 | "Color shadow" 39 | ]) 40 | 41 | @(ui_tool_ent_palette_group light) 42 | @(ui_tool_ent_gamemode_group light) 43 | @(ui_tool_ent_variant_group light 1) 44 | ] 45 | -------------------------------------------------------------------------------- /bin/LICENSE.dav1d.txt: -------------------------------------------------------------------------------- 1 | Copyright © 2018-2019, VideoLAN and dav1d authors 2 | All rights reserved. 3 | 4 | Redistribution and use in source and binary forms, with or without 5 | modification, are permitted provided that the following conditions are met: 6 | 7 | 1. Redistributions of source code must retain the above copyright notice, this 8 | list of conditions and the following disclaimer. 9 | 10 | 2. Redistributions in binary form must reproduce the above copyright notice, 11 | this list of conditions and the following disclaimer in the documentation 12 | and/or other materials provided with the distribution. 13 | 14 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 15 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 16 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 17 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 18 | ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 19 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 20 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 21 | ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 23 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | -------------------------------------------------------------------------------- /config/fx/other/drone.cfg: -------------------------------------------------------------------------------- 1 | registerfx FX_DRONE $FX_TYPE_PARTICLE [ 2 | fxpropf emitdist 512 3 | fxpropf emitcull 4 4 | fxpropi emitlen 200 5 | fxpropi parttype $FX_PARTTYPE_EXPLODE 6 | fxpropi part $PART_EXPLOSION 7 | fxpropi fade 1 8 | fxpropf maxpartsize 0.1 9 | fxpropf maxpartsize 0.5 $FX_MOD_LERP [ 10 | fxpropi lerptime 100 11 | ] 12 | fxpropi fadein 50 13 | fxpropi fadeout 200 14 | fxpropf blend 0.5 15 | fxpropi posfromenttag $TAG_JET_BACK 16 | ] 17 | 18 | registerfx FX_DRONE_SOUND $FX_TYPE_SOUND [ 19 | fxparent FX_DRONE 20 | fxpropf emitdist 512 21 | fxpropf emitcull 4 22 | fxpropi emitlen 200 23 | fxprops sound S_JET 24 | fxpropi onplayer 1 25 | fxpropi flags $SND_LOOP 26 | fxpropi fadein 100 27 | fxpropi fadeout 100 28 | fxpropf gain 0.1 29 | fxpropf rolloff 2 30 | ] 31 | 32 | registerfx FX_DRONE_BOOST $FX_TYPE_PARTICLE [ 33 | fxparent FX_DRONE 34 | fxpropf emitdist 512 35 | fxpropf emitcull 4 36 | fxpropi emitparam 0 37 | fxpropi emitlen 100 38 | fxpropi parttype $FX_PARTTYPE_SPLASH 39 | fxpropi part $PART_LIGHTZAP_FLARE 40 | fxpropf partsize 0.01 41 | fxpropf partsizechange 0.01 42 | fxpropi fade 100 43 | fxpropf vel 10 44 | fxpropf blend 0.5 45 | fxpropi num 5 46 | fxpropi posfromenttag $TAG_JET_BACK 47 | fxpropi colorized $FX_COLORIZE_PARAM 48 | ] 49 | -------------------------------------------------------------------------------- /config/fx/other/janitor.cfg: -------------------------------------------------------------------------------- 1 | registerfx FX_JANITOR $FX_TYPE_PARTICLE [ 2 | fxpropf emitdist 512 3 | fxpropf emitcull 4 4 | fxpropi emitlen 200 5 | fxpropi parttype $FX_PARTTYPE_EXPLODE 6 | fxpropi part $PART_EXPLOSION 7 | fxpropi fade 1 8 | fxpropf maxpartsize 0.1 9 | fxpropf maxpartsize 0.5 $FX_MOD_LERP [ 10 | fxpropi lerptime 100 11 | ] 12 | fxpropi fadein 50 13 | fxpropi fadeout 200 14 | fxpropf blend 0.5 15 | fxpropi posfromenttag $TAG_JET_BACK 16 | ] 17 | 18 | registerfx FX_JANITOR_SOUND $FX_TYPE_SOUND [ 19 | fxparent FX_JANITOR 20 | fxpropf emitdist 512 21 | fxpropf emitcull 4 22 | fxpropi emitlen 200 23 | fxprops sound S_JET 24 | fxpropi onplayer 1 25 | fxpropi flags $SND_LOOP 26 | fxpropi fadein 100 27 | fxpropi fadeout 100 28 | fxpropf gain 0.1 29 | fxpropf rolloff 2 30 | ] 31 | 32 | registerfx FX_JANITOR_BOOST $FX_TYPE_PARTICLE [ 33 | fxparent FX_JANITOR 34 | fxpropf emitdist 512 35 | fxpropf emitcull 4 36 | fxpropi emitparam 0 37 | fxpropi emitlen 100 38 | fxpropi parttype $FX_PARTTYPE_SPLASH 39 | fxpropi part $PART_LIGHTZAP_FLARE 40 | fxpropf partsize 0.01 41 | fxpropf partsizechange 0.01 42 | fxpropi fade 100 43 | fxpropf vel 10 44 | fxpropf blend 0.5 45 | fxpropi num 5 46 | fxpropi posfromenttag $TAG_JET_BACK 47 | fxpropi colorized $FX_COLORIZE_PARAM 48 | ] 49 | -------------------------------------------------------------------------------- /src/include/SDL_opengles.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2024 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | 22 | /** 23 | * \file SDL_opengles.h 24 | * 25 | * This is a simple file to encapsulate the OpenGL ES 1.X API headers. 26 | */ 27 | #include "SDL_config.h" 28 | 29 | #ifdef __IPHONEOS__ 30 | #include 31 | #include 32 | #else 33 | #include 34 | #include 35 | #endif 36 | 37 | #ifndef APIENTRY 38 | #define APIENTRY 39 | #endif 40 | -------------------------------------------------------------------------------- /config/comp/noise.cfg: -------------------------------------------------------------------------------- 1 | shader $SHADER_DEFAULT compositenoise [ 2 | attribute vec4 vvertex, vcolor; 3 | attribute vec2 vtexcoord0; 4 | uniform mat4 hudmatrix; 5 | varying vec2 texcoord0; 6 | varying vec4 colorscale; 7 | 8 | void main(void) 9 | { 10 | gl_Position = hudmatrix * vvertex; 11 | texcoord0 = vtexcoord0; 12 | colorscale = vcolor; 13 | } 14 | ] [ 15 | uniform vec4 params; 16 | uniform vec4 curmillis; 17 | varying vec2 texcoord0; 18 | varying vec4 colorscale; 19 | 20 | fragdata(0) vec4 fragcolor; 21 | 22 | float hash12(vec2 p) 23 | { 24 | vec3 p3 = fract(vec3(p.xyx) * 0.1031); 25 | p3 += dot(p3, p3.yzx + 33.33); 26 | return fract((p3.x + p3.y) * p3.z); 27 | } 28 | 29 | void main() 30 | { 31 | float a = 0.0; 32 | for(int t = 0; t < int(params.x); t++) 33 | { 34 | float v = float(t + 1) * params.y; 35 | vec2 pos = ((texcoord0 * 2.0 - 1.0) * v + curmillis.x * params.z + params.w); 36 | a += hash12(pos.xy); 37 | } 38 | a /= params.x; 39 | fragcolor = vec4(a, a, a, 1.0) * colorscale; 40 | } 41 | ] 42 | 43 | newui noise $SURFACE_COMPOSITE [ 44 | @(localargs params [2.0 0.152 1500.0 50.0]) 45 | execid uiarg1 46 | uirender compositenoise 1 1 [ 47 | uirenderparam params $params1 $params2 $params3 $params4 48 | ] 49 | ] -------------------------------------------------------------------------------- /config/tool/ents/lightfx.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_lightfx_flags = [ 2 | rndmin 3 | rndmax 4 | ] 5 | 6 | tool_ent_add_attrs_lightfx = [ 7 | tool_ent_add_attr lightfx type $T_ENT_NODELTA 8 | tool_ent_add_attr lightfx mod 0 9 | tool_ent_add_attr lightfx min 0 10 | tool_ent_add_attr lightfx max 0 11 | tool_ent_add_attr lightfx flags $T_ENT_NODELTA [ 12 | tool_ent_attr_alttype = 0 13 | 14 | caseif (& $$tool_ent_cur_attr 0x40) [ 15 | tool_ent_attr_alttype = 5 16 | ] (& $$tool_ent_cur_attr 0x20) [ 17 | tool_ent_attr_alttype = 4 18 | ] (& $$tool_ent_cur_attr 0x10) [ 19 | tool_ent_attr_alttype = 3 20 | ] (& $$tool_ent_cur_attr 0x8) [ 21 | tool_ent_attr_alttype = 2 22 | ] (& $$tool_ent_cur_attr 0x4) [ 23 | tool_ent_attr_alttype = 1 24 | ] 25 | ] [ 26 | $tool_ent_cur_attr = (& $$tool_ent_cur_attr 3) 27 | 28 | if $tool_ent_attr_alttype [ 29 | $tool_ent_cur_attr = (| $$tool_ent_cur_attr (<< 1 (+ $tool_ent_attr_alttype 1))) 30 | ] 31 | ] 32 | tool_ent_add_attr lightfx modes $T_ENT_NODELTA 33 | tool_ent_add_attr lightfx muts $T_ENT_NODELTA 34 | tool_ent_add_attr lightfx variant $T_ENT_NODELTA 35 | tool_ent_add_attr lightfx fxlevel $T_ENT_NODELTA [ 36 | @(tool_ent_fxlevel_getter lightfx) 37 | ] [ 38 | @(tool_ent_fxlevel_setter lightfx) 39 | ] 40 | ] 41 | -------------------------------------------------------------------------------- /config/legacy.cfg: -------------------------------------------------------------------------------- 1 | loadsky = [ 2 | skybox $arg1 3 | if (> $numargs 1) [spinsky $arg2] 4 | if (> $numargs 2) [yawsky $arg3] 5 | ]; setcomplete loadsky 1 6 | 7 | mapmsg = [maptitle $arg1]; setcomplete mapmsg 1 8 | cloudalpha = [cloudblend $arg1] 9 | savecurrentmap = [ savemap ] 10 | 11 | // people have complained /fov was removed 12 | fov = [do [ @(? (isthirdperson) third first)personfov @arg1 ]]; setcomplete fov 1 13 | texturecull = [ fixinsidefaces; compactvslots 1 ]; setcomplete texturecull 1 14 | name = [playername $arg1]; setcomplete name 1 15 | colour = [playercolour $arg1]; setcomplete colour 1 16 | vanity = [playervanity $arg1]; setcomplete vanity 1 17 | setinfo = [playername $arg1; playercolour $arg2; playermodel $arg3; playervanity $arg4; playerloadweap $arg5; playerrandweap $arg6]; setcomplete setinfo 1 18 | setmaster = [ setpriv $arg1 ]; setcomplete setmaster 1 19 | vcolor = [ vcolour $arg1 $arg2 $arg3 ] 20 | texcolor = [ texcolour $arg1 $arg2 $arg3 ] 21 | 22 | // random stuff 23 | privcreatortex = $privfoundertex 24 | privoperatortex = $privmoderatortex 25 | 26 | screenshotting = 0 27 | takescreenshot = [ 28 | if (! $screenshotting) [ 29 | screenshotting = 1 30 | sleep 50 [ 31 | screenshot 32 | showhud @@showhud 33 | showconsole @@showconsole 34 | screenshotting = 0 35 | ] 36 | showhud 0 37 | showconsole 0 38 | ] 39 | ]; setcomplete takescreenshot 1 40 | 41 | -------------------------------------------------------------------------------- /config/comp/rainbow.cfg: -------------------------------------------------------------------------------- 1 | shader $SHADER_DEFAULT compositerainbow [ 2 | attribute vec4 vvertex, vcolor; 3 | attribute vec2 vtexcoord0; 4 | uniform mat4 hudmatrix; 5 | varying vec2 texcoord0; 6 | varying vec4 colorscale; 7 | 8 | void main(void) 9 | { 10 | gl_Position = hudmatrix * vvertex; 11 | texcoord0 = vtexcoord0; 12 | colorscale = vcolor; 13 | } 14 | ] [ 15 | uniform sampler2D tex0, tex1; 16 | uniform vec4 params; // base multiplier size speed 17 | uniform vec4 curmillis; 18 | varying vec2 texcoord0; 19 | uniform vec4 texsize0; 20 | varying vec4 colorscale; 21 | 22 | fragdata(0) vec4 fragcolor; 23 | 24 | vec3 getcolor(vec2 coord, float delta) 25 | { 26 | return vec3(params.x + params.y * cos((params.z * (coord.y + delta * params.w)) + vec3(0, 23, 21))); 27 | } 28 | 29 | void main(void) 30 | { 31 | vec4 diffuse = texture2D(tex0, texcoord0), mask = texture2D(tex1, texcoord0); 32 | fragcolor = vec4(mix(getcolor(texcoord0, curmillis.x), diffuse.rgb, mask.a), diffuse.a) * colorscale; 33 | } 34 | ] 35 | 36 | newui rainbow $SURFACE_COMPOSITE [ 37 | @(localargs params [0.5 0.5 5.0 -1.0]) 38 | @(localargs tex ["textures/icon" "textures/icon"]) 39 | execid uiarg1 40 | uirender compositerainbow 1 1 [ 41 | uirenderparam params $params1 $params2 $params3 $params4 42 | uirendertex $tex1 43 | uirendertex $tex2 44 | ] 45 | ] 46 | -------------------------------------------------------------------------------- /config/ui/game/widgets/textinput.cfg: -------------------------------------------------------------------------------- 1 | // 1: 2 | ui_gameui_textinput_prompt = [ 3 | if (&& [=s $$arg1 ""] [! (uifocus?)]) [ 4 | uicolourtext $p_prompt 0x555555 1 5 | ] 6 | ] 7 | 8 | gameui_textinput_props = [ 9 | [ p_text_size 1.5 ] 10 | [ p_prompt ["[Enter text here"] ] 11 | [ p_width 0 ] 12 | [ p_lines 0 ] 13 | [ p_limit 0 ] 14 | [ p_immediate 0 ] 15 | [ p_on_change [] ] 16 | [ p_focus 0 ] 17 | ] 18 | 19 | // 1: 2: 3: 20 | ui_gameui_textinput = [ 21 | @(props $gameui_textinput_props arg3) 22 | 23 | uiborderedimageclamped $skintex 0x222222 0 $ui_texborder $ui_screenborder $p_width 0 [ 24 | uipropagate [uicolourblend 0.66] 25 | uihover [ uiinteractive 1 ] 26 | if $p_lines [ 27 | uimlfield $arg1 (* -1 $arg2) $p_lines $p_limit [ 28 | p_on_change 29 | ] $p_text_size $p_immediate [ 30 | ui_gameui_textinput_prompt $arg1 31 | if $p_focus uieditorsetfocus 32 | ] 33 | ] [ 34 | uifield $arg1 $arg2 [ 35 | p_on_change 36 | ] $p_text_size $p_immediate [ 37 | ui_gameui_textinput_prompt $arg1 38 | if $p_focus uieditorsetfocus 39 | ] 40 | ] 41 | 42 | ui_gameui_shadow 43 | ] 44 | ] 45 | -------------------------------------------------------------------------------- /src/shared/cube.h: -------------------------------------------------------------------------------- 1 | #ifndef CPP_CUBE_HEADER 2 | #define CPP_CUBE_HEADER 3 | 4 | #define _FILE_OFFSET_BITS 64 5 | 6 | #if !defined(WIN32) && defined(_WIN32) 7 | #define WIN32 8 | #endif 9 | 10 | #ifdef WIN32 11 | #define _USE_MATH_DEFINES 12 | #endif 13 | #include 14 | 15 | #include 16 | #include 17 | #include 18 | #include 19 | #include 20 | #include 21 | #include 22 | #include 23 | #include 24 | #include 25 | #include 26 | 27 | #ifdef WIN32 28 | #define WIN32_LEAN_AND_MEAN 29 | #ifdef _WIN32_WINNT 30 | #undef _WIN32_WINNT 31 | #endif 32 | #define _WIN32_WINNT 0x0500 33 | #include "windows.h" 34 | #include "io.h" 35 | #ifndef _WINDOWS 36 | #define _WINDOWS 37 | #endif 38 | #ifndef __GNUC__ 39 | #include 40 | #include 41 | #include 42 | #endif 43 | #define ZLIB_DLL 44 | #endif 45 | 46 | #ifndef STANDALONE 47 | #include 48 | #include 49 | #endif 50 | 51 | #include 52 | 53 | #include 54 | 55 | #include "tools.h" 56 | #include "command.h" 57 | #include "enum.h" 58 | #include "geom.h" 59 | #include "prop.h" 60 | #include "ents.h" 61 | #include "wind.h" 62 | #include "fx.h" 63 | 64 | #ifndef STANDALONE 65 | #include "glexts.h" 66 | #include "glemu.h" 67 | #else 68 | typedef enet_uint32 Uint32; 69 | #endif 70 | 71 | #include "iengine.h" 72 | #include "igame.h" 73 | 74 | #endif 75 | 76 | -------------------------------------------------------------------------------- /config/comp/texmask.cfg: -------------------------------------------------------------------------------- 1 | shader $SHADER_DEFAULT compositetexmask [ 2 | attribute vec4 vvertex, vcolor; 3 | attribute vec2 vtexcoord0; 4 | uniform mat4 hudmatrix; 5 | varying vec2 texcoord0; 6 | varying vec4 colorscale; 7 | 8 | void main(void) 9 | { 10 | gl_Position = hudmatrix * vvertex; 11 | texcoord0 = vtexcoord0; 12 | colorscale = vcolor; 13 | } 14 | ] [ 15 | uniform sampler2D tex0, tex1; 16 | uniform vec4 src, dst, val; // bump glow env mat 17 | varying vec2 texcoord0; 18 | varying vec4 colorscale; 19 | 20 | fragdata(0) vec4 fragcolor; 21 | 22 | void main(void) 23 | { 24 | vec4 srccol = texture2D(tex0, texcoord0), dstcol = texture2D(tex1, texcoord0), outcol = (srccol.r * 0.3 + srccol.g * 0.59 + srccol.b * 0.11) * src; 25 | fragcolor = (val + vec4(mix(outcol.r, dstcol.r, dst.r), mix(outcol.g, dstcol.g, dst.g), mix(outcol.b, dstcol.b, dst.b), mix(outcol.a, dstcol.a, dst.a))) * colorscale; 26 | } 27 | ] 28 | 29 | newui texmask $SURFACE_COMPOSITE [ 30 | @(localargs src [0.0 2.0 0.0 0.0]) 31 | @(localargs dst [1.0 0.0 1.0 1.0]) 32 | @(localargs val [0.0 0.0 0.0 0.0]) 33 | @(localargs tex ["textures/icon" "textures/blank"]) 34 | execid uiarg1 35 | uirender compositetexmask 1 1 [ 36 | uirenderparam src $src1 $src2 $src3 $src4 37 | uirenderparam dst $dst1 $dst2 $dst3 $dst4 38 | uirenderparam val $val1 $val2 $val3 $val4 39 | uirendertex $tex1 40 | uirendertex $tex2 41 | ] 42 | ] 43 | -------------------------------------------------------------------------------- /src/include/freetype/config/ftmodule.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file registers the FreeType modules compiled into the library. 3 | * 4 | * If you use GNU make, this file IS NOT USED! Instead, it is created in 5 | * the objects directory (normally `/objs/`) based on information 6 | * from `/modules.cfg`. 7 | * 8 | * Please read `docs/INSTALL.ANY` and `docs/CUSTOMIZE` how to compile 9 | * FreeType without GNU make. 10 | * 11 | */ 12 | 13 | FT_USE_MODULE( FT_Module_Class, autofit_module_class ) 14 | FT_USE_MODULE( FT_Driver_ClassRec, tt_driver_class ) 15 | FT_USE_MODULE( FT_Driver_ClassRec, t1_driver_class ) 16 | FT_USE_MODULE( FT_Driver_ClassRec, cff_driver_class ) 17 | FT_USE_MODULE( FT_Driver_ClassRec, t1cid_driver_class ) 18 | FT_USE_MODULE( FT_Driver_ClassRec, pfr_driver_class ) 19 | FT_USE_MODULE( FT_Driver_ClassRec, t42_driver_class ) 20 | FT_USE_MODULE( FT_Driver_ClassRec, winfnt_driver_class ) 21 | FT_USE_MODULE( FT_Driver_ClassRec, pcf_driver_class ) 22 | FT_USE_MODULE( FT_Module_Class, psaux_module_class ) 23 | FT_USE_MODULE( FT_Module_Class, psnames_module_class ) 24 | FT_USE_MODULE( FT_Module_Class, pshinter_module_class ) 25 | FT_USE_MODULE( FT_Renderer_Class, ft_raster1_renderer_class ) 26 | FT_USE_MODULE( FT_Module_Class, sfnt_module_class ) 27 | FT_USE_MODULE( FT_Renderer_Class, ft_smooth_renderer_class ) 28 | FT_USE_MODULE( FT_Renderer_Class, ft_smooth_lcd_renderer_class ) 29 | FT_USE_MODULE( FT_Renderer_Class, ft_smooth_lcdv_renderer_class ) 30 | FT_USE_MODULE( FT_Driver_ClassRec, bdf_driver_class ) 31 | 32 | /* EOF */ 33 | -------------------------------------------------------------------------------- /bin/LICENSE.zlib.txt: -------------------------------------------------------------------------------- 1 | The source code to this library used with SDL_image can be found here: 2 | http://www.libsdl.org/projects/SDL_image/libs/ 3 | --- 4 | 5 | Copyright notice: 6 | 7 | (C) 1995-2010 Jean-loup Gailly and Mark Adler 8 | 9 | This software is provided 'as-is', without any express or implied 10 | warranty. In no event will the authors be held liable for any damages 11 | arising from the use of this software. 12 | 13 | Permission is granted to anyone to use this software for any purpose, 14 | including commercial applications, and to alter it and redistribute it 15 | freely, subject to the following restrictions: 16 | 17 | 1. The origin of this software must not be misrepresented; you must not 18 | claim that you wrote the original software. If you use this software 19 | in a product, an acknowledgment in the product documentation would be 20 | appreciated but is not required. 21 | 2. Altered source versions must be plainly marked as such, and must not be 22 | misrepresented as being the original software. 23 | 3. This notice may not be removed or altered from any source distribution. 24 | 25 | Jean-loup Gailly Mark Adler 26 | jloup@gzip.org madler@alumni.caltech.edu 27 | 28 | If you use the zlib library in a product, we would appreciate *not* receiving 29 | lengthy legal documents to sign. The sources are provided for free but without 30 | warranty of any kind. The library has been entirely written by Jean-loup 31 | Gailly and Mark Adler; it does not include third-party code. 32 | -------------------------------------------------------------------------------- /config/ui/events/defend.cfg: -------------------------------------------------------------------------------- 1 | event_defend_secure = [ 2 | event_image (modetex) 0xFFFFFF 3 | local event_extra event_affinity _owner_colour 4 | event_extra = 0 5 | event_affinity = (geteventlist $event_id "args" "affinity") 6 | loop event_attackid $event_clients [ 7 | if (= (geteventtag $event_id "client" $event_attackid "team") (geteventlist $event_id "args" (? (=s $event_action "secure") "owner" "enemy"))) [ 8 | if $event_extra [ 9 | uitext "+" $game_hud_event_text_size [ 10 | uistyle leftmiddle 11 | uitextalign -1 12 | ] 13 | ] 14 | uitext (geteventname $event_id "client" $event_attackid) $game_hud_event_text_size [ 15 | uistyle leftmiddle 16 | uitextalign -1 17 | ] 18 | event_extra = 1 19 | ] 20 | ] 21 | 22 | _owner_colour = (getteamcolour (geteventlist $event_id "args" "owner")) 23 | 24 | event_image $pointtex (getteamcolour (geteventlist $event_id "args" "oldowner")) 25 | event_image $arrowrighttex 0xFFFFFF 26 | event_image $pointtex $_owner_colour 27 | 28 | uifont "play/clear/bold" [ 29 | uicolourtext (getprintable $event_affinity) $_owner_colour $game_hud_event_text_size 30 | ] 31 | 32 | _owner_colour = (modcolourhsv $_owner_colour 1 0.5 1) 33 | 34 | uicolourtext (getdefendname $event_affinity) $_owner_colour (*f $game_hud_event_text_size 0.8) 35 | ] 36 | 37 | event_defend_overthrow = [@event_defend_secure] 38 | -------------------------------------------------------------------------------- /src/enet/include/enet/unix.h: -------------------------------------------------------------------------------- 1 | /** 2 | @file unix.h 3 | @brief ENet Unix header 4 | */ 5 | #ifndef __ENET_UNIX_H__ 6 | #define __ENET_UNIX_H__ 7 | 8 | #include 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | 16 | #ifdef MSG_MAXIOVLEN 17 | #define ENET_BUFFER_MAXIMUM MSG_MAXIOVLEN 18 | #endif 19 | 20 | typedef int ENetSocket; 21 | 22 | #define ENET_SOCKET_NULL -1 23 | 24 | #define ENET_HOST_TO_NET_16(value) (htons (value)) /**< macro that converts host to net byte-order of a 16-bit value */ 25 | #define ENET_HOST_TO_NET_32(value) (htonl (value)) /**< macro that converts host to net byte-order of a 32-bit value */ 26 | 27 | #define ENET_NET_TO_HOST_16(value) (ntohs (value)) /**< macro that converts net to host byte-order of a 16-bit value */ 28 | #define ENET_NET_TO_HOST_32(value) (ntohl (value)) /**< macro that converts net to host byte-order of a 32-bit value */ 29 | 30 | typedef struct 31 | { 32 | void * data; 33 | size_t dataLength; 34 | } ENetBuffer; 35 | 36 | #define ENET_CALLBACK 37 | 38 | #define ENET_API extern 39 | 40 | typedef fd_set ENetSocketSet; 41 | 42 | #define ENET_SOCKETSET_EMPTY(sockset) FD_ZERO (& (sockset)) 43 | #define ENET_SOCKETSET_ADD(sockset, socket) FD_SET (socket, & (sockset)) 44 | #define ENET_SOCKETSET_REMOVE(sockset, socket) FD_CLR (socket, & (sockset)) 45 | #define ENET_SOCKETSET_CHECK(sockset, socket) FD_ISSET (socket, & (sockset)) 46 | 47 | #endif /* __ENET_UNIX_H__ */ 48 | 49 | -------------------------------------------------------------------------------- /config/ui/tool/ents/toolphysics.cfg: -------------------------------------------------------------------------------- 1 | # ui_tool_ent_physics = [ 2 | ui_tool_ent_param_group "Type" [ 3 | ui_tool_dropdown #(tool_ent_attr physics type) (sublist $PHYSICS_NAMES 0 $PHYSICS_MAX) [ 4 | #(ui_tool_ent_attr_props physics type) 5 | ] 6 | ] 7 | 8 | ui_tool_ent_param_group "Scale" [ 9 | ui_tool_numinput #(tool_ent_attr physics value) -999999 999999 1 [ 10 | #(ui_tool_ent_attr_props physics value [] 1) 11 | p_val_format = i 12 | ] 13 | ] 14 | 15 | ui_tool_ent_param_group "Size" [ 16 | ui_tool_numinput #(tool_ent_attr physics width) 0 999999 1 [ 17 | #(ui_tool_ent_attr_props physics width [] 1) 18 | p_val_format = i 19 | p_label = "X" 20 | ] 21 | 22 | ui_tool_numinput #(tool_ent_attr physics length) 0 999999 1 [ 23 | #(ui_tool_ent_attr_props physics length [] 1) 24 | p_val_format = i 25 | p_label = "Y" 26 | ] 27 | 28 | ui_tool_numinput #(tool_ent_attr physics height) 0 999999 1 [ 29 | #(ui_tool_ent_attr_props physics height [] 1) 30 | p_val_format = i 31 | p_label = "Z" 32 | ] 33 | ] 34 | 35 | ui_tool_ent_param_group "Falloff" [ 36 | ui_tool_numinput #(tool_ent_attr physics falloff) 0 100 1 [ 37 | #(ui_tool_ent_attr_props physics falloff [] 1) 38 | p_val_format = i 39 | ] 40 | ] 41 | 42 | @(ui_tool_ent_gamemode_group physics) 43 | @(ui_tool_ent_variant_group physics) 44 | ] 45 | -------------------------------------------------------------------------------- /src/engine/version.h: -------------------------------------------------------------------------------- 1 | #define STR_MACRO_HELPER(s) #s 2 | #define STR_MACRO(s) STR_MACRO_HELPER(s) 3 | 4 | #ifdef __clang__ 5 | #define VERSION_COMP "clang-" \ 6 | STR_MACRO(__clang_major__) "." \ 7 | STR_MACRO(__clang_minor__) "." \ 8 | STR_MACRO(__clang_patchlevel__) 9 | #elif defined(_MSC_VER) 10 | #define VERSION_COMP "msvc-" STR_MACRO(_MSC_VER) 11 | #else 12 | #define VERSION_COMP "gnuc-" \ 13 | STR_MACRO(__GNUC__) "." \ 14 | STR_MACRO(__GNUC_MINOR__) "." \ 15 | STR_MACRO(__GNUC_PATCHLEVEL__) 16 | #endif 17 | 18 | #define VERSION_MAJOR 2 19 | #define VERSION_MINOR 0 20 | #define VERSION_PATCH 9 21 | #define VERSION_HLP(x,y,z,r) #x#r#y#r#z 22 | #define VERSION_STR(x,y,z,r) VERSION_HLP(x,y,z,r) 23 | #define VERSION_STRING VERSION_STR(VERSION_MAJOR,VERSION_MINOR,VERSION_PATCH,.) 24 | #define VERSION_NAME "Red Eclipse" 25 | #define VERSION_FNAME "Red Eclipse" 26 | #define VERSION_UNAME "redeclipse" 27 | #define VERSION_VNAME "REDECLIPSE" 28 | #define VERSION_RELEASE "Big Bang Beta" 29 | #define VERSION_URL "www.redeclipse.net" 30 | #define VERSION_COPY "2009-2025" 31 | #define VERSION_DESC "An arena shooter for the modern era" 32 | #define VERSION_STEAM_APPID 967460 33 | #define VERSION_STEAM_DEPOT 967461 34 | #define VERSION_DISCORD "506825464946360321" 35 | 36 | #ifndef VERSION_BUILD 37 | #define VERSION_BUILD 0 38 | #endif 39 | #ifndef VERSION_BRANCH 40 | #define VERSION_BRANCH "selfbuilt" 41 | #endif 42 | #ifndef VERSION_REVISION 43 | #define VERSION_REVISION "" 44 | #endif 45 | 46 | #define LAN_PORT 28799 47 | #define MASTER_PORT 28800 48 | #define SERVER_PORT 28801 49 | -------------------------------------------------------------------------------- /bin/LICENSE.webp.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2010, Google Inc. All rights reserved. 2 | 3 | Redistribution and use in source and binary forms, with or without 4 | modification, are permitted provided that the following conditions are 5 | met: 6 | 7 | * Redistributions of source code must retain the above copyright 8 | notice, this list of conditions and the following disclaimer. 9 | 10 | * Redistributions in binary form must reproduce the above copyright 11 | notice, this list of conditions and the following disclaimer in 12 | the documentation and/or other materials provided with the 13 | distribution. 14 | 15 | * Neither the name of Google nor the names of its contributors may 16 | be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | -------------------------------------------------------------------------------- /config/comp/caustic.cfg: -------------------------------------------------------------------------------- 1 | shader $SHADER_DEFAULT compositecaustic [ 2 | attribute vec4 vvertex, vcolor; 3 | attribute vec2 vtexcoord0; 4 | uniform mat4 hudmatrix; 5 | varying vec2 texcoord0; 6 | varying vec4 colorscale; 7 | 8 | void main(void) 9 | { 10 | gl_Position = hudmatrix * vvertex; 11 | texcoord0 = vtexcoord0; 12 | colorscale = vcolor; 13 | } 14 | ] [ 15 | uniform vec4 curmillis; 16 | uniform vec4 params; // iters timescale timeoffset intensity 17 | varying vec2 texcoord0; 18 | varying vec4 colorscale; 19 | 20 | fragdata(0) vec4 fragcolor; 21 | 22 | const float tau = 6.28318530718; 23 | 24 | void main() 25 | { 26 | float time = curmillis.x * params.y + params.z; 27 | 28 | vec2 p = mod(texcoord0 * tau, tau) - 250.0; 29 | vec2 i = p; 30 | float c = 1.0; 31 | float inten = params.w; 32 | 33 | for(int n = 0; n < params.x; n++) 34 | { 35 | float t = time * (1.0 - (3.5 / float(n + 1))); 36 | i = p + vec2(cos(t - i.x) + sin(t + i.y), sin(t - i.y) + cos(t + i.x)); 37 | c += 1.0 / length(vec2(p.x / (sin(i.x + t) / inten), p.y / (cos(i.y + t) / inten))); 38 | } 39 | c /= params.x; 40 | c = 1.17 - pow(c, 1.4); 41 | 42 | fragcolor.rg = vec2(clamp(pow(abs(c), 8.0) + 0.5, 0.0, 1.0), 1.0) * colorscale.ra; 43 | } 44 | ] 45 | 46 | newui caustic $SURFACE_COMPOSITE [ 47 | @(localargs params [4.0 0.5 23.0 0.005]) 48 | execid uiarg1 49 | uirender compositecaustic 1 1 [ 50 | uirenderparam params $params1 $params2 $params3 $params4 51 | ] 52 | ] 53 | -------------------------------------------------------------------------------- /src/include/close_code.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2024 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | 22 | /** 23 | * \file close_code.h 24 | * 25 | * This file reverses the effects of begin_code.h and should be included 26 | * after you finish any function and structure declarations in your headers 27 | */ 28 | 29 | #ifndef SDL_begin_code_h 30 | #error close_code.h included without matching begin_code.h 31 | #endif 32 | #undef SDL_begin_code_h 33 | 34 | /* Reset structure packing at previous byte alignment */ 35 | #if defined(_MSC_VER) || defined(__MWERKS__) || defined(__BORLANDC__) 36 | #ifdef __BORLANDC__ 37 | #pragma nopackwarning 38 | #endif 39 | #pragma pack(pop) 40 | #endif /* Compiler needs structure packing set */ 41 | -------------------------------------------------------------------------------- /src/enet/check_cflags.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # ENet cflags detection for unix by Daniel 'q66' Kolesa 3 | # I hereby put this file into public domain, use as you wish 4 | 5 | CC=$* 6 | 7 | cat << EOF > check_func.c 8 | void TEST_FUN(); 9 | int main() { TEST_FUN(); return 0; } 10 | EOF 11 | cat << EOF > check_member.c 12 | #include "check_member.h" 13 | static void pass() {} 14 | int main() { struct TEST_STRUCT test; pass(test.TEST_FIELD); return 0; } 15 | EOF 16 | cat << EOF > check_type.c 17 | #include "check_type.h" 18 | int main() { TEST_TYPE test; return 0; } 19 | EOF 20 | 21 | CHECK_FUNC() { 22 | $CC check_func.c -DTEST_FUN=$1 -o check_func 2>/dev/null 23 | if [ $? -eq 0 ]; then printf " $2"; rm check_func; fi 24 | } 25 | 26 | CHECK_FUNC getaddrinfo -DHAS_GETADDRINFO 27 | CHECK_FUNC getnameinfo -DHAS_GETNAMEINFO 28 | CHECK_FUNC gethostbyaddr_r -DHAS_GETHOSTBYADDR_R 29 | CHECK_FUNC gethostbyname_r -DHAS_GETHOSTBYNAME_R 30 | CHECK_FUNC poll -DHAS_POLL 31 | CHECK_FUNC fcntl -DHAS_FCNTL 32 | CHECK_FUNC inet_pton -DHAS_INET_PTON 33 | CHECK_FUNC inet_ntop -DHAS_INET_NTOP 34 | 35 | echo "#include " > check_member.h 36 | $CC check_member.c -DTEST_STRUCT=msghdr -DTEST_FIELD=msg_flags \ 37 | -o check_member 2>/dev/null 38 | if [ $? -eq 0 ]; then printf " -DHAS_MSGHDR_FLAGS"; rm check_member; fi 39 | rm check_member.h 40 | 41 | echo "#include " > check_type.h 42 | echo "#include " >> check_type.h 43 | $CC check_type.c -DTEST_TYPE=socklen_t -o check_type 2>/dev/null 44 | if [ $? -eq 0 ]; then printf " -DHAS_SOCKLEN_T"; rm check_type; fi 45 | rm check_type.h 46 | 47 | echo '' 48 | rm check_func.c 49 | rm check_member.c 50 | rm check_type.c 51 | -------------------------------------------------------------------------------- /config/glsl/edit.cfg: -------------------------------------------------------------------------------- 1 | //////////////////////////////////////////////// 2 | // 3 | // miscellaneous edit shaders 4 | // 5 | //////////////////////////////////////////////// 6 | 7 | shader $SHADER_DEFAULT "blendbrush" [ 8 | attribute vec4 vvertex, vcolor; 9 | uniform mat4 camprojmatrix; 10 | uniform vec4 texgenS, texgenT; 11 | uniform float ldrscale; 12 | varying vec4 color; 13 | varying vec2 texcoord0; 14 | void main(void) 15 | { 16 | gl_Position = camprojmatrix * vvertex; 17 | color = vec4(ldrscale * vcolor.rgb, vcolor.a); 18 | texcoord0 = vec2(dot(texgenS, vvertex), dot(texgenT, vvertex)); 19 | } 20 | ] [ 21 | uniform sampler2D tex0; 22 | varying vec4 color; 23 | varying vec2 texcoord0; 24 | fragdata(0) vec4 fragcolor; 25 | void main(void) 26 | { 27 | fragcolor = texture2D(tex0, texcoord0).r * color; 28 | } 29 | ] 30 | 31 | lazyshader $SHADER_DEFAULT "prefab" [ 32 | attribute vec4 vvertex, vcolor; 33 | attribute vec3 vnormal; 34 | uniform mat4 prefabmatrix; 35 | uniform mat3 prefabworld; 36 | varying vec3 nvec; 37 | varying vec4 color; 38 | @(msaainterpvert) 39 | 40 | void main(void) 41 | { 42 | gl_Position = prefabmatrix * vvertex; 43 | color = vcolor; 44 | nvec = prefabworld * vnormal; 45 | @(msaapackvert) 46 | } 47 | ] [ 48 | varying vec3 nvec; 49 | varying vec4 color; 50 | @(msaainterpfrag) 51 | 52 | void main(void) 53 | { 54 | gcolor.rgb = color.rgb; 55 | gcolor.a = 0.0; 56 | vec3 normal = normalize(nvec); 57 | @(gnormpackdef normal packnorm) 58 | @(msaapackfrag) 59 | } 60 | ] 61 | 62 | -------------------------------------------------------------------------------- /src/engine/menus.cpp: -------------------------------------------------------------------------------- 1 | #include "engine.h" 2 | 3 | struct change 4 | { 5 | int type; 6 | const char *desc; 7 | 8 | change() {} 9 | change(int type, const char *desc) : type(type), desc(desc) {} 10 | }; 11 | static vector needsapply; 12 | 13 | VAR(IDF_PERSIST, applydialog, 0, 1, 1); 14 | VAR(0, hidechanges, 0, 0, 1); 15 | 16 | static const char *changenames[CHANGE_MAX] = { "graphics", "sound", "shader" }; 17 | 18 | void addchange(const char *desc, int type) 19 | { 20 | if(!applydialog) return; 21 | loopv(needsapply) if(!strcmp(needsapply[i].desc, desc)) return; 22 | string name; 23 | name[0]= 0; 24 | loopi(CHANGE_MAX) if(type&(1<textures/icons/edit/redo" $pointtex) 39 | event_image $event_rtex 0xFFFFFF 40 | ] 41 | 42 | event_bomber_start = [ 43 | event_image $modebombertex 0xFFFFFF 44 | event_image $bombtex (pulsecolour $PULSE_DISCO) 45 | event_image $arrowrighttex 0xFFFFFF 46 | event_image $pointtex 0xFFFFFF 47 | ] 48 | -------------------------------------------------------------------------------- /config/ui/game/widgets/group.cfg: -------------------------------------------------------------------------------- 1 | # gameui_group_props = [ 2 | [ p_label "" ] 3 | [ p_width 0 ] 4 | [ p_height 0 ] 5 | [ p_space_x 0.02 ] 6 | [ p_space_y 0.02 ] 7 | [ p_colour 0x88111111 ] 8 | [ p_border_scale 0.5 ] 9 | [ p_clamp 1 ] 10 | ] 11 | 12 | // 1: 2: 13 | ui_gameui_group = [ 14 | @(props $gameui_group_props arg2) 15 | 16 | uiborderedimageclamped $skintex $p_colour 0 $ui_texborder $ui_screenborder $p_width $p_height [ 17 | uiclamp $p_clamp $p_clamp 18 | 19 | uispace $p_space_x $p_space_y [ 20 | uistyle clampx 21 | 22 | uivlist 0 [ 23 | if (!=s $p_label "") [ 24 | uitext $p_label 1.5 25 | uiprev [uialign -1 -1] 26 | 27 | uifill 0 0.01 28 | ] 29 | 30 | arg1 31 | ] 32 | ] 33 | 34 | ui_gameui_shadow 35 | ] 36 | ] 37 | 38 | // 1: 2: 39 | ui_gameui_horizgroup = [ 40 | @(props $gameui_group_props arg2) 41 | 42 | uiborderedimageclamped $skintex $p_colour 0 $ui_texborder $ui_screenborder 0 $p_height [ 43 | uistyle clampx 44 | 45 | uispace $p_space_x $p_space_y [ 46 | uistyle clampx 47 | 48 | uivlist 0 [ 49 | uifill $p_width 50 | 51 | if (!=s $p_label "") [ 52 | uitext $p_label 1.5 53 | uiprev [uialign -1 -1] 54 | 55 | uifill 0 0.01 56 | ] 57 | 58 | arg1 59 | ] 60 | ] 61 | 62 | ui_gameui_shadowhoriz 63 | ] 64 | ] 65 | -------------------------------------------------------------------------------- /src/enet/include/enet/win32.h: -------------------------------------------------------------------------------- 1 | /** 2 | @file win32.h 3 | @brief ENet Win32 header 4 | */ 5 | #ifndef __ENET_WIN32_H__ 6 | #define __ENET_WIN32_H__ 7 | 8 | #ifdef _MSC_VER 9 | #ifdef ENET_BUILDING_LIB 10 | #pragma warning (disable: 4267) // size_t to int conversion 11 | #pragma warning (disable: 4244) // 64bit to 32bit int 12 | #pragma warning (disable: 4018) // signed/unsigned mismatch 13 | #pragma warning (disable: 4146) // unary minus operator applied to unsigned type 14 | #define _CRT_SECURE_NO_DEPRECATE 15 | #define _CRT_SECURE_NO_WARNINGS 16 | #endif 17 | #endif 18 | 19 | #include 20 | #include 21 | 22 | typedef SOCKET ENetSocket; 23 | 24 | #define ENET_SOCKET_NULL INVALID_SOCKET 25 | 26 | #define ENET_HOST_TO_NET_16(value) (htons (value)) 27 | #define ENET_HOST_TO_NET_32(value) (htonl (value)) 28 | 29 | #define ENET_NET_TO_HOST_16(value) (ntohs (value)) 30 | #define ENET_NET_TO_HOST_32(value) (ntohl (value)) 31 | 32 | typedef struct 33 | { 34 | size_t dataLength; 35 | void * data; 36 | } ENetBuffer; 37 | 38 | #define ENET_CALLBACK __cdecl 39 | 40 | #ifdef ENET_DLL 41 | #ifdef ENET_BUILDING_LIB 42 | #define ENET_API __declspec( dllexport ) 43 | #else 44 | #define ENET_API __declspec( dllimport ) 45 | #endif /* ENET_BUILDING_LIB */ 46 | #else /* !ENET_DLL */ 47 | #define ENET_API extern 48 | #endif /* ENET_DLL */ 49 | 50 | typedef fd_set ENetSocketSet; 51 | 52 | #define ENET_SOCKETSET_EMPTY(sockset) FD_ZERO (& (sockset)) 53 | #define ENET_SOCKETSET_ADD(sockset, socket) FD_SET (socket, & (sockset)) 54 | #define ENET_SOCKETSET_REMOVE(sockset, socket) FD_CLR (socket, & (sockset)) 55 | #define ENET_SOCKETSET_CHECK(sockset, socket) FD_ISSET (socket, & (sockset)) 56 | 57 | #endif /* __ENET_WIN32_H__ */ 58 | 59 | 60 | -------------------------------------------------------------------------------- /config/map/material.cfg: -------------------------------------------------------------------------------- 1 | texture water1 "nieb/water.png" 2 | texture 1 "appleflap/snow_nm.jpg" 3 | texture 1 "nieb/waterfall.png" 4 | texture 1 "nieb/waterfall_normal.png" 5 | texscale 0.5 6 | 7 | texture water2 "textures/water.jpg" 8 | texture 1 "textures/watern.jpg" 9 | texture 1 "textures/waterfall.jpg" 10 | texture 1 "textures/waterfalln.jpg" 11 | 12 | texture water3 "textures/water.jpg" 13 | texture 1 "appleflap/snow_nm.jpg" 14 | texture 1 "textures/waterfall.jpg" 15 | texture 1 "textures/waterfalln.jpg" 16 | 17 | texture water4 "nieb/water.png" 18 | texture 1 "snipergoth/watern.jpg" 19 | texture 1 "nieb/waterfall.png" 20 | texture 1 "nieb/waterfall_normal.png" 21 | texscale 0.5 22 | 23 | texture lava1 "textures/lava.jpg" 24 | texture 1 "nieb/lava_normal.png" 25 | texture 1 "textures/lava.jpg" 26 | texture 1 "nieb/lava_normal.png" 27 | 28 | texture lava2 "textures/lava2.jpg" 29 | texture 1 "nieb/lava_normal.png" 30 | texture 1 "textures/lava2.jpg" 31 | texture 1 "nieb/lava_normal.png" 32 | 33 | texture lava3 "nieb/lava.png" 34 | texture 1 "nieb/lava_normal.png" 35 | texture 1 "nieb/lava.png" 36 | texture 1 "nieb/lava_normal.png" 37 | texscale 0.5 38 | 39 | texture lava4 "textures/lava2.jpg" 40 | texture 1 "textures/watern.jpg" 41 | texture 1 "textures/lava2.jpg" 42 | texture 1 "textures/watern.jpg" 43 | 44 | texture glass1 "nieb/scratch2.png" 45 | 46 | texture glass2 "torley/glass/bacterianwindow_n.png" 47 | 48 | texture glass3 "torley/glass/frostedsimple_n.png" 49 | 50 | texture glass4 "torley/glass/selfcleaning_n.png" 51 | 52 | texture volfog1 "skyboxes/clouds01.png" 53 | texscale 5 54 | 55 | texture volfog2 "skyboxes/clouds02.png" 56 | texscale 5 57 | 58 | texture volfog3 "skyboxes/clouds03.png" 59 | texscale 5 60 | 61 | texture volfog4 "skyboxes/clouds04.png" 62 | texscale 5 63 | -------------------------------------------------------------------------------- /src/include/SDL_opengles2.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2024 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | 22 | /** 23 | * \file SDL_opengles2.h 24 | * 25 | * This is a simple file to encapsulate the OpenGL ES 2.0 API headers. 26 | */ 27 | #include "SDL_config.h" 28 | 29 | #if !defined(_MSC_VER) && !defined(SDL_USE_BUILTIN_OPENGL_DEFINITIONS) 30 | 31 | #ifdef __IPHONEOS__ 32 | #include 33 | #include 34 | #else 35 | #include 36 | #include 37 | #include 38 | #endif 39 | 40 | #else /* _MSC_VER */ 41 | 42 | /* OpenGL ES2 headers for Visual Studio */ 43 | #include "SDL_opengles2_khrplatform.h" 44 | #include "SDL_opengles2_gl2platform.h" 45 | #include "SDL_opengles2_gl2.h" 46 | #include "SDL_opengles2_gl2ext.h" 47 | 48 | #endif /* _MSC_VER */ 49 | 50 | #ifndef APIENTRY 51 | #define APIENTRY GL_APIENTRY 52 | #endif 53 | -------------------------------------------------------------------------------- /redeclipse.bat: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | setlocal enableextensions enabledelayedexpansion 3 | :redeclipse_path 4 | if DEFINED REDECLIPSE_PATH goto redeclipse_init 5 | pushd "%~dp0" 6 | set REDECLIPSE_PATH=%CD% 7 | popd 8 | :redeclipse_init 9 | set REDECLIPSE_SCRIPT=%~dp0\%~0 10 | for %%a in ("%REDECLIPSE_SCRIPT%") do set REDECLIPSE_SCRIPT_TIME=%%~ta 11 | if NOT DEFINED REDECLIPSE_BINARY set REDECLIPSE_BINARY=redeclipse 12 | if NOT DEFINED REDECLIPSE_START set REDECLIPSE_START=start 13 | set REDECLIPSE_SUFFIX=.exe 14 | set REDECLIPSE_MAKE=mingw32-make 15 | :redeclipse_setup 16 | if DEFINED REDECLIPSE_ARCH goto redeclipse_home 17 | set REDECLIPSE_ARCH=x86 18 | if DEFINED PROCESSOR_ARCHITEW6432 ( 19 | set REDECLIPSE_MACHINE=%PROCESSOR_ARCHITEW6432% 20 | ) else ( 21 | set REDECLIPSE_MACHINE=%PROCESSOR_ARCHITECTURE% 22 | ) 23 | if /i "%REDECLIPSE_MACHINE%" == "amd64" set REDECLIPSE_ARCH=amd64 24 | :redeclipse_home 25 | if DEFINED REDECLIPSE_HOME ( 26 | set REDECLIPSE_OPTIONS="-h%REDECLIPSE_HOME%" %REDECLIPSE_OPTIONS% 27 | ) 28 | :redeclipse_runit 29 | if EXIST "%REDECLIPSE_PATH%\bin\%REDECLIPSE_ARCH%\%REDECLIPSE_BINARY%%REDECLIPSE_SUFFIX%" ( 30 | pushd "%REDECLIPSE_PATH%" || goto redeclipse_error 31 | %REDECLIPSE_START% bin\%REDECLIPSE_ARCH%\%REDECLIPSE_BINARY%%REDECLIPSE_SUFFIX% %REDECLIPSE_OPTIONS% %* || ( 32 | popd 33 | goto redeclipse_error 34 | ) 35 | popd 36 | exit /b 0 37 | ) else ( 38 | if NOT "%REDECLIPSE_ARCH%" == "x86" ( 39 | set REDECLIPSE_ARCH=x86 40 | goto redeclipse_runit 41 | ) 42 | echo Unable to find a working binary. 43 | ) 44 | :redeclipse_error 45 | echo There was an error running Red Eclipse. 46 | pause 47 | exit /b 1 48 | -------------------------------------------------------------------------------- /config/fx/weapons/weapons.cfg: -------------------------------------------------------------------------------- 1 | W_FX_POWER_PARAM = 0 2 | 3 | fx_muzzle_flash = [ 4 | fxpropi emitlen $arg1 5 | fxpropi emitrestart 1 6 | fxpropi parttype $FX_PARTTYPE_EXPLODE 7 | fxpropi part $PART_EXPLOSION 8 | fxpropc colour 255 191 41 9 | fxpropc colour 0 (- 255 191) 100 $FX_MOD_RAND 10 | fxpropi fade 1 11 | fxpropf partsize 0.05 12 | fxpropf partsize $arg2 $FX_MOD_LERP [ 13 | fxpropi lerptime @arg1 14 | ] 15 | fxpropf maxpartsize 0.05 16 | fxpropf maxpartsize $arg2 $FX_MOD_LERP [ 17 | fxpropi lerptime @arg1 18 | ] 19 | fxpropf maxpartsize 0.25 $FX_MOD_RAND 20 | fxpropf blend 0.1 21 | fxpropf blend (-f $arg3 0.1) $FX_MOD_RAND 22 | fxpropi posfroment $FX_ENT_POS_MUZZLE 23 | ] 24 | 25 | fx_muzzle_light = [ 26 | fxpropi emitlen $arg1 27 | fxpropi emitrestart 1 28 | fxpropc colour 255 191 41 29 | fxpropc colour 0 (- 255 191) 100 $FX_MOD_RAND 30 | fxpropf radius 64 31 | fxpropf radius 32 $FX_MOD_RAND 32 | fxpropf blend $arg2 33 | fxpropi fadeout $arg1 34 | fxpropi posfroment $FX_ENT_POS_MUZZLE 35 | ] 36 | 37 | fx_muzzle_smoke = [ 38 | fxpropi emitlen $arg1 39 | fxpropi parttype $FX_PARTTYPE_SPLASH 40 | fxpropi part $PART_SMOKE_SOFT 41 | fxpropf partsize $arg2 42 | fxpropf partsizechange 0.002 43 | fxpropf vel 0 44 | fxpropf vel 1 $FX_MOD_RAND 45 | fxpropf shapesize 1 46 | fxpropf blend 0.05 47 | fxpropi fade 200 48 | fxpropf gravity -5 49 | fxpropi fadein (div $arg1 2) 50 | fxpropi fadeout (div $arg1 2) 51 | fxpropi posfroment $FX_ENT_POS_MUZZLE 52 | ] 53 | 54 | exec "config/fx/weapons/airblast.cfg" 55 | exec "config/fx/weapons/beam.cfg" 56 | exec "config/fx/weapons/energy.cfg" 57 | exec "config/fx/weapons/flame.cfg" 58 | exec "config/fx/weapons/muzzle.cfg" 59 | exec "config/fx/weapons/plasma.cfg" 60 | exec "config/fx/weapons/splash.cfg" 61 | -------------------------------------------------------------------------------- /src/enet/list.c: -------------------------------------------------------------------------------- 1 | /** 2 | @file list.c 3 | @brief ENet linked list functions 4 | */ 5 | #define ENET_BUILDING_LIB 1 6 | #include "enet/enet.h" 7 | 8 | /** 9 | @defgroup list ENet linked list utility functions 10 | @ingroup private 11 | @{ 12 | */ 13 | void 14 | enet_list_clear (ENetList * list) 15 | { 16 | list -> sentinel.next = & list -> sentinel; 17 | list -> sentinel.previous = & list -> sentinel; 18 | } 19 | 20 | ENetListIterator 21 | enet_list_insert (ENetListIterator position, void * data) 22 | { 23 | ENetListIterator result = (ENetListIterator) data; 24 | 25 | result -> previous = position -> previous; 26 | result -> next = position; 27 | 28 | result -> previous -> next = result; 29 | position -> previous = result; 30 | 31 | return result; 32 | } 33 | 34 | void * 35 | enet_list_remove (ENetListIterator position) 36 | { 37 | position -> previous -> next = position -> next; 38 | position -> next -> previous = position -> previous; 39 | 40 | return position; 41 | } 42 | 43 | ENetListIterator 44 | enet_list_move (ENetListIterator position, void * dataFirst, void * dataLast) 45 | { 46 | ENetListIterator first = (ENetListIterator) dataFirst, 47 | last = (ENetListIterator) dataLast; 48 | 49 | first -> previous -> next = last -> next; 50 | last -> next -> previous = first -> previous; 51 | 52 | first -> previous = position -> previous; 53 | last -> next = position; 54 | 55 | first -> previous -> next = first; 56 | position -> previous = last; 57 | 58 | return first; 59 | } 60 | 61 | size_t 62 | enet_list_size (ENetList * list) 63 | { 64 | size_t size = 0; 65 | ENetListIterator position; 66 | 67 | for (position = enet_list_begin (list); 68 | position != enet_list_end (list); 69 | position = enet_list_next (position)) 70 | ++ size; 71 | 72 | return size; 73 | } 74 | 75 | /** @} */ 76 | -------------------------------------------------------------------------------- /src/engine/wind.h: -------------------------------------------------------------------------------- 1 | enum 2 | { 3 | // 0 is a constant localized wind source 4 | WIND_EMIT_IMPULSE = 1, 5 | WIND_EMIT_VECTORED = 1 << 1 6 | }; 7 | 8 | struct windattrs 9 | { 10 | vec o; 11 | int mode; 12 | int yaw; 13 | float speed; 14 | int radius; 15 | float atten; 16 | int interval; 17 | int length; 18 | 19 | windattrs() : o(vec(0, 0, 0)), mode(0), yaw(0), speed(0), radius(0), atten(0), interval(0), length(0) {} 20 | }; 21 | 22 | struct windemitter 23 | { 24 | extentity *ent; // Wind entity 25 | int entindex; 26 | windattrs attrs; 27 | windemitter **hook; // Hook pointing to this instance 28 | float curspeed; 29 | int lastimpulse; 30 | bool unused; 31 | 32 | windemitter(extentity *e = NULL, int idx = -1); 33 | 34 | const vec &getwindpos(); 35 | int getwindmode(); 36 | int getwindyaw(); 37 | float getwindspeed(); 38 | int getwindradius(); 39 | int getwindatten(); 40 | int getwindinterval(); 41 | int getwindlen(); 42 | void updateimpulse(); 43 | void updatewind(); 44 | void update(); 45 | }; 46 | 47 | // windprobes used for large-scale wind sampling (e.g. particles) 48 | struct windprobe 49 | { 50 | int nextprobe; 51 | vec lastwind; 52 | 53 | void reset(); 54 | vec probe(const vec &o, const dynent *d = NULL); 55 | }; 56 | 57 | extern int windanimfalloff; 58 | 59 | extern int getwindanimdist(); 60 | extern void cleanupwind(); 61 | extern void setupwind(); 62 | extern void clearwindemitters(); 63 | extern void updatewind(); 64 | extern vec getwind(const vec &o, const dynent *d = NULL); 65 | extern void addwind(const vec &o, int mode, float speed, windemitter **hook = NULL, int yaw = 0, int interval = 0, int length = 4000, int radius = 0, float atten = 0.1f); 66 | extern void remwind(windemitter **we); 67 | extern void addwind(extentity *e); 68 | extern void remwind(extentity *e); 69 | -------------------------------------------------------------------------------- /config/ui/events/balance.cfg: -------------------------------------------------------------------------------- 1 | event_balance_warning = [ 2 | event_image $infotex 0xFFFFFF 3 | uitext (concatword "Team balance in ^fs^fc" (timestr (geteventlist $event_id "args" "millis") 4) "^fS") $game_hud_event_text_size [ 4 | uistyle leftmiddle 5 | uitextalign -1 6 | ] 7 | ] 8 | 9 | event_balance_successs = [ 10 | event_image $infotex 0xFFFFFF 11 | uitext "Team balance ^fs^fccompleted^fS" $game_hud_event_text_size [ 12 | uistyle leftmiddle 13 | uitextalign -1 14 | ] 15 | ] 16 | 17 | event_balance_failure = [ 18 | event_image $infotex 0xFFFFFF 19 | uitext "Team balance ^fs^fcfailed^fS" $game_hud_event_text_size [ 20 | uistyle leftmiddle 21 | uitextalign -1 22 | ] 23 | ] 24 | 25 | event_balance_lapse = [ 26 | event_image $infotex 0xFFFFFF 27 | uitext "Team balance no longer required" $game_hud_event_text_size [ 28 | uistyle leftmiddle 29 | uitextalign -1 30 | ] 31 | ] 32 | 33 | event_balance_unable = [ 34 | event_image $infotex 0xFFFFFF 35 | uitext "Team balance unable to be performed" $game_hud_event_text_size [ 36 | uistyle leftmiddle 37 | uitextalign -1 38 | ] 39 | ] 40 | 41 | event_balance_swap = [ 42 | event_image $infotex 0xFFFFFF 43 | local event_force; event_force = (geteventlist $event_id "args" "forcebal") 44 | uitext (concatword (? $event_force "Role switch" "Symmetry swap") " in ^fs^fc" (timestr (geteventlist $event_id "args" "millis") 4) "^fS") $game_hud_event_text_size [ 45 | uistyle leftmiddle 46 | uitextalign -1 47 | ] 48 | ] 49 | 50 | event_balance_swapped = [ 51 | event_image $infotex 0xFFFFFF 52 | local event_force; event_force = (geteventlist $event_id "args" "forcebal") 53 | uitext (concatword (? $event_force "Role switch" "Symmetry swap") " completed") $game_hud_event_text_size [ 54 | uistyle leftmiddle 55 | uitextalign -1 56 | ] 57 | ] 58 | -------------------------------------------------------------------------------- /src/support/jsmn.h: -------------------------------------------------------------------------------- 1 | #ifndef __JSMN_H_ 2 | #define __JSMN_H_ 3 | 4 | #include 5 | 6 | #ifdef __cplusplus 7 | extern "C" { 8 | #endif 9 | 10 | /** 11 | * JSON type identifier. Basic types are: 12 | * o Object 13 | * o Array 14 | * o String 15 | * o Other primitive: number, boolean (true/false) or null 16 | */ 17 | typedef enum { 18 | JSMN_UNDEFINED = 0, 19 | JSMN_OBJECT = 1, 20 | JSMN_ARRAY = 2, 21 | JSMN_STRING = 3, 22 | JSMN_PRIMITIVE = 4 23 | } jsmntype_t; 24 | 25 | enum jsmnerr { 26 | /* Not enough tokens were provided */ 27 | JSMN_ERROR_NOMEM = -1, 28 | /* Invalid character inside JSON string */ 29 | JSMN_ERROR_INVAL = -2, 30 | /* The string is not a full JSON packet, more bytes expected */ 31 | JSMN_ERROR_PART = -3 32 | }; 33 | 34 | /** 35 | * JSON token description. 36 | * type type (object, array, string etc.) 37 | * start start position in JSON data string 38 | * end end position in JSON data string 39 | */ 40 | typedef struct { 41 | jsmntype_t type; 42 | int start; 43 | int end; 44 | int size; 45 | #ifdef JSMN_PARENT_LINKS 46 | int parent; 47 | #endif 48 | } jsmntok_t; 49 | 50 | /** 51 | * JSON parser. Contains an array of token blocks available. Also stores 52 | * the string being parsed now and current position in that string 53 | */ 54 | typedef struct { 55 | unsigned int pos; /* offset in the JSON string */ 56 | unsigned int toknext; /* next token to allocate */ 57 | int toksuper; /* superior token node, e.g parent object or array */ 58 | } jsmn_parser; 59 | 60 | /** 61 | * Create JSON parser over an array of tokens 62 | */ 63 | void jsmn_init(jsmn_parser *parser); 64 | 65 | /** 66 | * Run JSON parser. It parses a JSON data string into and array of tokens, each describing 67 | * a single JSON object. 68 | */ 69 | int jsmn_parse(jsmn_parser *parser, const char *js, size_t len, 70 | jsmntok_t *tokens, unsigned int num_tokens); 71 | 72 | #ifdef __cplusplus 73 | } 74 | #endif 75 | 76 | #endif /* __JSMN_H_ */ 77 | -------------------------------------------------------------------------------- /config/comp/feather.cfg: -------------------------------------------------------------------------------- 1 | shader $SHADER_DEFAULT compositefeather [ 2 | attribute vec4 vvertex, vcolor; 3 | attribute vec2 vtexcoord0; 4 | uniform mat4 hudmatrix; 5 | varying vec2 texcoord0; 6 | varying vec4 colorscale; 7 | 8 | void main(void) 9 | { 10 | gl_Position = hudmatrix * vvertex; 11 | texcoord0 = vtexcoord0; 12 | colorscale = vcolor; 13 | } 14 | ] [ 15 | uniform sampler2D tex0; 16 | uniform vec2 params; // xoff yoff 17 | varying vec2 texcoord0; 18 | uniform vec4 texsize0; 19 | varying vec4 colorscale; 20 | 21 | fragdata(0) vec4 fragcolor; 22 | 23 | float random(vec2 st) 24 | { 25 | return fract(sin(dot(st.xy, vec2(12.9898, 78.233))) * 43758.5453123); 26 | } 27 | 28 | float blend(float x, float y) 29 | { 30 | return (x < 0.5) ? (2.0 * x * y) : (1.0 - 2.0 * (1.0 - x) * (1.0 - y)); 31 | } 32 | 33 | vec3 blend(vec3 x, vec3 y, float opacity) 34 | { 35 | vec3 z = vec3(blend(x.r, y.r), blend(x.g, y.g), blend(x.b, y.b)); 36 | return z * opacity + x * (1.0 - opacity); 37 | } 38 | 39 | void main(void) 40 | { 41 | vec4 diffuse = texture2D(tex0, texcoord0); 42 | 43 | if(params.x > 0) 44 | { 45 | float offset = texcoord0.x < params.x ? texcoord0.x : 1.0 - texcoord0.x; 46 | if(offset < params.x) diffuse.a *= offset / params.x; 47 | } 48 | if(params.y > 0) 49 | { 50 | float offset = texcoord0.y < params.y ? texcoord0.y : 1.0 - texcoord0.y; 51 | if(offset < params.y) diffuse.a *= offset / params.y; 52 | } 53 | 54 | fragcolor = diffuse * colorscale; 55 | } 56 | ] 57 | 58 | newui feather $SURFACE_COMPOSITE [ 59 | @(localargs params [0.1 0.0]) 60 | @(localdef tex "textures/icon") 61 | execid uiarg1 62 | uirender compositefeather 1 1 [ 63 | uirenderparam params $params1 $params2 64 | uirendertex $tex 65 | ] 66 | ] 67 | -------------------------------------------------------------------------------- /config/tool/ents/light.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_light_flags = [ 2 | noshadow 3 | static 4 | vol 5 | nospec 6 | colourshadow 7 | ] 8 | 9 | tool_ent_add_attrs_light = [ 10 | tool_ent_add_attr light radius 0 11 | tool_ent_add_attr light red $T_ENT_NODELTA [ 12 | tool_ent_attr_red_val = (divf $$tool_ent_cur_attr 255) 13 | ] [ 14 | $tool_ent_cur_attr = (toint (round (*f $tool_ent_attr_red_val 255))) 15 | ] 16 | tool_ent_add_attr light green $T_ENT_NODELTA [ 17 | tool_ent_attr_green_val = (divf $$tool_ent_cur_attr 255) 18 | ] [ 19 | $tool_ent_cur_attr = (toint (round (*f $tool_ent_attr_green_val 255))) 20 | ] 21 | tool_ent_add_attr light blue $T_ENT_NODELTA [ 22 | tool_ent_attr_blue_val = (divf $$tool_ent_cur_attr 255) 23 | ] [ 24 | $tool_ent_cur_attr = (toint (round (*f $tool_ent_attr_blue_val 255))) 25 | ] 26 | tool_ent_add_attr light flare $T_ENT_NODELTA 27 | tool_ent_add_attr light fscale 0 28 | tool_ent_add_attr light flags $T_ENT_NODELTA 29 | tool_ent_add_attr light palette $T_ENT_NODELTA 30 | tool_ent_add_attr light palindex $T_ENT_NODELTA [ 31 | @(tool_ent_palindex_getter light) 32 | ] [ 33 | @(tool_ent_palindex_setter light) 34 | ] 35 | tool_ent_add_attr light modes $T_ENT_NODELTA 36 | tool_ent_add_attr light muts $T_ENT_NODELTA 37 | tool_ent_add_attr light variant $T_ENT_NODELTA 38 | tool_ent_add_attr light fxlevel $T_ENT_NODELTA [ 39 | @(tool_ent_fxlevel_getter light) 40 | ] [ 41 | @(tool_ent_fxlevel_setter light) 42 | ] 43 | 44 | tool_ent_postget_light = [ 45 | tool_ent_attr_colour = [@tool_ent_attr_red_val @tool_ent_attr_green_val @tool_ent_attr_blue_val] 46 | ] 47 | 48 | tool_ent_preset_light = [ 49 | tool_ent_attr_red_val = (at $tool_ent_attr_colour 0) 50 | tool_ent_attr_green_val = (at $tool_ent_attr_colour 1) 51 | tool_ent_attr_blue_val = (at $tool_ent_attr_colour 2) 52 | ] 53 | ] 54 | -------------------------------------------------------------------------------- /config/ui/game/widgets/shadow.cfg: -------------------------------------------------------------------------------- 1 | ui_gameui_shadow = [ 2 | uiborderedimageclamped $skinshadowtex 0x66000000 0 $ui_texborder $ui_screenborder 0 0 [ 3 | uistyle clampxy 4 | ] 5 | ] 6 | 7 | ui_gameui_shadowhoriz = [ 8 | uiborderedimageclamped $skinshadowhoriztex 0x66000000 0 $ui_texborder $ui_screenborder 0 0 [ 9 | uistyle clampxy 10 | ] 11 | ] 12 | 13 | shader $SHADER_DEFAULT shdr_gameui_shadowhorizgrad [ 14 | attribute vec4 vvertex, vcolor; 15 | attribute vec2 vtexcoord0; 16 | uniform mat4 hudmatrix; 17 | varying vec2 texcoord0; 18 | varying vec4 colorscale; 19 | 20 | void main(void) 21 | { 22 | gl_Position = hudmatrix * vvertex; 23 | texcoord0 = vtexcoord0; 24 | colorscale = vcolor; 25 | } 26 | ] [ 27 | uniform sampler2D tex0; 28 | uniform float bgblend, blend, phase, factor; 29 | varying vec2 texcoord0; 30 | varying vec4 colorscale; 31 | 32 | fragdata(0) vec4 fragcolor; 33 | 34 | void main() 35 | { 36 | vec4 diffuse = texture2D(tex0, texcoord0) + vec4(colorscale.rgb, bgblend); 37 | 38 | // Alpha gradient to fade out left and right edges 39 | diffuse.a *= clamp(1.0 - abs(texcoord0.x + phase) * factor, 0.0, 1.0) * blend; 40 | 41 | fragcolor = diffuse * colorscale; 42 | } 43 | ] 1 44 | 45 | gameui_advshadowhoriz_props = [ 46 | [ p_colour 0x66000000 ] 47 | [ p_bgblend 0 ] 48 | [ p_blend 1 ] 49 | [ p_phase -0.5 ] 50 | [ p_factor 2 ] 51 | ] 52 | 53 | // 1: 54 | ui_gameui_advshadowhoriz = [ 55 | @(props $gameui_advshadowhoriz_props arg1) 56 | 57 | uirender shdr_gameui_shadowhorizgrad 0 0 [ 58 | uistyle clampxy 59 | uicolourset $p_colour 60 | uirenderparam bgblend $p_bgblend 61 | uirenderparam blend $p_blend 62 | uirenderparam phase $p_phase 63 | uirenderparam factor $p_factor 64 | uirendertex $skinshadowhoriztex 65 | ] 66 | ] 67 | -------------------------------------------------------------------------------- /doc/readme_tesseract.txt: -------------------------------------------------------------------------------- 1 | Note that this license is an extension of the original Sauerbraten source code license which is included under the file "readme_sauerbraten.txt" for reference. Both are essentially the ZLIB license, but the Tesseract license may include differing copyright owners and usage clarifications. 2 | 3 | Tesseract source code license, usage, and documentation. 4 | 5 | You may use the Tesseract source code if you abide by the ZLIB license http://www.opensource.org/licenses/zlib-license.php (very similar to the BSD license): 6 | 7 | LICENSE 8 | ======= 9 | 10 | Tesseract game engine source code, any release. 11 | 12 | Copyright (C) 2014-2019 Wouter van Oortmerssen, Lee Salzman, Mike Dysart, Robert Pointon, Quinton Reeves, and Benjamin Segovia 13 | 14 | This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. 15 | 16 | Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: 17 | 18 | 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. 19 | 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. 20 | 3. This notice may not be removed or altered from any source distribution. 21 | 22 | AUTHORS 23 | ====== 24 | Wouter "Aardappel" van Oortmerssen 25 | http://strlen.com 26 | 27 | Lee "eihrul" Salzman 28 | http://sauerbraten.org/lee/ 29 | 30 | Mike "Gilt" Dysart 31 | 32 | Robert "baby-rabbit" Pointon 33 | http://www.fernlightning.com 34 | 35 | Quinton "Quin" Reeves 36 | http://www.redeclipse.net 37 | 38 | Benjamin Segovia 39 | 40 | For additional authors/contributors, see the Tesseract distribution readme. 41 | -------------------------------------------------------------------------------- /config/fx/weapons/flame.cfg: -------------------------------------------------------------------------------- 1 | registerfx FX_W_FLAME $FX_TYPE_PARTICLE [ 2 | fxpropi emitlen 1 3 | fxpropi parttype $FX_PARTTYPE_SINGLE 4 | fxpropi part $PART_HINT 5 | fxpropi fade 64 6 | fxpropf partsize 0.2 7 | fxpropf partsize 0.5 $FX_MOD_RAND 8 | fxpropc colour 100 100 255 9 | fxpropf blend 0.1 10 | fxpropi posfroment $FX_ENT_POS_MUZZLE 11 | ] 12 | 13 | registerfx FX_W_FLAME_TRAIL $FX_TYPE_PARTICLE [ 14 | fxparent FX_W_FLAME 15 | fxpropi emitlen 400 16 | fxpropi parttype $FX_PARTTYPE_SPLASH 17 | fxpropi part $PART_HINT 18 | fxpropc colour 100 100 255 19 | fxpropi num 1 20 | fxpropf partsize 0.25 21 | fxpropf vel 0 22 | fxpropf shapesize 1 23 | fxpropf blend 0.2 24 | fxpropi fade 32 25 | fxpropf gravity -10 26 | fxpropi fadein 200 27 | fxpropi fadeout 200 28 | fxpropi posfroment $FX_ENT_POS_MUZZLE 29 | 30 | if (> $fxdetail 0) [ 31 | fxend FX_W_FLAME_FLAME_END 32 | ] 33 | ] 34 | 35 | if (> $fxdetail 0) [ 36 | registerfx FX_W_FLAME_SMOKE $FX_TYPE_PARTICLE [ 37 | fxparent FX_W_FLAME 38 | fx_muzzle_smoke 1000 0.25 39 | ] 40 | 41 | registerfx FX_W_FLAME_FLAME_END $FX_TYPE_PARTICLE [ 42 | fxpropi activelen 1000 43 | fxpropi emitlen 1 44 | fxpropi emitinterval 200 45 | fxpropi emitinterval 200 $FX_MOD_RAND 46 | fxpropi parttype $FX_PARTTYPE_SPLASH 47 | fxpropi part $PART_HINT 48 | fxpropc colour 255 128 64 49 | fxpropc hintcolour 0 0 255 50 | fxpropf hintblend 0.5 51 | fxpropi num 1 52 | fxpropf partsize 0.2 53 | fxpropf partsize 0.1 $FX_MOD_LERP [ 54 | fxpropi lerptime 1000 55 | ] 56 | fxpropf vel 0 57 | fxpropf shapesize 1 58 | fxpropf blend 1 59 | fxpropf blend 0 $FX_MOD_LERP [ 60 | fxpropi lerptime 1000 61 | ] 62 | fxpropi fade 200 63 | fxpropf gravity 33 64 | fxpropi posfroment $FX_ENT_POS_MUZZLE 65 | ] 66 | ] 67 | -------------------------------------------------------------------------------- /src/include/SDL_test_memory.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2024 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | 22 | /** 23 | * \file SDL_test_memory.h 24 | * 25 | * Include file for SDL test framework. 26 | * 27 | * This code is a part of the SDL2_test library, not the main SDL library. 28 | */ 29 | 30 | #ifndef SDL_test_memory_h_ 31 | #define SDL_test_memory_h_ 32 | 33 | #include "begin_code.h" 34 | /* Set up for C function definitions, even when using C++ */ 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | 40 | /** 41 | * \brief Start tracking SDL memory allocations 42 | * 43 | * \note This should be called before any other SDL functions for complete tracking coverage 44 | */ 45 | int SDLTest_TrackAllocations(void); 46 | 47 | /** 48 | * \brief Print a log of any outstanding allocations 49 | * 50 | * \note This can be called after SDL_Quit() 51 | */ 52 | void SDLTest_LogAllocations(void); 53 | 54 | 55 | /* Ends C function definitions when using C++ */ 56 | #ifdef __cplusplus 57 | } 58 | #endif 59 | #include "close_code.h" 60 | 61 | #endif /* SDL_test_memory_h_ */ 62 | 63 | /* vi: set ts=4 sw=4 expandtab: */ 64 | -------------------------------------------------------------------------------- /config/comp/hint.cfg: -------------------------------------------------------------------------------- 1 | shader $SHADER_DEFAULT compositehint [ 2 | attribute vec4 vvertex, vcolor; 3 | attribute vec2 vtexcoord0; 4 | uniform mat4 hudmatrix; 5 | varying vec2 texcoord0; 6 | varying vec4 colorscale; 7 | 8 | void main(void) 9 | { 10 | gl_Position = hudmatrix * vvertex; 11 | texcoord0 = vtexcoord0; 12 | colorscale = vcolor; 13 | } 14 | ] [ 15 | uniform vec3 size; // xradius yradius blendstart 16 | varying vec2 texcoord0; 17 | varying vec4 colorscale; 18 | 19 | fragdata(0) vec4 fragcolor; 20 | 21 | void main() 22 | { 23 | float dist = length((texcoord0 - vec2(0.5)) * size.xy) * 2.0; 24 | float blend = 1.0 - smoothstep(size.z, 1.0, dist); 25 | fragcolor.rg = vec2(1.0, blend) * colorscale.ra; 26 | } 27 | ] 28 | 29 | newui hint $SURFACE_COMPOSITE [ 30 | @(localargs size [1.0 1.0 0.0]) 31 | execid uiarg1 32 | uirender compositehint 1 1 [ 33 | uirenderparam size $size1 $size2 $size3 34 | ] 35 | ] 36 | 37 | newui hintbold $SURFACE_COMPOSITE [ 38 | @(localargs size [1.0 1.0 0.65]) 39 | execid uiarg1 40 | uirender compositehint 1 1 [ 41 | uirenderparam size $size1 $size2 $size3 42 | ] 43 | ] 44 | 45 | newui hintent $SURFACE_COMPOSITE [ 46 | @(localargs size [1.0 1.0 0.35]) 47 | execid uiarg1 48 | uirender compositehint 1 1 [ 49 | uirenderparam size $size1 $size2 $size3 50 | ] 51 | ] 52 | 53 | newui hintvert $SURFACE_COMPOSITE [ 54 | @(localargs size [1.0 2.0 0.0]) 55 | execid uiarg1 56 | uirender compositehint 1 1 [ 57 | uirenderparam size $size1 $size2 $size3 58 | ] 59 | ] 60 | 61 | newui hinthorz $SURFACE_COMPOSITE [ 62 | @(localargs size [2.0 1.0 0.0]) 63 | execid uiarg1 64 | uirender compositehint 1 1 [ 65 | uirenderparam size $size1 $size2 $size3 66 | ] 67 | ] 68 | 69 | newui stain $SURFACE_COMPOSITE [ 70 | @(localargs size [1.0 0.5 0.0]) 71 | execid uiarg1 72 | uirender compositehint 1 1 [ 73 | uirenderparam size $size1 $size2 $size3 74 | uicolourset 0x808080 75 | ] 76 | ] 77 | -------------------------------------------------------------------------------- /src/steam/isteamparentalsettings.h: -------------------------------------------------------------------------------- 1 | //====== Copyright � 2013-, Valve Corporation, All rights reserved. ======= 2 | // 3 | // Purpose: Interface to Steam parental settings (Family View) 4 | // 5 | //============================================================================= 6 | 7 | #ifndef ISTEAMPARENTALSETTINGS_H 8 | #define ISTEAMPARENTALSETTINGS_H 9 | #ifdef _WIN32 10 | #pragma once 11 | #endif 12 | 13 | #include "steam_api_common.h" 14 | 15 | // Feature types for parental settings 16 | enum EParentalFeature 17 | { 18 | k_EFeatureInvalid = 0, 19 | k_EFeatureStore = 1, 20 | k_EFeatureCommunity = 2, 21 | k_EFeatureProfile = 3, 22 | k_EFeatureFriends = 4, 23 | k_EFeatureNews = 5, 24 | k_EFeatureTrading = 6, 25 | k_EFeatureSettings = 7, 26 | k_EFeatureConsole = 8, 27 | k_EFeatureBrowser = 9, 28 | k_EFeatureParentalSetup = 10, 29 | k_EFeatureLibrary = 11, 30 | k_EFeatureTest = 12, 31 | k_EFeatureSiteLicense = 13, 32 | k_EFeatureKioskMode_Deprecated = 14, 33 | k_EFeatureMax 34 | }; 35 | 36 | class ISteamParentalSettings 37 | { 38 | public: 39 | virtual bool BIsParentalLockEnabled() = 0; 40 | virtual bool BIsParentalLockLocked() = 0; 41 | 42 | virtual bool BIsAppBlocked( AppId_t nAppID ) = 0; 43 | virtual bool BIsAppInBlockList( AppId_t nAppID ) = 0; 44 | 45 | virtual bool BIsFeatureBlocked( EParentalFeature eFeature ) = 0; 46 | virtual bool BIsFeatureInBlockList( EParentalFeature eFeature ) = 0; 47 | }; 48 | 49 | #define STEAMPARENTALSETTINGS_INTERFACE_VERSION "STEAMPARENTALSETTINGS_INTERFACE_VERSION001" 50 | 51 | // Global interface accessor 52 | inline ISteamParentalSettings *SteamParentalSettings(); 53 | STEAM_DEFINE_USER_INTERFACE_ACCESSOR( ISteamParentalSettings *, SteamParentalSettings, STEAMPARENTALSETTINGS_INTERFACE_VERSION ); 54 | 55 | //----------------------------------------------------------------------------- 56 | // Purpose: Callback for querying UGC 57 | //----------------------------------------------------------------------------- 58 | struct SteamParentalSettingsChanged_t 59 | { 60 | enum { k_iCallback = k_ISteamParentalSettingsCallbacks + 1 }; 61 | }; 62 | 63 | 64 | #endif // ISTEAMPARENTALSETTINGS_H 65 | -------------------------------------------------------------------------------- /src/steam/isteammusic.h: -------------------------------------------------------------------------------- 1 | //============ Copyright (c) Valve Corporation, All rights reserved. ============ 2 | 3 | #ifndef ISTEAMMUSIC_H 4 | #define ISTEAMMUSIC_H 5 | #ifdef _WIN32 6 | #pragma once 7 | #endif 8 | 9 | #include "steam_api_common.h" 10 | 11 | //----------------------------------------------------------------------------- 12 | // Purpose: 13 | //----------------------------------------------------------------------------- 14 | enum AudioPlayback_Status 15 | { 16 | AudioPlayback_Undefined = 0, 17 | AudioPlayback_Playing = 1, 18 | AudioPlayback_Paused = 2, 19 | AudioPlayback_Idle = 3 20 | }; 21 | 22 | 23 | //----------------------------------------------------------------------------- 24 | // Purpose: Functions to control music playback in the steam client 25 | //----------------------------------------------------------------------------- 26 | class ISteamMusic 27 | { 28 | public: 29 | virtual bool BIsEnabled() = 0; 30 | virtual bool BIsPlaying() = 0; 31 | 32 | virtual AudioPlayback_Status GetPlaybackStatus() = 0; 33 | 34 | virtual void Play() = 0; 35 | virtual void Pause() = 0; 36 | virtual void PlayPrevious() = 0; 37 | virtual void PlayNext() = 0; 38 | 39 | // volume is between 0.0 and 1.0 40 | virtual void SetVolume( float flVolume ) = 0; 41 | virtual float GetVolume() = 0; 42 | 43 | }; 44 | 45 | #define STEAMMUSIC_INTERFACE_VERSION "STEAMMUSIC_INTERFACE_VERSION001" 46 | 47 | // Global interface accessor 48 | inline ISteamMusic *SteamMusic(); 49 | STEAM_DEFINE_USER_INTERFACE_ACCESSOR( ISteamMusic *, SteamMusic, STEAMMUSIC_INTERFACE_VERSION ); 50 | 51 | // callbacks 52 | #if defined( VALVE_CALLBACK_PACK_SMALL ) 53 | #pragma pack( push, 4 ) 54 | #elif defined( VALVE_CALLBACK_PACK_LARGE ) 55 | #pragma pack( push, 8 ) 56 | #else 57 | #error steam_api_common.h should define VALVE_CALLBACK_PACK_xxx 58 | #endif 59 | 60 | 61 | STEAM_CALLBACK_BEGIN( PlaybackStatusHasChanged_t, k_iSteamMusicCallbacks + 1 ) 62 | STEAM_CALLBACK_END(0) 63 | 64 | STEAM_CALLBACK_BEGIN( VolumeHasChanged_t, k_iSteamMusicCallbacks + 2 ) 65 | STEAM_CALLBACK_MEMBER( 0, float, m_flNewVolume ) 66 | STEAM_CALLBACK_END(1) 67 | 68 | #pragma pack( pop ) 69 | 70 | 71 | #endif // #define ISTEAMMUSIC_H 72 | -------------------------------------------------------------------------------- /config/fx/projs/projs.cfg: -------------------------------------------------------------------------------- 1 | P_FX_LIFETIME_PARAM = 0 2 | P_FX_BOUNCE_VEL_PARAM = 0 3 | 4 | // 1<:name> 2: 3: 5 | register_proj_hit_fx = [ 6 | local _grow 7 | _grow = 0.04 8 | 9 | if $arg3 [ 10 | _grow = (*f $arg3 $_grow) 11 | ] 12 | 13 | if (! $nogore) [ 14 | registerfx $arg1 $FX_TYPE_PARTICLE [ 15 | if (!=s $arg2 "") [ 16 | fxparent $arg2 17 | ] 18 | fxpropf emitcull 4 19 | fxpropi emitlen 1 20 | fxpropi parttype $FX_PARTTYPE_SPLASH 21 | fxpropi part $PART_BLOOD 22 | fxpropi fade 80 23 | fxpropf vel 20 24 | fxpropf partsize 0.1 25 | fxpropf partsizechange $_grow 26 | fxpropi num 2 27 | fxpropc colour 100 100 100 28 | fxpropc colour 100 255 255 $FX_MOD_LERP [ 29 | fxpropi lerpmode $FX_MOD_LERP_PARAM 30 | ] 31 | ] 32 | ] [ 33 | registerfx $arg1 $FX_TYPE_PARTICLE [ 34 | if (!=s $arg2 "") [ 35 | fxparent $arg2 36 | ] 37 | fxpropf emitcull 4 38 | fxpropi emitlen 1 39 | fxpropi parttype $FX_PARTTYPE_SPLASH 40 | fxpropi part $PART_HINT 41 | fxpropi fade 80 42 | fxpropf vel 20 43 | fxpropf partsize 0.1 44 | fxpropf partsizechange $_grow 45 | fxpropi num 2 46 | fxpropi colorized 1 47 | fxpropf blend 0.5 48 | ] 49 | ] 50 | ] 51 | 52 | exec "config/fx/projs/acid.cfg" 53 | exec "config/fx/projs/blob.cfg" 54 | exec "config/fx/projs/bullet.cfg" 55 | exec "config/fx/projs/pellet.cfg" 56 | exec "config/fx/projs/flak.cfg" 57 | exec "config/fx/projs/shrapnel.cfg" 58 | exec "config/fx/projs/flame.cfg" 59 | exec "config/fx/projs/airblast.cfg" 60 | exec "config/fx/projs/plasma.cfg" 61 | exec "config/fx/projs/vortex.cfg" 62 | exec "config/fx/projs/energy.cfg" 63 | exec "config/fx/projs/beam.cfg" 64 | exec "config/fx/projs/grenade.cfg" 65 | exec "config/fx/projs/mine.cfg" 66 | exec "config/fx/projs/rocket.cfg" 67 | 68 | exec "config/fx/projs/casing.cfg" 69 | exec "config/fx/projs/gib.cfg" 70 | exec "config/fx/projs/debris.cfg" 71 | -------------------------------------------------------------------------------- /src/include/SDL_test_log.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2024 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | 22 | /** 23 | * \file SDL_test_log.h 24 | * 25 | * Include file for SDL test framework. 26 | * 27 | * This code is a part of the SDL2_test library, not the main SDL library. 28 | */ 29 | 30 | /* 31 | * 32 | * Wrapper to log in the TEST category 33 | * 34 | */ 35 | 36 | #ifndef SDL_test_log_h_ 37 | #define SDL_test_log_h_ 38 | 39 | #include "begin_code.h" 40 | /* Set up for C function definitions, even when using C++ */ 41 | #ifdef __cplusplus 42 | extern "C" { 43 | #endif 44 | 45 | /** 46 | * \brief Prints given message with a timestamp in the TEST category and INFO priority. 47 | * 48 | * \param fmt Message to be logged 49 | */ 50 | void SDLTest_Log(SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(1); 51 | 52 | /** 53 | * \brief Prints given message with a timestamp in the TEST category and the ERROR priority. 54 | * 55 | * \param fmt Message to be logged 56 | */ 57 | void SDLTest_LogError(SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(1); 58 | 59 | /* Ends C function definitions when using C++ */ 60 | #ifdef __cplusplus 61 | } 62 | #endif 63 | #include "close_code.h" 64 | 65 | #endif /* SDL_test_log_h_ */ 66 | 67 | /* vi: set ts=4 sw=4 expandtab: */ 68 | -------------------------------------------------------------------------------- /src/include/SDL_test.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2024 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | 22 | /** 23 | * \file SDL_test.h 24 | * 25 | * Include file for SDL test framework. 26 | * 27 | * This code is a part of the SDL2_test library, not the main SDL library. 28 | */ 29 | 30 | #ifndef SDL_test_h_ 31 | #define SDL_test_h_ 32 | 33 | #include "SDL.h" 34 | #include "SDL_test_assert.h" 35 | #include "SDL_test_common.h" 36 | #include "SDL_test_compare.h" 37 | #include "SDL_test_crc32.h" 38 | #include "SDL_test_font.h" 39 | #include "SDL_test_fuzzer.h" 40 | #include "SDL_test_harness.h" 41 | #include "SDL_test_images.h" 42 | #include "SDL_test_log.h" 43 | #include "SDL_test_md5.h" 44 | #include "SDL_test_memory.h" 45 | #include "SDL_test_random.h" 46 | 47 | #include "begin_code.h" 48 | /* Set up for C function definitions, even when using C++ */ 49 | #ifdef __cplusplus 50 | extern "C" { 51 | #endif 52 | 53 | /* Global definitions */ 54 | 55 | /* 56 | * Note: Maximum size of SDLTest log message is less than SDL's limit 57 | * to ensure we can fit additional information such as the timestamp. 58 | */ 59 | #define SDLTEST_MAX_LOGMESSAGE_LENGTH 3584 60 | 61 | /* Ends C function definitions when using C++ */ 62 | #ifdef __cplusplus 63 | } 64 | #endif 65 | #include "close_code.h" 66 | 67 | #endif /* SDL_test_h_ */ 68 | 69 | /* vi: set ts=4 sw=4 expandtab: */ 70 | -------------------------------------------------------------------------------- /config/ui/game/widgets/decortext.cfg: -------------------------------------------------------------------------------- 1 | gameui_decortext_props = [ 2 | [ p_label_size 2 ] 3 | [ p_colour 0xffffff ] 4 | [ p_light_intensity 0.15 ] 5 | [ p_pad_h 0.05 ] 6 | [ p_pad_v 0.01 ] 7 | [ p_width 0.9 ] 8 | ] 9 | 10 | // 1: 2: 11 | # ui_gameui_decortext = [ 12 | @(props $gameui_decortext_props arg2) 13 | 14 | local _anim_state _light_blend _light_blend_anim _light_len 15 | _anim_state = (*f (+f (sin (*f $totalmillis 0.1)) 1) 0.5) 16 | _light_blend_anim = (lerpf 0.25 1 $_anim_state) 17 | _light_blend = (*f $_light_blend_anim (lerpf 1 $p_light_intensity $_light_blend_anim)) 18 | _light_len = (*f $p_width (lerpf 0.66 1 $_anim_state)) 19 | 20 | uifill $p_width 0 [ 21 | uiclip $p_width 0.06 (*f $p_width 1.5) 0 [ 22 | uifill (*f $p_width 3) 0.05 [ 23 | local _anim_x _anim_y 24 | _anim_x = (*f (sin (*f $totalmillis 0.04)) $p_width 0.75) 25 | _anim_y = (*f (cos (*f $totalmillis 0.04)) 0.01) 26 | 27 | uipad (+f $_anim_x $p_width) 0 (+f $_anim_y 0.01) 0 [ 28 | uiimage $hinttex #(hsvtohex 8 0.2 1) 0 0.5 0.05 [ 29 | uipropagate [uicolourblend $_light_blend] 30 | ] 31 | ] 32 | ] 33 | ] 34 | 35 | uiimage "stain" #(hsvtohex 8 0.8 1) 0 $_light_len 0.02 [ 36 | uipropagate [uicolourblend $_light_blend] 37 | ] 38 | 39 | uiimage "stain" #(hsvtohex 8 0.1 1) 0 $_light_len 0.01 [ 40 | uipropagate [uicolourblend $_light_blend] 41 | ] 42 | 43 | uiimage $hintenttex #(hsvtohex 8 0.2 1) 0 $_light_len 0.04 [ 44 | uipropagate [uicolourblend (*f $_light_blend 0.75)] 45 | ] 46 | 47 | uispace $p_pad_h $p_pad_v [ 48 | uiimage $hintboldtex #(hsvtohex 8 0.5 0.5) 0 0 0 [ 49 | uipropagate [uicolourblend (*f $_light_blend 0.33)] 50 | ] 51 | uiprev [uistyle clampxy] 52 | 53 | uicolourtext $arg1 $p_colour $p_label_size 54 | 55 | uialign $p_label_align 56 | ] 57 | ] 58 | ] 59 | -------------------------------------------------------------------------------- /config/ui/tips.cfg: -------------------------------------------------------------------------------- 1 | uitipreset = [ 2 | ui_tooltip_body = "" 3 | ui_tooltip_time = 0 4 | ui_tooltip_last = 0 5 | ] 6 | uitipreset 7 | 8 | uitip = [ 9 | if (&& (!=s $arg1 "") (!=s (getalias [ui_tip_@arg1]) "")) [ 10 | uihover [ 11 | if (!=s $ui_tooltip_body $arg1) [ 12 | ui_tooltip_body = $arg1 13 | if $ui_tooltip_time [ 14 | ui_tooltip_time = (- $totalmillis (- $ui_tooltipblend (- $totalmillis $ui_tooltip_last))) 15 | ] [ 16 | ui_tooltip_time = $totalmillis 17 | ] 18 | ] 19 | ui_tooltip_last = $totalmillis 20 | if (! (uitest "tooltip" $SURFACE_FOREGROUND)) [ showui "tooltip" $SURFACE_FOREGROUND ] 21 | ] 22 | ] 23 | ] 24 | 25 | newui "tooltip" $SURFACE_FOREGROUND [ 26 | uiontop 1 27 | uiwinstyle $WINSTYLE_TOOLTIP 28 | uizindex 1 29 | uivlist 0 [ 30 | uiborderedimageclamped $skinalphatex 0x000000 0 $ui_texborder $ui_screenborder 0 0 [ 31 | uiborderedimageclamped $skinshadowtex 0x202020 0 $ui_texborder $ui_screenborder 0 0 [ 32 | uispace $ui_padnormal $ui_padsmall [ 33 | uivlist 0 [[ui_tip_@ui_tooltip_body]] 34 | local tooltip_frame; tooltip_frame = (- $totalmillis $ui_tooltip_last) 35 | if (|| (= $ui_tooltip_time 0) (> $tooltip_frame $ui_tooltipdelay)) [ 36 | local tooltip_since 37 | tooltip_since = (-f $tooltip_frame $ui_tooltipdelay) 38 | if (> $tooltip_since $ui_tooltipblend) [ 39 | hideui "tooltip" $uisurfacetype 40 | ] [ 41 | uiproproot [ uicolourblend (-f 1 (divf $tooltip_since $ui_tooltipblend)) ] 42 | ] 43 | ] [ 44 | local tooltip_since; tooltip_since = (- $totalmillis $ui_tooltip_time) 45 | if (< $tooltip_since $ui_tooltipblend) [ 46 | uiproproot [ uicolourblend (divf $tooltip_since $ui_tooltipblend) ] 47 | ] 48 | ] 49 | ] 50 | ] 51 | ] 52 | ] 53 | ] [] [ uitipreset ] 54 | -------------------------------------------------------------------------------- /config/ui/tool/ents/toolaffinity.cfg: -------------------------------------------------------------------------------- 1 | # ui_tool_ent_affinity = [ 2 | ui_tool_ent_param_group "Team" [ 3 | ui_tool_dropdown #(tool_ent_attr affinity team) $tool_team_names [ 4 | #(ui_tool_ent_attr_props affinity team) 5 | ] 6 | ] 7 | 8 | ui_tool_ent_param_group "Direction" [ 9 | uigrid 2 0 0 [ 10 | ui_tool_numinput #(tool_ent_attr affinity yaw) 0 360 1 [ 11 | #(ui_tool_ent_attr_props affinity yaw [] 1) 12 | p_label = "Yaw" 13 | p_val_format = i 14 | p_circular = 1 15 | ] 16 | 17 | ui_tool_button [ 18 | p_icon = "textures/icons/camera" 19 | p_icon_size = 0.015 20 | p_icon_align = 0 21 | p_tip_simple = "Yaw from camera" 22 | p_on_click = [ 23 | tool_param_set #(tool_ent_attr affinity yaw) (toint (round $camerayaw)) [ 24 | tool_ent_attr_change affinity $tool_ent_affinity_idx_yaw 25 | ] 26 | ] 27 | p_disabled = $tool_ent_delta_edit_on 28 | ] 29 | 30 | ui_tool_numinput #(tool_ent_attr affinity pitch) -90 90 1 [ 31 | #(ui_tool_ent_attr_props affinity pitch [] 1) 32 | p_label = "Pitch" 33 | p_val_format = i 34 | ] 35 | 36 | ui_tool_button [ 37 | p_icon = "textures/icons/camera" 38 | p_icon_size = 0.015 39 | p_icon_align = 0 40 | p_tip_simple = "Pitch from camera" 41 | p_on_click = [ 42 | tool_param_set #(tool_ent_attr affinity pitch) (toint (round $camerapitch)) [ 43 | tool_ent_attr_change affinity $tool_ent_affinity_idx_pitch 44 | ] 45 | ] 46 | p_disabled = $tool_ent_delta_edit_on 47 | ] 48 | ] 49 | ] 50 | 51 | @(ui_tool_ent_gamemode_group affinity) 52 | @(ui_tool_ent_variant_group affinity) 53 | 54 | ui_tool_ent_param_group "ID" [ 55 | ui_tool_numinput #(tool_ent_attr affinity id) 0 1000 1 [ 56 | #(ui_tool_ent_attr_props affinity id [] 1) 57 | p_val_format = i 58 | ] 59 | ] 60 | ] 61 | -------------------------------------------------------------------------------- /src/include/SDL_quit.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2024 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | 22 | /** 23 | * \file SDL_quit.h 24 | * 25 | * Include file for SDL quit event handling. 26 | */ 27 | 28 | #ifndef SDL_quit_h_ 29 | #define SDL_quit_h_ 30 | 31 | #include "SDL_stdinc.h" 32 | #include "SDL_error.h" 33 | 34 | /** 35 | * \file SDL_quit.h 36 | * 37 | * An ::SDL_QUIT event is generated when the user tries to close the application 38 | * window. If it is ignored or filtered out, the window will remain open. 39 | * If it is not ignored or filtered, it is queued normally and the window 40 | * is allowed to close. When the window is closed, screen updates will 41 | * complete, but have no effect. 42 | * 43 | * SDL_Init() installs signal handlers for SIGINT (keyboard interrupt) 44 | * and SIGTERM (system termination request), if handlers do not already 45 | * exist, that generate ::SDL_QUIT events as well. There is no way 46 | * to determine the cause of an ::SDL_QUIT event, but setting a signal 47 | * handler in your application will override the default generation of 48 | * quit events for that signal. 49 | * 50 | * \sa SDL_Quit() 51 | */ 52 | 53 | /* There are no functions directly affecting the quit event */ 54 | 55 | #define SDL_QuitRequested() \ 56 | (SDL_PumpEvents(), (SDL_PeepEvents(NULL,0,SDL_PEEKEVENT,SDL_QUIT,SDL_QUIT) > 0)) 57 | 58 | #endif /* SDL_quit_h_ */ 59 | -------------------------------------------------------------------------------- /config/fx/projs/bullet.cfg: -------------------------------------------------------------------------------- 1 | registerfx FX_P_BULLET_LIFE $FX_TYPE_PARTICLE [ 2 | fxpropf emitcull 4 3 | fxpropi parttype $FX_PARTTYPE_FLARE 4 | fxpropi part $PART_MUZZLE_FLARE 5 | fxpropi colorized $FX_COLORIZE_PARAM 6 | fxpropi fade 50 7 | fxpropf partsize 0.15 8 | fxpropf shapesize 0 9 | fxpropi fadein 50 10 | ] 11 | 12 | registerfx FX_P_BULLET_BOUNCE $FX_TYPE_STAIN [ 13 | fxpropi staintype $STAIN_BULLET 14 | fxpropf radius 0.8 15 | fxpropf radius 0.4 $FX_MOD_RAND 16 | ] 17 | 18 | registerfx FX_P_BULLET_BOUNCE_SPLASH $FX_TYPE_PARTICLE [ 19 | fxparent FX_P_BULLET_BOUNCE 20 | fxpropf emitdist 512 21 | fxpropf emitcull 4 22 | fxpropi emitlen 1 23 | fxpropi parttype $FX_PARTTYPE_SPLASH 24 | fxpropi part $PART_SPARK 25 | fxpropi fade 12 26 | fxpropf vel 100 27 | fxpropf partsize 0.25 28 | fxpropi num 5 29 | fxpropc colour 255 200 100 30 | ] 31 | 32 | registerfx FX_P_BULLET_DESTROY $FX_TYPE_STAIN [ 33 | fxpropi staintype $STAIN_BULLET 34 | fxpropf radius 0.8 35 | fxpropf radius 0.4 $FX_MOD_RAND 36 | ] 37 | 38 | registerfx FX_P_BULLET_DESTROY_SPARK $FX_TYPE_PARTICLE [ 39 | fxparent FX_P_BULLET_DESTROY 40 | fxpropf emitdist 512 41 | fxpropf emitcull 4 42 | fxpropi emitlen 1 43 | fxpropi parttype $FX_PARTTYPE_SPLASH 44 | fxpropi part $PART_SPARK 45 | fxpropi fade 12 46 | fxpropf vel 100 47 | fxpropf partsize 0.5 48 | fxpropi num 5 49 | fxpropc colour 255 200 100 50 | ] 51 | 52 | registerfx FX_P_BULLET_HIT $FX_TYPE_PARTICLE [ 53 | fxpropf emitcull 4 54 | fxpropi emitlen 1 55 | fxpropi parttype $FX_PARTTYPE_SPLASH 56 | fxpropi part $PART_SPARK 57 | fxpropi fade 20 58 | fxpropf vel 50 59 | fxpropf partsize 0.5 60 | fxpropi num 5 61 | fxpropc colour 255 200 100 62 | ] 63 | 64 | register_proj_hit_fx FX_P_BULLET_HIT2 FX_P_BULLET_HIT 65 | 66 | if (> $fxdetail 0) [ 67 | registerfx FX_P_BULLET_HIT_GLOW $FX_TYPE_PARTICLE [ 68 | fxparent FX_P_BULLET_HIT 69 | fxpropf emitcull 4 70 | fxpropi emitlen 1 71 | fxpropi parttype $FX_PARTTYPE_SINGLE 72 | fxpropi part $PART_SPARK 73 | fxpropi fade 1 74 | fxpropf vel 0 75 | fxpropf partsize 10 76 | fxpropi num 1 77 | fxpropc colour 255 200 100 78 | fxpropf blend 0.15 79 | ] 80 | ] 81 | -------------------------------------------------------------------------------- /config/ui/events/item.cfg: -------------------------------------------------------------------------------- 1 | event_item_use = [ 2 | event_image $startex 0xFFFFFF 3 | 4 | local event_this event_weap event_weapon 5 | 6 | event_weap = (geteventlist $event_id "args" "attr") 7 | event_weapon = (at $W_NAMES $event_weap) 8 | 9 | uitext (geteventname $event_id "client" 0) $game_hud_event_text_size [ 10 | uistyle leftmiddle 11 | uitextalign -1 12 | ] 13 | 14 | uitext "picked up a" (*f $game_hud_event_text_size 0.75) [ 15 | uistyle leftmiddle 16 | uitextalign -1 17 | ] 18 | 19 | event_image $[@[event_weapon]tex] $[@[event_weapon]colour] 20 | 21 | uitext $[@[event_weapon]longname] $game_hud_event_text_size [ 22 | uistyle leftmiddle 23 | uicolourset $[@[event_weapon]colour] 24 | uitextalign -1 25 | ] 26 | ] 27 | 28 | event_item_spawn = [ 29 | event_image $startex 0xFFFFFF 30 | 31 | local event_this event_weap event_weapon 32 | 33 | event_weap = (geteventlist $event_id "args" "attr") 34 | event_weapon = (at $W_NAMES $event_weap) 35 | 36 | uitext "A" (*f $game_hud_event_text_size 0.75) [ 37 | uistyle leftmiddle 38 | uitextalign -1 39 | ] 40 | 41 | event_image $[@[event_weapon]tex] $[@[event_weapon]colour] 42 | 43 | uitext $[@[event_weapon]longname] $game_hud_event_text_size [ 44 | uistyle leftmiddle 45 | uicolourset $[@[event_weapon]colour] 46 | uitextalign -1 47 | ] 48 | 49 | uitext "has spawned" (*f $game_hud_event_text_size 0.75) [ 50 | uistyle leftmiddle 51 | uitextalign -1 52 | ] 53 | ] 54 | 55 | event_item_drop = [ 56 | event_image $startex 0xFFFFFF 57 | 58 | local event_this event_weap event_weapon 59 | 60 | event_weap = (geteventlist $event_id "args" "attr") 61 | event_weapon = (at $W_NAMES $event_weap) 62 | 63 | uitext (geteventname $event_id "client" 0) $game_hud_event_text_size [ 64 | uistyle leftmiddle 65 | uitextalign -1 66 | ] 67 | 68 | uitext "dropped a" (*f $game_hud_event_text_size 0.75) [ 69 | uistyle leftmiddle 70 | uitextalign -1 71 | ] 72 | 73 | event_image $[@[event_weapon]tex] $[@[event_weapon]colour] 74 | 75 | uitext $[@[event_weapon]longname] $game_hud_event_text_size [ 76 | uistyle leftmiddle 77 | uicolourset $[@[event_weapon]colour] 78 | uitextalign -1 79 | ] 80 | ] 81 | -------------------------------------------------------------------------------- /config/ui/tool/ents/toolplayerstart.cfg: -------------------------------------------------------------------------------- 1 | # ui_tool_ent_playerstart = [ 2 | ui_tool_ent_param_group "Team" [ 3 | ui_tool_dropdown #(tool_ent_attr playerstart team) $tool_team_names [ 4 | #(ui_tool_ent_attr_props playerstart team) 5 | ] 6 | ] 7 | 8 | ui_tool_ent_param_group "Direction" [ 9 | uigrid 2 0 0 [ 10 | ui_tool_numinput #(tool_ent_attr playerstart yaw) 0 360 1 [ 11 | #(ui_tool_ent_attr_props playerstart yaw [] 1) 12 | p_label = "Yaw" 13 | p_val_format = i 14 | p_circular = 1 15 | ] 16 | 17 | ui_tool_button [ 18 | p_icon = "textures/icons/camera" 19 | p_icon_size = 0.015 20 | p_icon_align = 0 21 | p_tip_simple = "Yaw from camera" 22 | p_on_click = [ 23 | tool_param_set #(tool_ent_attr playerstart yaw) (toint (round $camerayaw)) [ 24 | tool_ent_attr_change playerstart $tool_ent_playerstart_idx_yaw 25 | ] 26 | ] 27 | p_disabled = $tool_ent_delta_edit_on 28 | ] 29 | 30 | ui_tool_numinput #(tool_ent_attr playerstart pitch) -90 90 1 [ 31 | #(ui_tool_ent_attr_props playerstart pitch [] 1) 32 | p_label = "Pitch" 33 | p_val_format = i 34 | ] 35 | 36 | ui_tool_button [ 37 | p_icon = "textures/icons/camera" 38 | p_icon_size = 0.015 39 | p_icon_align = 0 40 | p_tip_simple = "Pitch from camera" 41 | p_on_click = [ 42 | tool_param_set #(tool_ent_attr playerstart pitch) (toint (round $camerapitch)) [ 43 | tool_ent_attr_change playerstart $tool_ent_playerstart_idx_pitch 44 | ] 45 | ] 46 | p_disabled = $tool_ent_delta_edit_on 47 | ] 48 | ] 49 | ] 50 | 51 | @(ui_tool_ent_gamemode_group playerstart) 52 | @(ui_tool_ent_variant_group playerstart) 53 | 54 | ui_tool_ent_param_group "ID" [ 55 | ui_tool_numinput #(tool_ent_attr playerstart id) 0 1000 1 [ 56 | #(ui_tool_ent_attr_props playerstart id [] 1) 57 | p_val_format = i 58 | ] 59 | ] 60 | ] 61 | -------------------------------------------------------------------------------- /config/tool/ents/teleport.cfg: -------------------------------------------------------------------------------- 1 | tool_ent_teleport_flags = [ 2 | noaffinity 3 | ] 4 | 5 | tool_ent_add_attrs_teleport = [ 6 | tool_ent_add_attr teleport yaw $T_ENT_NODELTA [ 7 | tool_ent_attr_rotate = (= $$tool_ent_cur_attr -1) 8 | ] [ 9 | caseif $tool_ent_attr_rotate [ 10 | $tool_ent_cur_attr = -1 11 | ] [< $$tool_ent_cur_attr 0] [ 12 | $tool_ent_cur_attr = 0 13 | ] 14 | ] 15 | tool_ent_add_attr teleport pitch 0 16 | tool_ent_add_attr teleport push 0 17 | tool_ent_add_attr teleport radius 0 18 | tool_ent_add_attr teleport colour $T_ENT_NODELTA 19 | tool_ent_add_attr teleport type $T_ENT_NODELTA [ 20 | tool_ent_attr_dir = (mod $$tool_ent_cur_attr 3) 21 | tool_ent_attr_offset = (> $$tool_ent_cur_attr 2) 22 | ] [ 23 | $tool_ent_cur_attr = $tool_ent_attr_dir 24 | if $tool_ent_attr_offset [ 25 | $tool_ent_cur_attr = (+ $$tool_ent_cur_attr 3) 26 | ] 27 | ] 28 | tool_ent_add_attr teleport palette $T_ENT_NODELTA 29 | tool_ent_add_attr teleport palindex $T_ENT_NODELTA [ 30 | @(tool_ent_palindex_getter teleport) 31 | ] [ 32 | @(tool_ent_palindex_setter teleport) 33 | ] 34 | tool_ent_add_attr teleport flags $T_ENT_NODELTA 35 | tool_ent_add_attr teleport modes $T_ENT_NODELTA 36 | tool_ent_add_attr teleport muts $T_ENT_NODELTA 37 | tool_ent_add_attr teleport variant $T_ENT_NODELTA 38 | tool_ent_add_attr teleport blend $T_ENT_NODELTA [ // 18 39 | tool_ent_teleport_blend_val = (? $$tool_ent_cur_attr $$tool_ent_cur_attr 100) 40 | ] [ 41 | $tool_ent_cur_attr = (? (= $tool_ent_teleport_blend_val 100) 0 $tool_ent_teleport_blend_val) 42 | ] 43 | tool_ent_add_attr teleport size 0 44 | tool_ent_add_attr teleport envblend $T_ENT_NODELTA [ // 18 45 | tool_ent_teleport_envblend_val = (? $$tool_ent_cur_attr $$tool_ent_cur_attr 100) 46 | ] [ 47 | $tool_ent_cur_attr = (? (= $tool_ent_teleport_envblend_val 100) 0 $tool_ent_teleport_envblend_val) 48 | ] 49 | tool_ent_add_attr teleport hintcolour $T_ENT_NODELTA 50 | tool_ent_add_attr teleport hintblend $T_ENT_NODELTA [ 51 | tool_ent_teleport_hintblend_val = (? $$tool_ent_cur_attr $$tool_ent_cur_attr 0) 52 | ] [ 53 | $tool_ent_cur_attr = (? (= $tool_ent_teleport_hintblend_val 000) 0 $tool_ent_teleport_hintblend_val) 54 | ] 55 | ] 56 | -------------------------------------------------------------------------------- /config/ui/tool/ents/toolwind.cfg: -------------------------------------------------------------------------------- 1 | # ui_tool_ent_wind = [ 2 | ui_tool_ent_param_group "Mode" [ 3 | ui_tool_switch #(tool_ent_attr wind mode) [ 4 | #(ui_tool_ent_attr_props wind mode) 5 | p_options = ["Periodic" "Impulse"] 6 | p_label = "Strength" 7 | p_get = [& $#(tool_ent_attr wind mode) 1] 8 | p_set = [^ $#(tool_ent_attr wind mode) 1] 9 | ] 10 | 11 | ui_tool_switch #(tool_ent_attr wind mode) [ 12 | #(ui_tool_ent_attr_props wind mode) 13 | p_options = ["Local" "Vectored"] 14 | p_label = "Direction" 15 | p_get = [!= (& $#(tool_ent_attr wind mode) 2) 0] 16 | p_set = [^ $#(tool_ent_attr wind mode) 2] 17 | ] 18 | 19 | uifill 0 $ui_tool_elem_space_l 20 | 21 | ui_tool_numinput #(tool_ent_attr wind implen) 0 100000 100 [ 22 | #(ui_tool_ent_attr_props wind implen [] 1) 23 | p_label = "Impulse length" 24 | p_val_format = i 25 | p_disabled = (! (& $#(tool_ent_attr wind mode) 1)) 26 | ] 27 | 28 | ui_tool_numinput #(tool_ent_attr wind yaw) 0 360 1 [ 29 | #(ui_tool_ent_attr_props wind yaw [] 1) 30 | p_label = "Yaw" 31 | p_val_format = i 32 | p_circular = 1 33 | p_disabled = (! (& $#(tool_ent_attr wind mode) 2)) 34 | ] 35 | ] 36 | 37 | ui_tool_ent_param_group "Strength" [ 38 | ui_tool_numinput #(tool_ent_attr wind speed) 0 255 1 [ 39 | #(ui_tool_ent_attr_props wind speed [] 1) 40 | p_label = "Speed" 41 | p_val_format = i 42 | ] 43 | 44 | ui_tool_numinput #(tool_ent_attr wind atten) 0 100 1 [ 45 | #(ui_tool_ent_attr_props wind atten [] 1) 46 | p_label = "Attenuation" 47 | p_val_format = i 48 | ] 49 | 50 | ui_tool_numinput #(tool_ent_attr wind interval) 0 100000 100 [ 51 | #(ui_tool_ent_attr_props wind interval [] 1) 52 | p_label = "Interval" 53 | p_val_format = i 54 | ] 55 | ] 56 | 57 | ui_tool_ent_param_group "Radius" [ 58 | ui_tool_numinput #(tool_ent_attr wind radius) 0 100000 10 [ 59 | #(ui_tool_ent_attr_props wind radius [] 1) 60 | p_val_format = i 61 | ] 62 | ] 63 | 64 | @(ui_tool_ent_gamemode_group wind) 65 | @(ui_tool_ent_variant_group wind 1) 66 | ] 67 | -------------------------------------------------------------------------------- /src/include/SDL_test_compare.h: -------------------------------------------------------------------------------- 1 | /* 2 | Simple DirectMedia Layer 3 | Copyright (C) 1997-2024 Sam Lantinga 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the authors be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | */ 21 | 22 | /** 23 | * \file SDL_test_compare.h 24 | * 25 | * Include file for SDL test framework. 26 | * 27 | * This code is a part of the SDL2_test library, not the main SDL library. 28 | */ 29 | 30 | /* 31 | 32 | Defines comparison functions (i.e. for surfaces). 33 | 34 | */ 35 | 36 | #ifndef SDL_test_compare_h_ 37 | #define SDL_test_compare_h_ 38 | 39 | #include "SDL.h" 40 | 41 | #include "SDL_test_images.h" 42 | 43 | #include "begin_code.h" 44 | /* Set up for C function definitions, even when using C++ */ 45 | #ifdef __cplusplus 46 | extern "C" { 47 | #endif 48 | 49 | /** 50 | * \brief Compares a surface and with reference image data for equality 51 | * 52 | * \param surface Surface used in comparison 53 | * \param referenceSurface Test Surface used in comparison 54 | * \param allowable_error Allowable difference (=sum of squared difference for each RGB component) in blending accuracy. 55 | * 56 | * \returns 0 if comparison succeeded, >0 (=number of pixels for which the comparison failed) if comparison failed, -1 if any of the surfaces were NULL, -2 if the surface sizes differ. 57 | */ 58 | int SDLTest_CompareSurfaces(SDL_Surface *surface, SDL_Surface *referenceSurface, int allowable_error); 59 | 60 | 61 | /* Ends C function definitions when using C++ */ 62 | #ifdef __cplusplus 63 | } 64 | #endif 65 | #include "close_code.h" 66 | 67 | #endif /* SDL_test_compare_h_ */ 68 | 69 | /* vi: set ts=4 sw=4 expandtab: */ 70 | -------------------------------------------------------------------------------- /src/include/freetype/ttunpat.h: -------------------------------------------------------------------------------- 1 | /***************************************************************************/ 2 | /* */ 3 | /* ttunpat.h */ 4 | /* */ 5 | /* Definitions for the unpatented TrueType hinting system */ 6 | /* */ 7 | /* Copyright 2003, 2006 by */ 8 | /* David Turner, Robert Wilhelm, and Werner Lemberg. */ 9 | /* */ 10 | /* Written by Graham Asher */ 11 | /* */ 12 | /* This file is part of the FreeType project, and may only be used, */ 13 | /* modified, and distributed under the terms of the FreeType project */ 14 | /* license, LICENSE.TXT. By continuing to use, modify, or distribute */ 15 | /* this file you indicate that you have read the license and */ 16 | /* understand and accept it fully. */ 17 | /* */ 18 | /***************************************************************************/ 19 | 20 | 21 | #ifndef __TTUNPAT_H__ 22 | #define __TTUNPAT_H__ 23 | 24 | 25 | #include 26 | #include FT_FREETYPE_H 27 | 28 | #ifdef FREETYPE_H 29 | #error "freetype.h of FreeType 1 has been loaded!" 30 | #error "Please fix the directory search order for header files" 31 | #error "so that freetype.h of FreeType 2 is found first." 32 | #endif 33 | 34 | 35 | FT_BEGIN_HEADER 36 | 37 | 38 | /*************************************************************************** 39 | * 40 | * @constant: 41 | * FT_PARAM_TAG_UNPATENTED_HINTING 42 | * 43 | * @description: 44 | * A constant used as the tag of an @FT_Parameter structure to indicate 45 | * that unpatented methods only should be used by the TrueType bytecode 46 | * interpreter for a typeface opened by @FT_Open_Face. 47 | * 48 | */ 49 | #define FT_PARAM_TAG_UNPATENTED_HINTING FT_MAKE_TAG( 'u', 'n', 'p', 'a' ) 50 | 51 | /* */ 52 | 53 | FT_END_HEADER 54 | 55 | 56 | #endif /* __TTUNPAT_H__ */ 57 | 58 | 59 | /* END */ 60 | -------------------------------------------------------------------------------- /config/fx/weapons/muzzle.cfg: -------------------------------------------------------------------------------- 1 | // default for pistol1 2 | 3 | registerfx FX_W_MUZZLE1 $FX_TYPE_PARTICLE [ 4 | fx_muzzle_flash 50 1 1 5 | ] 6 | 7 | if (> $fxdetail 0) [ 8 | registerfx FX_W_MUZZLE1_SMOKE $FX_TYPE_PARTICLE [ 9 | fxparent FX_W_MUZZLE1 10 | fx_muzzle_smoke 500 0.25 11 | ] 12 | ] 13 | 14 | if (> $fxdetail 1) [ 15 | registerfx FX_W_MUZZLE1_LIGHT $FX_TYPE_LIGHT [ 16 | fxparent FX_W_MUZZLE1 17 | fx_muzzle_light 50 0.5 18 | ] 19 | ] 20 | 21 | // default for shotgun1 22 | 23 | registerfx FX_W_MUZZLE2 $FX_TYPE_PARTICLE [ 24 | fx_muzzle_flash 100 1 1 25 | ] 26 | 27 | if (> $fxdetail 0) [ 28 | registerfx FX_W_MUZZLE2_SMOKE $FX_TYPE_PARTICLE [ 29 | fxparent FX_W_MUZZLE2 30 | fx_muzzle_smoke 1000 0.375 31 | ] 32 | ] 33 | 34 | if (> $fxdetail 1) [ 35 | registerfx FX_W_MUZZLE2_LIGHT $FX_TYPE_LIGHT [ 36 | fxparent FX_W_MUZZLE2 37 | fx_muzzle_light 100 0.5 38 | ] 39 | ] 40 | 41 | // default for shotgun2 42 | 43 | registerfx FX_W_MUZZLE3 $FX_TYPE_PARTICLE [ 44 | fx_muzzle_flash 200 1.25 0.25 45 | ] 46 | 47 | if (> $fxdetail 0) [ 48 | registerfx FX_W_MUZZLE3_SMOKE $FX_TYPE_PARTICLE [ 49 | fxparent FX_W_MUZZLE3 50 | fx_muzzle_smoke 2000 0.5 51 | ] 52 | ] 53 | 54 | if (> $fxdetail 1) [ 55 | registerfx FX_W_MUZZLE3_LIGHT $FX_TYPE_LIGHT [ 56 | fxparent FX_W_MUZZLE3 57 | fx_muzzle_light 200 0.25 58 | ] 59 | ] 60 | 61 | // default for smg1 62 | 63 | registerfx FX_W_MUZZLE4 $FX_TYPE_PARTICLE [ 64 | fx_muzzle_flash 25 0.5 1 65 | ] 66 | 67 | if (> $fxdetail 0) [ 68 | registerfx FX_W_MUZZLE4_SMOKE $FX_TYPE_PARTICLE [ 69 | fxparent FX_W_MUZZLE4 70 | fx_muzzle_smoke 500 0.25 71 | ] 72 | ] 73 | 74 | if (> $fxdetail 1) [ 75 | registerfx FX_W_MUZZLE4_LIGHT $FX_TYPE_LIGHT [ 76 | fxparent FX_W_MUZZLE4 77 | fx_muzzle_light 25 0.5 78 | ] 79 | ] 80 | 81 | // default for smg2 82 | 83 | registerfx FX_W_MUZZLE5 $FX_TYPE_PARTICLE [ 84 | fx_muzzle_flash 100 0.75 0.25 85 | ] 86 | 87 | if (> $fxdetail 0) [ 88 | registerfx FX_W_MUZZLE5_SMOKE $FX_TYPE_PARTICLE [ 89 | fxparent FX_W_MUZZLE5 90 | fx_muzzle_smoke 1000 0.375 91 | ] 92 | ] 93 | 94 | if (> $fxdetail 1) [ 95 | registerfx FX_W_MUZZLE5_LIGHT $FX_TYPE_LIGHT [ 96 | fxparent FX_W_MUZZLE5 97 | fx_muzzle_light 100 0.25 98 | ] 99 | ] 100 | --------------------------------------------------------------------------------