static void chopGenerateBlockIfNeeded(void) { int i=0; int DistSpeedX = iPlayerSpeedX * 5; if(DistSpeedX<200) DistSpeedX = 200; while(i < NUMBER_OF_BLOCKS) { if(!mBlocks[i].bIsActive) { int iX,iY,sX,sY; iX = iLastBlockPlacedPosX + (350-DistSpeedX); sX = blockw; iY = iR(0,iScreenY); sY = blockh + iR(1,blockh/3); chopAddBlock(iX,iY,sX,sY,i); } i++; } }
static void chopGenerateBlockIfNeeded() { int i=0; while(i < NUMBER_OF_BLOCKS) { if(!mBlocks[i].bIsActive) { int iX,iY,sX,sY; iX = iLastBlockPlacedPosX + 300; sX = 5; iY = iR(0,iScreenY); sY = 25;//iR(0,50); chopAddBlock(iX,iY,sX,sY,i); } i++; } }