I never patented anything , i am a comunist :-) first thing you do is find out if there is anything like it or similar to it in any way. next thing is to find out if it is patentable via the simple guidlines they supply for "what is patentable". Next make sure you got 10,000$ to get it actually patented , and to pay a real patent lawyer, and protect the patent. Next try and make the 10Kback by charging people to use it, and protecting it at the same time.
Solution B , document it as your authorship (copyright) at all stages prior to releace , start a patent process. Sell sell sell, wh…