Comments for your code. I think you have written much more nicer than I at first. So conclusion: very not bad :-). But you have a lot of place that need to fix.