Class: Engine::Components::UI::FontRenderer

Inherits:
FontRendererBase show all
Defined in:
lib/engine/components/ui/font_renderer.rb

Instance Attribute Summary

Attributes inherited from FontRendererBase

#mesh, #texture

Attributes inherited from Engine::Component

#game_object

Instance Method Summary collapse

Methods inherited from FontRendererBase

#awake, #draw, #update_string

Methods inherited from Engine::Component

#_erase!, #destroy, #destroy!, #destroyed?, destroyed_components, erase_destroyed_components, method_added, #renderer?, #set_game_object, #update

Methods included from Serializable

allowed_class?, #awake, get_class, included, register_class, #uuid

Instance Method Details

#startObject



10
11
12
13
14
15
# File 'lib/engine/components/ui/font_renderer.rb', line 10

def start
  @ui_rect = game_object.component(UI::Rect)
  raise "UI::FontRenderer requires a UI::Rect component on the same GameObject" unless @ui_rect

  super
end

#ui_renderer?Boolean

Returns:

  • (Boolean)


6
7
8
# File 'lib/engine/components/ui/font_renderer.rb', line 6

def ui_renderer?
  true
end