Use new lang function
Refactor to use updated shadow topics core event
Refactor setup loading logic
Refactor and optimize some code