Jul-02-2018, 12:30 PM
Unfortunately, this is not how the forum works. We are not going to do it for you. It looks like you have found a code that is a good starting point and in fact is doing more than what you want. Put some efforts to change it and get the desired results. Ask specific questions when you have a specific problem
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs