316 end; |
316 end; |
317 |
317 |
318 //////////////////////////////////////////////////////////////////////////////// |
318 //////////////////////////////////////////////////////////////////////////////// |
319 procedure doStepActionTimer(Gear: PGear); |
319 procedure doStepActionTimer(Gear: PGear); |
320 begin |
320 begin |
321 case Gear.State of |
321 dec(Gear.Timer); |
322 gtsStartGame: begin |
322 case Gear.Kind of |
323 dec(Gear.Timer); |
323 gtATStartGame: begin |
324 AllInactive:= false; |
324 AllInactive:= false; |
325 if Gear.Timer > 0 then exit; |
325 if Gear.Timer = 0 then |
326 AddCaption(trmsg[sidStartFight], $FFFFFF, capgrpStartGame); |
326 AddCaption(trmsg[sidStartFight], $FFFFFF, capgrpGameState); |
327 DeleteGear(Gear) |
|
328 end; |
327 end; |
329 gtsSmoothWindCh: begin |
328 gtATSmoothWindCh: begin |
330 if Gear.Timer = 0 then |
329 if Gear.Timer = 0 then |
331 begin |
330 begin |
332 Gear.Timer:= 10; |
|
333 if WindBarWidth < Gear.Tag then inc(WindBarWidth) |
331 if WindBarWidth < Gear.Tag then inc(WindBarWidth) |
334 else if WindBarWidth > Gear.Tag then dec(WindBarWidth) |
332 else if WindBarWidth > Gear.Tag then dec(WindBarWidth); |
335 else DeleteGear(Gear) |
333 if WindBarWidth <> Gear.Tag then Gear.Timer:= 10; |
336 end else dec(Gear.Timer) |
334 end |
|
335 end; |
|
336 gtATFinishGame: begin |
|
337 AllInactive:= false; |
|
338 if Gear.Timer = 0 then |
|
339 GameState:= gsExit |
337 end; |
340 end; |
338 end; |
341 end; |
|
342 if Gear.Timer = 0 then DeleteGear(Gear) |
339 end; |
343 end; |
340 |
344 |
341 //////////////////////////////////////////////////////////////////////////////// |
345 //////////////////////////////////////////////////////////////////////////////// |
342 procedure doStepPickHammerWork(Gear: PGear); |
346 procedure doStepPickHammerWork(Gear: PGear); |
343 var i, ei: integer; |
347 var i, ei: integer; |