adding function and variable loading