Skip to content
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
package model;
import view.*;
public class DoodadTile extends Tile
{
private static DoodadStack _doodadStack;
public DoodadTile(String name, int boardIndex)
{
super(name, boardIndex);
_doodadStack = new DoodadStack();
}
@Override
public void getLandedOn(Player p)
{
FinancialStatement f = p.getFinancialStatement();
DoodadCard dc = _doodadStack.pickCard();
DoodadCardWindow DoodadCardWindow = new DoodadCardWindow();
DoodadCardWindow.showButtonDemo();
int amount = dc.getValue();
if (f.getCashBalance() > amount)
{
f.increaseCashBalance(-amount);
}
else if(f.getCashBalance() < amount)
{
f.setCashBalance(0);
}
// Pop next card
// Get cash out from card
// Check if player has enough money to pay in full
// If yes: Take cash from player
// Otherwise set players cash balance to 0
}
}