properly calculating the actions