fixed bug with local params overriding globals with intial assigments, improved logging, fixed bug with amounts not being stored, local params appear to be working now