Hidden/Spoiler:
Change the order of units [Solved]
Moderator: Moderators
-
Noobasaurus
- Droid Pilot Assassin

- Posts: 2006
- Joined: Tue Aug 17, 2010 5:56 pm
Change the order of units [Solved]
How do I change the order of the units? It doesn't seem to be the lua that does this, nor the points to unlock, so what could it be?
Last edited by Noobasaurus on Sun Jul 03, 2011 4:33 pm, edited 1 time in total.
-
AQT
- Gametoast Staff

- Posts: 4910
- Joined: Sat Nov 03, 2007 4:55 pm
- Location: SoCal, USA
Re: Change the order of units
It is the .lua that does this.Noobasaurus wrote:It doesn't seem to be the lua that does this
The positions will always be in that order. Any additional AddUnitClass functions will follow consecutively in order.setup_teams.lua wrote:Code: Select all
local typeList = { "soldier", "pilot", "assault", "sniper", "marine", "engineer", "officer", "special" }
- Jendo7
- Sith

- Posts: 1304
- Joined: Wed Apr 01, 2009 6:37 pm
- Location: Cambridge, England.
- Contact:
Re: Change the order of units
You can change the number of points to unlock a unit by either using the SetClassProperty function in the .lua, for example:
or alternatively put it in the default units .odf under Properties:
Code: Select all
ReadDataFile("dc:SIDE\\rep.lvl",
"rep_inf_ep3_officer")
SetClassProperty("rep_inf_ep3_officer", "PointsToUnlock", 16)Code: Select all
[Properties]
PointsToUnlock = 16-
Noobasaurus
- Droid Pilot Assassin

- Posts: 2006
- Joined: Tue Aug 17, 2010 5:56 pm
Re: Change the order of units
Well, the thing is, I set the pilot after special and marine after pilot, and it works for the CIS but for the republic the pilot is in front of the special.AQT wrote:It is the .lua that does this.Noobasaurus wrote:It doesn't seem to be the lua that does thisThe positions will always be in that order. Any additional AddUnitClass functions will follow consecutively in order.setup_teams.lua wrote:Code: Select all
local typeList = { "soldier", "pilot", "assault", "sniper", "marine", "engineer", "officer", "special" }
Pilot's odf:
Hidden/Spoiler:
Hidden/Spoiler:
Well, thanks, now I know another way to set points to unlock, but my question was how to change the order of the units. (Ex. Engineer in front of solider)Jendo7 wrote:You can change the number of points to unlock a unit by either using the SetClassProperty function in the .lua, for example:
or alternatively put it in the default units .odf under Properties:Code: Select all
ReadDataFile("dc:SIDE\\rep.lvl", "rep_inf_ep3_officer") SetClassProperty("rep_inf_ep3_officer", "PointsToUnlock", 16)
Code: Select all
[Properties] PointsToUnlock = 16
-
THEWULFMAN
- Space Ranger
- Posts: 5557
- Joined: Tue Aug 17, 2010 3:30 pm
- Projects :: Evolved 2
- Location: Columbus, Ohio
- Contact:
Re: Change the order of units
The name of the "class" type has nothing to do with how a unit behaves, so you can just change the order of which they are in. For example,if you want the engineer in front of the soldier, simpley change the lua from
To this
Hidden/Spoiler:
Hidden/Spoiler:
-
Noobasaurus
- Droid Pilot Assassin

- Posts: 2006
- Joined: Tue Aug 17, 2010 5:56 pm
Re: Change the order of units
Oh...well that's a simple fix.
Thanks for the help!
Thanks for the help!
