hedgewars/GSHandlers.inc
changeset 1631 6e313b3818ef
parent 1630 513a2c089160
child 1633 c1de4078b0fd
equal deleted inserted replaced
1630:513a2c089160 1631:6e313b3818ef
  1911 	HedgehogChAngle(HHGear);
  1911 	HedgehogChAngle(HHGear);
  1912 	if (Gear^.Timer mod 100) = 0 then
  1912 	if (Gear^.Timer mod 100) = 0 then
  1913 		begin
  1913 		begin
  1914 		rx:= rndSign(getRandom * _0_1);
  1914 		rx:= rndSign(getRandom * _0_1);
  1915 		ry:= rndSign(getRandom * _0_1);
  1915 		ry:= rndSign(getRandom * _0_1);
  1916 		addfilelog('rx, ry = '+floattostr(rx)+', '+floattostr(ry));
  1916 		
  1917 		AddGear(hwRound(Gear^.X), hwRound(Gear^.Y), gtBall, 0,
  1917 		AddGear(hwRound(Gear^.X), hwRound(Gear^.Y), gtBall, 0,
  1918 				SignAs(AngleSin(HHGear^.Angle) * _0_8, HHGear^.dX) + rx,
  1918 				SignAs(AngleSin(HHGear^.Angle) * _0_8, HHGear^.dX) + rx,
  1919 				AngleCos(HHGear^.Angle) * ( - _0_8) + ry,
  1919 				AngleCos(HHGear^.Angle) * ( - _0_8) + ry,
  1920 				0);
  1920 				0);
  1921 		
  1921