Does anyone know how to show the projected attack range of a building when placing it? (like the Photon Cannon or Missile Turret)
I know how to show the attack range once its placed, but not while placing it. I have been working on and off since the editor came out, and I have tried MANY different things.
It would be nice if you tested your method before posting in here, its stumped a lot of people in IRC chat too, but any suggestions are much appreciated.
EDIT: use this if WarTurtle's method (post #5) doesn't work for you (altough I think this method is prettier).
EDIT2: These steps are actually for showing the range on a certain selected unit.
I worked 6 hours straight on this one:
1. go to Actors.
2. Right click the actor list and "Add Object".
3. Give it a name (i.e. PhotonCannonProtectRange)
4. click "suggest"
5. Actor Type: Range
6. Based on: CActorRange
7. Click "OK".
8. Select the created object (or it's already selected).
9. Set the "Weapon" field to the weapon range you want to use (i.e. "Phase Cannon - Photon Cannon" )
10. Double click the "Events - Send" field.
11. Create a new event (right click the list -> Add Event).
12. Set the Msg Type to "Create".
13. Click the "ActionDamage" event (the one you just created).
14. Set "Msg Type" to "Selection Update (Local).
15. Set "Sub Name" to "Start".
16. Create another event in the same manner so it looks like the screenshot attached.
If you can select "Photon Cannon" in "Source Name", the bug was fixed and you should select it, if not this is how to work around it:
BUG: "Source Name" will only have "(None)", THIS SUCKS, because now we have to directly edit the XML of the map, this is how:
16. Download something that can edit MPQ files.
17. Save your map somewhere you can find it.
18. CLOSE GALAXY EDITOR.
19. Open your map in the MPQ editor and extract the following file somewhere you can find it: "Base.SC2Data\GameData\ActorData.xml".
20. Open "ActorData.xml" in any (non retarded) text editor (like Notepad++).
21. Now alter the "*" in both "SelectionLocalUpdate.*.Stop" to match the unitID you want to show the range for.
22. Update the "ActorData.xml" from your map with the one you modified.
23. Close MPQ editor and load your map in the Galaxy Editor.
24. Now find the actor you created at step 2., double click "Events - Send" and your stuff should like like the other screenshot.
selectionlocalupdate.*.start
-> validateunit is Unittype
-> selected
-> create
selectionlocalupdate.*.stop
-> valadateunit is unittype
-> destroy
For buildings when being placed
Abil.terranbuild.PLacement
->validateunit is buildingtype
->create
This creates the range around the building. Note buildings have a different visual (the little boxes) instead of the normal range for weapons. Aka my supply depot shows a ring of boxes around itself instead of the "attack" range normally shown for units.
I tried both methods and I'm unable to get it to work :(.
It shows his range once he is build, but not during placement which is what im looking for. I'll continue to work on it tonight with this info and hopefully I'll get somewhere or find my mistake. Thanks.
Having the same problems right now. Have a working range indicator on a tower after following Beider's Video Tutorial, but have no clue how to correct the range indicator when placing a tower.
Additionally I want apply this range to all of my 50 Towers .... is there an easy way instead of making validators for each tower? (which would be a mess)
You need to create a custom placement actor for you unit. the placement actor should be based on the standard "Placement Model" actor, the only things you need to change are the events to have it create the appropriate range actor on actor creation and destroy it on actor destruction.
edit: I realize somebody already posted the correct answer midway through the thread. Why are people still posting "I don't know how to do this" when the answer is literally in the same thread?
WEll, because when you are not that into the editor it is very hard to follow. The thing I actually come across is: Abil.terranbuild.PLacement ->validateunit is buildingtype ->create
I can't find "terranbuild" for example... and for "buildingtype" I also can't find something that fits here :-/
Well, I found out that for "terranbuild" my copy of the building ability of my probe would fit. But I can't find what "buildingtype" my Tower is (which is based on a Photon Cannon). In Events+ -> ValidateUnit -> there is not my tower or photon cannon, nor does IsProtoss or IsStructure work
Does anyone know how to show the projected attack range of a building when placing it? (like the Photon Cannon or Missile Turret)
I know how to show the attack range once its placed, but not while placing it. I have been working on and off since the editor came out, and I have tried MANY different things.
It would be nice if you tested your method before posting in here, its stumped a lot of people in IRC chat too, but any suggestions are much appreciated.
Thanks
Try looking at the protoss pylon and how it shows the energy range.
Not sure if this'll work though.
EDIT: use this if WarTurtle's method (post #5) doesn't work for you (altough I think this method is prettier).
EDIT2: These steps are actually for showing the range on a certain selected unit.
I worked 6 hours straight on this one:
1. go to Actors.
2. Right click the actor list and "Add Object".
3. Give it a name (i.e. PhotonCannonProtectRange)
4. click "suggest"
5. Actor Type: Range
6. Based on: CActorRange
7. Click "OK".
8. Select the created object (or it's already selected).
9. Set the "Weapon" field to the weapon range you want to use (i.e. "Phase Cannon - Photon Cannon" )
10. Double click the "Events - Send" field.
11. Create a new event (right click the list -> Add Event).
12. Set the Msg Type to "Create".
13. Click the "ActionDamage" event (the one you just created).
14. Set "Msg Type" to "Selection Update (Local).
15. Set "Sub Name" to "Start".
16. Create another event in the same manner so it looks like the screenshot attached.
If you can select "Photon Cannon" in "Source Name", the bug was fixed and you should select it, if not this is how to work around it:
BUG: "Source Name" will only have "(None)", THIS SUCKS, because now we have to directly edit the XML of the map, this is how:
16. Download something that can edit MPQ files.
17. Save your map somewhere you can find it.
18. CLOSE GALAXY EDITOR.
19. Open your map in the MPQ editor and extract the following file somewhere you can find it: "Base.SC2Data\GameData\ActorData.xml".
20. Open "ActorData.xml" in any (non retarded) text editor (like Notepad++).
21. Now alter the "*" in both "SelectionLocalUpdate.*.Stop" to match the unitID you want to show the range for.
22. Update the "ActorData.xml" from your map with the one you modified.
23. Close MPQ editor and load your map in the Galaxy Editor.
24. Now find the actor you created at step 2., double click "Events - Send" and your stuff should like like the other screenshot.
Test it :) . *pray pray pray*
lol he already had the ring showing once the building was built, thats just a behavior copy+paste in data editor >.>
But you answered his question with the Bonus, so its all good xD
Heya
okay
you want to make a range actor
for selection
set the weapon / range however you want
In the CActorBase
selectionlocalupdate.*.start -> validateunit is Unittype -> selected -> create
selectionlocalupdate.*.stop -> valadateunit is unittype -> destroy
For buildings when being placed
Abil.terranbuild.PLacement ->validateunit is buildingtype ->create
This creates the range around the building. Note buildings have a different visual (the little boxes) instead of the normal range for weapons. Aka my supply depot shows a ring of boxes around itself instead of the "attack" range normally shown for units.
I tried both methods and I'm unable to get it to work :(.
It shows his range once he is build, but not during placement which is what im looking for. I'll continue to work on it tonight with this info and hopefully I'll get somewhere or find my mistake. Thanks.
AndyBear
@WarTurtle2:
OH, MY, GOD. Lol.
Thanks for that. I _tried_ to add a term to only show it on some units, but all my attempts failed, let me check if this method works.
Edit: Ok I still can't get it to work your way Warturtle so I'll use my super long way of doing it :P.
(Still cant get "placement" to work too, sorry AndyBear).
Just enable RAW data to edit the *'s. You dont need to use an mpq editor. And no, I cant figure out placement either. ;(
also seeking a way to make range work during placement.
hey maverck
iv'e seen you got it to work in your latest map verison, how did you do it?
What you are looking for is the "PlacementModel" actor. Check under events, it should be self explanatory. If you don't understand, feel free to ask.
@Gronee: Go
thanks, got it to work
For buildings when being placed
Abil.terranbuild.PLacement ->validateunit is buildingtype ->create
I cant get this working, anybody any idea why?:D (I done exactly, which is there...)
I'm still stuck on this. Someone please...?
Having the same problems right now. Have a working range indicator on a tower after following Beider's Video Tutorial, but have no clue how to correct the range indicator when placing a tower.
Additionally I want apply this range to all of my 50 Towers .... is there an easy way instead of making validators for each tower? (which would be a mess)
You need to create a custom placement actor for you unit. the placement actor should be based on the standard "Placement Model" actor, the only things you need to change are the events to have it create the appropriate range actor on actor creation and destroy it on actor destruction.
edit: I realize somebody already posted the correct answer midway through the thread. Why are people still posting "I don't know how to do this" when the answer is literally in the same thread?
@RileyStarcraft: Go
WEll, because when you are not that into the editor it is very hard to follow. The thing I actually come across is: Abil.terranbuild.PLacement ->validateunit is buildingtype ->create
I can't find "terranbuild" for example... and for "buildingtype" I also can't find something that fits here :-/
Still don't get it :(
Well, I found out that for "terranbuild" my copy of the building ability of my probe would fit. But I can't find what "buildingtype" my Tower is (which is based on a Photon Cannon). In Events+ -> ValidateUnit -> there is not my tower or photon cannon, nor does IsProtoss or IsStructure work