Skip to main content

add_piece

Function add_piece 

Source
fn add_piece(
    parent: &EndCityPiece,
    offset: IVec3,
    template_name: &str,
    rotation: Rotation,
    overwrite: bool,
) -> EndCityPiece
Expand description

Vanilla’s addPiece. With pivot=ZERO and mirror=NONE, calculateConnectedPosition reduces to rotate(offset, parent.rotation) added to the parent’s template position.