I am trying to make the default player camera set to follow a hero that they have chosen but allow click to move. Currently I have been able to figure out how to make the camera follow their hero but you can still move your camera off of the hero if you scroll to the side like normal. I want to make it so the camera always follows your hero and you have to use click to move to see more of the map. The best description I can give of this is: Make camera controls like Diablo.
Sounds like exactly what I have on my map.
My map locks the camera on the unit a Player owns
Trigger: Always Trigger
Event: Timer - Every 0.1 seconds of Game Time
Actions:
General - If (Conditions) then do (Actions) else do (Actions)
If
((Closest unit to Start Area in (Any units in (Entire Map) owned by player 1) is alive == true
Then
Camera - Apply camera object Rotation (Facing of (Closest unit to Start Area in (Any units in (Entire Map) owned by player 1))) for player 1 over .5 sec
Camera - Pan the camera for player 1 to (Closest unit to Start Area in (Any units in (Entire Map) owned by player 1)) over .5 sec
Else
Pan the camera action locks the camera on the player, don't make the duration less then .5 sec or camera with start having a choppy look to it when it follows their hero unit.
Placed in the If Alive condition because all units can revive on my map after 45 seconds for testing balancing of different areas, I may remove this once I complete the map.
Camera Rotation action I made to always point the camera the direction that the unit is looking, player is always looking at the back of the unit's head.
I am trying to make the default player camera set to follow a hero that they have chosen but allow click to move. Currently I have been able to figure out how to make the camera follow their hero but you can still move your camera off of the hero if you scroll to the side like normal. I want to make it so the camera always follows your hero and you have to use click to move to see more of the map. The best description I can give of this is: Make camera controls like Diablo.
Sounds like exactly what I have on my map.
My map locks the camera on the unit a Player owns
Trigger: Always Trigger
Event: Timer - Every 0.1 seconds of Game Time
Actions:
General - If (Conditions) then do (Actions) else do (Actions)
If
((Closest unit to Start Area in (Any units in (Entire Map) owned by player 1) is alive == true
Then
Camera - Apply camera object Rotation (Facing of (Closest unit to Start Area in (Any units in (Entire Map) owned by player 1))) for player 1 over .5 sec
Camera - Pan the camera for player 1 to (Closest unit to Start Area in (Any units in (Entire Map) owned by player 1)) over .5 sec
Else
Pan the camera action locks the camera on the player, don't make the duration less then .5 sec or camera with start having a choppy look to it when it follows their hero unit.
Placed in the If Alive condition because all units can revive on my map after 45 seconds for testing balancing of different areas, I may remove this once I complete the map.
Camera Rotation action I made to always point the camera the direction that the unit is looking, player is always looking at the back of the unit's head.