index 0f6ec3531a96236f82f798e91e2e4db0417f5785..a7a01676b190617fff622c5addf09d72998e9613 100644 (file)
interface
interface
- uses g_player, e_graphics; // TPlayer, TRGB
+ uses g_player, g_base; // TPlayer, TRGB
procedure r_Player_DrawAll;
procedure r_Player_DrawDebug (p: TPlayer);
procedure r_Player_DrawAll;
procedure r_Player_DrawDebug (p: TPlayer);
SysUtils, Classes, Math,
MAPDEF, utils,
g_basic, g_game, g_phys, g_map, g_textures, g_menu, g_language, g_weapons, g_items, g_net, g_options,
SysUtils, Classes, Math,
MAPDEF, utils,
g_basic, g_game, g_phys, g_map, g_textures, g_menu, g_language, g_weapons, g_items, g_net, g_options,
- r_playermodel
+{$IFDEF ENABLE_HOLMES}
+ g_holmes,
+{$ENDIF}
+ r_playermodel, r_graphics, r_animations
;
procedure r_Player_DrawAll;
;
procedure r_Player_DrawAll;
if p.PunchAnim <> nil then
begin
if p.PunchAnim <> nil then
begin
- p.PunchAnim.Draw(fX + IfThen(p.Direction = TDirection.D_LEFT, 15 - p.Obj.Rect.X, p.Obj.Rect.X - 15), fY + fSlope + p.Obj.Rect.Y - 11, Mirror);
+ r_Animation_Draw(p.PunchAnim, fX + IfThen(p.Direction = TDirection.D_LEFT, 15 - p.Obj.Rect.X, p.Obj.Rect.X - 15), fY + fSlope + p.Obj.Rect.Y - 11, Mirror);
if p.PunchAnim.played then
begin
p.PunchAnim.Free;
if p.PunchAnim.played then
begin
p.PunchAnim.Free;
begin
{$IFDEF ENABLE_HOLMES}
begin
{$IFDEF ENABLE_HOLMES}
- if isValidViewPort and (self = gPlayer1) then
+ if p.isValidViewPort() and (p = gPlayer1) then
begin
g_Holmes_plrLaser(ax0, ay0, ax1, ay1);
end;
begin
g_Holmes_plrLaser(ax0, ay0, ax1, ay1);
end;
p.Obj.lerp(gLerpFactor, fX, fY);
if p.Animation <> nil then
p.Obj.lerp(gLerpFactor, fX, fY);
if p.Animation <> nil then
- p.Animation.Draw(fX, fY, TMirrorType.None);
+ r_Animation_Draw(p.Animation, fX, fY, TMirrorType.None);
if p.AnimationMask <> nil then
begin
e_Colors := p.Color;
if p.AnimationMask <> nil then
begin
e_Colors := p.Color;
- p.AnimationMask.Draw(fX, fY, TMirrorType.None);
+ r_Animation_Draw(p.AnimationMask, fX, fY, TMirrorType.None);
e_Colors.R := 255;
e_Colors.G := 255;
e_Colors.B := 255;
e_Colors.R := 255;
e_Colors.G := 255;
e_Colors.B := 255;