TheDuckCow / godot-road-generator

A godot plugin for creating 3D highways and streets.
MIT License
316 stars 16 forks source link

Create buttons to add/select new road before/after roadpoint #43

Closed bdog2112 closed 1 year ago

bdog2112 commented 1 year ago

This work is, for the most part, complete!

What's working:

What proved challenging:

What requires additional work/research/troubleshooting: Naming algorithm needs evaluation. See additional notes further below.

Monthly time limit has been reached.

bdog2112 commented 1 year ago

Regarding node naming requirements:

We know that Godot will auto-increment numbers at the end of a name. Hence, in the simplest scenario, we could forego doing any special name processing and let Godot do the work.

Conversely, we could go high tech and employ regular expressions to search for numbers in the middle of names with the caveat that there could be multiple numbers and complex scenarios that might be hard to support. We would also need to define the supported and non-supported scenarios.

I propose the following simple and sustainable approach:

Examples:

Input: my_road01 Output: my_road02, my_road03, my_road04

Input: my_road Output my_road001, my_road002, my_road003

Input: my_#1road Output: my#1road001, my#1road002, my#1_road003

TheDuckCow commented 1 year ago

Thanks for detailing out these options. Will get to the code review tomorrow.

Regarding node renaming: let's not go crazy with that, it was a minor note that I was just hoping we'd do a simple solution for. The utility of the other tasks are higher, so I can live with what we have for now.

edit: said differently, I support your solution as it's using part of what Godot already does, and your addition to just add a 001 if needed works fine 👍

bdog2112 commented 1 year ago

Hey @TheDuckCow. Just checking in. I'll be back in the office on Wednesday. Please let me know if you have feedback on this PR. Also, stay tuned for comments in this UI/UX thread, which ties in to several upcoming tasks.