摘要:
--lua 中点(.)和冒号(:)区别 class = {} function class:new(x, y) local mt = {} mt.x = x mt.y = y self.__index = self setmetatable(mt, self) return mt end ... 阅读全文
摘要:
1. 单行注释 -- 功能等同于C++中的// 2. 多行注释 --[[ 注释的内容 ]] 功能等同于C++中的 /**/ 3. 多行注释 --[ [ 注释和内容 ] ], 也等同于C++中的/**/, 这个主要用于注释的内容里面有像arr[arr2[idx]] 这种文本, 如果使用--[[ ]] 阅读全文
摘要:
readDouble是从一个文件中读取double类型的数据 阅读全文