Just like in C, you can't make assignments from variables (as opposed to literals) outside of a function. If you want to use vecSkill1.x as contrast, either use it directly in your function or rename it with a define.

The variable declarations outside of a function are processed at compile time, and the compiler doesn't know the value of vecSkill1.x at compile time yet.