Transform/Transforms = the position, rotation and scale of the object.
Instance = an object in layout
Prefab = Template object
What are Prefabs/Templates? -
prefab acts as a template from which you can create new object instances in the scene. Any edits made to a prefab asset are immediately reflected in all instances produced from it but you can also override components (behaviours variables) and settings(transforms/FX/instance variables) for each instance individually.
it should be work in tandem with having a scene graph structure (parent-child objects)
Don't Containers and Families do a similar job? -
short answer -> NO and YES (to both in their aspects).
it can have
bullet point answer -> for the following reasons;
- Can't save multiple instances of the same objects as separate containers/objects like you would be able to with for e.g multiple instances of tilemaps for level chunks.
- can't make a container with families that contains multiple types of objects e,g particles + sprite = NOPE
- containers don't act as a single object that can have behaviours
- can't have multiple of the same objects e.g glass shards in a window glass object
- currently no way to have the object transforms to be offset by a container object unless by using the pin behaviour or setting up a solution via eventsheets.
- No ability to change the object transforms in a container without changing them individually
- no ability to get expressions from objects in a container (like Container.sprite.Angle).
- no ability to set if objects are set to offset against a prefab
What difference would it make? -
- this would make create more interactive objects in a game maps.
- ability to reuse for Procedural Generated games (Tile maps, Enemy objects, bushes)
- composites of objects in a prefab (Treasure Chest surrounded by rock objects - as a single prefab object)
- Bullet prefab that contains bullets that are set in different angles, giving the ability to do quirky stuff with bullets.
- Possible Stretch goals -
- possibly make families out of prefabs too.
- possibly make prefabs from event sheets?
- potentially have the ability to have nested prefabs too unlike unity (Prefabs within a Prefab)