Game Development Community

Toggle TSE Mouse look

by Will Pall · in Torque Game Engine Advanced · 03/09/2005 (7:42 pm) · 6 replies

I've been trying to get at least the default 'z' command to work for mouse look, but so far nothing. I've tried my best looking at the TGE code trying to see where it changes from dialog control to mouselook in the missions.

Could someone please explain to me how I can get mouse look to work. It seems like all the basics for it are still there: pitch, yaw, free view. I've already got a little orc that I can run around in, but he can only go forwards, backwards, and strafe unless I use the World Editor to reorient him.

Sorry if my post was extremely hard to understand. I've been taking 3 hour long High School Graduation exams this week, it's about 10 o'clock, and I think I have that streptococcus that everyone hates.

#1
03/13/2005 (8:02 pm)
Well, either my question was so simple that no one thought to answer it, or nobody else knows the answer. Maybe ya'll just have no idea what I'm asking for. Oh well.

If I figure it out I'll post and tell everybody, cuz I know everybody really wants to know.
#2
03/13/2005 (8:49 pm)
Sorry man, I'm not sure what you want to do. Mouselook works in TSE by default. I probably misunderstood you though.
#3
03/16/2005 (4:37 pm)
If I start up a mission, such as the demo mission, then I "Drop player at camera" so that I can run around, I still see the little mouse moving around and I can't look around except by using the mission editor.

Maybe they've fixed it in a newer release or something.
#4
03/17/2005 (8:58 am)
Yep, sometimes it happened to me also.
This issue disappeared when I changed my video card form GeForce 5600 to Ati 9800.
I downloaded also a newer release of tse and recompiled it so I dunno if the issue was caused by the video card (which had anyway very poor performances) or by the older release of tse.
#5
03/17/2005 (7:02 pm)
This might go away if you add noCursor="1" to your GUI definition. If you're just playing around with the TSE demo, look for demo/client/ui/scenegui.gui, make it look like this:

//--- OBJECT WRITE BEGIN ---
new GameTSCtrl(SceneGui) {
	profile = "GuiContentProfile";
	horizSizing = "width";
	vertSizing = "height";
	position = "0 0 ";
	extent = "640 480";
	minExtent = "8 8";
	visible = "1";
	cameraZRot = "0";
	forceFOV = "0";
	 helpTag = "0";
	roomNumber = "1";
        noCursor="1";
};
//--- OBJECT WRITE END ---

Note the noCursor line.

Hope that helps.
#6
03/18/2005 (7:56 pm)
Alright guys! With ya'll pointing me in the right direction I have finally fixed it, and here's how:

1) I downloaded the newest HEAD as of 3-18-05. Not sure if it mattered because it didn't fix the problem immediately.

2) In "demo\client\scripts\sceneGui.cs" I changed the "SceneGui::onWake" function at the top to:
function SceneGui::onWake(%this)
{
   // Turn off any shell sounds...
   // alxStop( ... );

   $enableDirectInput = "1";
   activateDirectInput();

   // Update the action map
   moveMap.push();

   // Push the menu system
   //OverlayBuyNow.setVisible(false);  [b]<- comment[/b]
   //Canvas.pushdialog(OverlayDlg);      [b]these[/b]
}

3) Last, in "demo\client\ui\scenegui.gui" (as demonstrated by Brian) I rewrote it to:
//--- OBJECT WRITE BEGIN ---
new GameTSCtrl(SceneGui) {
	profile = "GuiContentProfile";
	horizSizing = "width";
	vertSizing = "height";
	position = "0 0 ";
	extent = "640 480";
	minExtent = "8 8";
	visible = "1";
	cameraZRot = "1";   [b]<- note this[/b]
	forceFOV = "0";
	 helpTag = "0";
	roomNumber = "1";
	noCursor = "1";       [b]<- and this[/b]
};
//--- OBJECT WRITE END ---


Then, when I opened a new mission file, I was no longer blocked by the crappy arrows, and I can look around. Small adjustments are all it needs, and I'll copy the crosshair code from TGE. Hope that helps someone.