Why does my behaviour tree reset its task variables

Did you try for the tasks in question to go file->refresh all nodes and compile again?