- When do you need a series, and when do you need a variable?
I need them to calc values on every bars.
No. You need a series when you use values from previous bars for your current calculation. So, for which of your variables do you need a series, and for which not?
- How do you define a series?
I assign series() to var pointer.
Yes. Now look at your code. Have you always assigned series() to var pointers?
- When do you add * and when not?
When I want to use a value of series, I add it.
No. You add it only in the definition of a series, and only when you're following the old version of the tutorial. In the current version, there is no '*' anymore as series are defined with 'vars' instead. But you can still use the old method of course.