HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

How Can I Set Camera Z?

09-17-2003, 04:32 PM#1
Heaven
In working on a quick test map for Moria which incorporates a Durin's Bridge prototype, I had to set the depth of the abyss the bridge spans really low so the camera wouldn't dip way beneath the level of the bridge.

How can I keep the camera height constant on a map while still allowing the left/right tilt things, and possibly even the zoom in thing?

Am I camera illiterate or what?



See some more shots of the bridge I'm talking about here:

http://www.bellsouthpwp.net/n/i/ninq...balrogpics.htm

It's just a 5x scale stone arch with custom pathing. I've painted the floor of the abyss with boundary texture, so it's dark but you can still see it.

I originally had the depth on the abyss really high, like over 1800 units, but in-game the camera would swoop to the bottom of the abyss when you panned over it. That's what I'm trying to avoid. I just want to set the Z to a fixed height.

Thanks in advance for any help.

Take care.
09-17-2003, 08:30 PM#2
Draco
I believe that the UMSWE editor allows you to set the "z" height. The trigger action is "Set Camera Field"
09-17-2003, 08:50 PM#3
Starcraftfreak
Yes, Draco is right. I added it back in 3.7.
09-18-2003, 03:53 AM#4
Heaven
How would I do the equivalent in JASS?

I've been beating my head against this for hours now and can't figure it out. I've even got a function that takes "in" as a chat command, bumps the fov down by 0.1 and displays the new field value. Like this:

set fov = GetCameraField( CAMERA_FIELD_FIELD_OF_VIEW)

call DisplayTimedTextToPlayer( Player(0), 0, 0, 30.0, "fov is:" + R2S( fov) )

set fov = fov - 0.1

call DisplayTimedTextToPlayer( Player(0), 0, 0, 30.0, "fov is now:" + R2S( fov) )

call SetCameraField( CAMERA_FIELD_FIELD_OF_VIEW, fov, 0.1)

set fov = GetCameraField( CAMERA_FIELD_FIELD_OF_VIEW)

call DisplayTimedTextToPlayer( Player(0), 0, 0, 30.0, "fov is finally:" + R2S( fov) )

In-game it shows the first field value, then it shows it correctly 0.1 less, then it shows it as the initial value. For example:

fov is:1.22
fov is now:1.12
fov is finally:1.22

Argh. And to top it all off after it does all that it resets the dang fov to 0.349 (i.e., zoomed into the floor practically).

I am so lost. Can someone please help or show me where to go to look? Camera tutorials? Anything?

Take care.
09-18-2003, 06:11 AM#5
Danexx
call SetCameraField( CAMERA_FIELD_Z_OFFSET, <Height>, <Rate>)