Possibly improve color choices
This commit is contained in:
@ -12,20 +12,20 @@ mod zobrist;
|
||||
|
||||
|
||||
fn main() {
|
||||
/*
|
||||
let ruleset = Ruleset {
|
||||
n_slots: 11,
|
||||
n_suits: 5,
|
||||
n_cards_per_suit: 10,
|
||||
n_arcana: 25
|
||||
};
|
||||
*/
|
||||
/*
|
||||
let ruleset = Ruleset {
|
||||
n_slots: 11,
|
||||
n_suits: 4,
|
||||
n_cards_per_suit: 13,
|
||||
n_arcana: 22
|
||||
};
|
||||
*/
|
||||
/*
|
||||
let ruleset = Ruleset {
|
||||
n_slots: 5,
|
||||
|
@ -1,6 +1,6 @@
|
||||
use rand::{seq::SliceRandom, Rng};
|
||||
|
||||
use crate::ruleset::{Card, Setup};
|
||||
use crate::ruleset::{self, Card, Setup};
|
||||
|
||||
pub struct Deal {
|
||||
pub slots: Vec<Vec<Card>>,
|
||||
@ -53,7 +53,9 @@ impl Deal {
|
||||
shuffles = extra_shuf
|
||||
}
|
||||
}
|
||||
for _ in shuffles..2 {
|
||||
// TODO: Use this in the game too
|
||||
let max_shuffles = 2; // if setup.ruleset.n_suits < 5 { 2 } else { 1 };
|
||||
for _ in shuffles..max_shuffles {
|
||||
slots.choose_mut(rng).unwrap().shuffle(rng);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user