baku 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ef2e30c0edfd4e7d4a9c462415f0bd8f67c5d92b
4
- data.tar.gz: ba0f22754231f5a9b4000db4e57b81a77021fc4e
3
+ metadata.gz: 3acdc8865ba365f5af863c36a85be4db11ed681c
4
+ data.tar.gz: eee1b0ba43a5a33483caa7baa809618ee4154961
5
5
  SHA512:
6
- metadata.gz: f33c07b0b01ef3e566a4b6f5ccbb6fbc747c11664e58b0706931b7a03e9c28e58caaaffc91683bee98a1a0d5c682433e2b66b7bb1a9d3a27ba33d0c94988e20b
7
- data.tar.gz: 6dd881ee7ff3349a911993e2c3a4b0bd460993c86ed3f14a3e2b21c5e5e8fe93493b124df5634530abd99ddd22db7fcf1b0a82e989c2021c50c9b5cc22577727
6
+ metadata.gz: 339e6f8a610ffe4f11101eb98868bc70a5d17959e1f2cb72dbd89238d8dd68e857a18fd76fdb9d80dd73d436c515d50075f6335e6fab742bae6af7de44049fc6
7
+ data.tar.gz: 77dbacbd13d4882ef2b9655db1bb52f778224d3f75733b5789b5aba24664f415f57df6bdb03b9573752eb3f2770f547e8c65f4aabc6a9f693adf0bbbdcbb500c
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ # 0.2.2
2
+
3
+ * Fix entities being added to entity manager multiple times.
4
+
1
5
  # 0.2.1
2
6
 
3
7
  * Restore system access to world delta_ms.
@@ -56,7 +56,9 @@ module Baku
56
56
 
57
57
  def add_entity_to_matching_component_lists(entity)
58
58
  @entities_by_component_mask.each do |component_mask, entities|
59
- if component_mask.matches?(entity.component_mask)
59
+ component_mask_match = component_mask.matches?(entity.component_mask)
60
+
61
+ if component_mask_match && !entities.include?(entity)
60
62
  entities << entity
61
63
  end
62
64
  end
data/lib/baku/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Baku
2
- VERSION = "0.2.1"
2
+ VERSION = "0.2.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: baku
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Tuttle