mirror of
https://github.com/tobspr/shapez.io.git
synced 2025-12-13 10:11:50 +00:00
Make wired pins component optional on the storage
This commit is contained in:
parent
48adc30a87
commit
0540a010a6
@ -50,8 +50,13 @@ export class StorageSystem extends GameSystemWithFilter {
|
||||
let targetAlpha = storageComp.storedCount > 0 ? 1 : 0;
|
||||
storageComp.overlayOpacity = lerp(storageComp.overlayOpacity, targetAlpha, 0.05);
|
||||
|
||||
pinsComp.slots[0].value = storageComp.storedItem;
|
||||
pinsComp.slots[1].value = storageComp.getIsFull() ? BOOL_TRUE_SINGLETON : BOOL_FALSE_SINGLETON;
|
||||
// a wired pins component is not guaranteed, but if its there, set the value
|
||||
if (pinsComp) {
|
||||
pinsComp.slots[0].value = storageComp.storedItem;
|
||||
pinsComp.slots[1].value = storageComp.getIsFull()
|
||||
? BOOL_TRUE_SINGLETON
|
||||
: BOOL_FALSE_SINGLETON;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user