updates Odin's old code
Well, most of it

Signed-off-by: ShadowChild <shadychild12@gmail.com>