fixed serious bugs
new factory added some call function