Megafunk / MassSample

My understanding of Unreal Engine 5's experimental ECS plugin with a small sample project.
MIT License
681 stars 112 forks source link

Missing UPROPERTY and const keywords in some places #63

Open zompi2 opened 4 months ago

zompi2 commented 4 months ago
  1. There was no UPROPERTY() in the FLifeTimeFragment
  2. In UE 5.3.2 the BuildTemplate and ValidateTemplate requires const UWorld& instad of UWorld&
Megafunk commented 4 months ago

What does adding reflection to the float in FLifeTimeFragment help with exactly? I assume it's needed for hashing of some sort?

zompi2 commented 4 months ago

Actually I think it doesn't help with anything in particular, but in the next example the float Distance is marked as an UPROPERTY too and I thought it'd be good to keep things consistent.

vorixo commented 4 months ago

Hey @zompi2 the point on having divergent examples is to show that you are not forced to make the variables in fragments UPROPERTY(es).

zompi2 commented 4 months ago

Ok, I understand now. I removed that UPROPERTY. Just added an extra space, because for someone new (like myself) the GENERATED_BODY right over the variable looked odd :)