Forgive my English is very poor
I have a project at Mac and it runs well,but when I moved it to my pc(win7), there are a lot of errors. Then I find that at win7, If I declare variable in static function, the console shows errors,but when I declare this variable out of function and use static,is ok.
for example
it can runs well at mac,but error at win7
I doubt this is Win7 issue. (Anything is possible of course ). I actually share the same project between 3 PCs. 2 of them running Win 7 and 1 of them is on XP. Never had any problems like this. Monodevelop has problems sometimes but they usually go away after restart. Maybe publish code for your whole class? Maybe something wrong beyond this one method that you are looking at?
I think I find the reason. At mac I have same comment code using Chinese characters but at win7 they cannot be distinguish. So I delete all Chinese characters and it works. It’s strange. However, thank you very much!
return new Vector3(offsetAccelerator, offsetAcceleratorHorizon, 0);
}
The reason is the Chinese characters such like “//获取重力感应值”. When I delete all Chinese characters it works at win7. But It can works at mac,don’t know why…
It seems MonoDevelop does not support chinese characters. I can only suggest to write an utility tool that will parse code files and add “\r\n” (EndOfLine symbols) after each chinese comment. :neutral: