Курсовая работа: Игровая программа
(CountNitro>0)and
(GasDeley=1) then
begin
Gas:=true;
CountNitro:=CountNitro-1;
GasDeley:=0;
PlaySound('Sound\Start_Nitro.wav',0,SND_ASYNC);
end;
end;
событие OnPaint :
procedure TSpeedGL.FormPaint(Sender: TObject);
var
ps:TPaintStruct;
begin
BeginPaint(dc,ps);
if Selected_Menu_item='' then
begin
case Menu_item of
1:begin LeftTiresMeny:=-0.849; RightTiresMeny:=0.8; TopTiresMeny:=0.76; end;
2:begin LeftTiresMeny:=-1.1; RightTiresMeny:=1.0; TopTiresMeny:=0.4; end;
3:begin LeftTiresMeny:=-0.8; RightTiresMeny:=0.8; TopTiresMeny:=0.0; end;
4:begin LeftTiresMeny:=-0.8; RightTiresMeny:=0.8; TopTiresMeny:=-0.58; end;
end;
if OldSelectMenyItem='Car' then begin
if RemoveMeny>=0.0 then begin RemoveMeny:=0.0; OldSelectMenyItem:='' end else
RemoveMeny:=RemoveMeny+0.018;
glCallList(Background);
glPushMatrix;
glTranslatef(RemoveMeny,0.0,0.0);