0% found this document useful (0 votes)
8 views

Cell

The document defines a Java class named 'Cell' within the 'engine.board' package. It includes attributes for a Marble object, a CellType, and a boolean indicating if the cell is a trap. The class provides getter and setter methods for these attributes to manage the state of the cell.

Uploaded by

yusuf tarek
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views

Cell

The document defines a Java class named 'Cell' within the 'engine.board' package. It includes attributes for a Marble object, a CellType, and a boolean indicating if the cell is a trap. The class provides getter and setter methods for these attributes to manage the state of the cell.

Uploaded by

yusuf tarek
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

package engine.

board;

import model.player.Marble;

public class Cell {

■private Marble marble;


■private CellType cellType;
■private boolean trap;

■public Cell(CellType cellType){
■■this.cellType = cellType;
■■this.trap = false;
■■this.marble = null;
■}

■public Marble getMarble() {


■■return marble;
■}

■public void setMarble(Marble marble) {


■■this.marble = marble;
■}

■public CellType getCellType() {


■■return cellType;
■}

■public void setCellType(CellType cellType) {


■■this.cellType = cellType;
■}

■public boolean isTrap() {


■■return trap;
■}

■public void setTrap(boolean trap) {


■■this.trap = trap;
■}
}

You might also like