class Enemy

Direct Known Subclasses

Defined in:

game/enemy.cr

Instance Method Summary

Instance methods inherited from class Actor

alive? alive?, animation_facing(direction) animation_facing, animation_rect(rect, i) : SF::IntRect animation_rect, animation_reset(direction) animation_reset, animation_step animation_step, apply_speed(direction : SF::Vector2f) apply_speed, collides?(other) collides?, dead? dead?, draw(target, states) draw, global_bounds global_bounds, hit hit, move(direction : SF::Vector2f) move, next_animation_step next_animation_step, normalize_movement(direction : SF::Vector2f) normalize_movement, position : SF::Vector2(Float32) position, position=(position : SF::Vector2(Float32)) position=, update(time) update

Constructor methods inherited from class Actor

new(position : SF::Vector2f) new

Instance Method Detail

def move(player_position : SF::Vector2f) #

Move towards player


[View source]