null check on greedy joker

This commit is contained in:
cellos51
2025-07-22 20:07:51 -04:00
parent 0e40dc43f7
commit c025d35468
+1 -1
View File
@@ -71,7 +71,7 @@ JokerEffect joker_get_score_effect(Joker *joker, Card *scored_card)
effect.mult = 4; effect.mult = 4;
break; break;
case GREEDY_JOKER_ID: // Greedy Joker case GREEDY_JOKER_ID: // Greedy Joker
if (scored_card->suit == DIAMONDS) // If the scored card is a diamond if (scored_card != NULL && scored_card->suit == DIAMONDS) // If the scored card is a diamond
{ {
effect.mult = 3; effect.mult = 3;
} }