• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Solved] how to move camera to see the sky

Status
Not open for further replies.
Level 3
Joined
Sep 9, 2019
Messages
15
How to make a command which puts the camera like this for a triggering player. (I want to see the unit and in the background I want to see the sky)
If I scroll up or down I want the camera to reset to default.
See_Sky.JPG
Thanks for help ^^
 

Uncle

Warcraft Moderator
Level 73
Joined
Aug 10, 2018
Messages
7,871
Use the Camera Actions to position and change the properties of a Player's camera:
  • Actions
    • Camera - Pan camera for Player 1 (Red) to (Position of (Triggering unit)) over 0.00 seconds
    • Camera - Set Player 1 (Red)'s camera Distance to target to 300.00 over 0.00 seconds
    • Camera - Set Player 1 (Red)'s camera Rotation to 90.00 over 0.00 seconds
This may help as well although in your case you probably don't need to Create a new Camera:
 
Last edited:

Uncle

Warcraft Moderator
Level 73
Joined
Aug 10, 2018
Messages
7,871
For the command you have many choices, you could have an Ability that changes the Camera, a Chat Message that changes the Camera, a Dialog Button, an Item, etc...

I assume you'd probably want a chat command like this:
  • Events
    • Player - Player 1 (Red) types a chat message containing -zoom as An exact match
    • Player - Player 2 (Blue) types a chat message containing -zoom as An exact match
    • Player - Player 3 (Teal) types a chat message containing -zoom as An exact match
  • Conditions
  • Actions
    • Camera - Pan camera for (Triggering player) to (Position of PlayerHero[Player number of (Triggering player)]) over 0.00 seconds
    • Camera - Set (Triggering player)'s camera Distance to target to 300.00 over 0.00 seconds
    • Camera - Set (Triggering player)'s camera Rotation to 90.00 over 0.00 seconds
PlayerHero is a Unit variable with an Array enabled -> []
You would Set this variable to be equal to each Player's Hero as soon as possible:
  • Set Heroes
    • Events
      • Time - Elapsed game time is 0.00 seconds
    • Conditions
    • Actions
      • Set VariableSet PlayerHero[1] = Paladin 0001 <gen>
      • Set VariableSet PlayerHero[2] = Archmage 0002 <gen>
      • Set VariableSet PlayerHero[3] = Mountain King 0003 <gen>
The [index] represents the Player's Number. Red = 1, Blue = 2, Teal = 3, etc...

So if Player 1 (Red) typed -zoom, the Camera would pan to the Paladin, Player 2 (Blue) would pan to the Archmage, and Player 3 (Teal) to the Mountain King. These are pre-placed Heroes that I'm using as an example. In your map you may purchase your Hero from a Tavern, or select them using a Region, in which case you would want to Set the PlayerHero variable in response to such Events. OR you may want this trigger to simply run when a Player Selects a Hero, either way the concept remains the same it's just the Event that changes.
 
Last edited:
Status
Not open for further replies.
Top