package Entities.Players.Keen is
type Keen is new Player with private;
procedure Teleport( this : access Keen;
fromX, fromY : Float;
toX, toY : Float );
private
type Action_Type is (Act_Moving, Act_Looking, Act_Looking_Back,
Act_Teleporting, Act_Idle, Act_Rising, Act_Dying);
type Keen is new Player with
record
attemptingJump : Boolean := False;
jumping : Boolean := False;
jumpStartY : Float := 0.0;
onPogo : Boolean := False;
shooting : Boolean := False;
shootStart : Time_Span := Time_Span_Zero;
action : Action_Type := Act_Moving;
actionStart : Time_Span := Time_Span_Zero;
actionDuration : Time_Span := Time_Span_Zero;
activating : Boolean := False;
idleStart : Time_Span := Time_Span_Zero;
idleNumber : Positive := 1;
teleportX,
teleportY : Float := 0.0;
lastTeleport : Time_Span := Time_Span_Zero;
deathX,
deathY : Float := 0.0;
dead : Boolean := False;
upTime : Time_Span := Time_Span_Zero;
minJumpHeight,
maxJumpHeight,
minPogoHeight,
maxPogoHeight,
maxBounceHeight : Float := 0.0;
lookSpeed : Float := 0.0;
end record;
procedure Construct( this : access Keen );
procedure Die( this : access Keen );
procedure Face( this : access Keen; dir : Direction_Type );
procedure Impulse( this : access Keen; name : Hashed_String );
function Is_Busy( this : not null access Keen'Class ) return Boolean;
procedure Move_Start( this : access Keen; dir : Cardinal_Direction );
procedure Move_Stop( this : access Keen; dir : Cardinal_Direction );
function Object_Input( stream : access Root_Stream_Type'Class ) return Keen;
for Keen'Input use Object_Input;
procedure Object_Read( stream : access Root_Stream_Type'Class; obj : out Keen );
for Keen'Read use Object_Read;
procedure Object_Write( stream : access Root_Stream_Type'Class; obj : Keen );
for Keen'Write use Object_Write;
procedure On_Hit_Wall( this : access Keen; dir : Cardinal_Direction );
procedure Reset_Idle( this : not null access Keen'Class );
procedure Shoot_Gun( this : not null access Keen'Class );
procedure Start_Action( this : not null access Keen'Class;
action : Action_Type;
length : Time_Span := Time_Span_Zero );
procedure Start_Jump( this : not null access Keen'Class );
procedure Stop_Jump( this : not null access Keen'Class );
procedure Tick( this : access Keen; upTime, dt : Time_Span );
procedure Update_Frame( this : access Keen; notify : Boolean := True );
end Entities.Players.Keen;