if i leave the game running, the material event function crashes with "too many functions!" as well!