c++
灰色V
这个作者很懒,什么都没留下…
展开
-
C++ 知识点
二、define中的三个特殊符号:#,##,#@ #define Conn(x,y) x##y#define ToChar(x) #@x#define ToString(x) #x (1)x##y表示什么?表示x连接y,举例说: int n = Conn(123,456); /* 结果就是n=123456;*/char* str = Con原创 2014-03-11 18:03:05 · 477 阅读 · 0 评论 -
lua 和xml交互
lua官方代码。 稍做修改 /** LuaXML License LuaXml is licensed under the terms of the MIT license reproduced below, the same as Lua itself. This means that LuaXml is free software and can be used for bo原创 2014-03-28 21:45:41 · 1762 阅读 · 0 评论 -
将lua中字符串转换成table,富文本
char* str = ((char*) tolua_tostring(tolua_S,1,0)); { lua_newtable(tolua_S); if (str == NULL) return 1; int n = 0; char ch = 0; char* ptr = str; while (true) { ch =原创 2014-03-29 00:29:41 · 5516 阅读 · 0 评论 -
quickCocos2dx 中添加自定义类,导出lua
1.在userpath\quick-cocos2d-x\lib\cocos2d-x\external\extra目录下,建立自定义导出类目录。 (我的目录为class) 2.在新建目录中添加自定义导出类,*.h文件和*.cpp文件。 #myMathEx.h文件 #ifndef _GAME_MYMATHEX_H_ #define _GAME_MYMATHEX_H_ class原创 2014-03-20 11:21:06 · 1282 阅读 · 0 评论