mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 19:49:50 +02:00
feat: add 124 support
This commit is contained in:
1 parent
c964e3c8ec
commit
1879895db2
13 files changed
+62
-5
No files matched your search
@@ -27,3 +27,4 @@ target
|
|||||||
/.vercel
|
/.vercel
|
||||||
/.astro
|
/.astro
|
||||||
.vercel
|
.vercel
|
||||||
|
/src
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
# BlitzKit 1.27.2
|
||||||
|
|
||||||
|
This update only affects the website.
|
||||||
|
|
||||||
|
## Fixes
|
||||||
|
|
||||||
|
- The new Improved Vertical Stabilizer equipment which only affects the gun depression found on the Type 63 now works
|
||||||
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "blitzkit",
|
"name": "blitzkit",
|
||||||
"private": true,
|
"private": true,
|
||||||
"version": "1.27.1",
|
"version": "1.27.2",
|
||||||
"description": "🎉 Tools for everything World of Tanks Blitz",
|
"description": "🎉 Tools for everything World of Tanks Blitz",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"types": "./types.d.ts",
|
"types": "./types.d.ts",
|
||||||
|
|||||||
@@ -180,6 +180,11 @@ export const StaticArmor = memo<ArmorSceneProps>(({ thicknessRange }) => {
|
|||||||
duel.protagonist.tank.equipment_preset,
|
duel.protagonist.tank.equipment_preset,
|
||||||
duel.protagonist.equipmentMatrix,
|
duel.protagonist.equipmentMatrix,
|
||||||
);
|
);
|
||||||
|
const hasDownImprovedVerticalStabilizer = await hasEquipment(
|
||||||
|
124,
|
||||||
|
duel.protagonist.tank.equipment_preset,
|
||||||
|
duel.protagonist.equipmentMatrix,
|
||||||
|
);
|
||||||
const boundingRect = canvas.getBoundingClientRect();
|
const boundingRect = canvas.getBoundingClientRect();
|
||||||
|
|
||||||
delta.set(event.clientX, event.clientY).sub(position);
|
delta.set(event.clientX, event.clientY).sub(position);
|
||||||
@@ -191,6 +196,7 @@ export const StaticArmor = memo<ArmorSceneProps>(({ thicknessRange }) => {
|
|||||||
gunModelDefinition.pitch,
|
gunModelDefinition.pitch,
|
||||||
turretModelDefinition.yaw,
|
turretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
modelTransformEvent.emit({ pitch, yaw });
|
modelTransformEvent.emit({ pitch, yaw });
|
||||||
}
|
}
|
||||||
@@ -275,6 +281,11 @@ export const StaticArmor = memo<ArmorSceneProps>(({ thicknessRange }) => {
|
|||||||
duel.protagonist.tank.equipment_preset,
|
duel.protagonist.tank.equipment_preset,
|
||||||
duel.protagonist.equipmentMatrix,
|
duel.protagonist.equipmentMatrix,
|
||||||
);
|
);
|
||||||
|
const hasDownImprovedVerticalStabilizer = await hasEquipment(
|
||||||
|
124,
|
||||||
|
duel.protagonist.tank.equipment_preset,
|
||||||
|
duel.protagonist.equipmentMatrix,
|
||||||
|
);
|
||||||
const boundingRect = canvas.getBoundingClientRect();
|
const boundingRect = canvas.getBoundingClientRect();
|
||||||
delta.set(event.clientX, event.clientY).sub(position);
|
delta.set(event.clientX, event.clientY).sub(position);
|
||||||
position.set(event.clientX, event.clientY);
|
position.set(event.clientX, event.clientY);
|
||||||
@@ -285,6 +296,7 @@ export const StaticArmor = memo<ArmorSceneProps>(({ thicknessRange }) => {
|
|||||||
gunModelDefinition.pitch,
|
gunModelDefinition.pitch,
|
||||||
turretModelDefinition.yaw,
|
turretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
modelTransformEvent.emit({ pitch, yaw });
|
modelTransformEvent.emit({ pitch, yaw });
|
||||||
}
|
}
|
||||||
@@ -357,6 +369,11 @@ export const StaticArmor = memo<ArmorSceneProps>(({ thicknessRange }) => {
|
|||||||
duel.protagonist.tank.equipment_preset,
|
duel.protagonist.tank.equipment_preset,
|
||||||
duel.protagonist.equipmentMatrix,
|
duel.protagonist.equipmentMatrix,
|
||||||
);
|
);
|
||||||
|
const hasDownImprovedVerticalStabilizer = await hasEquipment(
|
||||||
|
124,
|
||||||
|
duel.protagonist.tank.equipment_preset,
|
||||||
|
duel.protagonist.equipmentMatrix,
|
||||||
|
);
|
||||||
const boundingRect = canvas.getBoundingClientRect();
|
const boundingRect = canvas.getBoundingClientRect();
|
||||||
delta.set(event.clientX, event.clientY).sub(position);
|
delta.set(event.clientX, event.clientY).sub(position);
|
||||||
position.set(event.clientX, event.clientY);
|
position.set(event.clientX, event.clientY);
|
||||||
@@ -367,6 +384,7 @@ export const StaticArmor = memo<ArmorSceneProps>(({ thicknessRange }) => {
|
|||||||
gunModelDefinition.pitch,
|
gunModelDefinition.pitch,
|
||||||
turretModelDefinition.yaw,
|
turretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
modelTransformEvent.emit({ pitch, yaw });
|
modelTransformEvent.emit({ pitch, yaw });
|
||||||
}
|
}
|
||||||
|
|||||||
+3
-1
@@ -107,6 +107,7 @@ export function Characteristics() {
|
|||||||
const hasSupercharger = useEquipment(107);
|
const hasSupercharger = useEquipment(107);
|
||||||
const hasCalibratedShells = useEquipment(103);
|
const hasCalibratedShells = useEquipment(103);
|
||||||
const hasImprovedVerticalStabilizer = useEquipment(122);
|
const hasImprovedVerticalStabilizer = useEquipment(122);
|
||||||
|
const hasDownImprovedVerticalStabilizer = useEquipment(124);
|
||||||
const penetrationCoefficient = coefficient([
|
const penetrationCoefficient = coefficient([
|
||||||
hasCalibratedShells,
|
hasCalibratedShells,
|
||||||
resolvePenetrationCoefficient(true, shell.type) - 1,
|
resolvePenetrationCoefficient(true, shell.type) - 1,
|
||||||
@@ -129,9 +130,10 @@ export function Characteristics() {
|
|||||||
gunModelDefinition.pitch,
|
gunModelDefinition.pitch,
|
||||||
turretModelDefinition.yaw,
|
turretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
}, [hasImprovedVerticalStabilizer]);
|
}, [hasImprovedVerticalStabilizer, hasDownImprovedVerticalStabilizer]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Flex
|
<Flex
|
||||||
|
|||||||
+3
@@ -25,6 +25,7 @@ export function QuickInputs() {
|
|||||||
const initialGunPitch =
|
const initialGunPitch =
|
||||||
tankModelDefinition.initial_turret_rotation?.pitch ?? 0;
|
tankModelDefinition.initial_turret_rotation?.pitch ?? 0;
|
||||||
const hasImprovedVerticalStabilizer = useEquipment(122);
|
const hasImprovedVerticalStabilizer = useEquipment(122);
|
||||||
|
const hasDownImprovedVerticalStabilizer = useEquipment(124);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (!yawInput.current) return;
|
if (!yawInput.current) return;
|
||||||
@@ -92,6 +93,7 @@ export function QuickInputs() {
|
|||||||
gunModelDefinition.pitch,
|
gunModelDefinition.pitch,
|
||||||
turretModelDefinition.yaw,
|
turretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
modelTransformEvent.emit({ pitch, yaw });
|
modelTransformEvent.emit({ pitch, yaw });
|
||||||
mutateDuel((state) => {
|
mutateDuel((state) => {
|
||||||
@@ -133,6 +135,7 @@ export function QuickInputs() {
|
|||||||
gunModelDefinition.pitch,
|
gunModelDefinition.pitch,
|
||||||
turretModelDefinition.yaw,
|
turretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
modelTransformEvent.emit({ pitch, yaw });
|
modelTransformEvent.emit({ pitch, yaw });
|
||||||
mutateDuel((state) => {
|
mutateDuel((state) => {
|
||||||
|
|||||||
+7
@@ -118,6 +118,11 @@ export function Controls({ naked }: ControlsProps) {
|
|||||||
duel.protagonist.tank.equipment_preset,
|
duel.protagonist.tank.equipment_preset,
|
||||||
duel.protagonist.equipmentMatrix,
|
duel.protagonist.equipmentMatrix,
|
||||||
);
|
);
|
||||||
|
const hasDownImprovedVerticalStabilizer = await hasEquipment(
|
||||||
|
124,
|
||||||
|
duel.protagonist.tank.equipment_preset,
|
||||||
|
duel.protagonist.equipmentMatrix,
|
||||||
|
);
|
||||||
|
|
||||||
switch (event) {
|
switch (event) {
|
||||||
case Pose.HullDown: {
|
case Pose.HullDown: {
|
||||||
@@ -127,6 +132,7 @@ export function Controls({ naked }: ControlsProps) {
|
|||||||
protagonistGunModelDefinition.pitch,
|
protagonistGunModelDefinition.pitch,
|
||||||
protagonistTurretModelDefinition.yaw,
|
protagonistTurretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
|
|
||||||
camera.position
|
camera.position
|
||||||
@@ -159,6 +165,7 @@ export function Controls({ naked }: ControlsProps) {
|
|||||||
protagonistGunModelDefinition.pitch,
|
protagonistGunModelDefinition.pitch,
|
||||||
protagonistTurretModelDefinition.yaw,
|
protagonistTurretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
|
|
||||||
camera.position
|
camera.position
|
||||||
|
|||||||
+12
@@ -185,6 +185,11 @@ export function TankModel() {
|
|||||||
duel.protagonist.tank.equipment_preset,
|
duel.protagonist.tank.equipment_preset,
|
||||||
duel.protagonist.equipmentMatrix,
|
duel.protagonist.equipmentMatrix,
|
||||||
);
|
);
|
||||||
|
const hasDownImprovedVerticalStabilizer = await hasEquipment(
|
||||||
|
124,
|
||||||
|
duel.protagonist.tank.equipment_preset,
|
||||||
|
duel.protagonist.equipmentMatrix,
|
||||||
|
);
|
||||||
const boundingRect = canvas.getBoundingClientRect();
|
const boundingRect = canvas.getBoundingClientRect();
|
||||||
|
|
||||||
delta.set(event.clientX, event.clientY).sub(position);
|
delta.set(event.clientX, event.clientY).sub(position);
|
||||||
@@ -196,6 +201,7 @@ export function TankModel() {
|
|||||||
gunModelDefinition.pitch,
|
gunModelDefinition.pitch,
|
||||||
turretModelDefinition.yaw,
|
turretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
modelTransformEvent.emit({ pitch, yaw });
|
modelTransformEvent.emit({ pitch, yaw });
|
||||||
}
|
}
|
||||||
@@ -287,6 +293,11 @@ export function TankModel() {
|
|||||||
duel.protagonist.tank.equipment_preset,
|
duel.protagonist.tank.equipment_preset,
|
||||||
duel.protagonist.equipmentMatrix,
|
duel.protagonist.equipmentMatrix,
|
||||||
);
|
);
|
||||||
|
const hasDownImprovedVerticalStabilizer = await hasEquipment(
|
||||||
|
124,
|
||||||
|
duel.protagonist.tank.equipment_preset,
|
||||||
|
duel.protagonist.equipmentMatrix,
|
||||||
|
);
|
||||||
const boundingRect = canvas.getBoundingClientRect();
|
const boundingRect = canvas.getBoundingClientRect();
|
||||||
delta.set(event.clientX, event.clientY).sub(position);
|
delta.set(event.clientX, event.clientY).sub(position);
|
||||||
position.set(event.clientX, event.clientY);
|
position.set(event.clientX, event.clientY);
|
||||||
@@ -297,6 +308,7 @@ export function TankModel() {
|
|||||||
gunModelDefinition.pitch,
|
gunModelDefinition.pitch,
|
||||||
turretModelDefinition.yaw,
|
turretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
modelTransformEvent.emit({ pitch, yaw });
|
modelTransformEvent.emit({ pitch, yaw });
|
||||||
}
|
}
|
||||||
|
|||||||
+2
@@ -41,6 +41,7 @@ export const TankSandbox = forwardRef<HTMLCanvasElement, TankSandboxProps>(
|
|||||||
const mutateTankopediaEphemeral = TankopediaEphemeral.useMutation();
|
const mutateTankopediaEphemeral = TankopediaEphemeral.useMutation();
|
||||||
const canvas = useRef<HTMLCanvasElement>(null);
|
const canvas = useRef<HTMLCanvasElement>(null);
|
||||||
const hasImprovedVerticalStabilizer = useEquipment(122);
|
const hasImprovedVerticalStabilizer = useEquipment(122);
|
||||||
|
const hasDownImprovedVerticalStabilizer = useEquipment(124);
|
||||||
const protagonistGun = Duel.use((state) => state.protagonist.gun);
|
const protagonistGun = Duel.use((state) => state.protagonist.gun);
|
||||||
const protagonistTurret = Duel.use((state) => state.protagonist.turret);
|
const protagonistTurret = Duel.use((state) => state.protagonist.turret);
|
||||||
const mutateDuel = Duel.useMutation();
|
const mutateDuel = Duel.useMutation();
|
||||||
@@ -82,6 +83,7 @@ export const TankSandbox = forwardRef<HTMLCanvasElement, TankSandboxProps>(
|
|||||||
gunModelDefinition.pitch,
|
gunModelDefinition.pitch,
|
||||||
turretModelDefinition.yaw,
|
turretModelDefinition.yaw,
|
||||||
hasImprovedVerticalStabilizer,
|
hasImprovedVerticalStabilizer,
|
||||||
|
hasDownImprovedVerticalStabilizer,
|
||||||
);
|
);
|
||||||
|
|
||||||
modelTransformEvent.emit({ pitch, yaw });
|
modelTransformEvent.emit({ pitch, yaw });
|
||||||
|
|||||||
@@ -12,6 +12,7 @@ export function applyPitchYawLimits(
|
|||||||
pitchLimits: PitchLimits, // deg
|
pitchLimits: PitchLimits, // deg
|
||||||
yawLimits?: YawLimits, // deg
|
yawLimits?: YawLimits, // deg
|
||||||
verticalStabilizer = false,
|
verticalStabilizer = false,
|
||||||
|
downVerticalStabilizer = false,
|
||||||
) {
|
) {
|
||||||
let newPitch = pitch;
|
let newPitch = pitch;
|
||||||
let newYaw = yaw;
|
let newYaw = yaw;
|
||||||
@@ -22,7 +23,8 @@ export function applyPitchYawLimits(
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
const depressionBuff = verticalStabilizer ? degToRad(3) : 0;
|
const depressionBuff =
|
||||||
|
verticalStabilizer || downVerticalStabilizer ? degToRad(3) : 0;
|
||||||
const elevationBuff = verticalStabilizer ? degToRad(4) : 0;
|
const elevationBuff = verticalStabilizer ? degToRad(4) : 0;
|
||||||
let lowerPitch = -degToRad(pitchLimits.max) - depressionBuff;
|
let lowerPitch = -degToRad(pitchLimits.max) - depressionBuff;
|
||||||
let upperPitch = -degToRad(pitchLimits.min) + elevationBuff;
|
let upperPitch = -degToRad(pitchLimits.min) + elevationBuff;
|
||||||
|
|||||||
@@ -109,6 +109,7 @@ export function tankCharacteristics(
|
|||||||
const hasEngineAccelerator = equipment(117);
|
const hasEngineAccelerator = equipment(117);
|
||||||
const hasCamouflageNet = equipment(115);
|
const hasCamouflageNet = equipment(115);
|
||||||
const hasImprovedVerticalStabilizer = equipment(122);
|
const hasImprovedVerticalStabilizer = equipment(122);
|
||||||
|
const hasDownImprovedVerticalStabilizer = equipment(124);
|
||||||
const hasImprovedSuspension = equipment(123);
|
const hasImprovedSuspension = equipment(123);
|
||||||
|
|
||||||
const hasTungsten = consumable(45);
|
const hasTungsten = consumable(45);
|
||||||
@@ -425,7 +426,8 @@ export function tankCharacteristics(
|
|||||||
const gunDepression =
|
const gunDepression =
|
||||||
gunModelDefinition.pitch.max +
|
gunModelDefinition.pitch.max +
|
||||||
gunDefaultPitch +
|
gunDefaultPitch +
|
||||||
(hasImprovedVerticalStabilizer ? 3 : 0);
|
(hasImprovedVerticalStabilizer ? 3 : 0) +
|
||||||
|
(hasDownImprovedVerticalStabilizer ? 3 : 0);
|
||||||
const gunElevation =
|
const gunElevation =
|
||||||
-gunModelDefinition.pitch.min -
|
-gunModelDefinition.pitch.min -
|
||||||
gunDefaultPitch +
|
gunDefaultPitch +
|
||||||
|
|||||||
Submodule
+1
Submodule submodules/CUE4Parse added at 624e07c8c3.
Submodule submodules/blitzkit-closed updated: c1d631764f...31937a9f1e.
Reference in new issue
Block a user