Page 1 of 1

Teleport or spawn?

Posted: Sun Jul 19, 2020 11:04 pm
by djoos5
It has been a while since I did any scenario building and I am sure that these questions have been asked before, so forgive me if I ask again...

Is the Teleport action still the only way to simulate the 'spawning' of a unit (ie a marine platoon from a helicopter), or is there some new LUA code that allows me to spawn a unit by type and side?

Is there now LUA code that will change the side of a facility or unit to simulate its capture? Or do I need to still use the teleport action to port out the original and port in the same type unit assigned to the 'capturing' side?

Thanks in advance for the help?

RE: Teleport or spawn?

Posted: Mon Jul 20, 2020 12:33 am
by KnightHawk75
Yes there are LUA functions to spawn a unit of a given type on a given side (and have been for awhile now, ScenEdit_AddUnit).
Yes there are LUA functions to change the side of a facility or unit to simulate it's capture (ScenEdit_SetUnitSide).
ref: http://commandlua.github.io/index.html

If you run into trouble or need help with something specific post in the lua legion sub forum.




RE: Teleport or spawn?

Posted: Mon Jul 20, 2020 2:13 pm
by djoos5
Thank you very much!