Joe Miller 0 Posted July 15, 2005 I need a simple script to make a ai units spawn in a bunker each 10 seconds and join a certain group. I need also to stop the spawning of ai when a certain unit is destroyed. That's what i need: i've looked for scripts in ofpec but they are all complicated (patrols, multiplespawn etc) , i need just a simple spawn script. Share this post Link to post Share on other sites
Joe Miller 0 Posted July 15, 2005 Since noone was able to help me i tried and tried and now i managed to do something that seems good: ;---Cattura Variabili--- _unit = _this select 0 _pos = _this select 1 _group = _this select 2 _init = _this select 3 _uff = _this select 4 ;---Creazione unitŕ--- #loop ? !(alive _uff): goto "exit" _unit createUnit [getmarkerPos _pos,_group] ~10 ;---Riinizio dello script goto "loop" ;--- Fine dello script--- #exit exit Share this post Link to post Share on other sites
Metal Heart 0 Posted July 15, 2005 What's that do when group is full? ... nothing. Share this post Link to post Share on other sites
NeMeSiS 11 Posted July 15, 2005 What's that do when group is full?... nothing. [nameofspawnedunit] join grpnull? Share this post Link to post Share on other sites
Metal Heart 0 Posted July 15, 2005 Nope, it doesn't spawn unit when group is full. Share this post Link to post Share on other sites
NeMeSiS 11 Posted July 15, 2005 Nope, it doesn't spawn unit when group is full. the group wont get full if every unit joins a new group after being spawned Share this post Link to post Share on other sites
Metal Heart 0 Posted July 16, 2005 Oh sorry I misunderstood you. That way the limit would be grouplimit, 63 per side or so. Minus the groups elsewhere in the mission of course. I wonder what happens when that limit's reached. Share this post Link to post Share on other sites