modules/sdk-test-view-cpp/README.md
C++ implementation of the SpacetimeDB view test module. This mirrors the Rust sdk-test-view module to ensure feature parity between the C++ and Rust SDKs.
This module tests the C++ bindings' view functionality including:
std::optional<T>std::vector<T>player - Player entities with unique identitiesplayer_level - Player levels indexed for filteringplayer_location - Player positions with active statusReturns the caller's player record.
std::optional<Player>Returns the caller's player joined with their level.
std::optional<PlayerAndLevel>Returns all players at level 0.
std::vector<Player>Returns all active players within 5 units of the caller.
std::vector<PlayerLocation>emcmake cmake -B build
cmake --build build
The output will be build/lib.wasm.