Interaction tweaking and code cleanup