Fix race condition where onerror clearing m_connectedFlag before onclose
caused any network drop to be misidentified as a room-full rejection.
Add m_wasEverConnected flag set once in onopen, use it in onclose to
assign exit code 10 (room full) vs 11 (connection lost). Rename
rejected API surface to disconnected to reflect the generalized meaning.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Remove unused `using namespace Extensions` from isleapp.cpp and replace
per-header forward declaration blocks in 7 LEGO1 headers with a single
shared forward declarations header.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* WIP
* WIP
* Make camera the single source of truth for broadcast state
Remove redundant local copies of walkAnimId, idleAnimId, and
displayActorIndex from NetworkManager. BroadcastLocalState now reads
these from the camera's Controller, eliminating dual-copy sync issues.
Additional cleanup:
- Early-return on null cam in SendEmote/HandleCustomize for clarity
- Only consume camera-dependent pending requests when cam is available
- Move local name bubble creation from BroadcastLocalState to Tickle
- Remove dead NetworkManager::SetDisplayActorIndex method
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Fix clang format
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* Decouple 3rd person camera from player movement
Arrow keys now move the player relative to the camera direction instead
of using tank controls. The camera stays static unless explicitly
controlled via right-click drag, mouse wheel, or touch gestures.
Adds a single hook in CalculateNewPosDir that lets the extension take
over movement computation. The extension manages its own velocity
smoothing, computes camera-relative directions from an absolute yaw,
and writes nav controller velocities via friend class access.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Clean up ThirdPersonCamera: remove dead m_orbitYaw, extract helpers
Remove m_orbitYaw (always DEFAULT_ORBIT_YAW) and pass yaw directly to
ComputeOrbitVectors, eliminating save/restore blocks at all call sites.
Extract GetLocalYaw() and InitAbsoluteYaw() helpers to deduplicate
repeated atan2 patterns. Simplify SetupCamera by passing DEFAULT_ORBIT_YAW
directly. Move TURN_RATE constant to file scope.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Hide cursor while orbiting 3rd person camera with right mouse button
Move SDL event handling from LegoInputManager::UpdateLastInputMethod to
an exported function called at the end of SDL_AppEvent, so cursor state
changes aren't overridden by isleapp's SDL_ShowCursor(). Use
SDL_SetWindowRelativeMouseMode to hide the cursor and freeze its position
while the right mouse button is held in 3rd person camera mode.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* Export MultiplayerExt symbols accessed from isle executable
When lego1 is built as a shared library (DLL), symbols used by the isle
executable through the Extension<T>::Call() template need to be exported.
Add LEGO1_EXPORT to MultiplayerExt::enabled and MultiplayerExt::CheckRejected()
which are referenced from isleapp.cpp via the template instantiation.
https://claude.ai/code/session_01HHMmowothg25fephi6iidq
* Use inline const instead of constexpr for extension function pointers
constexpr cannot be used with dllimport function addresses since they
are resolved at load time through the IAT, not at compile time. Change
to inline const which preserves the single-definition semantics (via
inline) while allowing runtime initialization of the function pointers.
https://claude.ai/code/session_01HHMmowothg25fephi6iidq
* Fix multiplayer extension link errors across DLL boundary
When lego1 is a shared library, Extension<T>::Call() instantiated from
isle.exe references MultiplayerExt::enabled and CheckRejected() which
are not exported. Instead of exporting internal symbols (which also
breaks constexpr with dllimport), add an exported IsMultiplayerRejected()
wrapper that keeps the Extension<T>::Call() instantiation inside lego1.
https://claude.ai/code/session_01HHMmowothg25fephi6iidq
* Guard IsMultiplayerRejected with EXTENSIONS ifdef
extensions.cpp is only compiled when ISLE_EXTENSIONS is ON, so the
wrapper function and its call site need #ifdef EXTENSIONS guards for
targets like x86 MSVC where extensions are disabled.
https://claude.ai/code/session_01HHMmowothg25fephi6iidq
* Move IsMultiplayerRejected definition to multiplayer.cpp
The function is declared in multiplayer.h and belongs with the rest of
the multiplayer extension code, not in the general extensions.cpp file.
https://claude.ai/code/session_01HHMmowothg25fephi6iidq
---------
Co-authored-by: Claude <noreply@anthropic.com>
- Remove hardcoded multiplayer config from emscripten config.cpp
- Add relay HTTP endpoints for room preview (GET) and creation (POST)
with capacity check, CORS headers, and configurable max players
- Add WebSocket rejection detection (room full/503) via onclose flag
- Add CheckRejected extension call in IsleApp::Tick for clean shutdown
through SDL_APP_SUCCESS path instead of calling exit()
- Set Module._exitCode in JS for sessionStorage-based toast after reload
SDL3 commit 1a27b5b838f added code that overwrites window dimensions
with CSS values when external_size is detected. This broke rendering
because the window was created with browser dimensions instead of
the requested 640x480.
Force the correct window size immediately after creation to ensure
the renderer initializes with the proper dimensions.
CI / ${{ matrix.name }} (false, -DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=10.0.26100.0, false, false, Visual Studio 17 2022, true, Xbox One, windows-latest, amd64, false, true) (push) Waiting to run
CI / ${{ matrix.name }} (false, -DCMAKE_TOOLCHAIN_FILE=/opt/devkitpro/cmake/3DS.cmake, false, devkitpro/devkitarm:latest, false, Ninja, true, Nintendo 3DS, ubuntu-latest, true) (push) Waiting to run
CI / ${{ matrix.name }} (false, -DCMAKE_TOOLCHAIN_FILE=/opt/devkitpro/cmake/Switch.cmake, false, devkitpro/devkita64:latest, false, Ninja, Nintendo Switch, true, ubuntu-latest, true) (push) Waiting to run
CI / ${{ matrix.name }} (false, -DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=10.0.26100.0, false, false, Visual Studio 17 2022, true, Xbox One, windows-latest, amd64, false, true) (push) Waiting to run
CI / ${{ matrix.name }} (false, -DCMAKE_TOOLCHAIN_FILE=/opt/devkitpro/cmake/3DS.cmake, false, devkitpro/devkitarm:latest, false, Ninja, true, Nintendo 3DS, ubuntu-latest, true) (push) Waiting to run
CI / ${{ matrix.name }} (false, -DCMAKE_TOOLCHAIN_FILE=/opt/devkitpro/cmake/Switch.cmake, false, devkitpro/devkita64:latest, false, Ninja, Nintendo Switch, true, ubuntu-latest, true) (push) Waiting to run
* miniwin/shadercross: explicitly add include directory
* miniwin/sdl3gpu: update compiled shaders + add dxbc generation support
* isle: log SDL version at start up
CI / ${{ matrix.name }} (false, -DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=10.0.26100.0, false, false, Visual Studio 17 2022, true, Xbox One, windows-latest, amd64, false, true) (push) Has been cancelled
CI / ${{ matrix.name }} (false, -DCMAKE_TOOLCHAIN_FILE=/opt/devkitpro/cmake/3DS.cmake, false, devkitpro/devkitarm:latest, false, Ninja, true, Nintendo 3DS, ubuntu-latest, true) (push) Has been cancelled
CI / ${{ matrix.name }} (false, -DCMAKE_TOOLCHAIN_FILE=/opt/devkitpro/cmake/Switch.cmake, false, devkitpro/devkita64:latest, false, Ninja, Nintendo Switch, true, ubuntu-latest, true) (push) Has been cancelled
* - Set defaults if ini exists, but empty.
- Create a new dictionary object, not use null object.
* Switch Port
Todo: Fix: Misc crashes when interacting on island.
Todo: Fix: Joystick pointer is slow to move.
Todo: Fix: Touch doesn't behave.
* Fix: base GetPathInfo fixup in the SDL implementation, with check for null SDL_PathInfo.
Fix: Disable imgui shell functions.
Todo: Display imgui debug if enabled.
* Fix: Correction to suite style guidelines
* - Switch build homebrew NRO
- CI/CD to build Switch
* Fix typo in CI
* clang-format fix
* Clang-format against isleapp.cpp
* Use correct docker container for CI/CD
* Remove SDL fixups and use an SDL3 port with fixes.
Fixes crash bug and world issues!
* Fix: use Clang-Format 17 instead of 21
---------
Co-authored-by: SnepOMatic (Rhew) <github@rhew.co.uk>
* add psvita to cmake
* no PIE for vita
* add modules to vpk
* use custom pvr apphint
* select correct renderer for sdl renderer
* patch sdl3 shaders, got something on screen!
* use proper cmake patch for sdl
* add missing module
* remove test window which causes a bug in the vita sdl port to show up
* add gxm renderer (not working with display yet)
* avoid sdl renderer for vita, seems broken
* make gxm renderer work with new d3drm
* fix rendering somewhat, some geometry shows up
* support paletted textures directly to avoid copying the texture twice
* fix Draw2DImage
* make 3d work, broken lights
* clean up a bit
* fix normals matrix
* remove some unneeded changes
* forgot env var
* wrong env dest
* run clang format
* correct texture address mode, use tlsf instead of sceClibMspace
* double buffered uniforms seem to work now
* missed a line
* update GXMRenderer_EnumDevice
* hopefully actually fix uniform buffers
* run clang-format
* remove a change thats not needed
* improve fragment shader performance
* add vita to dist folder
* add base for vita config app
* add config self to vpk
* transform touch events to virtual size
* add livearea graphics
* Update cmake file to include livearea assets
* put manual in the right place
* add sample rco
* add messagebox on vita
* triple buffer textures because fences arent a thing on vita and making draw&cpu sync would be too slow
* make config app not crash on launch
* change defaults
* update gxm renderer with interface changes
* split 2d and 3d shaders completely
* update gxm renderer
* fix transition on gxm
* clang format
* move config cmake
* move CONFIG_vita
* always clear before drawing 2d image
* hopefully fix windows build
* clang-format fix broken includes
* order again
* undo moving qt cmake to its own list
* move uic search path
* use ifdefs for all d3drm backends, cpack to generate vpk
* cmake wrong escape
* small cleanups in gxm renderer
* defer texture delete to avoid overwriting the texture during a frame
* clang-format
* more of the layout for config
* remove top buttons
* use SceAppSettings instead of custom ui
* use select for back to info center on vita, to make screenshots possible again
* remove accidentally left in add_subdirectory
* adjust diskpath to be like other ports
* use vita_create_vpk and not cpack
* gxm: msaa support, fix wrong file path
* gxm: add mipmaps (disabled)
* clang-format
* fix open isle.ini with fopen
* add missing strings
* use iniparser_set not dictionary_set
* add default save path to config
* load config app after initializing ini on vita
* fix config build
* change the default disk & cd path, update the paf library
* update paf library headers
* include orders for clang-format
* clean up
* make shader compiler not required
* move asm language
* warn instead of error when shader source is changed when no compiler is found
---------
Co-authored-by: Li <li@silica.codes>
Co-authored-by: Christian Semmler <mail@csemmler.com>
* initial files
* get building
* proper paths & default to virtual mouse
* Wrap gradle under cmake & build SDL3.aar
run cmake with -DANDROID_NDK_PATH=/path/to/ndk to generate the .aar & run the gradle build
if using Android Studio you will have to run the aar script manually(or do the cmake cmd) then put the normal cmake args inside '-PcmakeArgs="-DCMAKE_BUILD_TYPE=Release ...."' at `Settings > Build, Execution, Deployment > Gradle-Android Compiler > Command-line Options`
Check CMakeLists.txt Android build block for more info
* workflow and format
* dont cmake -> gradle -> cmake
* icons
* prevent first start crash due to missing isle.ini
dont force require gles3 (vulkan & software are options)
* cleanup
* cmake script & ci cleanup
use a cmake script to downoad SDL3 sources for aar building
* script cleanups & gradle stub for android studio
handle the env var setting for the sdl3 aar build script
* signing
needed repository secrets:
- keystore : key.jks in base64
- keystorePassword : Key store password
- keyAlias : Key alias, ex key0
- keyPassword : Key Password
* conditionally run action without keys
* compile SDL once & cross-platformize gradle tasks
* suggestions
* use find_package over manual configuration
* use MxString
---------
Co-authored-by: Anders Jenbo <anders@jenbo.dk>
Co-authored-by: Christian Semmler <mail@csemmler.com>
* Add resolution adjustment, framerate limit, etc
- isle-config has been reworked to be a smaller, more organised window
- resolution adjustment has now been added to isle-config, so that the resolution on windowed game start can be set
- max framerate setting added to isle-config
- higher-quality options disabled in isle-config if computer has too little RAM (unlikely)
* Make clang-format happy
* Switch to MxS32, move variable declaration to end
* Adjust sizing of resolution spinboxes
* Add full screen video mode
When full screen is enabled, the game goes full-screen, and the screen resolution changes.
* Rework to add Exclusive Fullscreen option.
* Remove comment
* Raise max LoD value to 60
* Fix tab order
* Simplify code
* Add CLI --help argument
* Make clang-format happy
* Move to switch instead of creating temp var
* Remove unnecesary break
Co-authored-by: Christian Semmler <mail@csemmler.com>
* Remove unnecesary break 2
Co-authored-by: Christian Semmler <mail@csemmler.com>
* Make clang-format happy again
---------
Co-authored-by: Christian Semmler <mail@csemmler.com>
* ✨ feat: add ios support
* ⚗️ chore: trying some experiments to make ci working
* ⚗️ chore: is it really ci version problem?
* 💚 fix: it really is just a ci version issue
* 🩹 fix: go as low as possible
* 🩹 fix: support ipad