Thanks people,
First: the XML and Java mixing. So, if I understand that correctly, there are three things to be taken in account:
1. The scripts.plist has to be renamed into someuniquename.plist, listed in the worldscripts.plist together with eventual js scripts, and does no longer reside in the oxp's Config folder, but goes into the Scripts folder.
2. Java scripts go into the Scripts folder anyways and also have to be listed in the worldscripts.plist except if they are activated from the shipdata.plist, in which case they shall not be listed in the worldscripts.plist.
3. If a Java ship script is called from the shipdata.plist with ...
<key>script</key>
<string>SomeSortOfJavaScript.js</string>
... then "SomeSortOfJavaScript.js" should not be listed in the worldscripts.plist, yes?
Is all of the above correct?
Note that you have used inconsistent keys in your question. defense_ship_role asks for a role, but escort-ship asks for a ship type (the unique name of its shipdata.entry). There is also defense_ship, which works analogous to escort-ship, asking for the unique shipdata-key; and escort-role, which asks for a role.
I knew that one from the wiki. I did use escort-ship for I didn't want to have to create an AI for that specifically. I did use defense_ship_role because that's a ship someone gave me to use and it already has a custom built AI.
My problem is that for some reason the escorts never show up. I have no idea why, perhaps overlooking something glaringly obvious (again
) but one suspicion was that having defense ships and escorts together would perhaps constitute a problem. Thanks to Eric, I know now that the problem isn't that.
Of course you can use them as in your question. In that case the carrier would be escorted by one type of ship only, but would be able to launch a variety of defense ships in case of an attack (all those types that have the specified role in their role set).
That is my intention exactly, yes.
Rename script.plist to uniqueprefix-something-else.plist, put it in the Scripts folder, and list it in world-scripts.plist.
Thanks, done.
when you don't want to write a custom AI
Already have one ... perhaps will try with escort-role instead, perhaps there's a problem? Could use the escortAI perhaps?
Thanks for the tips so far,
L