Adding a gui button that makes selected units change position
by Jesse P · in RTS Starter Kit · 05/03/2008 (8:55 pm) · 6 replies
Ok here's something I really need to tackle but lack the coding skills to accomplish on my own and am needing some major help:
How would I add a gui button (or keyboard command for that matter) in the game that would make all selected units move into a circular formation? Would take quite a bit of coding and don't even know where to start really
Thanks in advance
How would I add a gui button (or keyboard command for that matter) in the game that would make all selected units move into a circular formation? Would take quite a bit of coding and don't even know where to start really
Thanks in advance
#2
05/04/2008 (10:21 am)
That one initiates when you set a movement destination, I imagine it wouldn't be too hard to get it to initiate when you click a button on the gui, but I'm not certain how to go about that. Any suggestions? Thanks
#3
05/05/2008 (4:45 pm)
Do you what your units to move to a scripted place in formation when a button is pressed? This could be done by adding the command function of the resource only, then calling the command when a button is pressed with the %x, %y, and %z parameters manually set to where ever you want the formation to be. Is that what you mean, or do you mean you want to be able to select a location and then hit a formation button to start the move?
#4

And have the squad move in formation in the direction of the V wherever you click the location to be.
05/05/2008 (4:55 pm)
Thinking about it more it would probably be easier to have it where the player hits the formation button and then selects the location. Like it is in the resource in the link above. I just need to figure out how to make a couple formation types that I have no clue how to go about. The main one I need to work on is what's called a wedge, which has a V shape in the front, the squad leader in the middle, and another V shape in the back. Like this:
And have the squad move in formation in the direction of the V wherever you click the location to be.
#5
05/06/2008 (6:51 pm)
I'll take a look at this. The formation is complex and will require some thinking through. I am also interested in the V formation for use in my game.
#6
05/06/2008 (7:46 pm)
Thanks, keep me posted. It's a common formation that the Army uses for squad movement
Torque Owner Jonathon Schad