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 java.util.Random;
public class Die {
/*
* Die will probably have to go in each individual turn, so that it can pull charity status
* from the player currently playing
*/
public int rollDice(Boolean c) {
Random rand = new Random();
//if statement for downsize first
//if statement for charity next
//then do the rest
if (c) {
int face = 1+rand.nextInt(12);
return face;
/* There needs to be something that takes charity - 1 from the player after rolling
* Or maybe just a simple "if charity > 0 then charity - 1 after every turn
*/
}
else {
int face = 1+rand.nextInt(6);
return face;
}
}
}