mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-22 03:07:04 +02:00
feat: initial turret rotation
This commit is contained in:
1 parent
d408df8b4c
commit
c10060decc
5 files changed
+97
-36
No files matched your search
+28
-22
@@ -97,9 +97,8 @@ type ShellDefinitionsList = Record<
|
||||
interface VehicleDefinitions {
|
||||
invisibility: { moving: number; still: number; firePenalty: number };
|
||||
hull: {
|
||||
turretPositions: {
|
||||
turret: string;
|
||||
};
|
||||
turretPositions: { turret: string };
|
||||
turretInitialRotation?: { yaw: 0; pitch: 6.5; roll: 0 };
|
||||
};
|
||||
turrets0: {
|
||||
[key: string]: {
|
||||
@@ -250,6 +249,13 @@ if (allTargets || targets?.includes('definitions')) {
|
||||
|
||||
modelDefinitions[tankId] = {
|
||||
turretOrigin,
|
||||
turretRotation: tankDefinition.root.hull.turretInitialRotation
|
||||
? {
|
||||
yaw: tankDefinition.root.hull.turretInitialRotation.yaw,
|
||||
pitch: tankDefinition.root.hull.turretInitialRotation.pitch,
|
||||
roll: tankDefinition.root.hull.turretInitialRotation.roll,
|
||||
}
|
||||
: undefined,
|
||||
turrets: {},
|
||||
};
|
||||
|
||||
@@ -409,25 +415,25 @@ if (allTargets || targets?.includes('definitions')) {
|
||||
);
|
||||
|
||||
console.log('Committing definitions...');
|
||||
// await commitMultipleFiles(
|
||||
// 'tresabhi',
|
||||
// 'blitzkrieg-assets',
|
||||
// 'main',
|
||||
// 'definitions',
|
||||
// [
|
||||
// {
|
||||
// content: JSON.stringify(tankDefinitions),
|
||||
// encoding: 'utf-8',
|
||||
// path: 'definitions/tanks.json',
|
||||
// },
|
||||
// {
|
||||
// content: JSON.stringify(modelDefinitions),
|
||||
// encoding: 'utf-8',
|
||||
// path: 'definitions/models.json',
|
||||
// },
|
||||
// ],
|
||||
// true,
|
||||
// );
|
||||
await commitMultipleFiles(
|
||||
'tresabhi',
|
||||
'blitzkrieg-assets',
|
||||
'main',
|
||||
'definitions',
|
||||
[
|
||||
{
|
||||
content: JSON.stringify(tankDefinitions),
|
||||
encoding: 'utf-8',
|
||||
path: 'definitions/tanks.json',
|
||||
},
|
||||
{
|
||||
content: JSON.stringify(modelDefinitions),
|
||||
encoding: 'utf-8',
|
||||
path: 'definitions/models.json',
|
||||
},
|
||||
],
|
||||
true,
|
||||
);
|
||||
}
|
||||
|
||||
if (
|
||||
|
||||
Reference in new issue
Block a user