Search found 26 matches

by bvargish
Tue Nov 03, 2015 8:08 pm
Forum: Bug reports
Topic: Possible JSON export glitch breaking Phaser callbacks
Replies: 5
Views: 31991

Re: Possible JSON export glitch breaking Phaser callbacks

By re-export I meant Export scene > Save raw info (JSON).

Please ignore this for now. If I can reliably duplicate this I'll provide all the files.
by bvargish
Mon Nov 02, 2015 9:39 pm
Forum: Bug reports
Topic: Possible JSON export glitch breaking Phaser callbacks
Replies: 5
Views: 31991

Re: Possible JSON export glitch breaking Phaser callbacks

Oops just realized I should have attached the JSON files. If I encounter this on another level I'll attach them. I no longer have the old JSON file.
by bvargish
Mon Nov 02, 2015 9:35 pm
Forum: Bug reports
Topic: Possible JSON export glitch breaking Phaser callbacks
Replies: 5
Views: 31991

Possible JSON export glitch breaking Phaser callbacks

I'm loading different scenes created in R.U.B.E. into Phaser and using setBodyContactCallback to detect a body's collision with sensors. The callbacks were only working for one of my levels for some reason. I compared every aspect of the body and sensors and all of the parameters were set the same. ...
by bvargish
Thu Oct 29, 2015 6:41 pm
Forum: Useful rubescripts
Topic: Make vertices at intersections of two overlapping polygons
Replies: 11
Views: 46940

Re: Make vertices at intersections of two overlapping polygo

Thanks again for your insight! As always, very helpful! I was thinking I'd use an open loop for a static ground shape like the one below. I highlighted where the line would be. I could add points to close it up, but nothing will ever hit the bottom of the line so I figured less points would be bette...
by bvargish
Wed Oct 28, 2015 6:41 pm
Forum: Useful rubescripts
Topic: Make vertices at intersections of two overlapping polygons
Replies: 11
Views: 46940

Re: Make vertices at intersections of two overlapping polygo

Awesome, thanks! Wouldn't I use a line rather than a loop in my case? Is a loop essentially just a closed line? If so, how is that any different from a polygon? If I had a simpler shape like a plus sign, would I be better off welding two rectangles together (2 shapes) rather than merging them into a...
by bvargish
Tue Oct 27, 2015 7:16 pm
Forum: Useful rubescripts
Topic: Make vertices at intersections of two overlapping polygons
Replies: 11
Views: 46940

Re: Make vertices at intersections of two overlapping polygo

Wow! This is really cool! Thank you! My end goal is indeed to make all the existing polygons into a handful of loop shapes, which I think Add body with edge fixture creates. Please correct me if I'm wrong! Basically what I'd be doing is keeping the top surface terrain points and deleting all the res...
by bvargish
Thu Oct 22, 2015 9:06 pm
Forum: Useful rubescripts
Topic: Make vertices at intersections of two overlapping polygons
Replies: 11
Views: 46940

Re: Make vertices at intersections of two overlapping polygo

Thanks so much! And sorry, I meant that the script stopped executing, not that the program crashed. There must have been something funky with the math code I snagged off the web because yours works fine. I updated your code to check every side of a fixture and log all intersection points, which is s...
by bvargish
Thu Oct 22, 2015 4:38 pm
Forum: R.U.B.E discussion
Topic: Need help making a motorized wheel
Replies: 2
Views: 10276

Re: Need help making a motorized wheel

Thanks for your reply! Yes, I watched that video and looked at the examples, but I was getting confused because my wheel isn't anchored to an external body. The gear is at the same position of the wheel, like it's internal to it. I also wasn't sure whether to use a wheel joint or a revolute joint. A...
by bvargish
Wed Oct 21, 2015 8:49 pm
Forum: Useful rubescripts
Topic: Make vertices at intersections of two overlapping polygons
Replies: 11
Views: 46940

Re: Make vertices at intersections of two overlapping polygo

I'm so close! For some reason my intersection points are slightly off. The body2 dotted line is pointing to a line that contains the intersection points on each end. They should be up and to the left where the two shapes overlap. Any ideas why this might be? Here's my code and an image. fixture f1 =...
by bvargish
Wed Oct 21, 2015 6:50 pm
Forum: Useful rubescripts
Topic: Make vertices at intersections of two overlapping polygons
Replies: 11
Views: 46940

Make vertices at intersections of two overlapping polygons

I'm working on a rubescript that will make vertices at the intersections of two overlapping polygons, with the ultimate goal of making a script that will merge two overlapping polygons. Just getting the vertices so I can create a new shape using their info will suffice for now, though. Before I post...