What language/api should I use?

cheez0r
Unregistered
 
Post: #1
Hello,

Being new to mac, but not all that new to programming, specifically C++, I wanted to learn how to create a game for the mac by doing.
I plan on making a 4X Space Game [I've been playing Galactic Civilizations on my PC, and just need a game like that for my mac ;P] so I decided to do that while learning programming.

My question is... what API and Language should I use?
I want to use OpenGL, so I was thinking of using Cocoa and Obj-C, but is this a good solution? I realize with Cocoa, it'll only work on OS X, but I don't really care about that... it's a learning project after all.

Or should I stick to something C++ish? I just basically want to know, what's a good hting to know for the ffuture?
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #2
Cocoa/ObjC is by far the most efficient way to make GUI programs on the Mac. If you want an immersive full-screen experience, though, Carbon is probably easier.
Quote this message in a reply
cheez0r
Unregistered
 
Post: #3
well most likely, i'd like to make it a Window-able, but mainly fullscreen game...

I'm assuming Carbon WOULD be better than, but would I use C++ or Obj-C?
Quote this message in a reply
Founder
Posts: 1,138
Joined: 2002.04
Post: #4
OSC, didn't you write an article on this subject on this site?

Carlos A. Camacho,
Founder
iDevGames
Quote this message in a reply
cheez0r
Unregistered
 
Post: #5
Reading that Article, I don't find my solution Annoyed
Quote this message in a reply
Moderator
Posts: 916
Joined: 2002.10
Post: #6
Quote:Originally posted by cheez0r
well most likely, i'd like to make it a Window-able, but mainly fullscreen game...

I'm assuming Carbon WOULD be better than, but would I use C++ or Obj-C?


for carbon you would use C++. If you used Cocoa, you would have the option of not only using Obj-C but also C++.
Quote this message in a reply
cheez0r
Unregistered
 
Post: #7
Cocoa seems more geared towards windowed applicatoins that use mac os x controls for the GUI correct?

I'd like to use cocoa cause it sounds neat, and is 'newer' than carbon, but on ther other hand, if there's no point to using cocoa on a fullscreen app, then i might aswell not.

oh well. i'll figure something out Wink

Is either any easier with OpenGL?
Quote this message in a reply
Moderator
Posts: 916
Joined: 2002.10
Post: #8
I have found Cocoa EXTREMELY easy to use in conjunction with OpenGL. Which is why I use Cocoa and OpenGL for all my games now Wink
Quote this message in a reply
cheez0r
Unregistered
 
Post: #9
do you find yourself ainly using Obj-C or C++? Or do use what i've seen referred to as "Obj-C++" ?

The reason I'm asking, I just want to see how much 'learning' i'm in for heh.
Quote this message in a reply
Moderator
Posts: 608
Joined: 2002.04
Post: #10
Quote:Originally posted by cheez0r
do you find yourself ainly using Obj-C or C++? Or do use what i've seen referred to as "Obj-C++" ?

The reason I'm asking, I just want to see how much 'learning' i'm in for heh.
If you already know C++, then I don't think Objective-C will be very hard for you to learn. All the code I have seen that uses Obj-C++ is very, how shall I say it, messy. It seems like the whole reason to use Obj-C is to have an object oriented language that is not C++ so why someone would want to mix the two, I don't know.
Quote this message in a reply
cheez0r
Unregistered
 
Post: #11
Yeah, as strange as it is, I WANT to learn Obj-C and just use it... but I don't want to cripple my programs. From the looks of things, if I wanted to ues Cocoa and Obj-C [and using OpenGL], i'd be fine.
Quote this message in a reply
Moderator
Posts: 916
Joined: 2002.10
Post: #12
Quote:Originally posted by jabber
If you already know C++, then I don't think Objective-C will be very hard for you to learn. All the code I have seen that uses Obj-C++ is very, how shall I say it, messy. It seems like the whole reason to use Obj-C is to have an object oriented language that is not C++ so why someone would want to mix the two, I don't know.


HEY! my program is very organized and pretty (well as far as I go). My only complaint is that it takes at least twice as long to compile. ugh, I'm hating this 30 second compile time. if you have one of those spiffy new computers that can compile in seconds.... well... I just hate you :envy:
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #13
I have a dual 867, so I can compile two ObjC++ files simultaneously, and it's still mind-bogglingly slow!
Quote this message in a reply
Mars_999
Unregistered
 
Post: #14
Quote:Originally posted by OneSadCookie
I have a dual 867, so I can compile two ObjC++ files simultaneously, and it's still mind-bogglingly slow!


OSC if you wouldn't mind, send me a project that you have that has ObjC++ and a time for it to do a complete compile from scratch. I will time it on my Dual and post the difference. I am curious to see how much difference their is between our systems?
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #15
I don't have any ObjC++ projects, the couple of times I tried it it was too slow to compile so I just used C instead of C++, and the other times I've compiled ObjC++ have been as help for forum members here.
Quote this message in a reply
Post Reply