Fix creating new Unity things

This commit is contained in:
Pascal Serrarens 2025-05-09 17:08:11 +02:00
parent e7bef66b8e
commit 71939b9aa5

View File

@ -41,7 +41,7 @@ namespace RoboidControl.Unity {
// // before we can create the wheel reliably // // before we can create the wheel reliably
// break; // break;
case RoboidControl.Thing coreThing: case RoboidControl.Thing coreThing:
if (coreThing.component != null) { if (coreThing.component == null) {
Thing thing = Thing.Create(coreThing); Thing thing = Thing.Create(coreThing);
coreThing.component = thing; coreThing.component = thing;
} }