Lemmings Forums

NeoLemmix => Community Edition => Closed => Topic started by: mantha16 on May 03, 2020, 08:45:36 PM

Title: [✓][SUG][ED] Show gridlines when snap-to-grid is active
Post by: mantha16 on May 03, 2020, 08:45:36 PM
Is it possible to create an optional feature in the editor where a visible grid can lay across the screen to help with accurate placement of terrain/objects.  Small squares if possible.

Thank you
Title: Re: [SUG][EDITOR] Show gridlines when snap-to-grid is active
Post by: WillLem on January 12, 2025, 03:46:25 AM
Quote from: mantha16 on May 03, 2020, 08:45:36 PMIs it possible to create an optional feature in the editor where a visible grid can lay across the screen to help with accurate placement of terrain/objects.

Quote from: GigaLem on January 11, 2025, 11:45:42 PM"View gridlines" for if you're not using clear physics mode in editor, toggle 1x1 grid or 2x2, 4x4, etc.

Yes, this is an idea I've also had and I'm surprised it's not already a feature. I'll definitely look at implementing this one as it will make snap-to-grid that much more usable.
Title: Re: [SUG][EDITOR] Show gridlines when snap-to-grid is active
Post by: WillLem on January 15, 2025, 06:18:22 AM
Done. Any preferences on grid colour?

(https://i.imgur.com/7OEtpdx.png)

Implemented in Commit 980915e
Title: Re: [SUG][EDITOR] Show gridlines when snap-to-grid is active
Post by: GigaLem on January 15, 2025, 06:20:46 AM
The color should be high contrast, like a bright gray or a invert of the back ground.
Title: Re: [SUG][EDITOR] Show gridlines when snap-to-grid is active
Post by: WillLem on January 15, 2025, 04:06:36 PM
Quote from: GigaLem on January 15, 2025, 06:20:46 AMThe color should be high contrast, like a bright gray or a invert of the back ground.

I originally drew it in bright grey and it looked far too high-contrast to me so I changed it to dark blue. I guess it's likely that everyone will have a different preference, and might even want to change it depending on the tileset they're working with, so I'll probably add a basic colour selector in settings.
Title: Re: [SUG][EDITOR] Show gridlines when snap-to-grid is active
Post by: WillLem on January 15, 2025, 05:59:28 PM
Added a basic colour selection list which updates the grid on-the-fly so it can be previewed:

(https://i.imgur.com/n3OIwZF.png)

The list provides 10 basic options to make it easier for users to make a choice and spend less time tweaking the settings, but it's actually possible to use any html web colour by using its name (there's a full list here (https://www.rapidtables.com/web/color/html-color-codes.html)) and adding it to the settings.ini (e.g. "GridColor CornflourBlue"), should users wish to do so.

Implemented in commit 59a811b.

EDIT: Users can also choose to set the colour to "(Invisible)" if they don't wish to use a visible grid (commit d5a58d6).