[1.1.94] Blueprint string import requirement incongruencies

Bugs that are actually features.
Post Reply
Qon
Smart Inserter
Smart Inserter
Posts: 2120
Joined: Thu Mar 17, 2016 6:27 am
Contact:

[1.1.94] Blueprint string import requirement incongruencies

Post by Qon »

This blueprint works:

Code: Select all

{
  blueprint: {
    icons: [
      {
        signal: { type: 'item', name: 'constant-combinator' },
        index: 1
      }
    ],
    entities: [
      {
        name: 'small-lamp',
        connections: {
          '1': {
            red: [ { entity_id: 2, circuit_id: 1 } ],
            green: [ { entity_id: 3 } ]
          }
        },
        position: { x: 0.5, y: 0.5 },
        entity_number: 1
      },
      {
        name: 'decider-combinator',
        connections: {
          '1': { red: [ { entity_id: 1 } ] }
        },
        position: { x: 1.5, y: 0.5 },
        direction: 2,
        entity_number: 2
      },
      {
        name: 'small-lamp',
        connections: {
          '1': {
            red: [ { entity_id: 4, circuit_id: 1 } ],
            green: [ { entity_id: 1 } ]
          }
        },
        position: { x: 0.5, y: 1.5 },
        entity_number: 3
      },
      {
        name: 'decider-combinator',
        connections: {
          '1': { red: [ { entity_id: 3 } ] }
        },
        position: { x: 1.5, y: 1.5 },
        direction: 2,
        entity_number: 4
      }
    ],
    item: 'blueprint',
    version: 281479277838336
  }
}
However, if I remove the ", circuit_id: 1 " parts from the red wires, the green wire don't appear (Though I get "Blueprint imported successfully" in flying text.)

Non-working bp:

Code: Select all

{
  blueprint: {
    icons: [
      {
        signal: { type: 'item', name: 'constant-combinator' },
        index: 1
      }
    ],
    entities: [
      {
        name: 'small-lamp',
        connections: {
          '1': { red: [ { entity_id: 2 } ], green: [ { entity_id: 3 } ] }
        },
        position: { x: 0.5, y: 0.5 },
        entity_number: 1
      },
      {
        name: 'decider-combinator',
        connections: {
          '1': { red: [ { entity_id: 1 } ] }
        },
        position: { x: 1.5, y: 0.5 },
        direction: 2,
        entity_number: 2
      },
      {
        name: 'small-lamp',
        connections: {
          '1': { red: [ { entity_id: 4 } ], green: [ { entity_id: 1 } ] }
        },
        position: { x: 0.5, y: 1.5 },
        entity_number: 3
      },
      {
        name: 'decider-combinator',
        connections: {
          '1': { red: [ { entity_id: 3 } ] }
        },
        position: { x: 1.5, y: 1.5 },
        direction: 2,
        entity_number: 4
      }
    ],
    item: 'blueprint',
    version: 281479277838336
  }
}
I could expect circuit_id to be a requirement for entities with multiple connection points (arithmetic and decider), but they don't seem to be. At least, the red wires which have them are not affected at all if circuit_id is there or not. It correctly defaults to 1.
I don't understand how the green wire is affected by the definition of the red wire though. That seems like a bug.
Expected result:
  • Both blueprints should work the same (not true here).
  • Red wire definitions shouldn't affect green wire definitions (not true here).
  • I should be able to leave out circuit_id if it connects to 1 (input) on a arithmetic/decider (true here for the red wire, it still works, but false in the sense that other "unrelated" parts of the blueprint breaks.)

Rseding91
Factorio Staff
Factorio Staff
Posts: 13219
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [1.1.94] Blueprint string import requirement incongruencies

Post by Rseding91 »

Thanks for the report however I don't consider changing the internal blueprint string representation worth our time. The format has its requirements (which have never been explained in detail) and if they aren't met then areas will not work (as you've found).

Wires specifically suppress any errors that show up because entities may or may not have wire support depending on the mod(s) active at any point when importing a string.
If you want to get ahold of me I'm almost always on Discord.

Post Reply

Return to “Not a bug”