equal
deleted
inserted
replaced
273 end; |
273 end; |
274 |
274 |
275 ResetKbd; |
275 ResetKbd; |
276 |
276 |
277 cWindSpeed:= rndSign(GetRandom * 2 * cMaxWindSpeed); |
277 cWindSpeed:= rndSign(GetRandom * 2 * cMaxWindSpeed); |
278 // cWindSpeedf:= cWindSpeed.QWordValue / _1.QWordValue throws Internal error 200502052 on fpc 2.5.1 |
278 cWindSpeedf:= cWindSpeed.QWordValue / _1.QWordValue; |
279 // see http://mantis.freepascal.org/view.php?id=17714 |
|
280 cWindSpeedf:= SignAs(cWindSpeed,cWindSpeed).QWordValue / SignAs(_1,_1).QWordValue; |
|
281 if cWindSpeed.isNegative then |
279 if cWindSpeed.isNegative then |
282 CWindSpeedf := -cWindSpeedf; |
280 CWindSpeedf := -cWindSpeedf; |
283 g:= AddGear(0, 0, gtATSmoothWindCh, 0, _0, _0, 1); |
281 g:= AddGear(0, 0, gtATSmoothWindCh, 0, _0, _0, 1); |
284 g^.Tag:= hwRound(cWindSpeed * 72 / cMaxWindSpeed); |
282 g^.Tag:= hwRound(cWindSpeed * 72 / cMaxWindSpeed); |
285 {$IFDEF DEBUGFILE}AddFileLog('Wind = '+FloatToStr(cWindSpeed));{$ENDIF} |
283 {$IFDEF DEBUGFILE}AddFileLog('Wind = '+FloatToStr(cWindSpeed));{$ENDIF} |