Курсовая работа: Система координат канви
Cue.Angle := Cue.angle - 6.28;
while( Cue.Angle < 0 do
Cue.Angle := Cue.angle + 6.28;
*/ if (CompMove != 0 && Player == 1)
{ Cue->Angle = Cue->Angle + Step*CompMove;
if(abs(CompAngle-Cue->Angle) <= Step)
{ CompMove = 0;
Cue->Angle = CompAngle;
MustBeHitted = True; } }
if(Player == 0 ) MustBeHitted = False;
if(MustBeHitted )
if(Cue->energy > MaxEnergy/2 )
{ Cue->Hit();
MustBeHitted = False; } for(int i =0; i <=Ball->count-1; i++)
{ // b = Ball->Items[i];
if(!b->exists ) continue;
if(b->InLose(num) )
{ b->Stop();
b->exists = False;
Balls--;
ballsIn++;
//lz = BilliardTable->Lose->Items[num];
lz->ballsInside++;
//PlayerN[Player]->balls++;
if(Balls == 1 )
{ GameStatus->gsGameOver();
Timer1->Enabled = False; }
cur = Cue->ToBall->ID;
do{