Images won't load on Device

General discussion about the R.U.B.E editor
Post Reply
Phantom Ppepper
Posts: 22
Joined: Tue Sep 10, 2013 3:59 am

Images won't load on Device

Post by Phantom Ppepper »

(Enters Noob)

OK, Just bought RUBE and I'm thoroughly excited. I'm using the Cocos2d Loader example XCODE Project. It runs great on my phone as well as the ios simulator without touching anything.

What I did: I essentially opened up the "images" scene (from the cocos2d sample loader) in rube, deleted everything, played around and saved it as another .json file (and rube project).

So in XCODE, I simply updated @"images.json" with my new .json file and it works great ... on the ios simulator.

However, on my device, the images are not there. The bodies are there, but not the images. I appriciate any and all feed back, as I have only about a month worth experience using Xcode, let alone any real programming experience.

TLDR- Images won't load on device. They do on the ios simulator however.
iforce2d
Site Admin
Posts: 861
Joined: Sat Dec 22, 2012 7:20 pm

Re: Images won't load on Device

Post by iforce2d »

Are there any clues in the output from the program (in the debug log panel)?
My guess is that you have added some images of your own, but those image files are not being copied into the bundle when building. Sometimes Xcode stubbornly refuses to detect new resources that you have added under a folder that is a 'reference' (blue folder icon in the project). You could try a full rebuild (clean product, then build product).
Phantom Ppepper
Posts: 22
Joined: Tue Sep 10, 2013 3:59 am

Re: Images won't load on Device

Post by Phantom Ppepper »

ok, interesting. I'm going to make a guess. I noticed that the error I am getting obviously says that the image path was not found. And I think that might have to do with how I originally started building the scene. I dropped some images from a Dropbox folder into rube. Then copied these images into the resources folder in the XCODE project. So on my computer, the ios simulator obviously has native access to the dropbox folder, but on my device - null.

So I assume if I rebuild the scene, in rube using the images from the project folder, this should fix it.

Looks like I just started backwards.
Post Reply