Page 1 of 1

Give Build Order with lua

Posted: 04 Aug 2008, 07:02
by Thor
Could someone please show me an example of how to give a build order to a unit or factory? thanks

edit: got it now, thanks lurker

Re: Give Build Order with lua

Posted: 04 Aug 2008, 07:55
by Evil4Zerggin
IIRC the CMD id to build a unit is -unitDefID. Not sure what parameters to give it, though; try {} or {x, y, z}. To give the order to a unit try this:

Code: Select all

Spring.GiveOrderToUnit(builderUnitID, -unitToBuildDefID, {--[[not sure what to put for params]]}, options})