Skip to main content

damage

Function damage 

pub fn damage(
    previous: &Scene,
    previous_parts: &SectionParts,
    current: &Scene,
    current_parts: &SectionParts,
) -> Result<Vec<Rect>, Unproven>
Expand description

Damage, in section coordinates, between two frames of a section drawn with parts: the old and new bounds of every part whose commands changed (or what a hinted part’s hint says changed). Ok with no rects means the section is unchanged.

When the parts nested inside some part differ between the frames (a menu that opened inside an overlay drew a part of its own), the outermost parts are compared instead, each as a whole.