package com.mycompany.app;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

@Setter
@Getter
@AllArgsConstructor
@NoArgsConstructor
public class Crupier extends Usuario {
    private String nombreCasino = "Casino de Lima";
    private Baraja baraja = new Baraja();
    public void getBarajar() {
        baraja.barajar();
    }

    public Carta darCarta () {
        Carta carta;
        int n = (int) (Math.random() * (baraja.getCartas().size() - 1)) + 1;
        carta = baraja.getCartas().get(n);
        baraja.getCartas().remove(n);
        return carta;
    }
}
