XCode 3.0
by Fredulus Ripplinger · in Torque Game Engine · 03/02/2008 (2:06 pm) · 15 replies
Does anyone use XCode 3.0? Because I haven't been able to compile/recompile anything, I never get an executable file, and I have tried everything. Is it because I'm on XCode 3.0, or what?
Edit: I just saw another thread a couple down that looked the same as this, but he edited and said the issue was resolved in another thread (that I didn't see anywhere). Anyone know where that thread is, if you can't just directly answer my question?
Edit: I just saw another thread a couple down that looked the same as this, but he edited and said the issue was resolved in another thread (that I didn't see anywhere). Anyone know where that thread is, if you can't just directly answer my question?
About the author
#2
[frustration]
[more]
[more]
:(
03/02/2008 (7:10 pm)
It seems I've run out of all possibilities of why I can't compile.[frustration]
[more]
[more]
:(
#3
03/03/2008 (6:58 am)
Check your project directories to find where it is placing the executable. Then copy it into place. I had a shell script that did it back in the day. My mini's in storage and I still haven't had time to set up my G5.
#4
03/03/2008 (7:40 am)
Can you give us any idea what happens when you try to compile?
#5
03/04/2008 (5:18 pm)
It gives me a folder called "Build" under the XCode folder (in the Torque SDK folder). Under that there's a folder called "torque_xcode_2_2_UB.build", and under that 2 folders, "Default" and "torque_xcode_2_2_UB.pbxindex". Under those, there are lots of .o's and .pbxtree's, along with a couple other types. I don't see an executable anywhere in there, or anywhere in my Torque files. I have my main TGE folder, and a TGE Backup under the same folder as the main one.
#6
In the main directory there is a Torque SDK folder. In that folder, there are a number of folders. The ones of interest are called "xcode", "engine", and "example".
The "engine" folder has all of the .h and .cc files that make up the engine code.
Inside the "xcode" folder is a file called "torque_xcode_2_2_UB.xcodeproj". This is the project that you open up in Xcode, and you should be able to just build this project right out of the box into the "Torque Demo OSX" application. If you open this project in Xcode and select "Project"->"Edit Project Settings..." you will see a window with some helpful information.
One of these is the "Place Build Products In:" setting. It should be set to "Default build products location" by default. The path is shown (greyed out) in the box underneath it. You should see that the default build products location is the "example" folder mentioned above.
If you go back and now look in the "example" folder, you should see an application called "Torque Demo OSX", which is the application built when you compile the engine. If you re-build the engine, this application file will be re-created in this location.
You can specify a different location for the build products, if you wish, using the dialog window mentioned above.
Hope that helps.
03/04/2008 (5:46 pm)
Well, here's what I see in a fresh install of TGE 1.5.2:In the main directory there is a Torque SDK folder. In that folder, there are a number of folders. The ones of interest are called "xcode", "engine", and "example".
The "engine" folder has all of the .h and .cc files that make up the engine code.
Inside the "xcode" folder is a file called "torque_xcode_2_2_UB.xcodeproj". This is the project that you open up in Xcode, and you should be able to just build this project right out of the box into the "Torque Demo OSX" application. If you open this project in Xcode and select "Project"->"Edit Project Settings..." you will see a window with some helpful information.
One of these is the "Place Build Products In:" setting. It should be set to "Default build products location" by default. The path is shown (greyed out) in the box underneath it. You should see that the default build products location is the "example" folder mentioned above.
If you go back and now look in the "example" folder, you should see an application called "Torque Demo OSX", which is the application built when you compile the engine. If you re-build the engine, this application file will be re-created in this location.
You can specify a different location for the build products, if you wish, using the dialog window mentioned above.
Hope that helps.
#7
03/05/2008 (8:22 am)
The version of xcode that I was using had the "place build products" area bugged, so I created a script. I wasn't using 3.0, though.
#8
How would I get an executable for starter.fps? I've been trying to get aiGuard in it, but now, every time I open it, it crashes. I'm sure where I went wrong is compiling.
03/05/2008 (1:30 pm)
Thanks, Rubes! That helps. There was a setting wrong. The (next) problem is...How would I get an executable for starter.fps? I've been trying to get aiGuard in it, but now, every time I open it, it crashes. I'm sure where I went wrong is compiling.
#9
The executable is just the code that runs the engine; the scripts (such as starter.fps) tell the engine which kind of game to run. So you have to modify the script to tell the engine to run starter.fps, or starter.racing, or whatever game you create.
You do this by modifying the "main.cs" script file within the main "example" folder. The first line is "$defaultGame = "; and you just change the to "starter.fps".
If you've already done this and your Torque Demo OSX crashes when you try to run starter.fps, then there's something strange going on, assuming you haven't modified the scripts or the engine code.
03/05/2008 (1:39 pm)
The compiled engine (Torque Demo OSX) is the executable for starter.fps.The executable is just the code that runs the engine; the scripts (such as starter.fps) tell the engine which kind of game to run. So you have to modify the script to tell the engine to run starter.fps, or starter.racing, or whatever game you create.
You do this by modifying the "main.cs" script file within the main "example" folder. The first line is "$defaultGame =
If you've already done this and your Torque Demo OSX crashes when you try to run starter.fps, then there's something strange going on, assuming you haven't modified the scripts or the engine code.
#10
03/05/2008 (2:39 pm)
Ohhhh! Ok! That helps a TON. Still, it crashes, now that I open it with the executable. It crashes when I try and start a mission. I'll just go through all of aiGuard again and see if I can get it to work, I guess.
#11
03/05/2008 (2:43 pm)
Good luck!
#12
"2. Add the files AIGuard.cc and AIGuard.h to your Torque project. (In my instance I saved them to my c:\Torque\engine\game directory and then added them into my project.)"
When he says "project", does that mean I should add them into starter.fps, too? I know this doesn't really have anything to do with XCode, but oh well...
03/05/2008 (2:49 pm)
Ok... in aiGuard, when it says:"2. Add the files AIGuard.cc and AIGuard.h to your Torque project. (In my instance I saved them to my c:\Torque\engine\game directory and then added them into my project.)"
When he says "project", does that mean I should add them into starter.fps, too? I know this doesn't really have anything to do with XCode, but oh well...
#13
03/06/2008 (6:35 am)
Read down through the resource. There are some fixed that worked to stop crashes like that. I don't think they were OS specific, since I only tried them under Win, so I'm not sure.
#14
I have a question though... what is that build folder for then? If it puts all the compiled stuff in the examples folder, what is actually in that build folder.
05/20/2008 (11:28 pm)
Wow, can I say that this article here helped me TONS. I was so confused as to what was happening with xCode. I've never successfully compiled TGE in windows and when I DID do it in xCode, I could not figure out what actually happened and where stuff went.I have a question though... what is that build folder for then? If it puts all the compiled stuff in the examples folder, what is actually in that build folder.
#15
I have a question though... what is that build folder for then? If it puts all the compiled stuff in the examples folder, what is actually in that build folder.
05/21/2008 (9:04 am)
Wow, can I say that this article here helped me TONS. I was so confused as to what was happening with xCode. I've never successfully compiled TGE in windows and when I DID do it in xCode, I could not figure out what actually happened and where stuff went.I have a question though... what is that build folder for then? If it puts all the compiled stuff in the examples folder, what is actually in that build folder.
Torque 3D Owner Rubes