fix: i18n의 타입 수정
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { FLIGHT_STARFIELD_TUNING } from '@/shared/config/starfield';
|
||||
import { clamp, randomInRange } from '@/shared/lib/math/number';
|
||||
import { FLIGHT_STARFIELD_TUNING } from "@/shared/config/starfield";
|
||||
import { clamp, randomInRange } from "@/shared/lib/math/number";
|
||||
|
||||
import { FlightStar } from '@/features/flight-starfield/model/types';
|
||||
import { FlightStar } from "@/features/flight-starfield/model/types";
|
||||
|
||||
export const getFlightStarCount = (width: number, height: number) => {
|
||||
const isMobile = width < FLIGHT_STARFIELD_TUNING.mobileBreakpoint;
|
||||
@@ -11,7 +11,9 @@ export const getFlightStarCount = (width: number, height: number) => {
|
||||
const max = isMobile
|
||||
? FLIGHT_STARFIELD_TUNING.starCount.mobile.max
|
||||
: FLIGHT_STARFIELD_TUNING.starCount.desktop.max;
|
||||
const byArea = Math.round((width * height) / FLIGHT_STARFIELD_TUNING.densityDivisor);
|
||||
const byArea = Math.round(
|
||||
(width * height) / FLIGHT_STARFIELD_TUNING.densityDivisor,
|
||||
);
|
||||
|
||||
return clamp(byArea, min, max);
|
||||
};
|
||||
@@ -51,7 +53,8 @@ const createFlightSpeed = () => {
|
||||
};
|
||||
|
||||
const createFlightVisualTier = () => {
|
||||
const highlight = Math.random() < FLIGHT_STARFIELD_TUNING.radius.highlightChance;
|
||||
const highlight =
|
||||
Math.random() < FLIGHT_STARFIELD_TUNING.radius.highlightChance;
|
||||
const tailRoll = Math.random();
|
||||
const tailLength =
|
||||
tailRoll < FLIGHT_STARFIELD_TUNING.tail.pointChance
|
||||
@@ -95,7 +98,8 @@ const createFlightVisualTier = () => {
|
||||
const createFlightSpawnRadius = (width: number, height: number) => {
|
||||
const roll = Math.random();
|
||||
const maxWideRadius = Math.min(
|
||||
Math.max(width, height) * FLIGHT_STARFIELD_TUNING.spawnRadius.wideRange.maxScaleOfViewport,
|
||||
Math.max(width, height) *
|
||||
FLIGHT_STARFIELD_TUNING.spawnRadius.wideRange.maxScaleOfViewport,
|
||||
FLIGHT_STARFIELD_TUNING.spawnRadius.wideRange.maxAbsolute,
|
||||
);
|
||||
const ringOuter = Math.min(
|
||||
|
||||
Reference in New Issue
Block a user