Matrix Games Forums

Forums  Register  Login  Photo Gallery  Member List  Search  Calendars  FAQ 

My Profile  Inbox  Address Book  My Subscription  My Forums  Log Out

Ferry mission to ship that is docked

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [New Releases from Matrix Games] >> Command: Modern Air / Naval Operations >> Mods and Scenarios >> Lua Legion >> Ferry mission to ship that is docked Page: [1]
Login
Message << Older Topic   Newer Topic >>
Ferry mission to ship that is docked - 11/27/2018 1:17:42 AM   
AlexinCT

 

Posts: 56
Joined: 10/31/2015
Status: offline
Obviously I can't create a ferry mission to a ship that is hosted to a port as I can't target that unit and create the mission, so I am asking if there is a way to do so with a lua script anyone can share.
Post #: 1
RE: Ferry mission to ship that is docked - 11/27/2018 7:11:48 PM   
Whicker

 

Posts: 249
Joined: 6/20/2018
Status: offline
could you have the ship leave port then create you mission and deactivate it, then return it to port? I do that sometimes when designing a scen, it is easier to work on the ship at sea.

It looks like it shouldn't be too hard to create the mission with lua, then assign the ship to that mission but I don't have an example to share.

(in reply to AlexinCT)
Post #: 2
RE: Ferry mission to ship that is docked - 11/27/2018 9:44:00 PM   
TheOttoman

 

Posts: 120
Joined: 12/14/2017
Status: offline
Here's something more massive than you are expecting, but I think that it does what you want, so feel free to use it as a basis.

First it creates sides, awareness, proficiencies, postures, and then it creates ports. Next it then creates ferry missions to each of those ports.

Then it for each platform type (in this case merchant vessel types) it creates a unit for each of the names in the array, puts it into a random port and then assigns it to a random ferry mission



< Message edited by TheOttoman -- 12/7/2018 10:14:28 PM >

(in reply to Whicker)
Post #: 3
RE: Ferry mission to ship that is docked - 11/27/2018 11:27:10 PM   
AlexinCT

 

Posts: 56
Joined: 10/31/2015
Status: offline
That is some interesting Lua there TheOttoma, neatly randomizes ships, but not what I am looking to do. I have a ship in port assigned to a mission, and I want a ferry mission for a helicopter I want to move to the ship. Obviously I can't create the ferry mission while the ship is in port. I guess I will need to create the ferry mission using Lua targeting the ship once it leaves port as suggested.

(in reply to TheOttoman)
Post #: 4
RE: Ferry mission to ship that is docked - 12/6/2018 12:54:21 AM   
tjhkkr


Posts: 2287
Joined: 6/3/2010
Status: offline
TheOttoman, that is the longest script I think I have seen. Wow. My weather script is not that long.
Did it take a while to debug? Nice job.

_____________________________

Remember that the evil which is now in the world will become yet more powerful, and that it is not evil which conquers evil, but only love -- Olga Romanov.

(in reply to AlexinCT)
Post #: 5
RE: Ferry mission to ship that is docked - 12/7/2018 1:50:44 AM   
Cik

 

Posts: 577
Joined: 10/5/2016
Status: offline
huh, that's fantastic! you've somehow caused my browser to print your entire script overflowing all the way down the page and outside the bounds of your post. that's very interesting!

(in reply to tjhkkr)
Post #: 6
Page:   [1]
All Forums >> [New Releases from Matrix Games] >> Command: Modern Air / Naval Operations >> Mods and Scenarios >> Lua Legion >> Ferry mission to ship that is docked Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts


Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI

0.156