Coder Social home page Coder Social logo

bilka2 / changemapsettings Goto Github PK

View Code? Open in Web Editor NEW
7.0 7.0 2.0 112 KB

Factorio mod that allows to change map and map generation settings at any time

Home Page: https://mods.factorio.com/mod/ChangeMapSettings

License: MIT License

Lua 99.09% Shell 0.91%
factorio factorio-mod mod

changemapsettings's People

Contributors

bilka2 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

rksharkz catt0

changemapsettings's Issues

Error while running event ChangeMapSettings::on_gui_click (ID 1) Value (inf) outside of range.

The mod Change Map Settings (5.0.1) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event ChangeMapSettings::on_gui_click (ID 1)
Value (inf) outside of range. The data type allows values from -340282346638528942488602606004204804240.000000 to 340282346638528942488602606004204804240.000000 in property tree at ROOT.terrain_segmentation
stack traceback:
	[C]: in function '__newindex'
	__ChangeMapSettings__/control.lua:143: in function 'change_map_gen_settings'
	__ChangeMapSettings__/control.lua:173: in function <__ChangeMapSettings__/control.lua:153>

2022-04-18_1920x1080

Changing map-gen settings inadvertently removes the "planet-size" autoplace_control

I noticed that you intentionally exclude "planet-size" from appearing in the map-gen gui if it's present as one of the autoplace_control_prototypes, which is indeed a good idea for Space Exploration players.

The issue is that the "planet-size" autoplace_control doesn't actually get preserved if the user were to make/apply any map-gen changes using the mod. Adding the following to control.lua:131 would prevent this issue from happening.

if player.surface.map_gen_settings.autoplace_controls["planet-size"] then
    settings.autoplace_controls["planet-size"] =
        player.surface.map_gen_settings.autoplace_controls["planet-size"]
end

Thanks in advance for looking into this. If you accept PR's, I'd be happy to submit a small PR with that change.

Option for unrestricted map settings

Map gen settings are already unlimited. Maybe the option could work for both map settings and map gen settings, which would mean adding limits for the map gen settings.

Old text from my notes (last edited October 2020):

make map settings not have limits/have override limits checkbox or something

Removal of Creative Mod's menu

When removing the Change Map Settings mod from a game, it removes its button from the top left of the game screen, and this is OK.

However, Creative Mod also places a button at the same spot. When Change Map Settings is removed from the game, it inadvertently also removes Creative Mod's button, which is terribly wrong.

This is causes a big issue, because the only way to restore Creative Mod's button is by removing it and adding it again to the game, which implies on removing all Creative Mod stuff from the game, which is a no-go. So while this is not fixed, one must decide either not having both mods installed, or to never remove Change Map Settings Mod from its game, otherwise Creative Mod will be permanently damaged.

As an additional idea, I would suggest adding an option for showing/hiding the Change Map Settings button, since it is not frequently used in game. This would be an elegant solution for reducing unused UI elements from the game view. This is important because game debug messages are obstructed by this button.

Resources decrease after mod removal

Hi,

if you make changes with the mod, save and remove it from the loaded mods, ALL ore deposits are MUCH smaller, even the ones already generated.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.