• 🏆 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!

Fix camera following an unit

Status
Not open for further replies.
Level 8
Joined
Dec 9, 2009
Messages
397
  • Camera - Lock camera target for Player 1 (Red) to (Triggering unit), offset by (0.00, 0.00) using Default rotation
Was there a question you had about that?

or are you looking for more of a camera system, check the spells section for Camera
there are a few systems.
 
I though my question was very simple. I've already checked the spells and nothing corresponds. Well, the camera is fix on a point. It can only rotates above the unit.
Imagine a circle. The camera is on the middle of the circle. Your unit is around the circle and moves. The camera stays in the middle of the circle but follows your move by rotating. I hope my metaphor could be helpful
 
Level 11
Joined
Mar 18, 2009
Messages
788
I though my question was very simple. I've already checked the spells and nothing corresponds. Well, the camera is fix on a point. It can only rotates above the unit.
Imagine a circle. The camera is on the middle of the circle. Your unit is around the circle and moves. The camera stays in the middle of the circle but follows your move by rotating. I hope my metaphor could be helpful

That explains it better, but you will still have to explain more of it how it should works with the map like; Can the unit move out of the camera range or can it move in to the center of the circle etc because this is a map specific trigger you are going to need.
 
Well your unit is "blocked" in this circle. It can't escape. It's for a kind of boss fight. So he can only move into this small area. So the unit will always be on the camera range.
Besides, the unit can't go into the middle of circle. I guess the camera will be stuck if he does so. Thus there is a restricted area in the middle of the circle when the camera is setting.
 
Okay, here are the exact triggers:
  • Camera Loop
  • Events:
    • Time - Every 0.01 seconds of game-time
  • Conditions
  • Actions:
    • Camera - Set Player 1's camera Rotation to (Angle from (Source of current camera view) to (Position of (Triggering Unit))) over 0.00 seconds
    • Camera - Set Player 1's camera Distance to target to (Distance from (Source of current camera view) to (Position of (Triggering Unit))) over 0.00 seconds
It should work perfectly :D
 
Level 11
Joined
Mar 18, 2009
Messages
788
Okay, here are the exact triggers:
  • Camera Loop
  • Events:
    • Time - Every 0.01 seconds of game-time
  • Conditions
  • Actions:
    • Camera - Set Player 1's camera Rotation to (Angle from (Source of current camera view) to (Position of (Triggering Unit))) over 0.00 seconds
    • Camera - Set Player 1's camera Distance to target to (Distance from (Source of current camera view) to (Position of (Triggering Unit))) over 0.00 seconds
It should work perfectly :D

I heard that 0.03 is the minimum for looping triggers :O
Also I think this problem is solved.
 
Status
Not open for further replies.
Top