implementing new opengui. this is still a mess