[Solved]Constant error!

[Solved]Constant error!
0.0 0


All… I’ve followed the “Hello World” tutorials perfectly, but I cannot get build-win32.bat to compile. even when I open cocos2d-win32.vc2010 in my Visual Basic C++ 2010 Express, then click Build Solution, then try to run the Hello World & tests “exe” files, the files will not run. I only get this error:

Get data from
file(C:2d-1.0.0-x-0.9.0\Release.win32\Images/close.png) failed!

Because of this, I cannot Build what I need, and “Cocos3d” does not ever show up under Templates when I try to create a new project! Please help.

-I’m running Windows 7 64 bit


Try to do this:
Right click the project > Properties> Debugging -> Working Directory
And set the path to Resource(HelloWorld/Resource).


I have tried this without any luck. Thank you for the suggestion though. Also, I get the same error for HelloWorld & tests, and I set both directories to their respective Resource folders.

Any other ideas?


Problem solved…. or maybe just a workaround.

Since the complaint was about not having the proper image in the noted directory, I copied that image from the Resources file and pasted it into the output file * C:2d-1.0.1-x-0.9.1\Release.win32. Once I ran the .exe again, it now complained about a NEW missing image file. I then realized it needed to have all Resources copied/pasted into the Release.win32 directory. Once I did that with the HelloWorld & tests Resource files, everything now works.

Not to try and get Cocos2D to show up as a template option…

Worked! Here are the next steps I had to do to make Cocos2D show up in the Templates files.

  1. Run install-templates-msvc.bat from the C:2d-1.0.1-x-0.9.1 directory.

  2. go to directory C:2d-1.0.1-x-0.9.1\template\msvc and run InstallWizardForVC2010Express.js

After this, I went to Solution > Add> New Project , and Cocos2d now shows up!