Game Development Community

T2D in TGE; works for me

by Gary "ChunkyKs" Briggs · in Torque Game Builder · 09/08/2006 (11:43 am) · 59 replies

I read in a changelog somewhere that T2D gui and core changes had been merged back into TGE 1.4.2. Additionally, the mac 1.4.2 is now effectively release candidate in CVS, so I downloaded and tried to get T2D into TGE again. It works fine. Here's what I did:

Copy the whole engine/T2D dir into TGE
Copy util/undo.{cc,h} into TGE

The following files in gui/controls include "gui/buttons/guiButtonCtrl.h". This needs to be changed to "gui/controls/guiButtonCtrl.h":
guiBitmapButtonCtrl.h
guiButtonCtrl.cc
guiColorPicker.cc
guiIconButtonCtrl.h
guiPopUpCtrl.h
guiPopUpCtrlEx.h

The following files in gui/variousplaces need to be copied into your tge/engine/gui dirs:
guiPopUpCtrlEx.{cc,h}
guiIconButtonCtrl.{cc,h}
guiIconButtonCtrl.{cc,h}
guiScriptNotifyCtrl.{cc,h}
guiSeparatorCtrl.{cc,h}
guiRolloutCtrl.{cc,h}
guiDynamicCtrlArrayControl.{cc,h}
guiAutosSrollCtrl.{cc,h}
guiDragAndDropCtrl.{cc,h}
guiFormCtrl.{cc,h}
guiImageList.{cc,h}

Several of them are in a dir called "gui/buttons" in T2D; when you copy them into TGE, put them in "gui/controls". Other than that, keep the directory structure intact.

Add all the cc files you newly copied into your build, EXCEPT FOR T2D/levelBuilder/levelBuilderPrimitiveTool.{cc,h} - Just skip this file.

Anyways. clicky the build button, go afksandwich while XCode spends an hour working out dependencies. When you come back, copy your new TGE binary/app into your TorqueGameBuilder/games/ dir [where the other T2D binaries are now], and run it.

Works fine for me. I'm using the current 1.4.2 TGE CVS, the last release 1.1.1 T2D, and the latest XCode on my powerbook.

Gary (-;
Page «Previous 1 2 3 Last »
#1
09/18/2006 (11:34 pm)
I can't wait to try this with windows version..
i wonder when tge 1.4.2 windows version comes out...
#2
10/03/2006 (12:24 pm)
Following your rules I was able to compile the TGE/TGB executable, but with only one change.
In current TGE CVS, the mIsZero function declared in /engine/math/mMathFn.h
So, I reverted it back as it was in normal TGE 1.4.
Then, added in header of engine/collision/convex.cc:
#include "t2d/t2dVector.h"

Do Clean. Do Build.

And all looks fine for now.
TGE Demo working fine, now going to check the TGB :)

Edit: confirmation - TGB also works. Thanks.
Used it on Windows platform.
#3
10/05/2006 (11:19 am)
...ignorance...

What are some common uses for doing this (simply convenience?). Is that what people have been doing to get networked TGB games?
#4
10/05/2006 (11:27 am)
In integration of TGB into TGE I see the use of TGB for advanced gui's and 2d games inside 3d.
The main benefit of it is having a working platform that allows you to use high quality 2d together with 3d.
Imagine that you are walking inside a MMO world, start talking to a friend, open special interface where you can play with all these beautiful TGB effects in a game like сhess or even some card-games? And if you have lots of friends - then play all together in 2d racing or again card-game.
I see TGB as addon to TGE, and not vice versa.

edit: spl
#5
10/05/2006 (12:17 pm)
Ah, I was wondering where this thread went! I've been trying to get T2D into TGE/TSE for a while now. Thanks for posting your results!

Steve
#6
10/05/2006 (12:50 pm)
Personally, I always thought that T2D would make an awesome UI layer. Who needs gameswf when you could just slap a T2D layer in there? Little UI controls spinning in and out with particle streamers, stuff like that...

Alternatively, I have T2D and I have TGE, and trying to run one in the other is like... sitting there begging to be done. With, or without, reason.

