License Recommendations:Those are just recommendations meant primarily for those that don't have any idea how to license the project. As code/assets without any stated license doesn't provide any rights and therefore can't be reused in any way, but are also (wrongly) seen by many as in Public Domain, it's important to always state your license and therefore your intentions with your work. All participants are free to use any other licenses as long as they're either permissive or copyleft.
This part is completely informal and meant just as help for those completely lost in the world of licenses. It's not meant to indicate some license or group of licenses is better than another. Things might be slightly simplified here for the sake of clarity, so read further sources and primarily the license text itself if you want to be sure. This should not be interpreted as a legal advice of any kind.
Once you pick your license or licenses (you can license different parts of your work by different licenses and it's usually good idea to split at least by code and assets as they behave quite differently), just copy it's full text, edit any parts like <author> or <year> and put in into file called LICENSE in your repository/work folder. In case of multiple license mention shortly which part is licensed by that given license, like "All code in this projects is licensed under those conditions:". You can also mention the license in your README or in header comment of individual source files, but that shouldn't be needed. You should always redistribute your license with sources and possibly even with binaries (that depends on license, but it doesn't hurt you to do so).
Generally speaking, you have three options. Let's dig into each a bit.
1. Public DomainThis option is for you, if you don't care tiniest bit what anyone does with your work. You want to give it to everyone, for free, to be used however they like. They can reuse any parts or the whole thing and don't have to bother you about it. You're basically giving it away, for real.
Unless you want to compose your own Public Domain statement, you've got two main options in this category and the nice bit is, you can license your code and your assets using one license, as you just waive all rights and there's not much to care about further.
Unlicense tl;dr;LegalCC0 tl;dr;LegalIt shouldn't make much difference which one you choose, the second one is probably slightly more popular while the first one keeps it short and simple, but that's about it.
2. Permissive licenseIf you don't want to give the thing away fully, but also want to let anyone use it for anything they want without much concern (that is including commercial use and about anything), you should consider a permissive license. Details might slightly differ, but mostly you require to get your copyright notice and that's it. No one has to bother you to reuse the work, yet you still own it.
Some good choices for code here are:
zlib tl;dr;LegalMIT tl;dr;LegalBSD tl;dr;LegalISC tl;dr;LegalApache tl;dr;LegalArtistic tl;dr;LegalThe first four are quite similar, short, permissive, the other two are slightly longer. What they allow and disallow also slightly differs, but the main idea is similar. The first one is used by SFML itself.
And you'll want to license the assets with a different one:
MirOS tl;dr;LegalOGA-BYCC-BY tl;dr;LegalHere, the first one derives from BSD license and gives roughly the same care to your assets, while the second one is probably the most popular permissive asset license.
3. CopyleftNow you not just wanna give, but you wanna everyone else to give back. That sounds wonderful, but also poses some limitations, as generally any derived work must reuse the same license and that's not always practical. Still, you can do this. There's also slight difference between strong and weak copyleft, where the first one demands even other components to adapt, while the second one only cares about itself, so it can be used together with things under other licenses.
Weak copyleft for your code:
Mozilla tl;dr;LegalLGPL tl;dr;LegalStrong copyleft for your code:
GPL tl;dr;LegalWeak copyleft for your assets:
Against DRMCC-BY-SA tl;dr;LegalFALI don't know about any way to strongly copyleft assets, as they mostly behave like solitary units.
If you're not sure you want to copyleft your code, you might consider one of the first two approaches as in that way, your work will become much more useful.
Some further reading to help you decide:ChooseALicenseFreedomDefinedOSIFSFIf you still don't know, probably just pick one of the three approaches and use the first one on list for code and for assets or ask around, but expect quite mixed feelings about any of them.
This post should stay up to date and may be edited later.