Terasology / DynamicCities

Cities that get fancy!
17 stars 13 forks source link

refactor: component field visibility public #112

Closed jdrueckert closed 9 months ago

jdrueckert commented 10 months ago

Newer Java versions are stricter with regards to access restrictions when using reflection. This affects in particular the serialization of non-public fields in our component classes. For this reason, we decided to exclude non-public component fields from serialization and refactor all non-public component fields to be public instead to ensure not breaking any game and especially saving/loading behavior.

A future module overhaul may have a more detailed look into the components and make considerate decisions to use non-public fields.

Relates to https://github.com/MovingBlocks/Terasology/pull/5191

jdrueckert commented 9 months ago

Failing integration tests were failing before. Merging despite unsuccessful checks.