Why is my new Ship Part locked?

Creation, discussion, and balancing of game content such as techs, buildings, ship parts.

Moderators: Oberlus, Committer

Post Reply
Message
Author
jhalfast
Space Krill
Posts: 5
Joined: Fri Sep 28, 2018 7:59 pm

Why is my new Ship Part locked?

#1 Post by jhalfast »

I thought I had a hand on things, but I've run into an embarrassing issue - I can't seem to add a new ship part correctly.

I've built a bare-bones part and added it to the items.inf for starting unlocks... it shows up complete with name and description from the string table, but it is unavailable. There's nothing in the script to keep it locked, and following my experience of adding a new hull and new building, it should be unlocked from the start.

Pertinent info from en.txt:

Code: Select all

PP_I_S_FUSION
Interstellar Fusion Engine

PP_I_S_FUSION_DESC
Increases [[metertype METER_SPEED]] by 30. Fusion Engine specifically designed for MARCS FTL propulsion.
Entry on items.inf:

Code: Select all

Item type = ShipPart name = "PP_I_S_FUSION"
Contents of PP_I_S_FUSION.focs.txt:

Code: Select all

Part
    name = "PP_I_S_FUSION"
    description = "PP_I_S_FUSION_DESC"
    class = Speed
    capacity = 30
    mountableSlotTypes = Internal
    buildcost = 15 * [[FLEET_UPKEEP_MULTIPLICATOR]] * [[SHIP_PART_COST_MULTIPLIER]]
    buildtime = 3
    tags = [ "PEDIA_PC_SPEED" ]
    location = OwnedBy empire = Source.Owner
    icon = "icons/ship_parts/engine-1.png"

#include "/scripting/common/upkeep.macros"
...I know it's got to be something very stupidly simple, please point out my error!

User avatar
Dilvish
AI Lead and Programmer Emeritus
Posts: 4768
Joined: Sat Sep 22, 2012 6:25 pm

Re: Why is my new Ship Part locked?

#2 Post by Dilvish »

Please be more specific about "shows up" and "is unavailable" -- shows up where? Is unavailable how? Can you make a ship design with it but just not build the ship? If the latter is the case, please 'show unavailable' in the BuildDesignator and then mousehover over this entry until you get the popup showing which of its enqueue/location conditions are met or not met, and take a screenshot of that and post it here.
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0

jhalfast
Space Krill
Posts: 5
Joined: Fri Sep 28, 2018 7:59 pm

Re: Why is my new Ship Part locked?

#3 Post by jhalfast »

My apologies. Without any change in coding, I started a new game, and all is well. Lesson learned.

Post Reply