Copying a field from Projects to Project Tasks

I am trying to copy a field from the project to the project task every time a new project task is created.
i have not been successful. if anyone has done this and can provide the code i would greatly appreciate it.
thank you