빙고게임 만들기 (C++/visual 6.0)
본 자료는 3페이지 의 미리보기를 제공합니다. 이미지를 클릭하여 주세요.
닫기
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
해당 자료는 3페이지 까지만 미리보기를 제공합니다.
3페이지 이후부터 다운로드 후 확인할 수 있습니다.

소개글

빙고게임 만들기 (C++/visual 6.0)에 대한 보고서 자료입니다.

본문내용

r, Bingo user){ // 배열복사함수
for(int i=0; i<5; i++){
for(int j=0; j<5; j++){
copy_user[i][j] = user.get_xy(i,j);
copy_computer[i][j] = computer.get_xy(i,j);
}
}
}
void output(Bingo computer, Bingo user){
system("cls"); // 화면 클리어
copy_board(computer, user);
//배열 출력
cout< cout<<"===user============================com===================="< for(int i=0 ; i<5 ; i++)
{
for(int j=0 ; j<5 ; j++)
{
cout< }
printf(" || ");
for(j=0 ; j<5 ; j++)
{
cout< }
cout< }
// 보조판 출력
cout< cout<<"===user============================com===================="< for(i=0 ; i<5 ; i++)
{
for(int j=0 ; j<5 ; j++)
{
if(copy_user[i][j] < 0)
{
cout<<" #";
}
else
{
cout<<" .";
}
}
cout<<" || ";
for(j=0 ; j<5 ; j++)
{
if(copy_computer[i][j] < 0)
{
cout<<" #";
}
else
{
cout<<" .";
}
}
cout< }
cout< }
};
void main()
{
system("mode con : lines = 25 cols=80");
int num;
int re=1;
int ch;
srand((int)time(NULL));
Bingo user;
Bingo computer;
BingoGame bingogame;
Input_user input_user;
Print print(computer, user);
while(re)
{ ///////////////////////////출력///////////////////////////////
print.output(computer, user);
///////////////////////////user 입력//////////////////////////
num = input_user.user_input();
///////////////////////////선택후계산/////////////////////////
bingogame.find(computer, user, num);
///////////////////////////출력///////////////////////////////
print.output(computer, user);
///////////////////////////이겼는지검사///////////////////////
re = bingogame.win(computer, user);
if(re == 0)
break;
///////////////////////////출력///////////////////////////////
print.output(computer, user);
///////////////////////////가중치최고값계산///////////////////
num = bingogame.com_max(computer);
///////////////////////////선택후계산/////////////////////////
bingogame.find(computer,user,num);
///////////////////////////출력///////////////////////////////
print.output(computer, user);
///////////////////////////이겼는지검사///////////////////////
re = bingogame.win(computer, user);
}
fflush(stdin);
// 입력대기를 사용하기위해 메모리를 비워준다.(cout은 메모리에 남아있기때문에)
//fflush를 쓰지 않았을경우 : 컴퓨터에 선택에 대해 키의 입력을 기다리는 대기 모드가 없이 지나간다.
while((ch = getchar()) != '\n'){ //입력대기
}
}

키워드

빙고,   게임,   빙고게임,   C++
  • 가격2,000
  • 페이지수9페이지
  • 등록일2010.06.28
  • 저작시기2010.6
  • 파일형식한글(hwp)
  • 자료번호#859802
본 자료는 최근 2주간 다운받은 회원이 없습니다.
청소해
다운로드 장바구니