切记:
float test;
进行除法运算的时候要注意:
test = 8 / 10;
Debug.log(" test is ---> "+ test); =====> test is 0;
改:
test = 8 .0f / 10.0f;
Debug.log(" test is ---> "+ test); =====> test is 0.8;
切记:
float test;
进行除法运算的时候要注意:
test = 8 / 10;
Debug.log(" test is ---> "+ test); =====> test is 0;
改:
test = 8 .0f / 10.0f;
Debug.log(" test is ---> "+ test); =====> test is 0.8;