mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-24 03:59:50 +02:00
fix: only use gun masking when clipping plane is available
This commit is contained in:
1 parent
d679641c9d
commit
a53cf2111e
1 file changed
+4
-3
@@ -259,9 +259,10 @@ export const SpacedArmorScene = memo<SpacedArmorSceneProps>(({ scene }) => {
|
|||||||
</group>
|
</group>
|
||||||
|
|
||||||
{modelNodes.map((node) => {
|
{modelNodes.map((node) => {
|
||||||
const isCurrentGun = node.name.startsWith(
|
const gunString = `gun_${gunModelDefinition.model.toString().padStart(2, '0')}`;
|
||||||
`gun_${gunModelDefinition.model.toString().padStart(2, '0')}`,
|
const isCurrentGun = gunModelDefinition.mask
|
||||||
);
|
? node.name.startsWith(gunString)
|
||||||
|
: node.name === gunString;
|
||||||
const isVisible = isCurrentGun;
|
const isVisible = isCurrentGun;
|
||||||
|
|
||||||
if (!isVisible) return null;
|
if (!isVisible) return null;
|
||||||
|
|||||||
Reference in new issue
Block a user