@andreabiagini5/applicazioni-e-servizi-web-project - v1.1.3
    Preparing search index...

    Interface Cell

    Entity representing a single board cell.

    interface Cell {
        pile?: Pile;
        addGrain(player: string): void;
        collapse(): void;
    }
    Index

    Properties

    Methods

    Properties

    pile?: Pile

    The pile contained in the cell.

    Methods

    • Adds a grain and claims the pile.

      Parameters

      • player: string

        the player who is adding the grain.

      Returns void

    • If the cell contains a pile with 4 grains, the pile is deleted, if the pile contains more than 4 grains, 4 grains are removed and the remaining are left.

      Returns void