How to show range indicator

Phubar

Ultra Cool Member
Reaction score
30
Hi all, i'm back on the editor and now i have to deal with the data editor and unfortunetly i dont understand almost anything...

Now i have to do this:

Press "N" key and a range circle of X (indipendent integer) range has to appear around my unit.
Press "Esc" key and the circle will disappear.

I have tried with behaviors and actors but i'm a real noob and i lost myself in the editor... so i will start from sratch.

Can you help me?
 

MissKerrigan

Active Member
Reaction score
23
- create a new actor of the type 'range' and call it 'your weapon range'

- select the weapon you want the range actor to show

- in the UI data you can change the distance of the range 'actors'

- create 2 actor events:

1. an event that creates the actor if the 'N' key is pressed
2. an event that removes the actor when the 'escape' key is pressed


Do you also want the range actor to be removed if the player removes his selection of the unit?
 

Phubar

Ultra Cool Member
Reaction score
30
Tnx for the solution!
I have only one unit so he will be always selected.
 

Phubar

Ultra Cool Member
Reaction score
30
Sry but i cannot find the "key pressed" event in the actor events, what i have to look for?
 

X-maul

AKA: Demtrod
Reaction score
201
You will have to associate the a button with an instant ability. Then make the actor react to Ability Used.


Othervise you will have to make a trigger with the event key pressed.
 

Phubar

Ultra Cool Member
Reaction score
30
Ok, i made a trigger but there is only an action "create actor" not the action "destroy actor" :(
I will try with the instant ability
 

X-maul

AKA: Demtrod
Reaction score
201
then create an effect at the location of the unit, and make the actor respond to the effect ;)

just make it a search effect (with no modification, so it does nothing)
 

Dave312

Censored for your safe viewing
Reaction score
269
I would just tie the Range actor to a behaviour. Then when you want to show the range, give the unit the behaviour. Then remove the behaviour when you want to hide it.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top