ID:161520
 
I am making a RTS and how would I go about adding something I clicked to the list?

Also, I would like some examples of a movement system (like the selected units move to a certain area.
DadGun wrote:
I am making a RTS and how would I go about adding something I clicked to the list?

Look up the atom Click() proc.

Also, I would like some examples of a movement system (like the selected units move to a certain area.

Make everything in your selected units list... move to the area! Oh, right, you wanted an example.
turf/DblClick() //called when you double-click a turf
for(var/unit/U in usr.selected_units) //loop through your list of units
U.Move(src) //move each one
In response to Kaioken
I'm guessing that DadGun would want the units to be shown moving. Move() would just warp the units so it might be preferable to use either walk() or walk_towards(). Some sort of path finding algorithm might be even better (especially if creating AI), but the walk() family should do the basics if the normal movement system is being used.