Closed jrdoughty closed 7 years ago
I went ahead and made the composites public for all classes in Objects.hx in 2bed4a4. I had already changed the Tire class to be like that since I've been using that a lot, not sure why I didn't update all of them before. Thanks for the catch!
By the way, I'd love to see what you're making :) I didn't realize anyone was working with VerletKha other than Lewis and myself.
Thanks for making the change, I'll pull it in shortly! The game is the grow your hoard folder found here: https://github.com/jrdoughty/Kha-examples Its an old Ludem Dare game I did that I'm converting to Kha, and I wanted to use a new physics engine. This one took a bit to figure out, but I've got a handle now I think on how I can make it do what I need, which is make projectiles fly!
I'm playing with adding projectiles to a game and I'm attaching those projectiles to Points. I however had to make my own point class that had the composite public:
class ProjectilePoint { public var composite:Composite; public function new(pos:Vector2) { composite = new Composite(); composite.particles.push(new Particle(pos)); Verlet.Instance.composites.push(composite); } }
Would this be a sensible change in your own opinion to the base Point Class?