renaming variables and hooking everything up