"arrow keys"

theDTD

Active Member
Reaction score
8
how to trigger this,
*when player press LEFT ARROW. the unit moves to left.
*. . . . . . . . . . . . .RIGHT ARROW. . . . . . . . . . . . . right.
*. . . . .. . . . . . . . DOWN ARROW. . . . . . . . . . . . .down.
*. . . . . . . . . . . . .UP ARROW. . . . . . . . . . . . . . . up.

+rep. . . thnks
 

demotry241

Don't Ever Categorize Yourself.
Reaction score
105
Code:
Up
    Events
        Player - Player 1 (Red) Presses the Up Arrow key
        Player - Player 2 (Blue) Presses the Up Arrow key
        Player - Player 3 (Teal) Presses the Up Arrow key
        Player - Player 4 (Purple) Presses the Up Arrow key
    Conditions
    Actions
        Unit Group - Pick every unit in (Units owned by (Triggering player) matching (((Matching unit) is A Hero) Equal to True)) and do (Actions)
            Loop - Actions
                Unit - Order (Picked unit) to Move To ((Position of (Picked unit)) offset by (0.00, 250.00))
Code:
Down
    Events
        Player - Player 1 (Red) Presses the Down Arrow key
    Conditions
    Actions
        Unit Group - Pick every unit in (Units owned by (Triggering player) matching (((Matching unit) is A Hero) Equal to True)) and do (Actions)
            Loop - Actions
                Unit - Order (Picked unit) to Move To ((Position of (Picked unit)) offset by (0.00, -250.00))


Code:
Left
    Events
        Player - Player 1 (Red) Presses the Left Arrow key
    Conditions
    Actions
        Unit Group - Pick every unit in (Units owned by (Triggering player) matching (((Matching unit) is A Hero) Equal to True)) and do (Actions)
            Loop - Actions
                Unit - Order (Picked unit) to Move To ((Position of (Picked unit)) offset by (-250.00, 0.00))


Code:
Right
    Events
        Player - Player 1 (Red) Presses the Right Arrow key
    Conditions
    Actions
        Unit Group - Pick every unit in (Units owned by (Triggering player) matching (((Matching unit) is A Hero) Equal to True)) and do (Actions)
            Loop - Actions
                Unit - Order (Picked unit) to Move To ((Position of (Picked unit)) offset by (250.00, 0.00))

there's this delay...

and lock the camera to a hero unit.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top