I need some one expert in ns3 to add routing metric

I already finish the work and my project did not have any errors, but my routing protocol did not get the path based on thats metric. I Already did the process to measure link quality by probing periodic packets. But its not measured the delay as expected. If any one have experiance to solve the problem please help me.