I made a quick fix to prevent it from crashing, let me know if it happens again.
You are very very lucky that you wrote this at the moment when I was online :) I will try to play your game and rate if it works