-
Notifications
You must be signed in to change notification settings - Fork 78
Description
I am working now for some time with this library, but recently I stumbled over a small detail which blocks my progress :
I am using properties on tiles and objects to mark in my level certain elements like keys, switches, switchable doors, enemies, etc. usually I add properties to these objects to customize the behavior.
I also want to use this principle for moving platforms and other decorations:
For example:

Here you see such a platform ("moving_platform") and its parameters(it will swing 40px up an down again). The advantage is that you can easily paint your level and even draw the paths of moving platforms and enemies inside the level editor.
But the problem is, that the code for rendering a part of the map is implemented in the Chunk class which is private to MapLayer.
From an Software architecture pov I would like to manage the moving platforms outside of the MapLayer, but then I cannot instantiate a Chunk. I cannot derive MapLayer nor Chunk as both are declared final(<--why?). Only possibility I see is to duplicate the code. But we are not using C++ to start to copy+paste methods into new classes, do we?
Would it be fine to make chunk public or the classes not final?
Or is there something else I miss?