Duplicate:
How can i use picker view in iphone application using cocos2d ?
Hello everyone i am working on iphone gaming project.In this game i want spin some image (like reel spin).But i can not do this.Can i use picker view in this application using cocos2d.If can then give some instruction how can i do that or any different solution for this project.
You can use anything your want. I am constantly amused by the number of people who think that Cocos2d is some sort of world that you enter where you cannot bring any of your old friends. Cocos2d is just a library that makes OpenGL easy for games, and that is all it is. All it is.
I think you might benefit from trying a few easier projects first. I have made the mistake of trying to jump into something beyond my understanding, and while in the end it may have been beneficial, I sometimes wish I had learned in a more systematic manner.
Related
It's a really simple question , but i'm still new at this.
I want to create a game with some levels.
Is it better to use a Navigation based app or a windows based?
views used are:(Main menu- Options - high scores - 10 levels)
Thanks!
If you want to create a game, take a look at the cocos2d framework. It will provide a complete solution for this kind of programs.
As to your question, I would not use a Navigation base app, since you do not want to give the option of going back through levels. You just need a way to manage all the different scenes youd have (levels), moving from one to another, and display a menu/options view when it is the case. So, if you do not want to use cocos2d, a window based app will suit your needs.
Most games have a 100% custom UI, but if you are just getting started, you might want to prototype your screens/flow between screens using UIKit first.
I've already created an iPhone app using UIKit. However, for one part of my app i will need to perform relatively heavy graphica (particles, lots of moving images). I can't rewrite the entire app in cocos2D due to my deadline. It's just for graphical purposes and i won't need user input via cocos2D. Another option i was considering was using plain openGL, but i'm quite sure cocos2D will be easier to learn.
In short: How can i use cocos2D in a small part (say one UIView) of my app without rewriting it? (User interaction is not necessary).
Edit: I found out, after a while more searching. For the record if someone else will need it in the future:
http://www.cocos2d-iphone.org/forum/topic/4708
http://www.cocos2d-iphone.org/forum/topic/9239
First, integrate cocos2d into your project.
Copy cocos2d directory into your project from downloaded cocos2d-iphone.
Modify cocos2d/ccConfig.h, #define CC_FONT_LABEL_SUPPORT 0
Copy fps_images.png into your project from downloaded cocos2d-iphone/Resources/Fonts if you want to show FPS that is implemented in cocos2d.
Next, implement to use cocos2d as cocos2d-iphone/tests/attachDemo/attachDemo.m.
I have been making my game in a pretty conventional manner. I just created a new window based application and have built off of that using my own images, table views, etc. Now I am about to begin programming the gameplay, and I just recently discovered Cocos2D. My question is this: In order to use Cocos2D for the actual gameplay (Which would take place in a single view) do I need to recreate my app from scratch? Or can I just make the one view using Cocos2D?
You could go down the mix-and-match route, but it would likely drive you insane.
If you want to embrace Cocos2D, you will likely be better off moving to it fully. More likely than not the time invested will be yield improvements in your existing code that you'll find surprising (certainly, I've found that rewriting something pretty much always yields a better solution in fewer lines of code).
You do not want to keep using the standard SDK in your game, if you're going to use Cocos2D for the game view (which you totally should).
Re-do the entire app in Cocos2D -- you'll have way more possibilities to make your game menus awesome and much less headaches; both while developing and while maintaining your game.
First of all thanks for taking the time to read through and attempt to help with the problem I'm having. First question posted here and after reading through the startup agreement I'll try and be descriptive as possible =)
I'm currently working on a Game for the Iphone as my final year university project. This game is one I hope to continue working on and expanding after I leave and use as a springboard for my CV into the industry. I've got a good few months left, so plenty of time to take things slowly and carefully plan it out.
I have a background in Java and OpenGL in C++ so I understand some of the basic fundamentals. I'm not that experienced in Objective C yet, need to start somewhere =), so I apologise for any obvious mistakes I'm making. The current state of code is i've got multiple items rendering to a single OpenGL ES view based on the OpenGL ES 1.1 model. I feel since the project is primarily 2D I shouldn't need to go to the higher version. I would post up the code I have but it's full of prototyping and misc code and is incredibly messy. In fact I wouldn't mind restarting the code as a multi view template then moving over the blocks of code as I get them working.
I've done research through many different mediums as to the ideal way to create a multi view application with each view being OpenGL-ES based. I've seen many tutorials on using the UI-kit view with an OpenGL view, but I've decided the best way for my project to ensure full dynamic and customisation I'd be happier using openGL for all the views.
TL;DR:
The question I'm trying to ask is if theres a good tutorial or template anywhere I'm missing that will allow me to start up a new multi view project that will allow me to switch between multiple views (Menus etc)?
You can't go far wrong with cocos2d if you're making a 2D app but want it to be openGL accelerated.
I was a flash developer for 3 years, and in the last 5 months, i begin the iphone development, i do 2 applications with interface builder for clients, and now i really want to do a little game, is quite simple, one match 3! I made the engine in interface builder, and seens good to me! But after i read some posts, i really want to try it in the cocos2D! So, in 2 days i rewrite all my first engine for cocos2D, very annoying upsidedown coordinates but ok, i really do! But the performance side by side with interface builder version is really scare! Many Many slow downs at the cocos2d side! And the animation seens bugged to me! I really scare! I really don't know what is the best choice for a simple game.
And i want some opinions:
Using cocos2d when need some physics? When we have many objects at screen? What is the performance boost i have with cocos2D?
I have how to share this 2 applications with you guys?! Without your UID?!
cocos2d uses chipmunk, which IMHO is a great physics library if all you need is 2d! Apple doesn't support ad-hoc distribution without knowing the Device ID of the test device!
I think baDa is asking when to use cocos2D and Interface Builder. Since you can develop games using Interface Builder, is it advisable to do so? What are the performance differences between this two approach (cocos2d vs Interface Builder)?
I also had a confusion and ask this to my self when i was just starting to program. After working with several games. I reallized that you can actually combine this two approaches. The big BUT is, when working with objects dynamically (specially with bunch of images) using IB, it totally removes the flexibility of the code. Adding/removing images, adjusting coordinates and replaceing scenes is just too awkward, bulky, and wastefull to implement.
My simpole rule is to use coocs2d for game developemnt and IB for other apps that is reach in interfaces.