Can now build to android apk

Need to fix:
- Remove default android header bar
- Fix rcss styling to work on small screens
This commit is contained in:
2026-08-09 00:16:23 -05:00
parent 4aa23d3670
commit a3c7d9cf75
13 changed files with 668 additions and 7 deletions

16
src/asset_io.hpp Normal file
View File

@@ -0,0 +1,16 @@
#pragma once
#include <SDL3/SDL.h>
#include <string>
inline SDL_IOStream *OpenAssetFile(const std::string &virtual_path) {
std::string resolved = virtual_path;
#if defined(__ANDROID__)
if (resolved.rfind("./assets/", 0) == 0) {
resolved = resolved.substr(9);
} else if (resolved.rfind("assets/", 0) == 0) {
resolved = resolved.substr(7);
}
#endif
return SDL_IOFromFile(resolved.c_str(), "rb");
}