They create fine but when I go to "Deploy to station" a new CV then that CV vanishes. It produces an error
[=ERROR=] Failed to connect component 'units_size_xl_builder_ship_macro' to 'tzonecluster_d_sector18_zone46_macro'. Child template connection not specified
I dug a bit deeper into NPC_Architect and $DeployedStation.buildlocation wasn't pointing at the correct buildlocation which causes the CV to fail to attach to the zone and hence vanish.
A station created with construct_station gets the buildlocation attribute right and you can "Deploy to station" a new CV
I wrote a testing script that creates a station every time you talk to a station Control Entity
When it finds somewhere free to build then it outputs some messages
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:193f6>: random zone 3 Magma Pool
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:193f6>: Free Build location <componentmacroslot:0x230e,buildcon1>
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:193f6>: Actual build location <componentmacroslot:0x230e,struct_bt_dv_canteran_outpost_02_macro>
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:197d8>: random zone 9 Furnace Chamber
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:197d8>: Free Build location <componentmacroslot:0x343b,buildcon1>
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:197d8>: Actual build location <componentmacroslot:0x343b,struct_bt_dv_water_destillery_macro>
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:19f0a>: random zone 4 Fervid Corona
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:19f0a>: Free Build location <componentmacroslot:0x2472,buildcon2>
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:19f0a>: Actual build location <componentmacroslot:0x2472,struct_econ_unique_ar_spp_xl_macro>
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:2055c>: random zone 2 Scorched Aura
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:2055c>: Free Build location <componentmacroslot:0x2171,buildcon1>
[Scripts] *** Context:md.StationStructuralRebuild.Test_Create_Station<inst:2055c>: Actual build location <componentmacroslot:0x2171,NULL>
Looking at that it seems to be putting the macro of the first NPC station in the zone into the buildlocation attribute or NULL if there isn't one
Its a bit of a show stopper

Code: Select all
<cue name="TestTrigger" namespace="this" instantiate="true" >
<conditions>
<check_any>
<event_conversation_started conversation="default" />
<event_conversation_returned_to_section section="default" />
</check_any>
<check_value value="event.object.container.class == class.station"/>
<check_value value="event.object.iscontrolentity" />
</conditions>
<actions>
<signal_cue_instantly cue="Test_Create_Station"/>
</actions>
</cue>
<cue name="Test_Create_Station" namespace="this" instantiate="true" comment="builds dummy stations">
<conditions>
<event_cue_signalled/>
</conditions>
<actions>
<find_sector name="$DV_CanteranSec" macro="macro.cluster_d_sector18_macro" space="md.$DeVries" required="true"/>
<find_zone name="$CanteranZones" space="$DV_CanteranSec" multiple="true" priorityzone="true" tempzone="false"/>
<set_value name="$RandZone" min="1" max="$CanteranZones.count" profile="flat"/>
<debug_text text="'random zone ' + $RandZone + ' ' + $CanteranZones.{$RandZone}.name"/>
<set_value name="$BuildIn" exact="$CanteranZones.{$RandZone}.name"/>
<do_if value="($CanteranZones.{$RandZone}.freebuildlocations.count ge 1)" >
<set_value name="$BuildLocation" exact="$CanteranZones.{$RandZone}.freebuildlocations.random"/>
<set_value name="$results" exact="'Free build location ' + @$BuildLocation + '\n'"/>
<debug_text text="'Free Build location ' + $BuildLocation"/>
</do_if>
<do_else>
<set_value name="$results" exact="'No - Free Build location'"/>
<show_notification caption="$BuildIn" details="[$results]" timeout="3s" queued="false"/>
<remove_value name="$BuildLocation"/>
</do_else>
<do_if value="@$BuildLocation">
<set_value name="$BuildMacro" exact="macro.struct_bt_alb_farm_complex_macro" />
<create_station name="$playerstation" macro="$BuildMacro" zone="$BuildLocation.component" owner="faction.player">
<position value="$BuildLocation.offset"/>
<buildsequence sequence="'a'" stage="1"/>
</create_station>
<debug_text text="'Actual build location ' + $playerstation.buildlocation"/>
<set_value name="$results" exact="$results + 'Actual build location ' + $playerstation.buildlocation"/>
<show_notification caption="$BuildIn" details="[$results]" timeout="10s" queued="false"/>
</do_if>
</actions>
</cue>
jth