Logo Platform
logo amplifiers simplified

Wireframe ships in galaxy view

Reply
Copied to clipboard!
7 years ago
Jan 24, 2018, 3:08:05 PM

I have a mod that adds a copy fo the Riftborn carrier hull.  It works fine but in the galaxy view it has the wireframe of a riftborn colony ship.   Is there a way to assign it the wireframe of the carrier hull?

0Send private message
7 years ago
Jan 24, 2018, 4:40:08 PM

Hey tygart!


You'll have to look at the file Mapping.xml:

    <XmlMapping Name="ClassGarrisonFleet.Body">
        <GameObject Name="Format('FleetBody({0})', $(GUID))" Prefab="Format('Prefabs/Game/GalaxyFleet/GalaxyFleet_{0}_0{1}', $(ShortHull), $(ShipHullIndex))"/>
        <Fallback>
            <GameObject Name="Format('FleetBody({0})', $(GUID))" Prefab="Format('Prefabs/Game/GalaxyFleet/GalaxyFleet_{0}', $(ShortHull))"/>
            <Fallback>
                <GameObject Name="Format('FleetBody({0})', $(GUID))" Prefab="Format('Prefabs/Game/GalaxyFleet/GalaxyFleet_Fallback{0}', $(ShortAffinityMapping))"/>
                <Fallback>
                    <GameObject Name="Format('FleetBody({0})', $(GUID))" Prefab="Prefabs/Game/GalaxyFleet/GalaxyFleet_Fallback"/>
                </Fallback>
            </Fallback>
        </Fallback>
    </XmlMapping>

    <XmlMapping Name="ClassDockedFleet.Body">
        <GameObject Name="Format('FleetBody({0})', $(GUID))" Prefab="Format('Prefabs/Game/Dock/DockingFleet_{0}_0{1}', $(ShortHull), $(ShipHullIndex))"/>
        <Fallback>
            <GameObject Name="Format('FleetBody({0})', $(GUID))" Prefab="Format('Prefabs/Game/Dock/DockingFleet_{0}', $(ShortHull))"/>
            <Fallback>
                <GameObject Name="Format('FleetBody({0})', $(GUID))" Prefab="Format('Prefabs/Game/Dock/DockingFleet_Fallback{0}', $(ShortAffinityMapping))"/>
                <Fallback>
                    <GameObject Name="Format('FleetBody({0})', $(GUID))" Prefab="Prefabs/Game/Dock/DockingFleet_Fallback"/>
                </Fallback>
            </Fallback>
        </Fallback>
    </XmlMapping>

These are the two elements you'll have to pay attention to (one for when the fleet moves, one for when the fleet is docked on a system).


Elements such as $(ShortHull) are parameters that are given by the code, in this case you have access to the following parameters:

- ShipHull: The full Name of the ship's HullDefinition, or its RepresentativeMappingOverride (that's what you might want to add in your HullDefinition! Look at the Mothership (aka Arks) Hulls, they use this attribute). Example: "HullLarge00Vampirilis"

- ShortHull: ShipHull, without "Hull" at the beginning. Example: "Large00Vampirilis"

- ShipHullIndex: the n° of the hull (as given by the descriptor "ShulHull0X" or the Mothership (aka Ark) level). Example: "1"

- AffinityMapping: the AffinityMapping of the empire who owns the fleet/ship. Example: "AffinityMappingVampirilis"

- ShortAffinityMapping: AffinityMapping without "AffinityMapping" at the start. Example: "Vampirilis"

- GUID: The unique identifier of the ship. It's used only for naming the objects the game creates with the Prefabs. Example: "14250"


TL;DR: Add a RepresentativeMappingOverride on your HullDefinition, so it says "I look like THIS HullDefinition!"

Updated 7 years ago.
0Send private message
0Send private message
?

Click here to login

Reply
Comment

Characters : 0
No results
0Send private message