Gary (-;
#7
10/05/2006 (12:52 pm)
I didn't realize we could mesh the two together until one of the GG employees posted that video a while back of a game running on T2D within TGE. That was it for me.

Steve
#8
10/05/2006 (1:45 pm)
Im using T2D for all the in game HUD stuff (health bar, ammo counters, countdown timers etc). Makes it easy to have great looking displays and you get all the T2D camera effects, physics and animation for free.
#9
10/05/2006 (4:19 pm)
I would like to see some examples of this. I am still not sure how you go about actually using TGB for UI.
#10
10/06/2006 (1:55 pm)
@Dave D:
You're probably thinking too hard about it :-)

Open your GUI Editor, and open your play GUI [or any other GUI for that matter]. Slap a T2D GUI Canvas on there, overlaying the whole screen. Do not give it a background image. Done.


You'll find a very old example in a movie I did here. If you look at the top left hand corner, there's a T2D particle effect; I put a T2D canvas on my PlayGUI, without a background, and put something in it.

Gary (-;
#11
10/06/2006 (2:19 pm)
A bit offtopic: Gary, can you share information about this "gravity" stuff you were doing in a movie?
#12
10/06/2006 (3:19 pm)
@bank: That's odescript. One of my pet projects.
The current thread where I put code drops is here: www.garagegames.com/mg/forums/result.thread.php?qt=48839

Gary (-;
#13
10/06/2006 (3:23 pm)
Gary, thanks. Will have a look.
#14
10/06/2006 (4:05 pm)
@Gary
You're right, I am thinking about it too hard. I didn't even think it would be that simple. Thanks for the insight
#15
10/06/2006 (4:07 pm)
@Dave: Glad it's working for ya :-)

@bank: It's still a WIP, So be warned!

Gary (-;
#16
10/20/2006 (11:48 am)
Going beyond using tgb as an HUD. Do you think it would be possible to do something like the following video using the merge of the 2 engines as discussed? It is a video of a shooter called Ikaruga made by Treasure Games, a company that has been making shooters since the Sega Genesis days.

Ikaruga game play

My real quesion is do you think performance would be suitable with the kind of action seen in the video.

Edit: link was borked
#17
10/20/2006 (3:21 pm)
Ah, Ikaruga.

You could implement that using just T2D. No 3d is necessary. In fact, a version going left to right comes in the box with T2D, called "spacescroller". The background thing is obviously what you're thinking you need a 3d engine for. I imagine it's easily fakable as a 2d backdrop.

Gary (-;
#18
10/20/2006 (3:29 pm)
You wouldn't need much 3D in Ikaruga. In fact, you could render 3D objects to make it appear 3D since it is always on a linear path. If you chose to use 3D objects, you would want to deal with the collidable geometry such as moving boxes and the like. And, of course, enemy models.

I love Ikaruga and Radiant Silvergun. Two of my favorite shooters ever.
#19
10/20/2006 (4:35 pm)
Sorry for the minor hijack... kinda branching off.

yeah, I used Ikaruga as an example because it almost has that blue screen look to it(background and foreground are distinctly seperate - most of the time). A 2d foreground with a 3d panning background. It's actually the reason merging the 2 engines caught my eye. I figured this type of game would be an ideal candidate.

IMO to get that nice depth perception (as seen in Ikaruga) the background would have to be true 3d and I don't think t2dShape3d would do the trick... however t2dShape3d would be perfect for all the foreground objects (ship, enemys, ect.).

But yeah, what I was thinking was basically the shooter tutorial but instead of scrolling tile maps... you have a TGE 3d background with a well scripted camera.
#20
11/09/2006 (7:25 pm)
Update:

Going through TGB 1.1.2 and trying to merge into TGE 1.5, there are the following differences:


File directories:
gui/controls/ guiPopupCtrlEx --> Need to change reference for gui/buttons/guiButtonCtrl.h to gui/controls/guiButtonCtrl.h

gui\buttons\guiIconButtonCtrl.* into gui\controls (need to change the files too, since the .h and .cc files have include files in the wrong directory)

gui\containers\guiAutoScrollCtrl.*
gui\containers\guiDragAndDropCtrl.*
gui\containers\guiDynamicCtrlArrayCtrl.*
gui\containers\guiRolloutCtrl.h
gui\containers\guiFormCtrl.*

gui\core\guiScriptNotifyCtrl.*


gui\editor\guiSeparatorCtrl.*
gui\editor\guiImageList.*


Edit: Fixed based on update.
Page «Previous 1 2 3 Last »