From 3ad8d2531329c1696a2bf86db8db9237309281ab Mon Sep 17 00:00:00 2001 From: realtradam Date: Fri, 11 Jun 2021 02:14:57 -0400 Subject: general cleanup --- docs/FelFlame/Components.html | 77 +++++++++++++++++++++++++++++-------------- 1 file changed, 52 insertions(+), 25 deletions(-) (limited to 'docs/FelFlame/Components.html') diff --git a/docs/FelFlame/Components.html b/docs/FelFlame/Components.html index fdb54c0..633c5fb 100644 --- a/docs/FelFlame/Components.html +++ b/docs/FelFlame/Components.html @@ -111,7 +111,7 @@

Creates component managers and allows accessing them them under the Components namespace as Constants

-

To see how component managers are used please look at the Helper::ComponentManagerTemplate documentation.

+

To see how component managers are used please look at the Helper::ComponentManagerTemplate documentation.

TODO: Improve Component overview

@@ -163,7 +163,7 @@
  • - .new(component_name, *attrs, **attrs_with_defaults) ⇒ Object + .new(component_name, *attrs, **attrs_with_defaults) ⇒ ComponentManager @@ -178,7 +178,7 @@
    -

    Creates a new component manager.

    +

    Creates a new component manager.

  • @@ -206,7 +206,7 @@
    -

    Iterate over all existing component managers. You also call other enumerable methods instead of each, such as `each_with_index` or `select`

    +

    Iterate over all existing component managers. You also call other enumerable methods instead of each, such as each_with_index or select

    @@ -233,12 +233,12 @@
     
     
    -32
    -33
    -34
    +41 +42 +43 -
    # File 'component_manager.rb', line 32
    +      
    # File 'component_manager.rb', line 41
     
     def each(&block)
       constants.each(&block)
    @@ -251,7 +251,7 @@
           

    - .new(component_name, *attrs, **attrs_with_defaults) ⇒ Object + .new(component_name, *attrs, **attrs_with_defaults) ⇒ ComponentManager @@ -260,13 +260,25 @@

    -

    Creates a new component manager.

    +

    Creates a new component manager.

    -

    Parameters:

    + +
    +

    Examples:

    + + +
    # Here color is set to default to red
    +# while max and current are nil until set.
    +# When you make a new component using this component manager
    +# these are the values and accessors it will have.
    +FelFlame::Component.new('Health', :max, :current, color: 'red')
    + +
    +

    Parameters:

    • @@ -306,7 +318,7 @@ attrs_with_defaults - (Keywords) + (Keyword: DefaultValue) @@ -319,6 +331,19 @@
    +

    Returns:

    +
      + +
    • + + + (ComponentManager) + + + +
    • + +
    @@ -326,26 +351,27 @@
     
     
    -15
    -16
    -17
    -18
    -19
    -20
    -21
    -22
     23
     24
     25
     26
     27
    -28
    +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 @@ -368,9 +395,9 @@ -- cgit v1.2.3
    -
    # File 'component_manager.rb', line 15
    +      
    # File 'component_manager.rb', line 23
     
     def new(component_name, *attrs, **attrs_with_defaults)
    -  const_set(component_name, Class.new(FelFlame::Helper::ComponentManagerTemplate) {})
    +  const_set(component_name, Class.new(FelFlame::Helper::ComponentManager) {})
       attrs.each do |attr|
         FelFlame::Components.const_get(component_name).attr_accessor attr
       end
    @@ -357,6 +383,7 @@
           instance_variable_set("@#{attr}", default)
         end
       end
    +  FelFlame::Components.const_get(component_name)
     end