萌新
精华
|
战斗力 鹅
|
回帖 0
注册时间 2004-5-31
|
楼主 |
发表于 2004-6-9 15:08
|
显示全部楼层
int PASCAL WinMain(HINSTANCE hinstance,HINSTANCE hPrevhinstance,LPSTR lpCmdLine,int windowmode){
if(!initwindow(\"ExpForCopy\",hinstance,windowmode)||!initddraw()){
MessageBox(hwnd,\"MyFish\",\"There must be something wrong!\",MB_OK);
return false;
}
InitPicture();
MSG msg;
for(;;){
if(PeekMessage(&msg,NULL,0,0,PM_REMOVE)){
if(msg.message==WM_QUIT){
MessageBox(hwnd,\"Let\'s us get out of this window\",\"gogogo\",MB_OK);
break;
}
TranslateMessage(&msg);
DispatchMessage(&msg);
}
else Refresh();
}
return msg.lParam;
}
bool initwindow(char *windowname,HINSTANCE hinstance,int windowmode){
WNDCLASSEX win;
win.cbSize=sizeof(WNDCLASSEX);
win.style=CS_HREDRAW|CS_VREDRAW;
win.lpfnWndProc=(WNDPROC)WinProc;
win.cbClsExtra=0;
win.cbWndExtra=0;
win.hInstance=hinstance;
win.hIcon=NULL;
win.hCursor=NULL;
win.hbrBackground=CreateSolidBrush(RGB(255,255,255));
win.lpszMenuName=NULL;
win.lpszClassName=windowname;
win.hIconSm=NULL;
RegisterClassEx(&win);
hwnd=CreateWindow(windowname,windowname,WS_POPUP|WS_MAXIMIZE,CW_USEDEFAULT,0,GetSystemMetrics(SM_CXSCREEN),GetSystemMetrics(SM_CYSCREEN),NULL,NULL,hinstance,NULL);
if(!hwnd)return false;
ShowWindow(hwnd,windowmode);
UpdateWindow(hwnd);
return true;
}
LRESULT CALLBACK WinProc(HWND hwnd,UINT message,WPARAM wParam,LPARAM lParam){
switch(message){
case WM_KEYDOWN:
switch(wParam){
case VK_ESCAPE:
KillTimer(hwnd,0);
PostMessage(hwnd,WM_CLOSE,0,0);
break;
case VK_DOWN:
if(snake[0].direction!=2)snake[0].direction=3;
break;
case VK_UP:
if(snake[0].direction!=3)snake[0].direction=2;
break;
case VK_LEFT:
if(snake[0].direction!=0)snake[0].direction=1;
break;
case VK_RIGHT:
if(snake[0].direction!=1)snake[0].direction=0;
break;
}
return 0;
case WM_DESTROY:
PostQuitMessage(0);
return 0;
}
return DefWindowProc(hwnd,message,wParam,lParam);
}
bool initddraw(){
if(DirectDrawCreateEx(NULL,(void**)&lpDD,IID_IDirectDraw7,NULL)!=DD_OK)return false;
if(lpDD->SetCooperativeLevel(hwnd,DDSCL_EXCLUSIVE|DDSCL_FULLSCREEN|DDSCL_NOWINDOWCHANGES|DDSCL_ALLOWREBOOT)!=DD_OK)return false;
if(lpDD->SetDisplayMode(1024,768,32,0,DDSDM_STANDARDVGAMODE)!=DD_OK)return false;
memset(&ddsd,0,sizeof(DDSURFACEDESC2));
ddsd.dwSize=sizeof(ddsd);
ddsd.dwFlags=DDSD_CAPS;
ddsd.ddsCaps.dwCaps=DDSCAPS_PRIMARYSURFACE;
if(lpDD->CreateSurface(&ddsd,&lpDDSPrimary,NULL)!=DD_OK)return false;
ddsd.dwFlags=DDSD_CAPS|DDSD_WIDTH|DDSD_HEIGHT;
ddsd.ddsCaps.dwCaps=DDSCAPS_OFFSCREENPLAIN|DDSCAPS_SYSTEMMEMORY;
ddsd.dwHeight=768;
ddsd.dwWidth=1024;
if(lpDD->CreateSurface(&ddsd,&lpDDSBuffer,NULL)!=DD_OK)return false;
for(int i=0;i<3;i++)if(lpDD->CreateSurface(&ddsd,&lpDDSBack,NULL)!=DD_OK)return false;
for(int o=0;o<18;o++)if(lpDD->CreateSurface(&ddsd,&IpDDSBack[o],NULL)!=DD_OK)return false;
hdc=::CreateCompatibleDC(NULL);
return true;
}
bool LoadPicture(char *PictureName,int i,int Iorl){
bitmap=(HBITMAP)::LoadImage(NULL,PictureName,IMAGE_BITMAP,1024,768,LR_LOADFROMFILE);
::SelectObject(hdc,bitmap);
if(Iorl==1){
if(lpDDSBack->GetSurfaceDesc(&ddsd)!=DD_OK)return false;
if(lpDDSBack->GetDC(&hdc1)!=DD_OK)return false;
::BitBlt(hdc1,0,0,ddsd.dwWidth,ddsd.dwHeight,hdc,0,0,SRCCOPY);
lpDDSBack->ReleaseDC(hdc1);
}
else{
if(IpDDSBack->GetSurfaceDesc(&ddsd)!=DD_OK)return false;
if(IpDDSBack->GetDC(&hdc1)!=DD_OK)return false;
::BitBlt(hdc1,0,0,ddsd.dwWidth,ddsd.dwHeight,hdc,0,0,SRCCOPY);
IpDDSBack->ReleaseDC(hdc1);
}
return true;
}
void InitPicture(){
LoadPicture(\"snakebody.bmp\",1,1);
LoadPicture(\"rikku.bmp\",0,1);
LoadPicture(\"fish.bmp\",2,1);
LoadPicture(\"fishwater6.bmp\",5,0);
LoadPicture(\"fishwater5.bmp\",4,0);
LoadPicture(\"fishwater4.bmp\",3,0);
LoadPicture(\"fishwater3.bmp\",2,0);
LoadPicture(\"fishwater2.bmp\",1,0);
LoadPicture(\"fishwater1.bmp\",0,0);
LoadPicture(\"FishMonster6.bmp\",17,0);
LoadPicture(\"FishMonster5.bmp\",16,0);
LoadPicture(\"FishMonster4.bmp\",15,0);
LoadPicture(\"FishMonster3.bmp\",14,0);
LoadPicture(\"FishMonster2.bmp\",13,0);
LoadPicture(\"FishMonster1.bmp\",12,0);
LoadPicture(\"FishMonsterLeft6.bmp\",11,0);
LoadPicture(\"FishMonsterLeft5.bmp\",10,0);
LoadPicture(\"FishMonsterLeft4.bmp\",9,0);
LoadPicture(\"FishMonsterLeft3.bmp\",8,0);
LoadPicture(\"FishMonsterLeft2.bmp\",7,0);
LoadPicture(\"FishMonsterLeft1.bmp\",6,0);
}
int RandEx(int max){
srand(GetTickCount()*10000);
return rand()%max;
}
bool IsTouch(LPDIRECTDRAWSURFACE7 lpDDS_src,int lpDDS_srcX,int lpDDS_srcY){
ZeroMemory(&ddsd_src,sizeof(ddsd_src));
ddsd_src.dwSize=sizeof(ddsd_src);
lpDDS_src->Lock(NULL,&ddsd_src,DDLOCK_WAIT,NULL);
BYTE *lPsrc=(BYTE*)ddsd_src.lpSurface;
int Distance=lpDDS_srcY*ddsd_src.lPitch+lpDDS_srcX*4;
int IsTouch=0;
_asm{
mov eax,lPsrc
add eax,Distance
mov ebx,[eax]
cmp ebx,0
jz NoTouch
mov IsTouch,1
NoTouch:
emms
}
lpDDS_src->Unlock(NULL);
return IsTouch;
}
void CopyBlt(LPDIRECTDRAWSURFACE7 lpDDS_src,LPDIRECTDRAWSURFACE7 lpDDS_dest,int lpDD_srcX,int lpDD_srcY,int lpDD_destTopX,int lpDD_destTopY,int lpDD_destBottomX,int lpDD_destBottomY){
ZeroMemory(&ddsd_src,sizeof(ddsd_src));
ddsd_src.dwSize=sizeof(ddsd_src);
ZeroMemory(&ddsd_dest,sizeof(ddsd_dest));
ddsd_dest.dwSize=sizeof(ddsd_dest);
lpDDS_src->Lock(NULL,&ddsd_src,DDLOCK_WAIT,NULL);
lpDDS_dest->Lock(NULL,&ddsd_dest,DDLOCK_WAIT,NULL);
BYTE *lPsrc=(BYTE*)ddsd_src.lpSurface;
BYTE *lPdest=(BYTE*)ddsd_dest.lpSurface;
int FirstPoint_src=lpDD_srcY*ddsd_src.lPitch+lpDD_srcX*4;
int FirstPoint_dest=lpDD_destTopY*ddsd_dest.lPitch+lpDD_destTopX*4;
int lpDD_destHeight=lpDD_destBottomY-lpDD_destTopY;
int lpDD_destWidth=(lpDD_destBottomX-lpDD_destTopX)/2;
_asm{
mov eax,lPsrc
add eax,FirstPoint_src
mov ebx,lPdest
add ebx,FirstPoint_dest
mov edi,lpDD_destHeight
FirstLoop:
push eax
push ebx
mov esi,lpDD_destWidth
SecondLoop:
movq mm0,[ebx]
movq [eax],mm0
add ebx,8
add eax,8
dec esi
jnz SecondLoop
pop ebx
pop eax
add eax,ddsd_src.lPitch
add ebx,ddsd_dest.lPitch
dec edi
jnz FirstLoop
emms
}
lpDDS_src->Unlock(NULL);
lpDDS_dest->Unlock(NULL);
}
void AlphaBlt(LPDIRECTDRAWSURFACE7 lpDDS,int lpDDSX,int lpDDSY,int RectTopX,int RectTopY,int RectBottomX,int RectBottomY){
ZeroMemory(&ddsd_src,sizeof(ddsd_src));
ddsd_src.dwSize=sizeof(ddsd_src);
ZeroMemory(&ddsd_dest,sizeof(ddsd_dest));
ddsd_dest.dwSize=sizeof(ddsd_dest);
lpDDSBuffer->Lock(NULL,&ddsd_src,DDLOCK_WAIT,NULL);
lpDDS->Lock(NULL,&ddsd_dest,DDLOCK_WAIT,NULL);
_int64 mask=0x7f7f7f7f7f7f7f7f;
int FirstPoint_src=lpDDSY*ddsd_src.lPitch+lpDDSX*4;
int FirstPoint_dest=RectTopY*ddsd_dest.lPitch+RectTopX*4;
int lpDDSHeight=RectBottomY-RectTopY;
int lpDDSWidth=(RectBottomX-RectTopX)/2;
_int64 Black=0x00000000ffffffff;
_asm{
mov eax,ddsd_src.lpSurface
add eax,FirstPoint_src
mov ebx,ddsd_dest.lpSurface
add ebx,FirstPoint_dest
mov edi,lpDDSHeight
FirstLoop:
push eax
push ebx
mov esi,lpDDSWidth
SecondLoop:
movq mm0,[eax]
movq mm1,[ebx]
add [ebx],0
jnz NoBlack
add [ebx+4],0
jz ColorKey
pand mm1,Black
NoBlack:
psrlw mm0,1
pand mm0,mask
pand mm1,mask
paddusb mm0,mm1
ColorKey:
movq [eax],mm0
add eax,8
add ebx,8
dec esi
jnz SecondLoop
pop ebx
pop eax
add eax,ddsd_src.lPitch
add ebx,ddsd_dest.lPitch
dec edi
jnz FirstLoop
emms
}
lpDDSBuffer->Unlock(NULL);
lpDDS->Unlock(NULL);
}
void SnakeMove(){
if(NumberOfSnake>=1)for(int i=NumberOfSnake;i>=1;i--){
if(snake[0].direction==0){
if(snake[i-1].x>=10)snake.x=snake[i-1].x-10;
else snake.x=0;
snake.y=snake[i-1].y;
}
else if(snake[0].direction==1){
if(snake[i-1].x<=895)snake.x=snake[i-1].x+10;
else snake.x=905;
snake.y=snake[i-1].y;
}
else if(snake[0].direction==2){
if(snake[i-1].y<=610)snake.y=snake[i-1].y+10;
else snake.y=620;
snake.x=snake[i-1].x;
}
else if(snake[0].direction==3){
if(snake[i-1].y>=10)snake.y=snake[i-1].y-10;
else snake.y=0;
snake.x=snake[i-1].x;
}
}
if(snake[0].direction==0){
if(snake[0].x<=925)snake[0].x=snake[0].x+snake[0].speed;
else snake[0].death=1;
}
else if(snake[0].direction==1){
if(snake[0].x>=5)snake[0].x=snake[0].x-snake[0].speed;
else snake[0].death=1;
}
else if(snake[0].direction==2){
if(snake[0].y>=5)snake[0].y=snake[0].y-snake[0].speed;
else snake[0].death=1;
}
else if(snake[0].direction==3){
if(snake[0].y<=680)snake[0].y=snake[0].y+snake[0].speed;
else snake[0].death=1;
}
}
void Refresh(){
Dead();
if(snake[0].death==0){
FishInWater();
eated();
SnakeMove();
Rendfish();
for(int i=0;i<=NumberOfSnake;i++)AlphaBlt(lpDDSBack[1],snake.x,snake.y,snake.ImageTopX,snake.ImageTopY,snake.ImageButtomX,snake.ImageButtomY);
DisplayScore(\"你的分数:\",0,0);
DisplayScore(ItoA(),100,0);
CopyBlt(lpDDSPrimary,lpDDSBuffer,0,0,0,0,1024,768);
}
else{
CopyBlt(lpDDSPrimary,lpDDSBack[0],0,0,0,0,1024,768);
}
}
void Rendfish(){
if(fish.exist==0){
fish.x=RandEx(100)*9.5;
fish.y=RandEx(100)*6.5;
fish.exist=1;
}
}
void eated(){
if(fish.exist==1)if(snake[0].y-fish.y>=snake[0].ImageTopY-snake[0].ImageButtomY&&snake[0].y-fish.y<=fish.ImageButtomYL-fish.ImageTopYL&&snake[0].x-fish.x<=fish.ImageButtomXL-fish.ImageTopXL&&snake[0].x-fish.x>=snake[0].ImageTopX-snake[0].ImageButtomX){
if(fish.Direction==0){
if(snake[0].direction==1){
if(IsTouch(IpDDSBack[FishMoveNumber],fish.ImageTopXL+(snake[0].x+snake[0].width-fish.x),fish.ImageTopYL+(snake[0].y+snake[0].height/2-fish.y))){
fish.exist=0;
junction();
score=score+interval;
interval+=5;
}
}
else if(snake[0].direction==0){
if(IsTouch(IpDDSBack[FishMoveNumber],fish.ImageTopXL+(snake[0].x-fish.x),fish.ImageTopYL+snake[0].y+(snake[0].height/2-fish.y))){
fish.exist=0;
junction();
score=score+interval;
interval+=5;
}
}
else if(snake[0].direction==2){
if(IsTouch(IpDDSBack[FishMoveNumber],fish.ImageTopXL+(snake[0].x+snake[0].width/2-fish.x),fish.ImageTopYL+(snake[0].y-fish.y))){
fish.exist=0;
junction();
score=score+interval;
interval+=5;
}
}
else{
if(IsTouch(IpDDSBack[FishMoveNumber],fish.ImageTopXL+(snake[0].x+snake[0].width/2-fish.x),fish.ImageTopYL+(snake[0].y+snake[0].height-fish.y))){
fish.exist=0;
junction();
score=score+interval;
interval+=5;
}
}
}
if(fish.Direction==6){
if(snake[0].direction==1){
if(IsTouch(IpDDSBack[FishMoveNumber],fish.ImageTopXR+(snake[0].x+snake[0].width-fish.x),fish.ImageTopYR+(snake[0].y+snake[0].height/2-fish.y))){
fish.exist=0;
junction();
score=score+interval;
interval+=5;
}
}
else if(snake[0].direction==0){
if(IsTouch(IpDDSBack[FishMoveNumber],fish.ImageTopXR+(snake[0].x-fish.x),fish.ImageTopYR+(snake[0].y+snake[0].height/2-fish.y))){
fish.exist=0;
junction();
score=score+interval;
interval+=5;
}
}
else if(snake[0].direction==2){
if(IsTouch(IpDDSBack[FishMoveNumber],fish.ImageTopXR+(snake[0].x+snake[0].width/2-fish.x),fish.ImageTopYR+(snake[0].y-fish.y))){
fish.exist=0;
junction();
score=score+interval;
interval+=5;
}
}
else{
if(IsTouch(IpDDSBack[FishMoveNumber],fish.ImageTopXR+(snake[0].x+snake[0].width/2-fish.x),fish.ImageTopYR+(snake[0].y+snake[0].height-fish.y))){
fish.exist=0;
junction();
score=score+interval;
interval+=5;
}
}
}
}
}
void junction(){
NumberOfSnake++;
switch(snake[0].direction){
case 0:
if(snake[NumberOfSnake-1].x>=10)snake[NumberOfSnake].x=snake[NumberOfSnake-1].x-10;
else snake[NumberOfSnake].x=0;
snake[NumberOfSnake].y=snake[NumberOfSnake-1].y;
break;
case 1:
if(snake[NumberOfSnake-1].x<=895)snake[NumberOfSnake].x=snake[NumberOfSnake-1].x+10;
else snake[NumberOfSnake].x=905;
snake[NumberOfSnake].y=snake[NumberOfSnake-1].y;
break;
case 2:
if(snake[NumberOfSnake-1].y<=610)snake[NumberOfSnake].y=snake[NumberOfSnake-1].y+10;
else snake[NumberOfSnake].y=620;
snake[NumberOfSnake].x=snake[NumberOfSnake-1].x;
break;
case 3:
if(snake[NumberOfSnake-1].y>=10)snake[NumberOfSnake].y=snake[NumberOfSnake-1].y-10;
else snake[NumberOfSnake].y=0;
snake[NumberOfSnake].x=snake[NumberOfSnake-1].x;
break;
}
}
void DisplayScore(char *Score,int x,int y){
if (lpDDSBuffer->GetDC(&hdc) == DD_OK) {
SetBkColor(hdc, RGB(0, 0, 255));
SetTextColor(hdc, RGB(255, 255, 0));
TextOut(hdc,x,y, Score, strlen(Score));
lpDDSBuffer->ReleaseDC(hdc);
}
}
char *ItoA(){
int s=score;
char* a=(char*)malloc(sizeof(char));
a=itoa(score,a,10);
return a;
}
void Dead(){
if(NumberOfSnake>=10)for(int i=NumberOfSnake;i>=10;i--){
if(snake[0].y-snake.y>=snake[0].ImageTopY-snake[0].ImageButtomY&&snake[0].y-snake.y<=snake.ImageButtomY-snake.ImageTopY&&snake[0].x-snake.x<=snake.ImageButtomX-snake.ImageTopX&&snake[0].x-snake.x>=snake[0].ImageTopX-snake[0].ImageButtomX){
if(snake[0].direction==0){
if(IsTouch(IpDDSBack[1],snake.ImageTopX+(snake[0].x-snake.x),snake.ImageTopY+snake[0].y+(snake[0].height/2-snake.y))){
snake[0].death=1;
}
}
else if(snake[0].direction==1){
if(IsTouch(lpDDSBack[1],snake.ImageTopX+(snake[0].x+snake[0].width-snake.x),snake.ImageTopY+(snake[0].y+snake[0].height/2-snake.y))){
snake[0].death=1;
}
}
else if(snake[0].direction==2){
if(IsTouch(IpDDSBack[1],snake.ImageTopX+(snake[0].x+snake[0].width/2-snake.x),fish.ImageTopYL+(snake[0].y-snake.y))){
snake[0].death=1;
}
}
else if(snake[0].direction==3){
if(IsTouch(IpDDSBack,snake.ImageTopX+(snake[0].x+snake[0].width/2-snake.x),snake.ImageTopY+(snake[0].y+snake[0].height-snake.y))){
snake[0].death=1;
}
}
}
}
}
/////////////////////////////////////////////////////////////////////////////////////////////
void FishInWater(){
if(water[WaterNumber=RandEx(9)].exist==0){
while(!(water[WaterNumber].height=RandEx(5)*21*(WaterNumber+1))||water[WaterNumber].height>=703);
water[WaterNumber].width=RandEx(10)*7*(WaterNumber+1);
water[WaterNumber].WaterSize=2;
water[WaterNumber].exist=1;
}
if(PictureNumber>5){
PictureNumber=RandEx(5);
}
CopyBlt(lpDDSBuffer,IpDDSBack[PictureNumber],0,0,0,0,1024,768);
if(!(FishTimer%4)){
if(fish.IsStop==1){
fish.FishSpeed--;
if(fish.FishSpeed<=1)fish.FishSpeed=1;
FishMoveNumber=6+fish.Direction;
}
else{
FishMoveNumber++;
fish.FishSpeed++;
}
if(fish.x<=2){
fish.Direction=6;
FishMoveNumber+=fish.Direction;
}
else if(fish.x>=650){
FishMoveNumber-=fish.Direction;
fish.Direction=0;
}
if(FishMoveNumber>11+fish.Direction)FishMoveNumber=6+fish.Direction;
if(fish.FishSpeed>=5)fish.FishSpeed=5;
else if(fish.FishSpeed<=0)fish.FishSpeed=0;
if(fish.Direction==0){
fish.x-=fish.FishSpeed;
}
else{
fish.x+=fish.FishSpeed;
}
if(!(FishTimer%160)){
if(RandEx(99)>50)FishUpDown=1;
else FishUpDown=0;
}
if(FishUpDown==0){
fish.y--;
if(fish.y<148)fish.y=148;
}
else{
fish.y++;
if(fish.y>678)fish.y=678;
}
}
if(fish.IsStop==0)
if(RandEx(100)<1){
fish.IsStop=1;
}
for(int i=0;i<=9;i++){
if(water.exist==1){
if(water.height<=148){
water.exist=0;
}
else if(!(WaterPointTimer%5)){
if(water.height<700&&water.height>600)water.width-=10;
else if(water.height<500&&water.height>400)water.width-=7;
else if(water.height<300&&water.height>200)water.width-=5;
else {
water.width+=10;
water.WaterSize++;
}
water.height-=15;
}
DrawWater(i);
}
}
if(fish.Direction==0)AlphaBlt(IpDDSBack[FishMoveNumber],fish.x,fish.y,fish.ImageTopXL,fish.ImageTopYL,fish.ImageButtomXL,fish.ImageButtomYL);
else AlphaBlt(IpDDSBack[FishMoveNumber],fish.x,fish.y,fish.ImageTopXR,fish.ImageTopYR,fish.ImageButtomXR,fish.ImageButtomYR);
if(!(WaterTimer%8))PictureNumber++;
if(fish.IsStop==1)if(RandEx(100)<5)fish.IsStop=0;
WaterTimer++;
FishTimer++;
WaterPointTimer++;
}
void DrawWater(int i){
lpDDSBuffer->GetDC(&hdc);
SelectObject(hdc,hpen);
SelectObject(hdc,hbrush1);
Ellipse(hdc,water.width,water.height,water.width+water.WaterSize,water.height+water.WaterSize);
SelectObject(hdc,hbrush2);
Ellipse(hdc,water.width+water.WaterSize/4,water.height+water.WaterSize/4,water.width+water.WaterSize/2,water.height+water.WaterSize/2);
lpDDSBuffer->ReleaseDC(hdc);
}
void Light(int CircleHalfLong,int CircleX,int CircleY,int Bright){
for(int H=0;H<768;H++)
for(int W=0;W<1024;W++){
int l=((H-CircleY)*(H-CircleY)+(W-CircleX)*(W-CircleX))/(CircleHalfLong*CircleHalfLong);
if(l<=1)
BaseLightTable[W+H*1024]=Bright/3;
else BaseLightTable[W+H*1024]=Bright;
}
ZeroMemory(&ddsd,sizeof(ddsd));
ddsd.dwSize=sizeof(ddsd);
lpDDSBuffer->Lock(NULL,&ddsd,DDLOCK_WAIT,NULL);
_int8 *lPsrc=(_int8*)ddsd.lpSurface;
_int8 *LightTable=(_int8*)BaseLightTable;
_asm{
mov eax,lPsrc
mov ebx,LightTable
mov edi,768
FirstLoop:
push eax
mov esi,512
SecondLoop:
movq mm0,[eax]
movq mm1,[ebx]
punpcklbw mm1,mm1
punpcklbw mm1,mm1
psubusb mm0,mm1
movq [eax],mm0
add eax,8
add ebx,2
dec esi
jnz SecondLoop
pop eax
add eax,ddsd.lPitch
dec edi
jnz FirstLoop
emms
}
lpDDSBuffer->Unlock(NULL);
}
贴不下了!
你逼我的! |
|