Skip to content

Commit 61fd4fd

Browse files
committed
feat: building out multi-skull craniotomy system
1 parent 1103f31 commit 61fd4fd

File tree

3 files changed

+5
-29
lines changed

3 files changed

+5
-29
lines changed

Assets/Scripts/Craniotomy/CraniotomySkull.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,11 @@ public void Disable()
2626

2727
public void Enable()
2828
{
29-
for (int i = 0; i < 5; i++)
30-
skullRenderer.material.SetFloat(string.Format("_CraniotomySize_{0}", i), _craniotomySizes[i] / 2);
29+
if (skullRenderer != null)
30+
{
31+
for (int i = 0; i < 5; i++)
32+
skullRenderer.material.SetFloat(string.Format("_CraniotomySize_{0}", i), _craniotomySizes[i] / 2);
33+
}
3134
}
3235

3336
private void UpdateVisibility()

Assets/Scripts/Pinpoint/JSON/CraniotomyData.cs

Lines changed: 0 additions & 16 deletions
This file was deleted.

Assets/Scripts/Pinpoint/JSON/CraniotomyData.cs.meta

Lines changed: 0 additions & 11 deletions
This file was deleted.

0 commit comments

Comments
 (0)