class Hitbox

Defined in:

entities/boxes.cr

Constructors

Instance Method Summary

Instance methods inherited from class Collider::Capsule

bounds bounds, collide(collider : Circle) : Bool
collide(collider : Rectangle) : Bool
collide(collider : Capsule) : Bool
collide
, load load, origin1 : SF::Vector2(Float32) origin1, origin1=(origin1 : SF::Vector2(Float32)) origin1=, origin2 : SF::Vector2(Float32) origin2, origin2=(origin2 : SF::Vector2(Float32)) origin2=, radius : Float32 radius, radius=(radius : Float32) radius=, render(target, states) render

Constructor methods inherited from class Collider::Capsule

new(origin1 : SF::Vector2(Float32), origin2 : SF::Vector2(Float32), radius : Float32) new

Instance methods inherited from class Collider

bounds bounds, collidable : Bool collidable, collidable=(collidable : Bool) collidable=, collide(collider : Collider) : Bool
collide(collider : Rectangle) : Bool
collide(collider : Circle) : Bool
collide(collider : Capsule) : Bool
collide(collider : Group) : Bool
collide
, handlers : Array(Collider -> Nil) handlers, handlers=(handlers : Array(Collider -> _)) handlers=, load load, on(&block : Collider -> Nil) on, trigger(collider) trigger, unload unload

Instance methods inherited from class Entity

add(entity : Entity) add, children : Array(Entity) children, children=(children : Array(Entity)) children=, draw(target : SF::RenderTarget, states : SF::RenderStates) draw, finalize finalize, load load, offset : Proc(Vector) offset, offset=(offset : Proc(Vector)) offset=, owner : Entity | Nil owner, owner=(owner : Entity | Nil) owner=, position position, remove(entity : Entity) remove, render(target, states) render, unload unload, update : Bool update

Constructor methods inherited from class Entity

new new

Constructor Detail

def self.new(owner, origin1, origin2, radius, damage : Float64, frames) #

[View source]

Instance Method Detail

def damage : Float64 #

[View source]
def damage=(damage : Float64) #

[View source]
def direction #

[View source]
def direction=(direction : Vector | Nil) #

[View source]
def time : Float64 #

[View source]
def time=(time : Float64) #

[View source]
def update #

[View source]