Sets of generic functions that are very polished, then able to be pasted into any new program to immediately provide functionality.
I have a few games and editors and I've been thinking. Program it really well, once.
It is better to program modular systems. For example a Bitmap Font system I drop a dozen functions into a program and a few files into the program directory and suddenly the program has fantastic text. I have another system that safely loads objects and textures, keeps track of them, skips loading a texture again if loaded, clones already loaded objects, and smartly deletes the asset if no longer needed. Instant optimized asset management.
In some programs I have a rudimentary textbox accept input. It's harder than it sounds. I was thinking I should work out the very best textbox, like support backspace (done), add a character marker, mouse support, edit the middle of the text not just the end. Have it use the Bitmap font system. Basically program it awesome and super efficient. Then I can drop those functions into any program I make and have awesome text input.
Then I thought if I can do this with text input, then why not add on to it with a basic dictionary support. Like have every text input broken up into words and sent to a word list file. Then when typing have it try and auto complete the word, press space and it auto completes. So doable. Great for editors, like typing dialog.
I was thinking the same thing about lists. Like a lot of times I need to vertically list selectable stuff like file names, quests, maps, stuff. It's usually real rudimentary like a for loop and some mouse click handling stuff. I could just program a really nice generic list with mouse over graphics, a scroll bar, mouse wheel scroll support. Maybe a generic folder loader for it too. Then any time a program needs an awesome list it's there.
I use a system that prevents the program from crashing when the screen is locked or a Full Screen app is minimized. Same deal.
I guess moving between projects it seems to me there are certain things that can be programmed really well once that can be shared between programs, immediately giving a huge benefit. Like a brand new game and instead of starting with an empty page you start with 20-30 functions and some sort of framework.
See my previous tip here...
https://forum.thegamecreators.com/thread/207584