android-native: real-server login by default, readable CJK text, 16 KB pages

- FreeType: add the cff/psaux/pshinter modules (from the pinned 2.13.3
  tarball, same sha256). Android's only CJK font is the CFF2
  NotoSansCJK-Regular.ttc, which the TrueType-only build could not open,
  so every Chinese glyph drew as a box.
- Font oversample rounds the UI density up: Android's 1760x800 UI on a
  2376x1080 screen is 1.35, which rounded to 1x bilevel glyphs stretched
  1.35x. Now 2x anti-aliased glyphs are scaled down. macOS 2.0 unchanged.
- MainActivity: a launcher start (no intent args) opens the login screen
  against 192.168.21.203 instead of auto-logging into the in-process fake
  server; explicit args still select the fake-server smoke flow.
- build-android-native.sh: ANDROID_SUPPORT_FLEXIBLE_PAGE_SIZES=ON for SDL3
  and libmain (LOAD alignment 0x1000 -> 0x4000), with a stamp that
  rebuilds a cached pre-flag SDL3. Clears Android's 16 KB compat warning.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
shenlei
2026-09-29 12:16:38 +09:00
co-authored by Claude Opus 5.5
parent 3c52ced02e
commit 53d06c3c26
73 changed files with 33280 additions and 10 deletions
@@ -15,9 +15,13 @@ import org.libsdl.app.SDLActivity;
* Runs native_render's main() (libmain.so). Command-line arguments come from the launch intent,
* e.g. adb shell am start -n org.metin2port.client/.MainActivity \
* --es args "--live-server 192.168.21.203:11000:13000 --login-screen"
* Without arguments the client runs against the in-process fake server once Client/ is in files/.
* A launcher start (no arguments) opens the login screen against DEFAULT_ARGS' server, so the
* installed app is played by hand on the real server. Any explicit args replace DEFAULT_ARGS; args
* without --live-server (e.g. --es args "--fake-mobs 64") run the in-process fake-server smoke flow.
*/
public class MainActivity extends SDLActivity {
private static final String DEFAULT_ARGS = "--live-server 192.168.21.203:11000:13000 --login-screen";
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
@@ -70,7 +74,7 @@ public class MainActivity extends SDLActivity {
String args = intent != null ? intent.getStringExtra("args") : null;
Log.i("Metin2Args", "native args: " + args);
if (args == null || args.trim().isEmpty())
return new String[0];
args = DEFAULT_ARGS;
return args.trim().split("\\s+");
}