class Works::Player
- Works::Player
- Reference
- Object
Defined in:
works/player.crConstant Summary
-
AnimationIdleInterval =
10.seconds
-
BuildDistance =
Cell.size.to_i * 10
-
MiningAmount =
1
-
MiningDistance =
Cell.size.to_i * 4
-
MiningInterval =
500.milliseconds
-
ProgressBarHeight =
5 * Screen.scale_factor
-
HUD
-
StructRemovalDistance =
Cell.size.to_i * 5
-
StructRemovalInterval =
1.seconds
Constructors
Instance Method Summary
- #animations : Works::Animations
- #animations=(animations : Works::Animations)
- #buildable?(cell : Cell)
- #destroy
- #distance(cell : Cell)
- #draw(dx, dy)
- #draw_action_progress(x, y)
- #draw_inventory(x, y)
- #draw_player_x
- #draw_selection(dx, dy, color)
- #draw_selections(x, y)
- #height
- #hide_struct_info
- #idle_timer : Works::Timer
- #init(sheet : LibAllegro::Bitmap)
- #init_animations(sheet : LibAllegro::Bitmap)
- #inventory : Works::Inventory
- #minable?(cell : Cell)
- #mining_timer : Works::Timer
- #ore_hover : Tile::Ore::Base | Nil
- #overlaps?(cell : Cell)
- #removable?(cell : Cell)
- #speed : Int32
- #speed=(speed : Int32)
- #sprite_width
- #struct_hover : Struct::Base | Nil
- #struct_hud_shown
- #struct_info : Struct::Base | Nil
- #struct_removal_timer : Works::Timer
- #update(keys : Keys, mouse : Mouse, map : Map)
- #update_inventory(keys : Keys, mouse : Mouse, map : Map)
- #update_mining(map : Map, mouse : Mouse, mouse_col, mouse_row)
- #update_movement(keys : Keys)
- #update_struct_info(mouse : Mouse)
- #update_structs(map : Map, keys : Keys, mouse : Mouse, mouse_col, mouse_row)
- #width
- #x : Int32
- #x=(x : Int32)
- #y : Int32
- #y=(y : Int32)