Hi, I am happy to announce that cocos2d v2.0-beta is available for download:
Highlights from v2.0-alpha:
- Forward-ported changes from v1.1 (batched particles, faster reorder, ARC compatible, and more)
- Improved
drawinternal API - Added alignment + multiline in
LabelBMFont - Added “Milliseconds per frame” in Director
- Improved internal GL cache
- and more
Full Changelog: CHANGELOG
Release Notes: Release Notes v2.0-beta
API Reference: API Reference v2.0-beta
Migration Guide: Migrating from v1.x to v2.0
v2.0 Mini FAQ:
Q: Should I use v2.0 or v1.0 ?
- A: It depends on your requirements, and varies from case to case.
- A: If you need to support older devices (1st & 2nd generation iPhones) you should use cocos2d v1.x
- A: If you need to GL shaders, you should use cocos2d v2.x
- A: v2.0 is about supporting new technologies (blocks, OpenGL ES 2.0, etc) and improving the current API, while cocos2d v1.x is about backward compatibility
Q: How stable is v2.0-beta ?
- A: From a code point of view, it is pretty stable. At Zynga, we have just released a game that is based on cocos2d v2.0 (DreamZoo)
- A: But from an API point of view, you should know that the API is still not stable. It might change a bit until v2.0-final is released.
Q: When v2.0-final will be released ?
- A:Most probably during Q1 2012, perhaps in February.






cocos2d v1.1 final release still coming soon or stopped? Thanks riq, good job!
What a surprise! Thanks for this new version. I have updated my shooter project and all is working fine and smooth.
Thanks all cocos2d developers for such a hard work!
Hi guys,
i tried to install templates but i got the message permission denied… any solution?
sudo is not supported why?
thanks
@melvinng05 The 1.x branch is still in active development, so yes, 1.1 is still coming.
araker concentrates on the 1.x branch and riq now concentrates on 2.x.
Been trying to implement shaders in this version, I cant get anything going.
I decided to look at the tests to see if I could pinpoint the problem, but the shader tests appear broken to me (only the Blur shader appears) the rest throw endless errors:
OpenGL error 0×0502 in -[CCSprite draw] 552
@diadem_lee:
It is already fixed on github, on the “gles20″ branch:
https://github.com/cocos2d/cocos2d-iphone/tree/gles20
@riq
Thanks, got this working without issue!
Any plans to do a little writeup on the openGL changes? They were challenging for me to adapt to, especially as a openGL noob trying to learn.
@diadem_lee:
I suggest reading this book: http://shop.oreilly.com/product/9780596804831.do
It shows how to code both using OpenGL ES 1.1 and ES 2.0.
You will learn a lot about openGL ES.
@riq thanks for the book suggestion, i will check it out.
What I was referring to was not pure openGL but more the wrapper/convenience functions Cocos2D has implemented. It has taken me a while to understand the specifics of how to get started in the Cocos2D environment. There are tutorials out there, but the recent changes seem to break them.
Once I had the working version of the tests of course it was much easier to just read through the code. I guess I was just hoping for a blurb on the design goals/best practices to the changes, if that makes sense?
For example, I am specifically having issue with ccGLBindTexture2D. I think its implementing a cache of some sort, but when I try to use it I am having problems. I have rolled back to using glBindTexture directly.
Thanks!
@diadem_lee:
I think this guide might help you:
http://www.cocos2d-iphone.org/wiki/doku.php/prog_guide:migrate_to_v2.0
Hi,
First of all, I would like to thank everyone worked on cocos2d, it is really a wonderful treasure of APIs.
I tried cocos2d v2 beta, and noticed there is a problem while running the game for performance analysis from within Xcdoe, by choosing profile, and then pick any performance tool in the instruments, once start launching it gives error ‘failed to get task for pid xxx’ , it will only run if i started the instrument and run the game from there ?
I tried the same game code, with the stable release v1.1 it is working perfectly.?
Thanks once again, and looking forward to address this in the stable release, or if currently there is a solution, please let me know.
Thanks.
@Ammar Al-Issa: No idea
What Xcode version are you using ?
Thanks for replying, I discovered the issue, it was little bit strange, i just deleted the game, and deleted the provisioning profile, then run it once again, it worked perfectly.
Thanks
Hi Riq, I’m trying out to migrate custom CCSprite#draw to cocos2d 2.0 beta … I followed the 1.0->2.0 migration guide but I keep getting EXC_BAD_ACCESS inside the CC_NODE_DRAW_SETUP() macro on the ccGLUseProgram( shaderProgram_->program_ ); line. I’m using the cocos2d beta download + ARC, would appreciate bit of help with this
Marin
@Marin
Please, post the traceback and the exact code that you are using. Also I suggest using the latest code form github.
riq, I figured it out – in the migration guide it’s not mentioned you actually have to load the shader program and assign it to the class. (Wasn’t that obvious for me)
Marin
hi, in the b2ContactListener class, the virtual function may be [ virtual void EndContact(b2Contact* contact); ] not be called.
ex: i create two sensor, and move one to the other, the BeginContact be called once, but the EndContact not be called when the two body divided. the first sensor run the reverse action, the BeginContact not be called
Compiling for armv6 missed CCParticleSystemPoint
Solved adding the one from v1 and including it in CCParticleExamples.h
I’m trying to archive a distribution copy of my app for the App Store. At first it was complaining that I needed to add armv6 to the settings…but when I do that I get a lot of CCParticleExample errors…
Is there a work-around or fix?