public class Field
extends java.lang.Object
Constructor and Description |
---|
Field(SlotView[][] field,
javafx.scene.canvas.Canvas gameCanvas)
Creates a Field.
|
Modifier and Type | Method and Description |
---|---|
SlotView |
get(int i,
int j)
Getter for field.
|
void |
set(int i,
int j,
SlotView slotView)
Places slotView on the given position of the field.
|
public Field(SlotView[][] field, javafx.scene.canvas.Canvas gameCanvas)
field
- the fieldgameCanvas
- the game canvaspublic SlotView get(int i, int j)
i
- rowj
- columnpublic void set(int i, int j, SlotView slotView)
i
- rowj
- columnslotView
- the item to place.