Morphed beta
Interface of @v12-engine/engine
ts
export interface MorphedSomething that has just become another type where it stands (morph): a building upgraded, a unit transformed. Its new type's parts are set (stats, abilities, slots, and every Component.onSpawn of a part it did not have yet): what a pack gives it of its own for the type it is now, as the heroes pack makes a hero of what became a hero's type and stocks what became a shop. Run before the entityMorphed event
Members
entity
ts
readonly entity: Entity;What changed type, as it is now
from
ts
readonly from: string;The type it was