Fixing memory leaks in GameplayState.cpp.