A cross-platform, open-source mobile 2D game framework. It is a C++ version of the cocos2d-iphone project.

learn more… | top users | synonyms

1
vote
1answer
60 views

OpenGL, C++ -> How do you lay out objects on screen?

When I used to write java code, there were layout managers like "grid bag" and box. I am working on a game using Cocos2D-X and running into trouble laying out objects on screen so that they are not ...
0
votes
0answers
10 views

Cocos2d-x beginwithclear doesn't seem to work

I am rendering two CCRenderTextures. All rendering code start with a beginwithClear call on the CCRenderetexture. However it seems that the color buffer is not cleared and the second texture I draw ...
0
votes
0answers
15 views

Cocos2d-X Adding subfolders to Classes folder throws errors

I am working on a Cocos2D-X project. I am trying to organize my code files into sub-folders inside the Classes folder. The Classes folder is being shared for both iOS and Android. If I just leave the ...
0
votes
0answers
11 views

how to play my recording with everyplay (for iOS)

I'm trying to use everyplay to record my game,but I don't know which method can play my recording. I tried: [[[Everyplay sharedInstance] capture] stopRecording]; [[Everyplay sharedInstance] ...
0
votes
0answers
13 views

How to get pixel data from PVR file?

I am wondering if it is possible to create a CCImage object with a PVR file. My goal is to get access to the pixel data of an image to perform picking. The image that is been picked is a PVR file and ...
0
votes
1answer
50 views

Inserting into SQLITE in cocos2d-x

I am using cocos2d-x to create an app in android which needs to use a database. I have used the following method, which I found whilst searching forums, to use SQLITE in cocos2d-x : use ...
1
vote
2answers
25 views

Ring and Pole - Box2d

How I can make a b2Body in box2d so that it could form a ring which does not collide from the center just like a ring. like when we flick the object and there's another body (like pole), the pole can ...
0
votes
0answers
31 views

can we port cocos2d app to Android [closed]

I have developed a game in cocos2d and want to port it in Android. Is it possible? I have read that it cross platform app can be developed using cocos2d-x. if its not possible to port cocos2d to ...
0
votes
2answers
45 views

How do I make a classwide CCArray with Cocos2d-x?

I'm just starting to learn C++ and Cocos2d-x after a couple years of Objective-C. Tonight's obstacle appears to be learning how to use the CCArray function as a classwide variable. HelloWorldScene.h ...
0
votes
1answer
13 views

sizeWithFont for Android

I am porting a cocos2d iOS game to cocos2d-x Android and the cocos2d game code has this method sizeWithFont, but I do not have this method to use in Android. So what method can I use to replace ...
0
votes
1answer
48 views

Android back button not working in Cocos2d-x

I want quit my Cocos2d-x game on back button press in Android. For this I have overloaded the CCLayer::keyBackClicked method in my class GameScene and I have also called setKeypadEnabled(true) from ...
1
vote
0answers
22 views

cocos2d-x java.lang.IllegalArgumentException: No configs match configSpec

my android device is HUAWEI C8500S Android Version:2.2.2 cocos2d-x version:2.1.1 i run my app on the Android phone ,not on the emulator. bug log: java.lang.IllegalArgumentException: No configs ...
0
votes
1answer
52 views

How do I get the screen density using Cocos2d-x?

I recently decided to pick up Android development after spending a year or two learning how to code with iOS. Now I'm trying to port my Cocos2d-iphone code over to Cocos2d-x and I'm totally confused ...
1
vote
0answers
20 views

Cocos2d HTML5 turn off anti aliasing

Does anyone know, how to turn off antialiasing in Cocos2d HTML5? I know it is possible in cocos2d, but i can't seem to find it in the HTML5 version. I'm trying to down and upscale a Sprite (0.5x and ...
0
votes
1answer
37 views

Opening a CCScene in Lua from a C++ CCScene in cocos2d-x

I'm trying to use Lua scripting and Cocos2d-x together and I'm having a bit of trouble making things work properly. Part 1: I have two CCScene classes, HomeScene and GameScene. HomeScene is written ...
1
vote
0answers
37 views

Incorrect “Invalid Arguments” errors given by Eclipse code analyzer

I am using cocos2d-x library and trying to call couple of functions from it. The code compiles without any error while the code analyzer keeps complaining about "Invalid Arguments" in two functions: ...
0
votes
1answer
55 views

cocos2d-x: sequential action running on multiple sprites

i have many sprites and i want to move them in screen sequentially. for example 'A' moves to (x1,y1) place then 'B' goes to (x2,y2). i want to run these actions sequentially means first 'A' finishes ...
0
votes
0answers
16 views

cocos2d-x with android game not working giving fatal errror

I am using cocos2d-x for android game development and I am following this link My Hello World program runs after that when I tried to use the code in the site the application doesn't show anything ...
0
votes
1answer
12 views

how to convert CCSprite to UIImage in cocos2d-x?

I know that in cocos2d, there's a simple way to convert CCSprite to UIImage by using [UIImage imageWithData:[renderer getUIImageAsDataFromBuffer:kCCImageFormatPNG]]. However, in cocos2d-x, CCRender do ...
0
votes
1answer
63 views

In my cocos2dx project “Google play game services”, was applied

sorry for my poor English In my cocos2dx project "Google play game services", was applied. An error has occurred. This is the part immediately below. "Initializing Your Games Client in Android" ...
0
votes
1answer
60 views

cocos2d-x object management with multiple scenes and layers

I would like to understand about object management in game creation. I am working with Cocos2d-x. I have a scene, it has several layers. Those layers are made up on several layers each. The user ...
1
vote
3answers
53 views

Creating InAppPurchase in Cocos2d-x

I am new to Cocos2d-x.I need to create InAppPurchase For Cocos2d-x iOS game (CPP).can anybody help me to create InAppPurchase.or any Tutorials Related to this. Thanks in Advance.
0
votes
0answers
31 views

Getting Error with NDK

I am working on android game development using COCOS2D-x and i am working in ubuntu environment. I am Following this ...
0
votes
0answers
23 views

Cocos2d-x Javascript Bindings supported platforms?

I've asked this question on the Cocos2d-x forums and haven't gotten a reply. Sadly that seems par for the course for those forums :/ My question is, are the docs that state the JavaScript bindings ...
0
votes
1answer
46 views

Calling C++(cocos2dx) method from java(android) for my in-app billing

I'm trying to add in-app billing in my cocos2dx-android project. I am able to give a call to java function from c++ class via jni. This is the way i give a call to my java function via jni. ...
-1
votes
1answer
86 views

InApp Purchase in Cocos2d-x [closed]

I need to implement InApp Purchase in Cocos2d-x.Can anybody guide me on this.because InApp Purchase is in ObjC and Cocos2d-x is in CPP.i'm struggling to implement.or how can i make a Callbacks for ...
0
votes
0answers
83 views

Error fatal error: CCApplication.h: No such file or directory

I am trying to create a new cocos2dx project in windows 7 64 bit cocos2dx version : cocos2d-2.1rc0-x-2.1.3 ADT Bundle : adt-bundle-windows-x86_64-20130514 NDK : android-ndk-r8e-windows-x86_64 Path ...
0
votes
1answer
101 views

Android error activity manager type 3 (Eclipse, using jni)

I've been doing an app for a week in cocos2d-x (jni, in c++) The problem is now I can't run it, can't test it on my device.. I get this error: [2013-05-25 21:09:07 - PaperAgeAndroid] ...
0
votes
1answer
50 views

Cocos2d-x - Object creation and management in game design

How do others keep track of everything going on in their games? I am working on a new game and I am quickly realizing everything that I need to keep track of. Example: Maybe a layerManager that ...
0
votes
2answers
48 views

cocos2d-x write the callbacks using c++11 lambda

sometimes the usage of a callback is very limited, which makes it in-appropriate to be a member function. so at these times I always want to write the event call backs as lambda functions as the usage ...

1 2 3 4 5 26
15 30 50 per page