摘要: 对于float f; 方法1: char buf[32]; snprintf(buf, sizeof(buf), "%f ", f); string s = buf; 方法2: #include <stdlib.h> char buf[32]; _gcvt(f, 16, buf); string s = buf; 方法3: #include <sstream> ostringstream oss; oss < < f; string s = oss.str(); ... 阅读全文
posted @ 2013-01-22 18:46 冷夜 - 网游编程技术 阅读(757) 评论(0) 推荐(0) 编辑
摘要: 1.准备动画图片资源自己新建个imageset,把动画每帧的图片放进去,定义好相应的Image<?xml version="1.0" encoding="UTF-8"?><Imageset Name="aniImagesets" Imagefile="animation.tga" NativeHorzRes="1024" NativeVertRes="768" > <Image Name="ani1" XPos="0 阅读全文
posted @ 2013-01-22 16:34 冷夜 - 网游编程技术 阅读(1111) 评论(0) 推荐(1) 编辑