He is unable to do his homework but I am not going to help him out.
That's mean. What will happen if you ignore that?
He will get a bad grade.
You probably should help instead. It's rude to ignore a friend's problems and be disrespectful to them.
I don't care, he's only my friend due to our hobbies in common.
If he is your friend, you should treat  him with respect. If you don't want to help him, you need to speak up and not ignore him. Otherwise your friendship will not work even with your hobbies.