]> Pileus Git - ~andy/spades/blobdiff - src/org/pileus/spades/Spades.java
Fix null pointers and pile parsing
[~andy/spades] / src / org / pileus / spades / Spades.java
index 3c023c99b307580cbfbd1d7fa1d53d8d57476475..17eacfaa99259d8073d799e1a613d831751ebc82 100644 (file)
@@ -41,8 +41,8 @@ public class Spades
                        this.cards.hand = Spades.getCards(txt, "You have: (.*)");
                        this.cards.requestRender();
                }
-               if (txt.matches("turn!")) {
-                       this.cards.pile = Spades.getCards(txt, ".*turn! (.*)");
+               if (txt.matches(".*turn!.*")) {
+                       this.cards.pile = Spades.getCards(txt, ".*turn! \\((.*)\\)");
                        this.cards.requestRender();
                }
        }