Bi tane varmıs arsivimde, calısması lazım makinede C yok su an :) Author : Pretty_Child & BypassGroup : kod27Email : pretty_child@turkstorm. org & root@turkh. org/ Phisti menu <-- Display menuabout <-- Display aboutinitCard <-- Initialize card ( assign 0 and NULL)generateCard <-- Generate a carddrawCards <-- Draw Closed CardcheckBeforeChosen <-- Check if card is chosen beforecalculatePoints <-- Calculates values of cards on the table, when one of player get a rounddrawClosedCards <-- Draw cards of computer closely, checkSame <-- Checks if two cards are same. wait <-- PauseplayComputer <-- Check cards and returns position of card that computer play. /#include < stdio. h >#include < stdlib. h >#include < time. h >#include < string. h >#include < conio. h >#include < assert. h >#define NAME_LEN 10 #define SIDE 186 / Defining a character will be used for drawing cards /#define MID 205 / Defining a character will be used for drawing cards /#define CARD_NUM 4#define TOTAL 52#define PISHTI 10#define SIZE 100#define NDEBUGenum ;typedef struct Card ;Card generateCard ;void drawCards ;int checkBeforeChosen ;void initCard ;int checkPlayedCard ;int calculatePoints ;void drawClosedCards ;void menu ;void about ;int checkSame ;int playComputer ;void wait ;void printCardNumber ;char printMessage ;void displayScores( int score1, int score2 ) ;void screen ;int searchCard ;void puanlama ;intmain {char choice ;char message;Card playerCards;Card computerCards ;Card deckCards;Card tableCards;Card chosenCards;short int i, j, k;short int totalUser, totalComputer, round, cardPosition, userScore, compScore, tableFlag, lastFlag, endPoint;message = calloc( SIZE, sizeof );playerCards = calloc( CARD_NUM, sizeof ;computerCards = calloc( CARD_NUM, sizeof ;deckCards = calloc( TOTAL, sizeof ;tableCards = calloc( TOTAL, sizeof ;chosenCards = calloc( TOTAL, sizeof ;strcpy ;menu ;do{choice = getchar ;fflush ;switch {case 'H':case 'h':about ;menu ;break;case 'P':case 'p':puanlama ;menu ;break ;case 'C':case 'c':printf ;exit( 1 ) ;case 'B':case 'b':system ;printf ;scanf ;fflush ;while( endPoint <= 0 || endPoint > 999 ) break ;default :printf ;break ;}}while ;userScore = 0 ;compScore = 0 ;srand( time );while {for( i = 0 ; i < TOTAL ; i++ ) wait( 40 );for ( i = 0 ; i < TOTAL ; i++ ){do while( checkBeforeChosen -1 );} i--;totalComputer = 0 ;totalUser = 0 ;for( j = 0 ; j < CARD_NUM ; j++ ) for( j = 0 ; j < CARD_NUM ; j++)for( k = j+1 ; k < CARD_NUM ; k++ )assert( ! checkSame && ! checkSame && ! checkSame );j = CARD_NUM - 1 ;k = j ;system ;round = 1 ;tableFlag = 1 ;lastFlag = -1 ;while( i >= 0 ){if( totalUser 0 && totalComputer 0 ){while if( i < 0 ) }screen ;if( round % 2 1 ) / User /{ printf ;printf ;scanf ;fflush ;while( cardPosition < 1 || cardPosition > totalUser ) if( tableFlag 1 ){tableCards = playerCards ;chosenCards = tableCards ;if( ( playerCards . num tableCards . num || playerCards . num 11 ) && j > 0 ){userScore += calculatePoints( tableCards, j+1 );printMessage ;do while( j >= 0 );j = 0; tableFlag = -1 ;lastFlag = USER ;}} else for playerCards = playerCards ;initCard( &playerCards );totalUser-- ;}else{printf ;wait( 200 ) ;cardPosition = playComputer ;if( tableFlag 1 ){tableCards = computerCards ;chosenCards = tableCards ;if( ( computerCards . num tableCards . num || computerCards . num 11 ) && j > 0 ){compScore += calculatePoints( tableCards, j+1 );printMessage ;do while( j >= 0 );j = 0; tableFlag = -1 ;lastFlag = COMPUTER;}}else for computerCards = computerCards ;initCard( &computerCards );totalComputer-- ;}round++ ;}if else system ;displayScores ;printf ;getch ;}system ;displayScores ;printf ;if printf ;else if printf ;elseprintf ;printf ;free ;free ;free ;free ;free ;free ;return ( 0 );}int searchCard int playComputer {short int i ;for( i = 0 ; i < total ; i++ )if return ;for( i = 0 ; i < total ; i++ )if( searchCard 3 && cards . num!= 11 )return ;for( i = 0 ; i < total ; i++ )if( searchCard >= 2 )return ;do while( lastCard->num 0 && cards . num 11 && total!= 1 );return ;}/ This function pause process for a while. This function was taken from web site /void wait void drawClosedCards {short int i, l ; / Local variables /putchar ;for( i = 0 ; i < cardNum ; i++ ) / Draw top of cards / putchar ;for( i = 0 ; i < cardNum ; i++ ) printf ;putchar ;for( i = 0 ; i < cardNum ; i++ )printf ; putchar ;for( i = 0 ; i < cardNum ; i++ )printf ; putchar ;for( i = 0 ; i < cardNum ; i++ )printf ; putchar ;for( i = 0 ; i < cardNum ; i++ )printf ; putchar ;for( i = 0 ; i < cardNum ; i++ )printf ; putchar ;for( i = 0 ; i < cardNum ; i++ )printf ; putchar ;for( i = 0 ; i < cardNum ; i++ )printf ;putchar ;for( i = 0 ; i < cardNum ; i++ )printf ;putchar ;for( i = 0 ; i < cardNum ; i++ ) printf ; putchar ;for( i = 0 ; i < cardNum ; i++ ) printf ; putchar ;for( i = 0 ; i < cardNum ; i++ )printf ;putchar ;for( i = 0 ; i < cardNum ; i++ ) printf ;putchar ;for( i=0;i < cardNum ; i++ ) putchar ;}/ Calculate the points of card which are on the table /int calculatePoints {short int i ;short int sum ;if( total 2 && cards . num cards . num && cards . num!= 11 ) / Phisti /return ;else if ( total 2 && cards . num cards . num && cards . num 11 ) / Phisti Jack /return( PISHTI 2 ) ;sum = 0 ;for( i = 0 ; i <= total ; i++ ) return ;}/ Check card if it was chosen before or not Return -1 if it was chosen before, else return 1 /int checkBeforeChosen int checkSame / Initialize the cards /void initCard / Generate Card /Card generateCard {short int randNum ;Card tempCard ;randNum = malloc( sizeof ) ; randNum = 1 + ( rand % 13 ) ;tempCard. num = randNum ; randNum = 1 + ( rand %4 ) ;switch free ;return ;}void printCardNumber / Draw Cards on the Screen /void drawCards {short int i, j ; / Local variables / putchar ;for( j = 0 ; j < total ; j++ ) putchar ; for( j = 0 ; j < total ; j++ ) putchar ;for( j = 0 ; j < total ; j++ )printf ; putchar ;for( j = 0 ; j < total ; j++ )printf ; putchar ;for( j = 0 ; j < total ; j++ ) putchar ;for( j = 0 ; j < total ; j++ ) putchar ;for( j = 0 ; j < total ; j++ ) putchar ;for( j = 0 ; j < total ; j++ )printf ;putchar ;for( j = 0 ; j < total ; j++ ) putchar ;for( j = 0 ; j < total ; j++ ) putchar ;for( j = 0 ; j < total ; j++ )printf ; putchar ;for( j = 0 ; j < total ; j++ ) printf ; putchar ;for( j = 0 ; j < total ; j++ ) putchar ;for( j = 0 ; j < total ; j++ ) putchar ;}/ This function only prints choices of main menu /void menu void about char printMessage void displayScores( int score1, int score2 ) void screen void puanlama %40 indirimli olarak "Centos Sistem ve Sunucu Ynetimi" adlı kitabımızı satın alarak, Linux üzerine yapılacak olan devam projeleri icin destekte bulunabilirsiniz : http://www.hepsiburada.com/centos-sistem-ve-sunucu-yonetimi-oku-izle-dinle-ogren-p-KKODLAB01579

Sen deve başla takıldığın yerde biz yardım ederiz. Kimsenin senin devini sıfırdan yapmasını beklemiyorsun herhalde? Bütün mesajlarım ve konularım BSD Lisansı"yla lisanslanmıştır.

hocam notepade atsaydın bare çok uzunmuş :D ble dewmi olur ya :D Ben giderken sen dnüyodun, sen benden daha fazla şey bilirsin vs.

Arkadaşlar C veya C++ da yapılmış bir pişti oyunu yapmam gerekio yardımlarınızı bekliom. Hazır yapılmışı da olabilir hiç yoktan iyidir. TopLumda Hep itiLirz SanmaKi Buna iSteKLiyiz, Biz SadeCe SevdiKLerimizin eSeriyiz..!!

O nasıl dev yle ya, cpp ile pişti. İlginç.. Sen hiç kaval çaldın mı?

oha :D hocam otur yapsana devini :) hazırları var tabii ki ama sen de yapabilirsin. pişti oyununun konseptini düşününce c++ syntaxlarını bilen birinin yapabileceği bir oyun, biraz uzun olur ama dev sonuçta otur yaz, kendini geliştir.