1
0
mirror of https://github.com/tobspr/shapez.io.git synced 2025-06-13 13:04:03 +00:00

Fix paste constant

This commit is contained in:
FatCatX 2021-05-05 10:37:13 -07:00
parent 177f50bce8
commit 0753dc536e

View File

@ -36,6 +36,7 @@ export class SerializerInternal {
if (typeof result == "string") {
return result;
}
result.uid = serializedEntity.uid;
root.entityMgr.registerEntity(result, serializedEntity.uid);
root.map.placeStaticEntity(result);
}
@ -63,9 +64,7 @@ export class SerializerInternal {
rotationVariant: data.rotationVariant,
variant: data.variant,
});
entity.uid = payload.uid;
const errorStatus = this.deserializeComponents(root, entity, payload.components);
return errorStatus || entity;
@ -93,7 +92,9 @@ export class SerializerInternal {
}
const errorStatus = entity.components[componentId].deserialize(data[componentId], root);
return errorStatus;
if (errorStatus) {
return errorStatus;
}
}
}
}