removed profiler and made vertex a struct