mirror of
https://github.com/cyberarm/i-mic-fps.git
synced 2025-12-15 23:52:35 +00:00
Refactored bounding box to use 2 vectors, stubbed PhysicsManager.
This commit is contained in:
@@ -12,7 +12,7 @@ class IMICFPS
|
||||
if @root
|
||||
@root.insert_subtree(bounding_box.dup, object)
|
||||
else
|
||||
@root = AABBNode.new(parent: nil, object: object, bounding_box: BoundingBox.new(0,0,0, 0,0,0))
|
||||
@root = AABBNode.new(parent: nil, object: object, bounding_box: BoundingBox.new)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -48,6 +48,15 @@ class IMICFPS
|
||||
@b = nil
|
||||
end
|
||||
|
||||
def make_leaf
|
||||
@a = nil
|
||||
@b = nil
|
||||
end
|
||||
|
||||
def make_branch(node_a, node_b)
|
||||
|
||||
end
|
||||
|
||||
def insert_subtree(bounding_box, object)
|
||||
# p "#{bounding_box} -> #{object.class}"
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user