From 866ed5e2ca86d2f780492f01c30b3350037d3f7c Mon Sep 17 00:00:00 2001 From: realtradam Date: Thu, 3 Feb 2022 04:18:07 -0500 Subject: added new group method for entity manager --- docs/FelFlame/Scenes.html | 765 ---------------------------------------------- 1 file changed, 765 deletions(-) delete mode 100644 docs/FelFlame/Scenes.html (limited to 'docs/FelFlame/Scenes.html') diff --git a/docs/FelFlame/Scenes.html b/docs/FelFlame/Scenes.html deleted file mode 100644 index 68f4ece..0000000 --- a/docs/FelFlame/Scenes.html +++ /dev/null @@ -1,765 +0,0 @@ - - - - - - - Class: FelFlame::Scenes - - — Documentation by YARD 0.9.26 - - - - - - - - - - - - - - - - - - - -
- - -

Class: FelFlame::Scenes - - - -

-
- -
-
Inherits:
-
- Object - -
    -
  • Object
  • - - - -
- show all - -
-
- - - - - - - - - - - -
-
Defined in:
-
lib/felflame.rb,
- lib/felflame/scene_manager.rb
-
-
- -
- -

Overview

-
- -

Creates and manages Scenes. Scenes are collections of Systems, and execute all the Systems when called upon. Any scenes you create are accessable under the Scenes namespace as Constants.

- - -
-
-
- - -
- - - -

Instance Attribute Summary collapse

-
    - -
  • - - - #priority ⇒ Object - - - - - - - - - - - - - - - - -
    -

    How early this Scene should be executed in a list of Scenes.

    -
    - -
  • - - -
  • - - - #systems ⇒ Array<System> - - - - - - - - - readonly - - - - - - - - - -
    -

    The list of Systems this Scene contains.

    -
    - -
  • - - -
- - - - - -

- Instance Method Summary - collapse -

- - - - -
-

Constructor Details

- -
-

- - #initialize(name, priority: 0) ⇒ Scenes - - - - - -

-
- -

Create a new Scene using the name given

- - -
-
-
-

Parameters:

-
    - -
  • - - name - - - (String) - - - - — -
    -

    String format must follow requirements of a constant

    -
    - -
  • - -
- - -
- - - - -
-
-
-
-22
-23
-24
-25
-
-
# File 'lib/felflame/scene_manager.rb', line 22
-
-def initialize(name, priority: 0)
-  self.priority = priority
-  FelFlame::Scenes.const_set(name, self)
-end
-
-
- -
- -
-

Instance Attribute Details

- - - -
-

- - #priorityObject - - - - - -

-
- -

How early this Scene should be executed in a list of Scenes

- - -
-
-
- - -
- - - - -
-
-
-
-12
-13
-14
-
-
# File 'lib/felflame/scene_manager.rb', line 12
-
-def priority
-  @priority
-end
-
-
- - - -
-

- - #systemsArray<System> - - - - - -

-
- -

The list of Systems this Scene contains

- - -
-
-
- -

Returns:

-
    - -
  • - - - (Array<System>) - - - -
  • - -
- -
- - - - -
-
-
-
-29
-30
-31
-
-
# File 'lib/felflame/scene_manager.rb', line 29
-
-def systems
-  @systems ||= []
-end
-
-
- -
- - -
-

Instance Method Details

- - -
-

- - #add(*systems_to_add) ⇒ Boolean - - - - - -

-
- -

Adds any number of Systems to this Scene

- - -
-
-
- -

Returns:

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

    true

    -
    - -
  • - -
- -
- - - - -
-
-
-
-42
-43
-44
-45
-46
-47
-48
-49
-
-
# File 'lib/felflame/scene_manager.rb', line 42
-
-def add(*systems_to_add)
-  self.systems |= systems_to_add
-  self.systems = systems.sort_by(&:priority)
-  systems_to_add.each do |system|
-    system.scenes |= [self]
-  end
-  true
-end
-
-
- -
-

- - #callBoolean - - - - - -

-
- -

Execute all systems in this Scene, in the order of their priority

- - -
-
-
- -

Returns:

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

    true

    -
    - -
  • - -
- -
- - - - -
-
-
-
-35
-36
-37
-38
-
-
# File 'lib/felflame/scene_manager.rb', line 35
-
-def call
-  systems.each(&:call)
-  true
-end
-
-
- -
-

- - #clearBoolean - - - - - -

-
- -

Removes all Systems from this Scene

- - -
-
-
- -

Returns:

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

    true

    -
    - -
  • - -
- -
- - - - -
-
-
-
-60
-61
-62
-63
-64
-65
-66
-67
-
-
# File 'lib/felflame/scene_manager.rb', line 60
-
-def clear
-  systems.each do |system|
-    system.scenes.delete self
-  end
-  systems.clear
-  # FelFlame::Stage.update_systems_list if FelFlame::Stage.scenes.include? self
-  true
-end
-
-
- -
-

- - #remove(*systems_to_remove) ⇒ Boolean - - - - - -

-
- -

Removes any number of Systems from this Scene

- - -
-
-
- -

Returns:

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

    true

    -
    - -
  • - -
- -
- - - - -
-
-
-
-53
-54
-55
-56
-
-
# File 'lib/felflame/scene_manager.rb', line 53
-
-def remove(*systems_to_remove)
-  self.systems -= systems_to_remove
-  true
-end
-
-
- -
- -
- - - -
- - \ No newline at end of file -- cgit v1.2.3