From 55f1db30e7a609cebd2fab27c55ece1da45be232 Mon Sep 17 00:00:00 2001 From: realtradam Date: Mon, 3 Jan 2022 07:34:38 -0500 Subject: . --- docs/FelFlame/ComponentManager.html | 211 ++++++++++-------------------------- 1 file changed, 58 insertions(+), 153 deletions(-) (limited to 'docs/FelFlame/ComponentManager.html') diff --git a/docs/FelFlame/ComponentManager.html b/docs/FelFlame/ComponentManager.html index 119a7ed..143fd3a 100644 --- a/docs/FelFlame/ComponentManager.html +++ b/docs/FelFlame/ComponentManager.html @@ -102,7 +102,7 @@

Overview

-

Component Managers are what is used to create individual components which can be attached to entities. When a Component is created from a Component Manager that has accessors given to it, you can set or get the values of those accessors using standard ruby message sending (e.g @component.var = 5), or by using the #attrs and #update_attrs methods instead.

+

Component Managers are what is used to create individual components which can be attached to entities. When a Component is created from a Component Manager that has accessors given to it, you can set or get the values of those accessors using standard ruby message sending (e.g @component.var = 5), or by using the #to_h and #update_attrs methods instead.

@@ -312,30 +312,6 @@
  • - #attr_changed_trigger_systems(attr) ⇒ Boolean - - - - - - - - - - - - - -
    -

    Execute systems that have been added to execute on variable change.

    -
    - -
  • - - -
  • - - #delete ⇒ Boolean @@ -449,7 +425,7 @@
    -

    A hash, where all the keys are attributes linked to their respective values.

    +

    A hash, where all the keys are attributes storing their respective values.

  • @@ -531,6 +507,8 @@
     
     
    +154
    +155
     156
     157
     158
    @@ -542,12 +520,10 @@
     164
     165
     166
    -167
    -168
    -169
    +167 -
    # File 'lib/felflame/component_manager.rb', line 156
    +      
    # File 'lib/felflame/component_manager.rb', line 154
     
     def initialize(**attrs)
       # Prepare the object
    @@ -614,12 +590,12 @@
           
     
     
    -206
    -207
    -208
    +202 +203 +204
    -
    # File 'lib/felflame/component_manager.rb', line 206
    +      
    # File 'lib/felflame/component_manager.rb', line 202
     
     def addition_triggers
       @addition_triggers ||= []
    @@ -670,12 +646,12 @@
           
     
     
    -222
    -223
    -224
    +218 +219 +220
    -
    # File 'lib/felflame/component_manager.rb', line 222
    +      
    # File 'lib/felflame/component_manager.rb', line 218
     
     def attr_triggers
       @attr_triggers ||= {}
    @@ -726,12 +702,12 @@
           
     
     
    -214
    -215
    -216
    +210 +211 +212
    -
    # File 'lib/felflame/component_manager.rb', line 214
    +      
    # File 'lib/felflame/component_manager.rb', line 210
     
     def removal_triggers
       @removal_triggers ||= []
    @@ -787,12 +763,12 @@
           
     
     
    -133
    -134
    -135
    +131 +132 +133
    -
    # File 'lib/felflame/component_manager.rb', line 133
    +      
    # File 'lib/felflame/component_manager.rb', line 131
     
     def addition_triggers
       @addition_triggers ||= []
    @@ -843,12 +819,12 @@
           
     
     
    -149
    -150
    -151
    +147 +148 +149
    -
    # File 'lib/felflame/component_manager.rb', line 149
    +      
    # File 'lib/felflame/component_manager.rb', line 147
     
     def attr_triggers
       @attr_triggers ||= {}
    @@ -899,12 +875,12 @@
           
     
     
    -141
    -142
    -143
    +139 +140 +141
    -
    # File 'lib/felflame/component_manager.rb', line 141
    +      
    # File 'lib/felflame/component_manager.rb', line 139
     
     def removal_triggers
       @removal_triggers ||= []
    @@ -922,78 +898,7 @@
     
         
           
    -

    - - #attr_changed_trigger_systems(attr) ⇒ Boolean - - - - - -

    -
    - -

    Execute systems that have been added to execute on variable change

    - - -
    -
    -
    - -

    Returns:

    -
      - -
    • - - - (Boolean) - - - - — -
      -

      true

      -
      - -
    • - -
    - -
    - - - - -
    -
    -
    -
    -260
    -261
    -262
    -263
    -264
    -265
    -266
    -267
    -268
    -
    -
    # File 'lib/felflame/component_manager.rb', line 260
    -
    -def attr_changed_trigger_systems(attr)
    -  systems_to_execute = self.class.attr_triggers[attr]
    -  systems_to_execute = [] if systems_to_execute.nil?
    -
    -  systems_to_execute |= attr_triggers[attr] unless attr_triggers[attr].nil?
    -
    -  systems_to_execute.sort_by(&:priority).reverse_each(&:call)
    -  true
    -end
    -
    -
    - -
    -

    +

    #deleteBoolean @@ -1036,6 +941,8 @@
     
     
    +269
    +270
     271
     272
     273
    @@ -1046,12 +953,10 @@
     278
     279
     280
    -281
    -282
    -283
    +281

    -
    # File 'lib/felflame/component_manager.rb', line 271
    +      
    # File 'lib/felflame/component_manager.rb', line 269
     
     def delete
       addition_triggers.each do |system|
    @@ -1110,12 +1015,12 @@
           
     
     
    -235
    -236
    -237
    +231 +232 +233
    -
    # File 'lib/felflame/component_manager.rb', line 235
    +      
    # File 'lib/felflame/component_manager.rb', line 231
     
     def entities
       @entities ||= []
    @@ -1164,17 +1069,17 @@
           
     
     
    +237
    +238
    +239
    +240
     241
     242
     243
    -244
    -245
    -246
    -247
    -248
    +244
    -
    # File 'lib/felflame/component_manager.rb', line 241
    +      
    # File 'lib/felflame/component_manager.rb', line 237
     
     def entity
       if entities.empty?
    @@ -1201,7 +1106,7 @@
     
    -

    Returns A hash, where all the keys are attributes linked to their respective values.

    +

    Returns A hash, where all the keys are attributes storing their respective values.

    @@ -1220,7 +1125,7 @@ —
    -

    A hash, where all the keys are attributes linked to their respective values.

    +

    A hash, where all the keys are attributes storing their respective values.

    @@ -1233,16 +1138,16 @@
     
     
    +284
    +285
     286
     287
     288
     289
    -290
    -291
    -292
    +290
    -
    # File 'lib/felflame/component_manager.rb', line 286
    +      
    # File 'lib/felflame/component_manager.rb', line 284
     
     def to_h
       return_hash = instance_variables.each_with_object({}) do |key, final|
    @@ -1300,14 +1205,14 @@
           
     
     
    -252
    -253
    -254
    -255
    -256
    +248 +249 +250 +251 +252
    -
    # File 'lib/felflame/component_manager.rb', line 252
    +      
    # File 'lib/felflame/component_manager.rb', line 248
     
     def update_attrs(**opts)
       opts.each do |key, value|
    @@ -1324,7 +1229,7 @@
     
    -- cgit v1.2.3