Change the order of units [Solved]
Posted: Sat Jul 02, 2011 11:16 pm
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?
Hidden/Spoiler:
Get more from your games!
http://www.gametoast.com/
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" }
Code: Select all
ReadDataFile("dc:SIDE\\rep.lvl",
"rep_inf_ep3_officer")
SetClassProperty("rep_inf_ep3_officer", "PointsToUnlock", 16)Code: Select all
[Properties]
PointsToUnlock = 16Well, 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" }
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