felecs 5.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.byebug_history +20 -0
- data/.gitignore +17 -0
- data/.inch.yml +11 -0
- data/.rspec +1 -0
- data/.rubocop.yml +13 -0
- data/.ruby-version +1 -0
- data/CHANGELOG.mdown +80 -0
- data/Gemfile +10 -0
- data/Gemfile.lock +87 -0
- data/LICENSE +21 -0
- data/README.mdown +465 -0
- data/Rakefile +66 -0
- data/bin/console +15 -0
- data/bin/setup +8 -0
- data/docs/CNAME +1 -0
- data/docs/FelECS/ComponentManager.html +1239 -0
- data/docs/FelECS/Components.html +337 -0
- data/docs/FelECS/Entities.html +792 -0
- data/docs/FelECS/Order.html +251 -0
- data/docs/FelECS/Scenes.html +765 -0
- data/docs/FelECS/Stage.html +572 -0
- data/docs/FelECS/Systems.html +1505 -0
- data/docs/FelECS.html +335 -0
- data/docs/FelFlame/ComponentManager.html +1239 -0
- data/docs/FelFlame/Components.html +333 -0
- data/docs/FelFlame/Entities.html +792 -0
- data/docs/FelFlame/Helper/ComponentManager.html +1627 -0
- data/docs/FelFlame/Helper.html +142 -0
- data/docs/FelFlame/Order.html +251 -0
- data/docs/FelFlame/Scenes.html +765 -0
- data/docs/FelFlame/Stage.html +572 -0
- data/docs/FelFlame/Systems.html +1505 -0
- data/docs/FelFlame.html +319 -0
- data/docs/Felflame_.html +143 -0
- data/docs/_index.html +188 -0
- data/docs/class_list.html +51 -0
- data/docs/css/common.css +1 -0
- data/docs/css/full_list.css +58 -0
- data/docs/css/style.css +497 -0
- data/docs/file.README.html +560 -0
- data/docs/file.version.html +74 -0
- data/docs/file_list.html +56 -0
- data/docs/frames.html +17 -0
- data/docs/index.html +560 -0
- data/docs/js/app.js +314 -0
- data/docs/js/full_list.js +216 -0
- data/docs/js/jquery.js +4 -0
- data/docs/method_list.html +419 -0
- data/docs/top-level-namespace.html +137 -0
- data/felecs.gemspec +45 -0
- data/lib/felecs/component_manager.rb +279 -0
- data/lib/felecs/entity_manager.rb +160 -0
- data/lib/felecs/order.rb +24 -0
- data/lib/felecs/scene_manager.rb +69 -0
- data/lib/felecs/stage_manager.rb +47 -0
- data/lib/felecs/system_manager.rb +258 -0
- data/lib/felecs/version.rb +9 -0
- data/lib/felecs.rb +67 -0
- data/mrbgem/mrbgem.rake +4 -0
- data/mrbgem/mrblib/felecs.rb +913 -0
- metadata +229 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: dbda9ce032a8ff902776ae17f14b7f78774b175258afa64c1dbb4257dff0d222
|
4
|
+
data.tar.gz: 9b23f4dba597faa05786db1d0d85f8bc784c77ae6875d1b42baa1ae2ebae58c6
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: da3173f2b0d9668be1c9a34632d84c29c1a9ea4dc03f40d4fb0d9c14f1456effe672f3c356c429fd7ac47afc6eb611dc616f5b0693216ddbd7154e3906a52132
|
7
|
+
data.tar.gz: a177121dfa9e697960cef37f4576c21e269531f37f09acb7f5e67ef7525bb366a2986c055fcdc153c1274430764f2a655a3006530d92d3b45984543120a9f88b
|
data/.byebug_history
ADDED
data/.gitignore
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
/.bundle/
|
2
|
+
/pkg/
|
3
|
+
/spec/reports/
|
4
|
+
/tmp/
|
5
|
+
|
6
|
+
# Ignore generated coverage
|
7
|
+
coverage/*
|
8
|
+
coverage
|
9
|
+
|
10
|
+
# Ignore yard metadata
|
11
|
+
.yardoc/*
|
12
|
+
.yardoc
|
13
|
+
/_yardoc/
|
14
|
+
|
15
|
+
# Ignore codeclimate executable and env vars
|
16
|
+
codeclimate/env.rb
|
17
|
+
codeclimate/test-reporter-latest-linux-amd64
|
data/.inch.yml
ADDED
@@ -0,0 +1,11 @@
|
|
1
|
+
files:
|
2
|
+
# define files included in the analysis (defaults to ["{app,lib}/**/*.rb"])
|
3
|
+
included:
|
4
|
+
- lib/felflame.rb
|
5
|
+
- lib/felflame/component_manager.rb
|
6
|
+
- lib/felflame/entity_manager.rb
|
7
|
+
- lib/felflame/system_manager.rb
|
8
|
+
- lib/felflame/scene_manager.rb
|
9
|
+
- lib/felflame/stage_manager.rb
|
10
|
+
# define files excluded from the analysis (defaults to [])
|
11
|
+
excluded:
|
data/.rspec
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
--require spec_helper
|
data/.rubocop.yml
ADDED
data/.ruby-version
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
2.7.3
|
data/CHANGELOG.mdown
ADDED
@@ -0,0 +1,80 @@
|
|
1
|
+
# ChangeLog
|
2
|
+
|
3
|
+
###### [major.minor.bugfix] - year-month-day
|
4
|
+
|
5
|
+
![Fixed](https://img.shields.io/badge/-Fixed-blue)
|
6
|
+
![Added](https://img.shields.io/badge/-Added-brightgreen)
|
7
|
+
![Changed](https://img.shields.io/badge/-Changed-yellow)
|
8
|
+
![Deprecated](https://img.shields.io/badge/-Deprecated-orange)
|
9
|
+
![Removed](https://img.shields.io/badge/-Removed-red)
|
10
|
+
|
11
|
+
## [5.0.0](https://github.com/realtradam/FelFlame/releases/tag/5.0.0) - 2022-02-02
|
12
|
+
![Changed](https://img.shields.io/badge/-Changed-yellow)
|
13
|
+
- Renamed to FelECS
|
14
|
+
|
15
|
+
![Fixed](https://img.shields.io/badge/-Fixed-blue)
|
16
|
+
- Trigger on attr_changed was fixed to now trigger the system after the attr value is changed.
|
17
|
+
|
18
|
+
## [4.0.0](https://github.com/realtradam/FelFlame/releases/tag/4.0.0) - 2021-12-30
|
19
|
+
![Removed](https://img.shields.io/badge/-Removed-red)
|
20
|
+
- Removed all ids as they were not used
|
21
|
+
|
22
|
+
![Changed](https://img.shields.io/badge/-Changed-yellow)
|
23
|
+
- Scenes now have their own priority attribute
|
24
|
+
- Stages now sort and execute by Scenes, rather then the net Systems in the Scenes
|
25
|
+
- Component method `.attrs` was renamed to `.to_h`
|
26
|
+
- Renamed the `data` accessor to `._data`
|
27
|
+
- Various arrays are automatically compacted
|
28
|
+
|
29
|
+
![Added](https://img.shields.io/badge/-Added-brightgreen)
|
30
|
+
- Classes and Modules which used a data array now have the entire set of array methods available to their respective Classes and Modules
|
31
|
+
- Convenience methods for accessing a single entity in a component(`@component.entity`) and accessing a single entity in a component(`@entity.component[@component_manager]`)
|
32
|
+
- `FelFlame::Order` class which can set the order of your Scenes and Systems
|
33
|
+
|
34
|
+
![Fixed](https://img.shields.io/badge/-Fixed-blue)
|
35
|
+
- Replaced all instances of `sort_by!` with `sort_by` for compatibility with mruby
|
36
|
+
- Minor optimizations such as less array duplication
|
37
|
+
|
38
|
+
## [3.0.0](https://github.com/realtradam/FelFlame/releases/tag/3.0.0) - 2021-07-12
|
39
|
+
![Changed](https://img.shields.io/badge/-Changed-yellow)
|
40
|
+
- The Scene alias was changed from ```FelFlame::Sce``` to ```FelFlame::Scn``` as it is more intuitive.
|
41
|
+
|
42
|
+
## [2.0.0](https://github.com/realtradam/FelFlame/releases/tag/2.0.0) - 2021-07-10
|
43
|
+
![Changed](https://img.shields.io/badge/-Changed-yellow)
|
44
|
+
- Entities and Components now reference each other using the objects themselves rather then their id's
|
45
|
+
```ruby
|
46
|
+
# before:
|
47
|
+
@entity.components[@component_manager].each do |component_id|
|
48
|
+
# iterate over id's, usually would need to do a lookup to get the component itself
|
49
|
+
end
|
50
|
+
|
51
|
+
# after:
|
52
|
+
@entity.components[@component_manager].each do |component|
|
53
|
+
# iterate over the components themselves! No need for lookup anymore
|
54
|
+
end
|
55
|
+
```
|
56
|
+
```ruby
|
57
|
+
# same for components referencing entities
|
58
|
+
# before:
|
59
|
+
@component.entities.each do |entity_id|
|
60
|
+
#iterate over id's
|
61
|
+
end
|
62
|
+
|
63
|
+
# after:
|
64
|
+
@component.entities.each do |entity|
|
65
|
+
# directly iterate over entities themselves!
|
66
|
+
end
|
67
|
+
```
|
68
|
+
|
69
|
+
|
70
|
+
## [1.0.2](https://github.com/realtradam/FelFlame/releases/tag/1.0.2) - 2021-07-09
|
71
|
+
![Fixed](https://img.shields.io/badge/-Fixed-blue)
|
72
|
+
- Stripped superflous files shrinking gem size significantly
|
73
|
+
|
74
|
+
## [1.0.1](https://github.com/realtradam/FelFlame/releases/tag/1.0.1) - 2021-07-09
|
75
|
+
![Fixed](https://img.shields.io/badge/-Fixed-blue)
|
76
|
+
- Defining attributes in components are no longer allowed to overwrite methods
|
77
|
+
|
78
|
+
## [1.0.0](https://github.com/realtradam/FelFlame/releases/tag/1.0.0) - 2021-07-09
|
79
|
+
![Added](https://img.shields.io/badge/-Added-brightgreen)
|
80
|
+
- Initial release
|
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
@@ -0,0 +1,87 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
felecs (5.0.0)
|
5
|
+
|
6
|
+
GEM
|
7
|
+
remote: https://rubygems.org/
|
8
|
+
specs:
|
9
|
+
ansi (1.5.0)
|
10
|
+
ast (2.4.2)
|
11
|
+
builder (3.2.4)
|
12
|
+
diff-lcs (1.4.4)
|
13
|
+
docile (1.4.0)
|
14
|
+
minitest (5.14.4)
|
15
|
+
minitest-reporters (1.4.3)
|
16
|
+
ansi
|
17
|
+
builder
|
18
|
+
minitest (>= 5.0)
|
19
|
+
ruby-progressbar
|
20
|
+
parallel (1.20.1)
|
21
|
+
parser (3.0.2.0)
|
22
|
+
ast (~> 2.4.1)
|
23
|
+
rainbow (3.0.0)
|
24
|
+
rake (13.0.6)
|
25
|
+
redcarpet (3.5.1)
|
26
|
+
regexp_parser (2.1.1)
|
27
|
+
rexml (3.2.5)
|
28
|
+
rspec (3.10.0)
|
29
|
+
rspec-core (~> 3.10.0)
|
30
|
+
rspec-expectations (~> 3.10.0)
|
31
|
+
rspec-mocks (~> 3.10.0)
|
32
|
+
rspec-core (3.10.1)
|
33
|
+
rspec-support (~> 3.10.0)
|
34
|
+
rspec-expectations (3.10.1)
|
35
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
36
|
+
rspec-support (~> 3.10.0)
|
37
|
+
rspec-mocks (3.10.2)
|
38
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
39
|
+
rspec-support (~> 3.10.0)
|
40
|
+
rspec-support (3.10.2)
|
41
|
+
rubocop (1.18.3)
|
42
|
+
parallel (~> 1.10)
|
43
|
+
parser (>= 3.0.0.0)
|
44
|
+
rainbow (>= 2.2.2, < 4.0)
|
45
|
+
regexp_parser (>= 1.8, < 3.0)
|
46
|
+
rexml
|
47
|
+
rubocop-ast (>= 1.7.0, < 2.0)
|
48
|
+
ruby-progressbar (~> 1.7)
|
49
|
+
unicode-display_width (>= 1.4.0, < 3.0)
|
50
|
+
rubocop-ast (1.7.0)
|
51
|
+
parser (>= 3.0.1.1)
|
52
|
+
ruby-progressbar (1.11.0)
|
53
|
+
simplecov (0.21.2)
|
54
|
+
docile (~> 1.1)
|
55
|
+
simplecov-html (~> 0.11)
|
56
|
+
simplecov_json_formatter (~> 0.1)
|
57
|
+
simplecov-console (0.9.1)
|
58
|
+
ansi
|
59
|
+
simplecov
|
60
|
+
terminal-table
|
61
|
+
simplecov-html (0.12.3)
|
62
|
+
simplecov_json_formatter (0.1.3)
|
63
|
+
terminal-table (3.0.1)
|
64
|
+
unicode-display_width (>= 1.1.1, < 3)
|
65
|
+
unicode-display_width (2.0.0)
|
66
|
+
yard (0.9.26)
|
67
|
+
|
68
|
+
PLATFORMS
|
69
|
+
ruby
|
70
|
+
|
71
|
+
DEPENDENCIES
|
72
|
+
felecs!
|
73
|
+
minitest-reporters (~> 1.4, >= 1.4.3)
|
74
|
+
rake (~> 13.0)
|
75
|
+
redcarpet (~> 3.5, >= 3.5.1)
|
76
|
+
rspec (~> 3.10)
|
77
|
+
rubocop (~> 1.7)
|
78
|
+
simplecov (~> 0.21.2)
|
79
|
+
simplecov-console (~> 0.9.1)
|
80
|
+
simplecov_json_formatter (~> 0.1.3)
|
81
|
+
yard (~> 0.9.26)
|
82
|
+
|
83
|
+
RUBY VERSION
|
84
|
+
ruby 2.7.3p183
|
85
|
+
|
86
|
+
BUNDLED WITH
|
87
|
+
2.1.4
|
data/LICENSE
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
MIT License
|
2
|
+
|
3
|
+
Copyright (c) 2021 _Tradam
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
13
|
+
copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
21
|
+
SOFTWARE.
|