Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
Group management enhancements #7886
The third one is also based on @KeldorKatarn's patches: KeldorKatarn/OpenTTD_PatchPack@49082fb and KeldorKatarn/OpenTTD_PatchPack@bdabd04.
LordAro left a comment •
"Specific name" is ...a bad name. It took me a while looking at the code to realise what it was doing. Perhaps "automatically generated name" (or "autogen name" for things that want a shorter string)
In terms of commands, I wonder if it's actually worth creating a whole new command for what's essentially just CMD_CREATE_GROUP with an extra boolean flag.
CmdCreateGroup has the following bits:
Plenty of room to combine the two, IMO
I changed the functions'/variables' names as you suggested.
As for the command in my opinion it's a bit clearer to reading/using the code with 2 separated commands, instead of taking care of the various bits. Like if