FYI--
There's a thread over on the Badlogic forums (libgdx) regarding RUBE. Thought others on this site might be interested.
http://www.badlogicgames.com/forum/view ... =15&t=7522
Depending on how things go, I hope to have a basic RUBE JSON loader for libgdx running this coming weekend.
--tim
libgdx / RUBE thread
Re: libgdx / RUBE thread
Yeah I see that. Looks like you guys are getting things rolling! I am about to start traveling for a couple of weeks so I might not be online as often as usual, but if there is anything you need to know just ask and I will try to answer asap.
Re: libgdx / RUBE thread
First pass of libgdx JSON loader is up and running. It uses the libgdx Json class rather than org.json. Kudos to HeRMeS who laid the groundwork. I've been testing it today and have updated a few things in my fork.
HeRMeS github project: https://github.com/cvayer/RubeLoader
my fork of that project: https://github.com/tescott/RubeLoader
--tim
HeRMeS github project: https://github.com/cvayer/RubeLoader
my fork of that project: https://github.com/tescott/RubeLoader
--tim
Re: libgdx / RUBE thread
I've updated my fork. Now includes image support, an updated readme, and a new example demoing the loader capabilities.
https://github.com/tescott/RubeLoader
--tim
https://github.com/tescott/RubeLoader
--tim
Re: libgdx / RUBE thread
@ tescott can you please make a tutorial on using your Rube loader for libgdx ? It would help a lot, Thanks!
Re: libgdx / RUBE thread
I'll try to get something done for tomorrow. Keep an eye out!lacipalfi wrote:@ tescott can you please make a tutorial on using your Rube loader for libgdx ? It would help a lot, Thanks!
--tim
Re: libgdx / RUBE thread
Hope this helps. If you still have questions after viewing, please follow-up and I'll answer as best as I can.
http://youtu.be/hgo7Pxtcoyk
--tim
http://youtu.be/hgo7Pxtcoyk
--tim
Re: libgdx / RUBE thread
Hey love the loader Tim!
The video is also very helpful, although the first part was mainly about the rube editor itself.
Also noticed the project game me errors if i didnt have the controllers project in eclipse too (just for others to note really)
Anyway! i have a quesiton, I wonderd if you could give a quick example on how to use the loader to access specific things in the scene.
For example if you wanted to edit a specific bodys attributes in some way, whats the best way to latch onto the object?
Really appreciated!
Stew
The video is also very helpful, although the first part was mainly about the rube editor itself.
Also noticed the project game me errors if i didnt have the controllers project in eclipse too (just for others to note really)
Anyway! i have a quesiton, I wonderd if you could give a quick example on how to use the loader to access specific things in the scene.
For example if you wanted to edit a specific bodys attributes in some way, whats the best way to latch onto the object?
Really appreciated!

Stew
Re: libgdx / RUBE thread
There are a few ways to access objects:
Hope this helps!
--tim
- * scene.getWorld(): This method returns the Box2D physics world. After loading, it is populated with the bodies, joints, and fixtures from the JSON file.
* scene.getBodies(): This method returns an array of bodies created
* scene.getFixtures(): This method returns an array of fixtures created
* scene.getJoints(): This method returns an array of joints created
* scene.getImages(): This method returns an array of RubeImages defined in the JSON file. Note: it is up to the app to perform all rendering
* scene.getMappedImage(): This method returns an array of all RubeImages associated with a particular Body.
* scene.getCustom(): This method allows you to retrieve custom property info from an object.
* scene.getNamed(): This method allows you to retrieve a scene object based on name. Since multiple objects can have the same name, this returns an Array<> type.
Hope this helps!
--tim
Re: libgdx / RUBE thread
Tim, you are a Legend!
I tried tom implement it myself but i dont know my arse from my elbow with this stuff so i gave up after 2 hours! Thank you so much!
I tried tom implement it myself but i dont know my arse from my elbow with this stuff so i gave up after 2 hours! Thank you so much!
