Examples of Card


Examples of com.threerings.parlor.card.data.Card

     */
    protected Card pickRandomPlayableCard (Hand hand)
    {
        List<Card> playableCards = Lists.newArrayList();
        for (int ii = 0; ii < hand.size(); ii++) {
            Card card = hand.get(ii);
            if (_trickCardGame.isCardPlayable(hand, card)) {
                playableCards.add(card);
            }
        }
        return RandomUtil.pickRandom(playableCards);
View Full Code Here

Examples of com.zonga.supapuker.model.Card

        addOneCardInBlueAndRedOfEachValues(4, 5, 6, 7, 8, 9, 10);
    }

    private void addOneCardInBlueAndRedWithValue(int value, int howManyTimes) {
        for (int i = 0; i < howManyTimes; i++) {
            add(new Card(PGCardColor.BLUE, value));
            add(new Card(PGCardColor.RED, value));
        }
    }
View Full Code Here

Examples of communist.poker.Card

  private void refresh_hand(boolean force) {
    System.out.println("refreshing hand force: " + force);
    for (int i = 0; i < 5; i++) {
      if (force || !holds.contains(new Integer(i))) {
        Card c = cards.draw_card();
        hand[i].update_card(c);
        hand_hold[i].setBackground(Color.GRAY);
      }
    }
    holds = new ArrayList<Integer>();
View Full Code Here

Examples of csa.jportal.card.Card

    void buildLeafForCommunication()
    {
        // for now -> only Mana Payment
        ManaPayment mana = pendingCommunication.manaExpected;
        Card card = pendingCommunication.E.mInitiatorCard;
        if (mana.paymentType == ManaPayment.MP_TRIGGER_ACTIVATE_CARD)
        {
            // only spontanous Mana supported as yet
            EAIAction ret;
            ManaCollection cost = ManaCollection.getCost(mana);
View Full Code Here

Examples of data_model.card

      ps_getCards.setBoolean(3, y);
      ResultSet rs = ps_getCards.executeQuery();
      ArrayList<card> Cards = new ArrayList<card>();
      while (rs.next())
      {
        Cards.add(new card(rs.getInt(1), rs.getInt(2), rs.getInt(3), rs.getInt(4), rs.getInt(5), rs.getInt(6), rs.getInt(7), rs.getString(8), rs.getString(9), rs.getBoolean(10)));
      }
      logger.log(Level.INFO, "Karteninformation des Spieler mit der ID " + id + " erfolgreich ausgelesen");
      return Cards;
    }
    catch (SQLException exception)
View Full Code Here

Examples of edu.villanova.studs.poker.transport.Card

        TableDataIntf td = new TableDataCommunity();
        Hashtable<String, Object> opts = new Hashtable<String, Object>();
        Locale.setDefault( Locale.GERMAN );
        try {
            Player p = new Player();
            p.addCard( new Card(1,1) );
            p.addCard( new Card(1,2) );
            td.addPlayer( p );
            td.addPlayer( new Player() );
        } catch (TransportException e) {
          e.printStackTrace(System.out);
            CalcEngineException ex = new CalcEngineException( "My message" , e);
View Full Code Here

Examples of factOrFiction.model.Card

    }
   
    CardGroup group = deck.main;
   
    for (Iterator<Card> iter = cards.iterator(); iter.hasNext();) {
      Card card = iter.next();
      String genericType = card.getGenericType();
     
      if(genericType == null) {
        group = deck.main;
      }
      else  {
View Full Code Here

Examples of fi.luomus.commons.containers.Card

public class CardTests {

  @Test
  public void test() {
    Card card = new Card("1234567");
    Assert.assertEquals("1", card.v(1));
    Assert.assertEquals("12", card.v(1, 2));
    Assert.assertEquals("1234567", card.v(1, 7));
    Assert.assertEquals("1234567", card.v(1, 8));
    Assert.assertEquals("1234567", card.v(1, 200));
    Assert.assertEquals("234567", card.v(2, 200));
    Assert.assertEquals("7", card.v(7));
    Assert.assertEquals("7", card.v(7, 1));
    Assert.assertEquals("7", card.v(7, 2));
    Assert.assertEquals("7", card.v(7, 3));
    Assert.assertEquals("", card.v(8));
    Assert.assertEquals("", card.v(8, 2));
    Assert.assertEquals("", card.v(9, 200));
    Assert.assertEquals("", card.v(200, 300));
  }
View Full Code Here

Examples of game.Card

     * Makes sure the correct card is chosen normally
     */
    @Test
    public void testCheating()
    {
        Card cd = new Card(7, 's');
        PlayerController.previousCard = cd;
       
        Cheating cheat = new Cheating();
        Hand hand = new Hand(10);
        //System.out.println(hand);
        ArrayList<Card> cards = new ArrayList<Card>();
        cards.add(new Card(6, 'c'));
        cards.add(new Card(5, 'c'));
        cards.add(new Card(10, 'c'));
        cards.add(new Card(8, 'c'));
        cards.add(new Card(1, 'c'));
        cards.add(new Card(3, 'c'));
        cards.add(new Card(7, 'c'));
        hand.addCards(cards);
       
        assertEquals(cards.get(3), cheat.getNextCard(hand));
    }
View Full Code Here

Examples of general.Card

    Card[] cards = new Card[52];
    int pos = 0;
    for (Title t : Title.values())
    {
      for (Symbol symbol : Symbol.values()){
        cards[pos] = new Card(t, symbol);
        pos++;
      }
    }
    return cards;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.