write
Called when the entity is saved.
Put any logic to save the data in the entity here.
Do not assume that when this is called, the entity is being unloaded. This may be called for other reasons, such as when a player right clicks with DebugWaxedWeatheredCutCopperStairs