Greetings,
At the end of the game, cards must be scored in the "stRoundEnd" function.
Each player has their own hand from
I've written out pseudo-code for how I want to handle the scoring logic, but it relies on the type_arg values of all the cards from players' hands being stuffed into individual arrays.
Foreach player, Foreach card in hand, I want to push that 'type_arg' value into an array so that I can handle the scoring logic on the array instead of a player hand with card objects.
Anybody have an example project I could reference or some guidance on converting cards in hand to an array of values? Much obliged friends, cheers.
At the end of the game, cards must be scored in the "stRoundEnd" function.
Each player has their own hand from
Code: Select all
$this->cards->getCardsInLocation($player_id); Foreach player, Foreach card in hand, I want to push that 'type_arg' value into an array so that I can handle the scoring logic on the array instead of a player hand with card objects.
Anybody have an example project I could reference or some guidance on converting cards in hand to an array of values? Much obliged friends, cheers.