Proper player stats scripting.

What is the proper function or way to set a players stats in a script and save them?

— Canned message start —

This thread is not related to the official Trinity codebase and was moved to the Custom Code section.

Please read the stickies next time.

— Canned message end —