928 if (CurAmmoGear <> nil) and (CurAmmoGear^.Kind = gtResurrector) then |
928 if (CurAmmoGear <> nil) and (CurAmmoGear^.Kind = gtResurrector) then |
929 DrawTextureCentered(ox, sy - cHHRadius - 7 - HealthTagTex^.h, HealthTagTex); |
929 DrawTextureCentered(ox, sy - cHHRadius - 7 - HealthTagTex^.h, HealthTagTex); |
930 |
930 |
931 if bShowFinger and ((Gear^.State and gstHHDriven) <> 0) then |
931 if bShowFinger and ((Gear^.State and gstHHDriven) <> 0) then |
932 begin |
932 begin |
933 ty := oy - 56; |
933 ty := oy - 32; |
934 // move finger higher up if tags are above hog |
934 // move finger higher up if tags are above hog |
935 if (cTagsMask and htTeamName) <> 0 then |
935 if (cTagsMask and htTeamName) <> 0 then |
936 ty := ty - Team^.NameTagTex^.h - 2; |
936 ty := ty - Team^.NameTagTex^.h - 2; |
937 if (cTagsMask and htName) <> 0 then |
937 if (cTagsMask and htName) <> 0 then |
938 ty := ty - NameTagTex^.h - 2; |
938 ty := ty - NameTagTex^.h - 2; |
939 if (cTagsMask and htHealth) <> 0 then |
939 if (cTagsMask and htHealth) <> 0 then |
940 ty := ty - HealthTagTex^.h - 2; |
940 ty := ty - HealthTagTex^.h - 2; |
941 DrawSprite(sprFinger, ox - 16, ty, |
941 tx := ox; |
942 GameTicks div 32 mod 16); |
942 tx := round(max(((-cScreenWidth + 16) / zoom) + SpritesData[sprFinger].Width div 2, min(((cScreenWidth - 16) / zoom) - SpritesData[sprFinger].Width div 2, tx))); |
|
943 ty := round(max(cScreenHeight div 2 - ((cScreenHeight - 16) / (zoom)) + SpritesData[sprFinger].Height div 2, min(cScreenHeight div 2 - ((-cScreenHeight + SpritesData[sprFinger].Height) / (zoom)) - SpritesData[sprFinger].Width div 2 - 96, ty))); |
|
944 t := tx-ox; |
|
945 if t <> 0 then |
|
946 dAngle := radtodeg(-arctan2(-(ty-oy),t)) + 90 |
|
947 else if ty > oy then |
|
948 dAngle := 180 |
|
949 else |
|
950 dAngle := 0; |
|
951 DrawSpriteRotatedF(sprFinger, tx, ty, GameTicks div 32 mod 16, 1, dAngle); |
943 end; |
952 end; |
|
953 |
944 |
954 |
945 if (Gear^.State and gstDrowning) = 0 then |
955 if (Gear^.State and gstDrowning) = 0 then |
946 if (Gear^.State and gstHHThinking) <> 0 then |
956 if (Gear^.State and gstHHThinking) <> 0 then |
947 DrawSprite(sprQuestion, ox - 10, oy - cHHRadius - 34, (RealTicks shr 9) mod 8) |
957 DrawSprite(sprQuestion, ox - 10, oy - cHHRadius - 34, (RealTicks shr 9) mod 8) |
948 end |
958 end |