Black Trigram (흑괘) - Korean Martial Arts Combat Simulator API - v0.7.11
    Preparing search index...

    Variable REFERENCE_PIXELS_PER_METERConst

    REFERENCE_PIXELS_PER_METER: 100 = ...

    Reference pixels-per-meter ratio for scale calculations.

    Korean: 참조 미터-픽셀 변환

    This is the REFERENCE ratio used for calculating scale factors. The actual pixels-per-meter varies by device resolution:

    • Calculate actual ratio: arenaWidthPixels / arenaWidthMeters
    • Calculate scale: actualRatio / REFERENCE_PIXELS_PER_METER

    Do NOT use this for direct coordinate conversion. Use bounds.width / bounds.worldWidthMeters instead.

    // Calculate actual pixels per meter from arena bounds
    const actualPixelsPerMeter = bounds.width / bounds.worldWidthMeters;

    // Calculate scale relative to reference
    const scale = actualPixelsPerMeter / REFERENCE_PIXELS_PER_METER;

    참조픽셀미터비율