Use XDG_DATA_HOME for Flatpak so that fs_homepath is accessible without
special permissions/handling. This changes the home path for Flatpak
from ~/.q3a/ to ~/.var/app/org.ioquake3.ioquake3/data/q3a/.
There is a copy to clipboard option but the error itself wasn't printed
to the console so it wasn't copied to the clipboard.
Unix-like platforms print it to the console so it's written in
crashlog.txt.
The error was only displayed for Team Arena if one of the Team Arena pk3s
were found. Fix it to be display when trying to run Team Arena even with
no Team Arena pk3s present.
Don't project sun shadows (r_forceSun 1) on to view depth equal to 1.0
(nothing drawn or skybox). This caused a full second shadow of the
entire level in tr.screenShadowImage. It would move as the camera far
plane changed and rotate/stretch strangely as the camera view changed.
It was visible in-game on lightmapped transparent surfaces facing the
skybox and happen to overlap the extra shadow of the level.
This affected the glass in wop_padship's underwater room.
Default com_maxfps to 0 under Emscripten. Under Emscripten the browser
handles throttling the frame rate. Manual framerate throttling interacts
poorly with Emscripten's browser-driven event loop.
If getting the display index of the existing window fails, fallback to
the default display size instead of falling back to 640x480.
emscripten r_mode -2 worked on window creation but vid_restart fellback
to 640x480.
Also make viewing client.html directly use client-config.json in the
same directory so it's possible to "live edit" both the files without
having to run make.
List files for multiple games in a single client-config.json file so
that com_basegame argument can pick different game data.
Use ioquake3.html?com_basegame=demoq3 (or tademo) to run the Quake 3 or
Team Arena demo. They require new QVMs from baseq3/missionpack to run.
Modify the client HTML file when copying it to the build directory to
apply current CLIENTBIN and BASEGAME. It always loads engine/data from
the current directory (no need to try to locate the build directory).
- Remove emscripten build steps from Makefile (see readme)
- USE_CURL=0 has no effect
- HAVE_VM_COMPILED=false has no effect
- WebGL 1 and 2 are supported by the OpenGL2 renderer
- FULL_ES2 (client-side arrays) isn't needed
- Rename EMSCRIPTENOBJ to GENERATEDTARGETS and separate it from
TARGETS so it's more readable.
This enables several things:
* Optionally load pk3 files from a web server at runtime instead of bundling them with Emscripten at build time
* Set command line arguments via URL param
* It's not ugly
emscripten 3.1.27 reduced the stack size from 5MB to 64KB. This caused
run-time errors: Uncaught RuntimeError: index out of bounds
Co-authored-by: James Darpinian <jdarpinian@gmail.com>
This mainly targets OpenGL ES 2.0 but it also supports compiling GLSL as
ESSL 3.00. It's missing support for framebuffer objects which should be
possible on ES 2. (Though using renderbuffers instead of textures.)
opengl1 cvars that are not supported will display a message and disable
the cvar. This has not been reviewed for new opengl2 cvars. Enabling
cvars may cause rendering issues. Some of the broken cvars may be
possible to support using OpenGL ES 3 features.
The game displays okay with the default cvars.
Fix six image skybox having a black border around the sides of the sky
when using OpenGL 1.1 (using CL_CLAMP instead of GL_CLAMP_TO_EDGE).
It's technically visible in q3dm10 but it's more obvious in Team Arena
maps such as mpteam6.