Tag Info

Hot answers tagged

8

Am I hurting myself by learning C++ before... No, C++ is a good way to learn about all the basics of programming, including Object Oriented programming, and memory management which might be handled for you in other languages. There's got to be a reason the university requires C++ It is an industry standard across the world. It is quite portable as there ...


7

Xcode can indeed be used to create games. You can do anything a Mac/iOS device is capable of by programming in Xcode. I think you should focus on what part of the project you want to focus on. As you state you are a brand new Objective-C programmer (welcome). In my opinion it would be quite a mouth full to try and just into Objective-C programming whilst ...


7

It is against the Apple and Mac OS terms of agreement to install Mac OS on anything aside from an Apple authorized machine. You are in breach of your user agreement by doing even that. So app-store stuff aside - you are in legal hot water. However! Pushing that aside, I'd like to note at least one game has been published with a similar method as the one you ...


7

You're not hurting yourself because you're doing what is required by your school. Learning to program is only partially about learning the syntax of a specific language (and it's a small part!). Right now you're learning to think logically and like a programmer. Don't worry about learning things you don't need, because it's all useful in some way.


6

If you'd like to learn Objective-C, I suggest you have a look at cocos2d. It's an open-source 2d engine (written in Objective-C) that allows you to write games for iOS or Mac OS using XCode. It's not as easy to create games with as with a package like Unity, but there are lots of tutorials (and even books) for cocos2d to be found. A good place to start ...


5

Absolutely! XCode is the standard programming IDE for the Mac and iOS. So if your goal is making a game for iOS, you will probably be using XCode along with a few other helping technologies of your choice (e.g. OpenGL ES 2.0). But since you mentioned game engines I'd also recommend you to use one, since they'll save you a lot of time and effort: If you ...


4

NVIDIA's Cg Toolkit should be able to compile (or translate) shaders offline and spit errors. Another option is to create a tiny executable yourself that takes in a shader file and tries to compile it with your GPU driver's compiler (or perhaps such a compiler is already provided for you by the vendor). Though I think at least in the latter cases many ...


3

No, if you are referring to writing Objective-C using the Cocos2D framework to do animations, your animator will not be able to do so without xCode. He could write the code in a text file and pass that to you, but will not be able to compile them to check that they do work (which really defeats the purpose I suppose.) However, if you only need sprite ...


3

My guess is that none of those static library variables are used directly by the executable. The compiler likes to optimize these situations by removing the initialization code of unused variables. For this thing to work, you have to at least touch each variable (do a read/write that cannot be optimized out*) that you want initialized from all static ...


2

Objective-C is but one of many languages you can learn to use for iOS programming. Not only are you completely free to write C and C++ code on iOS (with some caveats), Apple also supports a language called Objective-C++, which is exactly what it sounds like. While you do not need to use Objective-C to program your core application, the Apple APIs are all ...


2

I'm unfamiliar with objective C, so I can't give any specific code. But the general way to accomplish things like this is by doing a per pixel collision check. Basically it works just like how you have it based on the rectangle, but before firing the touch event, you have to loop through all the pixels that were touched and make sure at least one of them ...


2

Do as ryrich said, however the actual code on Objective-C would be something like this: (Assuming your CCNode class is called "Seal") int sealCounter = 0; for (id *node in self.children) { if ([node isKindOfClass:[Seal class]]) { sealCounter++; } }


2

Build your own level editor - it's the conclusion I came to after having developed several games. A simple editor would involve creating some simple buttons (the items in the levels) and some simple logic for positioning, rotating and scaling them on stage. After you have all the items in a level just push their details (position, type, etc) to an/or several ...


2

I dont know the version of the sdk you are using, but in the latest version Game Center now support multiplayer games, witch means now Game Center can handle all data exchange. Take a look at this tutorial: How To Make A Simple Multiplayer Game with Game Center Tutorial: Part 1/2


1

This is only a guess, but as far as I know you should include SDL as <SDL.h>. As I can see that you include SDL as <SDL/SDL.h> and SDL Mixer as "SDL_mixer.h", the problem is that the header of SDL_mixer.h includes <SDL_types.h>, but in your case it would have to be <SDL/SDL_types.h>. You should either extend the include search path ...


1

I don't think there's such a thing as a "Game UI Tempalte-Only Engine". Really your best bet for getting IOS and Android dev in one go + out of the box UI widgets (such as text , buttons, etc) is Unity. I find it a lot easier than the run of the mill "Open GL Text libraries" and such: http://docs.unity3d.com/Documentation/Components/gui-Basics.html


1

This answer actually fixes the issue: Use the -all_load linker option to load all members of static libraries. Or for a specific library, use -force_load path_to_archive. In Xcode, you'll want to add these options under "Other Linker Flags" for your executable (not your static library).


1

The reason it is different speeds is because you are not calculating/using a delta time. Basically the frame rate could be any number at any time slowing or speeding up your animations. To counteract this, programmers calculate a delta time: delta = currentTime - previousFramesTime; // time difference between this frame and the last frame Then use this in ...


1

C++ is where almost every new programmer learn about object-oriented designs first (at least in my area, it's true). So you are not hurting yourself. Also you can develop iOS (even Android )apps in C++. If you are thinking to go into game-development, C++ is the de-facto language here, supported by most of the game-engines. So learning C++ is always a ...



Only top voted, non community-wiki answers of a minimum length are eligible