Tighten the mobile skill arc and reduce auto-hunt artwork
This commit is contained in:
@@ -9,7 +9,7 @@ int main() {
|
||||
struct Screen { float width, height, inset, target; };
|
||||
for (const auto screen : {Screen{640, 360, 24, 48}, Screen{800, 600, 0, 48},
|
||||
Screen{1300, 600, 40, 48}, Screen{1067, 600, 32, 72},
|
||||
Screen{1366, 1024, 62, 48}}) {
|
||||
Screen{1366, 1024, 62, 48}, Screen{1169, 600, 0, 74}}) {
|
||||
const auto layout = mt_host::make_touch_layout(screen.width, screen.height, screen.inset, screen.target);
|
||||
const auto& attack = layout.buttons[0];
|
||||
float previous_angle = -1000;
|
||||
@@ -24,6 +24,7 @@ int main() {
|
||||
"skills leave the bottom status and menu strip clear");
|
||||
const float dx = b.x - attack.x, dy = b.y - attack.y;
|
||||
const float distance = std::hypot(dx, dy);
|
||||
check(distance <= 121 * layout.scale, "the skill arc stays compact around attack");
|
||||
if (i == 1) first_distance = distance;
|
||||
check(std::abs(distance - first_distance) < 0.01f, "all six skills occupy one ring");
|
||||
float angle = std::atan2(dy, dx);
|
||||
@@ -33,7 +34,7 @@ int main() {
|
||||
}
|
||||
for (int j = 0; j < i; ++j) {
|
||||
const auto& other = layout.buttons[j];
|
||||
check(std::hypot(b.x - other.x, b.y - other.y) > 1.05f * (b.radius + other.radius),
|
||||
check(std::hypot(b.x - other.x, b.y - other.y) > 1.15f * (b.radius + other.radius),
|
||||
"expanded touch areas cannot activate a neighboring control");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user