flame icon indicating copy to clipboard operation
flame copied to clipboard

Convert Component.positionType into a mixin

Open st-pasha opened this issue 3 years ago • 3 comments

Given that .positionType is only used by 2 classes, I suggest moving this field out of the main Component class into a separate mixin. This would reduce the complexity of the class somewhat, and also its size.

st-pasha avatar Mar 04 '22 22:03 st-pasha

It's only used by two of our classes, but removing it increases the complexity for our users, since it is used a lot by them. I also don't think an enum is as expensive as an object, but that should be investigated.

spydon avatar Mar 04 '22 23:03 spydon

but removing it increases the complexity for our users, since it is used a lot by them.

Can you give me an example of how it is used by the users? I thought it was mostly for the internal event processing logic.

st-pasha avatar Mar 08 '22 19:03 st-pasha

Can you give me an example of how it is used by the users? I thought it was mostly for the internal event processing logic.

People mostly use it to build huds from other components.

spydon avatar Mar 08 '22 22:03 spydon

Not valid anymore with the use of the CameraComponent.

spydon avatar Sep 11 '23 19:09 spydon