MaxenceDC / sparsestructures

A simple and configurable one-mixin mod that makes all (even datapacks and modded) structures more spread out (or more common!), essentially making them rarer/easier to find. Useful in big modpacks with a lot of structures mod to encourage exploration and make the experience more challenging or balanced.
https://modrinth.com/mod/sparsestructures
MIT License
4 stars 4 forks source link

Sometimes High-speed Rail overrides Sparse Structure's Config #18

Closed Aninuscsalas closed 6 months ago

Aninuscsalas commented 6 months ago

Minecraft generates the same config file for both mods. (Not sure which mod causes it so i made a report in both repos https://github.com/pcal43/highspeed-rail/issues/15)

Steps to reproduce:

Both config files (highspeed-rail.json5 and sparsestructures.json5) have the same content. Its either this

{

  //
  // List of blocks and how they affect a train travelling on top.  cartSpeed is in blocks-per-second.
  //
  'blocks' : [
    {
        'blockId': 'minecraft:gravel',
        'cartSpeed': 40
    }
  ],

  // Whether a speedometer should be displayed when you get in a minecart.
  //
  // The mod must be installed on the client for this to work.
  'isSpeedometerEnabled'     : true,

  // Whether the 'true' speed should also be displayed on the speedometer.  The deafult speedometer just shows your
  // approximate speed; this precisely measures distance travelled every tick.  It's more resource-intensive
  // and also flickers sort of annoyingly, so disabled by default.  There's usually not much difference, anyway.
  'isTrueSpeedometerEnabled' : false,

  // Whether Vanilla ice boats should be allowed.  Set to 'false' to limit ice boats to ground speed; 'true'
  //
  // The mod must be installed on the client for this to work.
  'isIceBoatsEnabled'        : false
}

or this

// ### THE MOD REQUIRES A RESTART OF THE GAME TO APPLY CHANGES ###
{
  // this is the main spread factor (default is 2)
  //
  // tips : a spread factor can be a decimal number (such as 1.5)
  //        a spread factor of 1 means all structure's placement are not modified (useful if you want to use only custom spread factors)
  //        a spread factor above 1 means all structures are rarer
  //        a spread factor below 1 means all structure are more common
  "spreadFactor": 2,

  // this is a list of custom spread factors
  "customSpreadFactors": [
    // example of the mansion being doubled in rarity (the mod's default)
    {
        "structure": "minecraft:mansion",
        "factor": 2
    },
    // add the structures you want to modify in the format:
    // {
    //     "structure": "namespace:structure_name",
    //     "factor": number
    // },
    // where "structure" is a structure_set or the name of a structure
    // /!\ if you put the name of a structure, all structures in its set will be modified
    // (example : "minecraft:village_plains" will modify all structures in the "villages" set)
    // see https://minecraft.wiki/w/Tutorials/Custom_structures#Structure_Set for more info
    //
    // tip : the same spread factors rules apply here
  ]
}

Minecraft logs (No errors here) : https://mclo.gs/lulisJF

MaxenceDC commented 6 months ago

Hmm that's a really weird issue, I too use highspeed rail and I don't think I've encountered this issue... I'll check and see if I can reproduce it and fix it. Thank you for reporting this

MaxenceDC commented 6 months ago

Oh I think I know why, highspeedrail and my mod both use the same default config name. I'm curious as to why it's happening since they are not located in the same directory, but I'll change the default config name to something specific to sparse structures, I think that might fix the issue.