[FIX] mac compatibility
[FIX] Cocos2D 2.1 compatibility