Ok, I have three things to say.
Firstly, your code can be more readable if you surround them with "```". You should use "`" when surround a single code line or fragment. I'll format it for you this time. :)
Secondly, if you look at the line that's calling new
, you'll see that it's calling it from game_save_class
which is an exported property. So the most likely reason why you're getting the error is because that property is null.
Thirdly, it looks like your post got stuck in the moderation queue. Make sure that you have confirmed your email address. :)