HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Generic Questions

10-15-2007, 03:39 AM#1
Evil-Tormenter
Hello! I was wondering if anyone could answer these questions for me. Allow me to thank you in advance for reading this post :)

1. I've implemented a keyboard-based movement system in my map. It's working fine, but now I need to find a way to hide the UI and still allow the hero to be controlled through the keys. I've tried enabling Letterbox Mode and Cinematic Mode, but both modes don't allow my unit to receive commands from my keyboard. Any ideas?

2. I've locked my camera's focus to my unit, but I need to find a way with which to pan the camera to a point a few meters behind the head of the unit and make the unit the camera's axis of rotation. In other words, I need a camera that is fixed at a point behind my unit and turns as it does. What trigger command should I use to achieve this effect?
10-15-2007, 04:37 AM#2
Strilanc
2) You will need to pan the camera to a point behind the unit constantly:
- compute the point using polar projection and the facing of the unit (+180)
- pan the camera to that point

note: do this every ~0.1 seconds and use a pan time of ~0.1s so it looks smooth and doesn't take up too much cpu
10-15-2007, 05:49 AM#3
Dil999
0.1 seconds isnt smooth at all. you will probably want 0.05 at most.
10-15-2007, 06:24 AM#4
Tide-Arc Ephemera
0.05 has SOME visible jumps. I'd try 0.04 at most. I like using 0.03, 0.02 and 0.01 are excessive and overpower little children/computers.
10-15-2007, 08:21 PM#5
Evil-Tormenter
Thanks for all the help, guys!

I've managed to lock the camera to a point behind the unit using polar offsets, but I can't get it to pan down to an angle and face the direction the unit is facing. How do I work that?

Thanks again!
10-16-2007, 07:58 PM#6
Salbrismind
Quote:
Originally Posted by Evil-Tormenter
Thanks for all the help, guys!

I've managed to lock the camera to a point behind the unit using polar offsets, but I can't get it to pan down to an angle and face the direction the unit is facing. How do I work that?

Thanks again!

Try certain camera actions like:

Set Camera Field - Change Angle of attack to about 20 degrees, you can adjust it to suit a better view.

Lock Camera target for (player) to (unit) (offset etc.) , but at the end make sure you set the rotation to unit's rotation that way it will follow it's movement and turning.

To get it close behind the unit try: Set Camera Field - Distance to target, try a low number like 100 or 50
10-16-2007, 10:46 PM#7
Strilanc
Quote:
Originally Posted by Dil999
0.1 seconds isnt smooth at all. you will probably want 0.05 at most.

Woops, I should have said to set pan duration to ~0.2s. If your pan time is longer than your update period you can get away with longer update periods.
10-16-2007, 11:55 PM#8
Evil-Tormenter
Thank you for your continuous help, guys! I managed to get the camera to work: now I'm just working out the angle and the direction.

I'm still puzzled about #1, though. Any ideas?
10-17-2007, 03:06 AM#9
Salbrismind
Quote:
Originally Posted by Evil-Tormenter
Thank you for your continuous help, guys! I managed to get the camera to work: now I'm just working out the angle and the direction.

Did you see my post?

Quote:
I'm still puzzled about #1, though. Any ideas?

You may have to simply compromise with keeping the interface on.
10-19-2007, 11:43 AM#10
BBDino
Does Unit Classification - Ward still allow hot keys to be used? I seem to remember that that hides the command card, at least.
10-19-2007, 12:00 PM#11
The Elite
no, i dont think it allows hotkeys, but just run a test