class Phase::Beam

Defined in:

phase/beam.cr

Constant Summary

Damage = 3
Duration = 1337.milliseconds
MaxDistance = 3333
SegmentHeight = 32
Segments = (MaxDistance / SegmentHeight).to_i
SegmentWidth = 8
SpriteSegment = "./assets/beam.png"
SpriteTip = "./assets/beam_tip.png"

Constructors

Instance Method Summary

Instance methods inherited from class Phase::SuperWeapon

draw(window : SF::RenderWindow) draw, firing? : Bool firing?, hit?(circle : Circle) : Bool hit?, name : String name

Constructor methods inherited from class Phase::SuperWeapon

new(name : String = "") new

Constructor Detail

def self.new(x = 0, y = 0, rotation = 0_f64) #

[View source]

Instance Method Detail

def distance : Float64 #

[View source]
def draw(window : SF::RenderWindow) #

[View source]
def duration_timer : GSF::Timer #

[View source]
def height #

[View source]
def hit?(circle : Circle) : Bool #

[View source]
def move(x, y, rotation) #

[View source]
def rotation(*args, **options) #

[View source]
def rotation(*args, **options, &) #

[View source]
def sprite : SF::Sprite #

[View source]
def sprite_tip : SF::Sprite #

[View source]
def update(frame_time, current : Bool, timer_done : Bool, x : Float64, y : Float64, rotation : Float64, objs : Array(HealthObj)) #

[View source]