• 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.

Make Spacebar center on Hero

Status
Not open for further replies.
Level 5
Joined
Aug 17, 2014
Messages
106
Good morning,

I have been looking around for a trigger or maybe someone knows a simpler way of making it so when u press spacebar the camera centers on your hero 1 similarly to what F1 does. Is that possible? I am in the middle of finishing a MOBA and that is one of the last things I want for it.
 
I don't think there is any way to register a spacebar key, unfortunately. I might be wrong, but I have never seen it.

I found two different ways to achieve what you want without using the normal hotkeys. One of them uses spacebar, the other one uses backspace.

For spacebar: Allow local files in your registry, make a folder in your Warcraft 3 root directory called "Units" and then throw this file in there. This allows you to register hotkeys as strings. Register 32 for space bar. This however requires you to have your unit selected to work, and it will take up an ability slot.

For backspace: Simply convert a town hall into a dummy unit and constantly move it to your hero. Then every time you click backspace the camera will instantly pan to your hero.

Here are two maps with both solutions.
 

Attachments

  • Backspace.w3x
    16.7 KB · Views: 39
  • Space Bar.w3x
    17.1 KB · Views: 72
Last edited:
Level 7
Joined
Jun 30, 2017
Messages
50
To further elaborate on @Tasyen 's post, you should do something like this:
Screenshot_2.png
 
Status
Not open for further replies.
Top