Page 1 of 1

[Unsolved]Technology Descriptions

Posted: Tue Mar 22, 2016 7:38 pm
by Hellaciouss
Hello,

Having an issue here with descriptions for technology.

I am trying to create an addition tier of solar power/

Here is the small issue I'm having;

Image

The technology description here is being pulled form the solar_energy technology description

I have it set up in my locale file here as solar_energy_2 as the tech name and solar_energy_2 tech description as Allows access to a more efficent and smaller version of the larger solar panel as you can see here

How do it get it to pull the solar_energy_2 tech description instead of the solar_energy one?

Image

Re: Technology Descriptions

Posted: Tue Mar 22, 2016 8:15 pm
by Hellaciouss
I've solved my problem and I feel a bit silly.

In my technology.lua file I had

Code: Select all

type = "technology",
name = "solar-energy-2"
And it needed to be:

Code: Select all

type = "technology",
name = "solar_energy_2",

Re: [Solved]Technology Descriptions

Posted: Tue Mar 22, 2016 8:25 pm
by daniel34
I would advise you to use dashes (-) instead of underscores (_) as word-separator because all entities/items/recipes in Factorio and most other mods are already written that way and it is easier to understand your code if someone else reads it (in code, the _ is already used for function names).

Re: [Solved]Technology Descriptions

Posted: Wed Mar 23, 2016 7:07 pm
by Hellaciouss
daniel34 wrote:I would advise you to use dashes (-) instead of underscores (_) as word-separator because all entities/items/recipes in Factorio and most other mods are already written that way and it is easier to understand your code if someone else reads it (in code, the _ is already used for function names).
I've been unable to add custom technology descriptions to tier'd technology unless I use _'s. When I use -'s it just defaults to the tier 1 description. Is there another way around this? I do notice I get the little nifty 2 or 3 on the technology icon when I use the -'s though, which is neat, but again, I am unable to have a custom description to the "-2" addition.

It seems like it's something that would need to be changed by devs as none of the tier'd tech have additional descriptions. They either have none or default to the tier 1 description.

Re: [Unsolved]Technology Descriptions

Posted: Thu Mar 24, 2016 11:43 pm
by Hellaciouss
Anyone able to shed some light onto how this could be done? Still unable to find a way to add a different description to the technology while keeping the -2 (the number 2 on the bottom right hand of the tech icon)

Re: [Unsolved]Technology Descriptions

Posted: Fri Mar 25, 2016 12:00 am
by DaveMcW
I don't think you can. If the description is that important to you, rename the tech solar-energy-two.