• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

Camera Problems

Status
Not open for further replies.
Level 6
Joined
May 8, 2010
Messages
150
Event:
Player - Player 1 (Red) Presses the Right Arrow key

Action:
Camera - Rotate camera Rotation[(Player number of (Triggering player))] degrees around (Position of PlayersHero[(Player number of (Triggering player))]) for Player 1 (Red) over 1.00 seconds

Set Rotation[(Player number of (Triggering player))] = (Rotation[(Player number of (Triggering player))] + 10.00)

This always seems to bug..
It always resets the camera.. even though the variable shud have a number stored for it to go to.. but it resets to front view of the unit..

Also after its done.. it doesnt lock back onto the unit properly.

Ive tried loads of different things and i cant get it working..

oh yeh and basically i want it to do.. is when i press the left key on the keyboard.. it rotates the camera an amount to the left..
But im struggeling :/

I think im going to make a point variable that sticks on a unit which may fix the camera not locking on problem.
Just not sure about the rest.

+ rep for help once again.
 
Yeah, I believe that action does rotate the camera and returns it back to the initial view.
Use Camera - Set Camera Field (Timed) instead;
  • Camera - Set (Triggering player)'s camera Rotation to Rotation[Player number of (Triggering player)] over 1.00 seconds
Moreover, your Set Rotation[] variable must be set before the Camera - Set Camera Field (Timed) action.
 
Status
Not open for further replies.
Top