Hafody Posted February 2, 2017 Posted February 2, 2017 What is the best way to get a group which consists of one airframe to respawn back to original base it departed from after landing at a different base...???
FlightControl Posted February 2, 2017 Posted February 2, 2017 moose example Not an answer with mist, but with moose... local PlaneSpawn = SPAWN:New("Planegroup") PlaneSpawn:InitRepeatOnLanding() PlaneSpawn:Spawn() Once the plane group lands, it will be respawned at the original position defined in the mission editor. Check here: http://flightcontrol-master.github.io/MOOSE/ Fc [TABLE][sIGPIC][/sIGPIC]| Join MOOSE community on: DISCORD :thumbup: Website of the MOOSE LUA Framework. MOOSE framework Downloads. Check out Example Missions to try out and learn. MOOSE YouTube Channel for live demonstrations and tutorials. [/TABLE]
Grimes Posted February 3, 2017 Posted February 3, 2017 It is mostly just down to determining when you want to respawn the group. So you can do a check like if Unit.getByName('whatever') and Unit.getByName('whatever'):inAir() == false then mist.resapwnGroup('whatever', true) end Depending on how often that was checked it may respawn the group the moment it lands. Alternatively you can add a delay to the check or whatever else. The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
Wrench Posted February 5, 2017 Posted February 5, 2017 Mine is slightly different: if not Group.getByName('RUSCAP1') then local msg = {} msg.text = "Respawning RUSCAP1." msg.displayTime = 30 msg.msgFor = {coa = {'all'}} mist.message.add(msg) mist.respawnGroup('RUSCAP1', true) local con = Group.getByName('RUSCAP1'):getController() end I can't remember where I got this from, but it works. It also displays a message for 30 seconds. This is setup to respawn a group called RUSCAP1. This just respawns them wherever they originally started, so if they start on a ramp, they'll respawn on the ramp. Be aware that parking spaces are not preserved, so they'll just pick the first open parking space. Carrier Script.
FlightControl Posted February 6, 2017 Posted February 6, 2017 What is the best way to get a group which consists of one airframe to respawn back to original base it departed from after landing at a different base...??? Tomorrow we'll get your stuff together Hafody :-) We're almost there, aren't we? FC [TABLE][sIGPIC][/sIGPIC]| Join MOOSE community on: DISCORD :thumbup: Website of the MOOSE LUA Framework. MOOSE framework Downloads. Check out Example Missions to try out and learn. MOOSE YouTube Channel for live demonstrations and tutorials. [/TABLE]
Recommended Posts