C#笔记:读取NPK中png文件的坐标
在DNF中,角色贴图以.ani文件的坐标为中心,NPK中png的坐标为绘制坐标(坐上)进行绘制,绘制的结果如图所示:
原点坐标-232,-333
原点坐标-232,-333
皮肤坐标207,224
皮肤坐标207,224
太刀柄194,264
太刀柄194,264
太刀刃213,283
太刀刃213,283
读取代码,目前只完成读取IMGV2的图片型索引,指向型索引和其他IMG格式还未完成:
using System; using System.Collections.Generic; using System.Text; using System.IO; namespace 提取NPK { class Program { static string 文件路径 = @"D:\单机dnf\朽叶DNF客户端 V1.0531\台服DNF客户端\ImagePacks2\sprite(ex).NPK"; static string 文件路径2 = @"D:\单机dnf\朽叶DNF客户端 V1.0531\台服DNF客户端\ImagePacks2\sprite.NPK"; static string 文件路径3 = @"D:\单机dnf\朽叶DNF客户端 V1.0531\台服DNF客户端\ImagePacks2\sprite_character_swordman_equipment_avatar_skin(Transformed).npk"; static Stream 流; static byte[] 缓存字节数组; static string NPK文件头; static int IMG文件总数; static Dictionary<int, Dictionary<int, string>> IMG文件索引表 = new Dictionary<int, Dictionary<int, string>>(); static byte[] NPK校验位 = new byte[32]; static byte[][] IMG文件序列; static IMGV2文件接口[] IMGV2文件数组; static void Main(string[] args) { 流 = new FileStream(文件路径3,FileMode.Open); 缓存字节数组 = new byte[16]; 流.Read(缓存字节数组,0,16); NPK文件头 = Encoding.UTF8.GetString(缓存字节数组); Console.WriteLine("NPK文件头:"+NPK文件头); 缓存字节数组 = new byte[4]; 流.Read(缓存字节数组, 0, 4); IMG文件总数 = BitConverter.ToInt32(缓存字节数组,0); Console.WriteLine("IMG文件总数:" + IMG文件总数); for (int i = 0; i < IMG文件总数; i++) { Console.WriteLine("-----------------------------------------"); 缓存字节数组 = new byte[4]; 流.Read(缓存字节数组, 0, 4); int 地址偏移量 = BitConverter.ToInt32(缓存字节数组, 0); Console.WriteLine("地址偏移量:" + 地址偏移量); 缓存字节数组 = new byte[4]; 流.Read(缓存字节数组, 0, 4); int IMG文件大小 = BitConverter.ToInt32(缓存字节数组, 0); Console.WriteLine("IMG文件大小" + IMG文件大小); 缓存字节数组 = new byte[256]; 流.Read(缓存字节数组, 0, 256); string 异或字符串 = "puchikon@neople dungeon and fighter DNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNFDNF "; for (int t = 0; t < 256; t++) { 缓存字节数组[t] ^= (byte)异或字符串[t]; } string IMG文件名称 = Encoding.UTF8.GetString(缓存字节数组); IMG文件名称 = IMG文件名称.Substring(0,IMG文件名称.IndexOf(".img")+4); Console.WriteLine("IMG文件名称"+IMG文件名称); Console.WriteLine($codeholder_0amp;quot;当前字节流位置{流.Position}"); IMG文件索引表.Add(地址偏移量, new Dictionary<int, string>() { { IMG文件大小, IMG文件名称 } }); } IMG文件索引表.DumpAll(); 流.Read(NPK校验位,0,32); IMG文件序列 = new byte[IMG文件总数][]; for (int i = 0; i < IMG文件序列.Length; i++) { 流.Position = IMG文件索引表.GetKey(i); IMG文件序列[i] = new byte[IMG文件索引表.GetValueKey(i)]; 流.Read(IMG文件序列[i],0,IMG文件索引表.GetValueKey(i)); } //IMG文件序列.DumpAll(); IMGV2文件数组 = new IMGV2文件接口[IMG文件序列.Length]; for (int i = 0; i < IMGV2文件数组.Length; i++) { IMGV2文件数组[i] = new IMGV2(IMG文件序列[i]); } Console.WriteLine("-----------------------------------------"); Console.WriteLine("测试部分:读取NPK第0个IMG的信息:"); Console.WriteLine("文件头:"+IMGV2文件数组[0].取文件头()); Console.WriteLine("索引表大小:"+IMGV2文件数组[0].取索引表大小()); Console.WriteLine("保留:" + IMGV2文件数组[0].取保留()); Console.WriteLine("版本号:" + IMGV2文件数组[0].取版本号()); Console.WriteLine("索引表数目:" + IMGV2文件数组[0].取索引表数目()); Console.WriteLine("-----------------------------------------"); Console.WriteLine("测试部分:读取NPK第0个IMG的坐标"); for (int i = 0; i < IMGV2文件数组[0].取索引表数目(); i++) { Console.WriteLine(IMGV2文件数组[0].取IMG索引文件(i).取颜色系统().ToColorSystemName()); Console.Write(IMGV2文件数组[0].取IMG索引文件(i).取x坐标()); Console.Write("\t"); Console.WriteLine(IMGV2文件数组[0].取IMG索引文件(i).取y坐标()); Console.Write(IMGV2文件数组[0].取IMG索引文件(i).取图像宽()); Console.Write("\t"); Console.WriteLine(IMGV2文件数组[0].取IMG索引文件(i).取图像高()); Console.Write(IMGV2文件数组[0].取IMG索引文件(i).取帧域宽()); Console.Write("\t"); Console.WriteLine(IMGV2文件数组[0].取IMG索引文件(i).取帧域高()); } Console.ReadLine(); } } public static class 扩展方法类_IMG文件索引表 { //调试输出 public static void DumpAll(this Dictionary<int, Dictionary<int, string>> _dic) { List<int> keys = new List<int>(); List<int> values_keys = new List<int>(); List<string> values_values = new List<string>(); foreach (KeyValuePair<int,Dictionary<int,string>> item0 in _dic) { keys.Add(item0.Key); foreach (KeyValuePair<int,string> item1 in item0.Value) { values_keys.Add(item1.Key); values_values.Add(item1.Value); } } for (int i = 0; i < _dic.Count; i++) { string result = ""; result += keys[i].ToString(); result += "\t"; result += values_keys[i].ToString(); result += "\t"; result += values_values[i]; Console.WriteLine(result); } } //取主键 public static int GetKey(this Dictionary<int, Dictionary<int, string>> _dic,int index) { List<int> keys = new List<int>(); foreach (KeyValuePair<int, Dictionary<int, string>> item0 in _dic) { keys.Add(item0.Key); } return keys[index]; } //取子键 public static int GetValueKey(this Dictionary<int, Dictionary<int, string>> _dic, int index) { List<int> values_keys = new List<int>(); foreach (KeyValuePair<int, Dictionary<int, string>> item0 in _dic) { foreach (KeyValuePair<int, string> item1 in item0.Value) { values_keys.Add(item1.Key); } } return values_keys[index]; } //取子值 public static string GetValueValue(this Dictionary<int, Dictionary<int, string>> _dic, int index) { List<string> values_values = new List<string>(); foreach (KeyValuePair<int, Dictionary<int, string>> item0 in _dic) { foreach (KeyValuePair<int, string> item1 in item0.Value) { values_values.Add(item1.Value); } } return values_values[index]; } } public static class 扩展方法类_IMG文件序列 { //调试输出 public static void DumpAll(this byte[][] _array) { for (int i = 0; i < _array.Length; i++) { Console.WriteLine("当前IMG文件序号:"+i); Console.WriteLine(BitConverter.ToString(_array[i])); } } } public static class 扩展方法类_字节数组 { //复制数组的一部分 public static byte[] SubArray(this byte[] _array,int startIndex,int length) { byte[] result = new byte[length]; for (int i = 0; i < result.Length; i++) { result[i] = _array[i + startIndex]; } return result; } } public static class 扩展方法类_整数型 { //整数转字符串,指颜色系统 public static string ToColorSystemName(this int _value) { if (_value == (int)PNG文件颜色系统枚举.ARGB8888) { return "ARGB8888"; } if (_value == (int)PNG文件颜色系统枚举.ARGB4444) { return "ARGB4444"; } if (_value == (int)PNG文件颜色系统枚举.ARGB1555) { return "ARGB1555"; } else { return ""; } } } public interface IMGV2文件接口 { string 取文件头(); int 取索引表大小(); int 取保留(); int 取版本号(); int 取索引表数目(); IMG索引文件接口 取IMG索引文件(int _index); } public interface IMG文件接口 : IMGV2文件接口 { } public interface IMG图片型索引文件接口 { int 取颜色系统(); int 取压缩状态(); int 取图像宽(); int 取图像高(); int 取图像大小(); int 取x坐标(); int 取y坐标(); int 取帧域宽(); int 取帧域高(); } public interface IMG指向型索引文件接口 { int 取类型(); int 取指向帧号(); } public interface IMG索引文件接口 : IMG图片型索引文件接口, IMG指向型索引文件接口 { } public enum PNG文件颜色系统枚举 : int { ARGB8888 = 0x10, ARGB4444 = 0x0f, ARGB1555 = 0x0e } public enum PNG压缩状态枚举 : int { 未压缩 = 0x05, ZLib压缩 = 0x06 } public enum IMG索引类型枚举 : int { 指向型 = 0x11, 图片型 } public class 指向型索引项类 : IMG索引文件接口 { int 类型; int 指向帧号; public 指向型索引项类(int _类型,int _指向帧号) { 类型=_类型; 指向帧号=_指向帧号; } void 置类型(int _value) { 类型 = _value; } void 置指向帧号(int _value) { 指向帧号 = _value; } public int 取类型(){return 类型;} public int 取指向帧号() { return 指向帧号; } public int 取颜色系统(){ return 0; } public int 取压缩状态(){ return 0; } public int 取图像宽(){ return 0; } public int 取图像高(){ return 0; } public int 取图像大小(){ return 0; } public int 取x坐标(){ return 0; } public int 取y坐标(){ return 0; } public int 取帧域宽(){ return 0; } public int 取帧域高(){ return 0; } } public class 图片型索引项 : IMG索引文件接口 { int 颜色系统; int 压缩状态; int 图像宽 ; int 图像高 ; int 图像大小; int x坐标 ; int y坐标 ; int 帧域宽 ; int 帧域高 ; public 图片型索引项( int _颜色系统, int _压缩状态, int _图像宽, int _图像高, int _图像大小, int _x坐标, int _y坐标, int _帧域宽, int _帧域高) { 颜色系统 = _颜色系统; 压缩状态 = _压缩状态; 图像宽 = _图像宽; 图像高 = _图像高; 图像大小 = _图像大小; x坐标 = _x坐标; y坐标 = _y坐标; 帧域宽 = _帧域宽; 帧域高 = _帧域高; } public int 取颜色系统() { return 颜色系统; } public int 取压缩状态() { return 压缩状态; } public int 取图像宽() { return 图像宽; } public int 取图像高() { return 图像高; } public int 取图像大小() { return 图像大小; } public int 取x坐标() { return x坐标; } public int 取y坐标() { return y坐标; } public int 取帧域宽() { return 帧域宽; } public int 取帧域高() { return 帧域高; } public int 取类型() { return 0; } public int 取指向帧号() { return 0; } } public class IMGV2: IMGV2文件接口 { string 文件头 = ""; int 索引表大小 = 0; int 保留 = 0; int 版本号 = 0; int 索引表数目 = 0; IMG索引文件接口[] IMG索引文件接口数组; byte[][] 贴图数据数组; public IMGV2(byte[] _data) { int index = 0; 文件头 = Encoding.UTF8.GetString(_data.SubArray(index, 16)); index += 16; 索引表大小 = BitConverter.ToInt32(_data.SubArray(index, 4),0); index += 4; 保留 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; 版本号 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; 索引表数目 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; IMG索引文件接口数组 = new IMG索引文件接口[索引表数目]; for (int i = 0; i < 索引表数目; i++) { int 类型 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); if (类型 == (int)IMG索引类型枚举.指向型) { index += 4; int 指向帧号 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); IMG索引文件接口数组[i] = new 指向型索引项类(类型, 指向帧号); index += 4; } else { int 颜色系统 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; int 压缩状态 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; int 图像宽 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; int 图像高 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; int 图像大小 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; int x坐标 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; int y坐标 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; int 帧域宽 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); index += 4; int 帧域高 = BitConverter.ToInt32(_data.SubArray(index, 4), 0); IMG索引文件接口数组[i] = new 图片型索引项( 颜色系统, 压缩状态, 图像宽, 图像高, 图像大小, x坐标, y坐标, 帧域宽, 帧域高); index += 4; } } 贴图数据数组 = new byte[索引表数目][]; for (int i = 0; i < 贴图数据数组.Length; i++) { if (IMG索引文件接口数组[i].取类型() == (int)IMG索引类型枚举.指向型) { 贴图数据数组[i] = new byte[0]; } else { 贴图数据数组[i] = _data.SubArray(index, IMG索引文件接口数组[i].取图像大小()); index += IMG索引文件接口数组[i].取图像大小(); } } } public string 取文件头(){return 文件头;} public int 取索引表大小(){return 索引表大小;} public int 取保留(){return 保留;} public int 取版本号(){return 版本号;} public int 取索引表数目(){return 索引表数目;} public IMG索引文件接口 取IMG索引文件(int _index){ return IMG索引文件接口数组[_index]; } } }
程序运行结果:
NPK文件头:NeoplePack_Bill IMG文件总数:51 ----------------------------------------- 地址偏移量:13516 IMG文件大小298502 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0000.img 当前字节流位置284 ----------------------------------------- 地址偏移量:312018 IMG文件大小299898 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0001.img 当前字节流位置548 ----------------------------------------- 地址偏移量:611916 IMG文件大小299719 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0002.img 当前字节流位置812 ----------------------------------------- 地址偏移量:911635 IMG文件大小298463 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0003.img 当前字节流位置1076 ----------------------------------------- 地址偏移量:1210098 IMG文件大小299821 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0004.img 当前字节流位置1340 ----------------------------------------- 地址偏移量:1509919 IMG文件大小299558 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0005.img 当前字节流位置1604 ----------------------------------------- 地址偏移量:1809477 IMG文件大小299294 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0006.img 当前字节流位置1868 ----------------------------------------- 地址偏移量:2108771 IMG文件大小299680 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0007.img 当前字节流位置2132 ----------------------------------------- 地址偏移量:2408451 IMG文件大小299151 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0008.img 当前字节流位置2396 ----------------------------------------- 地址偏移量:2707602 IMG文件大小298417 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0009.img 当前字节流位置2660 ----------------------------------------- 地址偏移量:3006019 IMG文件大小292744 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0010.img 当前字节流位置2924 ----------------------------------------- 地址偏移量:3298763 IMG文件大小295141 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0011.img 当前字节流位置3188 ----------------------------------------- 地址偏移量:3593904 IMG文件大小302429 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0012.img 当前字节流位置3452 ----------------------------------------- 地址偏移量:3896333 IMG文件大小299771 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0013.img 当前字节流位置3716 ----------------------------------------- 地址偏移量:4196104 IMG文件大小293572 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0014.img 当前字节流位置3980 ----------------------------------------- 地址偏移量:4489676 IMG文件大小294174 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0015.img 当前字节流位置4244 ----------------------------------------- 地址偏移量:4783850 IMG文件大小298299 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0016.img 当前字节流位置4508 ----------------------------------------- 地址偏移量:5082149 IMG文件大小298769 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0017.img 当前字节流位置4772 ----------------------------------------- 地址偏移量:5380918 IMG文件大小299184 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0018.img 当前字节流位置5036 ----------------------------------------- 地址偏移量:5680102 IMG文件大小299221 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0019.img 当前字节流位置5300 ----------------------------------------- 地址偏移量:5979323 IMG文件大小299060 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0020.img 当前字节流位置5564 ----------------------------------------- 地址偏移量:6278383 IMG文件大小302605 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0021.img 当前字节流位置5828 ----------------------------------------- 地址偏移量:6580988 IMG文件大小303607 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0022.img 当前字节流位置6092 ----------------------------------------- 地址偏移量:6884595 IMG文件大小349799 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body0023.img 当前字节流位置6356 ----------------------------------------- 地址偏移量:7234394 IMG文件大小299357 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1000.img 当前字节流位置6620 ----------------------------------------- 地址偏移量:7533751 IMG文件大小299330 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1001.img 当前字节流位置6884 ----------------------------------------- 地址偏移量:7833081 IMG文件大小299087 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1002.img 当前字节流位置7148 ----------------------------------------- 地址偏移量:8132168 IMG文件大小298969 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1003.img 当前字节流位置7412 ----------------------------------------- 地址偏移量:8431137 IMG文件大小299132 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1004.img 当前字节流位置7676 ----------------------------------------- 地址偏移量:8730269 IMG文件大小299348 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1005.img 当前字节流位置7940 ----------------------------------------- 地址偏移量:9029617 IMG文件大小298862 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1006.img 当前字节流位置8204 ----------------------------------------- 地址偏移量:9328479 IMG文件大小299237 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1007.img 当前字节流位置8468 ----------------------------------------- 地址偏移量:9627716 IMG文件大小299815 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1008.img 当前字节流位置8732 ----------------------------------------- 地址偏移量:9927531 IMG文件大小298910 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1009.img 当前字节流位置8996 ----------------------------------------- 地址偏移量:10226441 IMG文件大小302148 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1010.img 当前字节流位置9260 ----------------------------------------- 地址偏移量:10528589 IMG文件大小299295 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1011.img 当前字节流位置9524 ----------------------------------------- 地址偏移量:10827884 IMG文件大小297324 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1014.img 当前字节流位置9788 ----------------------------------------- 地址偏移量:11125208 IMG文件大小298591 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1015.img 当前字节流位置10052 ----------------------------------------- 地址偏移量:11423799 IMG文件大小298167 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1016.img 当前字节流位置10316 ----------------------------------------- 地址偏移量:11721966 IMG文件大小298086 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1017.img 当前字节流位置10580 ----------------------------------------- 地址偏移量:12020052 IMG文件大小298965 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1018.img 当前字节流位置10844 ----------------------------------------- 地址偏移量:12319017 IMG文件大小301448 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1019.img 当前字节流位置11108 ----------------------------------------- 地址偏移量:12620465 IMG文件大小299091 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body1020.img 当前字节流位置11372 ----------------------------------------- 地址偏移量:12919556 IMG文件大小336300 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body80000.img 当前字节流位置11636 ----------------------------------------- 地址偏移量:13255856 IMG文件大小392005 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body80100.img 当前字节流位置11900 ----------------------------------------- 地址偏移量:13647861 IMG文件大小284806 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body80200.img 当前字节流位置12164 ----------------------------------------- 地址偏移量:13932667 IMG文件大小269570 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body80300.img 当前字节流位置12428 ----------------------------------------- 地址偏移量:14202237 IMG文件大小567263 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body81100.img 当前字节流位置12692 ----------------------------------------- 地址偏移量:14769500 IMG文件大小550293 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body81200.img 当前字节流位置12956 ----------------------------------------- 地址偏移量:15319793 IMG文件大小197001 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body81300.img 当前字节流位置13220 ----------------------------------------- 地址偏移量:15516794 IMG文件大小137137 IMG文件名称sprite/character/swordman/equipment/avatar/skin/sm_body90100.img 当前字节流位置13484 13516 298502 sprite/character/swordman/equipment/avatar/skin/sm_body0000.img 312018 299898 sprite/character/swordman/equipment/avatar/skin/sm_body0001.img 611916 299719 sprite/character/swordman/equipment/avatar/skin/sm_body0002.img 911635 298463 sprite/character/swordman/equipment/avatar/skin/sm_body0003.img 1210098 299821 sprite/character/swordman/equipment/avatar/skin/sm_body0004.img 1509919 299558 sprite/character/swordman/equipment/avatar/skin/sm_body0005.img 1809477 299294 sprite/character/swordman/equipment/avatar/skin/sm_body0006.img 2108771 299680 sprite/character/swordman/equipment/avatar/skin/sm_body0007.img 2408451 299151 sprite/character/swordman/equipment/avatar/skin/sm_body0008.img 2707602 298417 sprite/character/swordman/equipment/avatar/skin/sm_body0009.img 3006019 292744 sprite/character/swordman/equipment/avatar/skin/sm_body0010.img 3298763 295141 sprite/character/swordman/equipment/avatar/skin/sm_body0011.img 3593904 302429 sprite/character/swordman/equipment/avatar/skin/sm_body0012.img 3896333 299771 sprite/character/swordman/equipment/avatar/skin/sm_body0013.img 4196104 293572 sprite/character/swordman/equipment/avatar/skin/sm_body0014.img 4489676 294174 sprite/character/swordman/equipment/avatar/skin/sm_body0015.img 4783850 298299 sprite/character/swordman/equipment/avatar/skin/sm_body0016.img 5082149 298769 sprite/character/swordman/equipment/avatar/skin/sm_body0017.img 5380918 299184 sprite/character/swordman/equipment/avatar/skin/sm_body0018.img 5680102 299221 sprite/character/swordman/equipment/avatar/skin/sm_body0019.img 5979323 299060 sprite/character/swordman/equipment/avatar/skin/sm_body0020.img 6278383 302605 sprite/character/swordman/equipment/avatar/skin/sm_body0021.img 6580988 303607 sprite/character/swordman/equipment/avatar/skin/sm_body0022.img 6884595 349799 sprite/character/swordman/equipment/avatar/skin/sm_body0023.img 7234394 299357 sprite/character/swordman/equipment/avatar/skin/sm_body1000.img 7533751 299330 sprite/character/swordman/equipment/avatar/skin/sm_body1001.img 7833081 299087 sprite/character/swordman/equipment/avatar/skin/sm_body1002.img 8132168 298969 sprite/character/swordman/equipment/avatar/skin/sm_body1003.img 8431137 299132 sprite/character/swordman/equipment/avatar/skin/sm_body1004.img 8730269 299348 sprite/character/swordman/equipment/avatar/skin/sm_body1005.img 9029617 298862 sprite/character/swordman/equipment/avatar/skin/sm_body1006.img 9328479 299237 sprite/character/swordman/equipment/avatar/skin/sm_body1007.img 9627716 299815 sprite/character/swordman/equipment/avatar/skin/sm_body1008.img 9927531 298910 sprite/character/swordman/equipment/avatar/skin/sm_body1009.img 10226441 302148 sprite/character/swordman/equipment/avatar/skin/sm_body1010.img 10528589 299295 sprite/character/swordman/equipment/avatar/skin/sm_body1011.img 10827884 297324 sprite/character/swordman/equipment/avatar/skin/sm_body1014.img 11125208 298591 sprite/character/swordman/equipment/avatar/skin/sm_body1015.img 11423799 298167 sprite/character/swordman/equipment/avatar/skin/sm_body1016.img 11721966 298086 sprite/character/swordman/equipment/avatar/skin/sm_body1017.img 12020052 298965 sprite/character/swordman/equipment/avatar/skin/sm_body1018.img 12319017 301448 sprite/character/swordman/equipment/avatar/skin/sm_body1019.img 12620465 299091 sprite/character/swordman/equipment/avatar/skin/sm_body1020.img 12919556 336300 sprite/character/swordman/equipment/avatar/skin/sm_body80000.img 13255856 392005 sprite/character/swordman/equipment/avatar/skin/sm_body80100.img 13647861 284806 sprite/character/swordman/equipment/avatar/skin/sm_body80200.img 13932667 269570 sprite/character/swordman/equipment/avatar/skin/sm_body80300.img 14202237 567263 sprite/character/swordman/equipment/avatar/skin/sm_body81100.img 14769500 550293 sprite/character/swordman/equipment/avatar/skin/sm_body81200.img 15319793 197001 sprite/character/swordman/equipment/avatar/skin/sm_body81300.img 15516794 137137 sprite/character/swordman/equipment/avatar/skin/sm_body90100.img ----------------------------------------- 测试部分:读取NPK第0个IMG的信息: 文件头:Neople Img File 索引表大小:6664 保留:0 版本号:2 索引表数目:210 ----------------------------------------- 测试部分:读取NPK第0个IMG的坐标 ARGB8888 189 231 71 107 500 500 ARGB8888 189 231 71 107 500 500 ARGB8888 193 231 68 107 500 500 ARGB8888 201 245 94 93 500 500 ARGB8888 202 249 77 90 500 500 ARGB8888 202 249 77 90 500 500 ARGB8888 202 249 77 90 500 500 ARGB8888 201 249 78 90 500 500 ARGB8888 201 249 78 90 500 500 ARGB8888 200 249 79 90 500 500 ARGB8888 209 247 78 92 500 500 ARGB8888 208 246 82 93 500 500 ARGB8888 207 246 92 93 500 500 ARGB8888 190 248 78 90 500 500 ARGB8888 189 248 79 90 500 500 ARGB8888 183 248 85 90 500 500 ARGB8888 179 248 89 90 500 500 ARGB8888 181 248 87 90 500 500 ARGB8888 182 248 86 90 500 500 ARGB8888 189 248 79 90 500 500 ARGB8888 189 248 79 90 500 500 0 0 0 0 0 0 ARGB8888 208 246 82 93 500 500 0 0 0 0 0 0 ARGB8888 190 248 78 90 500 500 ARGB8888 189 248 79 90 500 500 ARGB8888 183 248 85 90 500 500 ARGB8888 179 248 89 90 500 500 ARGB8888 181 248 87 90 500 500 ARGB8888 182 248 86 90 500 500 ARGB8888 189 248 79 90 500 500 ARGB8888 189 248 79 90 500 500 0 0 0 0 0 0 ARGB8888 190 253 65 85 500 500 ARGB8888 197 256 64 82 500 500 ARGB8888 240 253 87 83 500 500 ARGB8888 237 228 89 108 500 500 ARGB8888 237 225 88 111 500 500 ARGB8888 237 224 77 112 500 500 ARGB8888 237 225 77 111 500 500 ARGB8888 237 225 77 111 500 500 ARGB8888 237 225 77 111 500 500 0 0 0 0 0 0 0 0 0 0 0 0 ARGB8888 240 253 87 83 500 500 ARGB8888 237 228 89 108 500 500 ARGB8888 237 225 88 111 500 500 ARGB8888 237 224 77 112 500 500 ARGB8888 237 225 77 111 500 500 ARGB8888 237 225 77 111 500 500 ARGB8888 237 225 77 111 500 500 0 0 0 0 0 0 0 0 0 0 0 0 ARGB8888 240 253 87 83 500 500 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ARGB8888 189 231 71 107 500 500 ARGB8888 193 231 68 107 500 500 ARGB8888 202 249 77 90 500 500 0 0 0 0 0 0 0 0 0 0 0 0 ARGB8888 199 244 75 93 500 500 ARGB8888 200 244 77 93 500 500 ARGB8888 217 248 82 89 500 500 ARGB8888 226 252 107 82 500 500 ARGB8888 225 252 119 82 500 500 ARGB8888 226 252 112 82 500 500 ARGB8888 226 252 107 82 500 500 ARGB8888 226 252 107 82 500 500 ARGB8888 226 252 107 82 500 500 ARGB8888 226 252 107 82 500 500 ARGB8888 202 238 71 101 500 500 ARGB8888 202 238 71 101 500 500 ARGB8888 202 238 70 101 500 500 ARGB8888 202 239 70 100 500 500 ARGB8888 201 235 70 104 500 500 ARGB8888 208 204 71 137 500 500 ARGB8888 208 201 65 140 500 500 ARGB8888 208 201 45 140 500 500 ARGB8888 208 201 45 140 500 500 ARGB8888 208 201 45 140 500 500 ARGB8888 208 201 45 140 500 500 ARGB8888 208 201 45 140 500 500 ARGB8888 208 201 45 140 500 500 ARGB8888 208 201 45 140 500 500 0 0 0 0 0 0 ARGB8888 200 233 64 106 500 500 ARGB8888 200 234 64 105 500 500 ARGB8888 200 235 64 104 500 500 ARGB8888 200 235 64 104 500 500 ARGB8888 200 234 64 105 500 500 ARGB8888 200 233 64 106 500 500 ARGB8888 198 240 64 102 500 500 0 0 0 0 0 0 0 0 0 0 0 0 ARGB8888 202 231 70 108 500 500 ARGB8888 171 275 102 72 500 500 ARGB8888 168 271 108 74 500 500 ARGB8888 168 308 113 43 500 500 0 0 0 0 0 0 ARGB8888 202 231 70 108 500 500 ARGB8888 208 238 71 99 500 500 ARGB8888 193 236 80 92 500 500 ARGB8888 185 237 100 93 500 500 ARGB8888 196 238 77 97 500 500 ARGB8888 208 238 74 97 500 500 ARGB8888 196 236 97 93 500 500 ARGB8888 188 237 99 95 500 500 ARGB8888 198 238 88 99 500 500 ARGB8888 199 244 75 93 500 500 ARGB8888 200 244 77 93 500 500 ARGB8888 217 248 82 89 500 500 ARGB8888 226 252 107 82 500 500 ARGB8888 225 252 119 82 500 500 ARGB8888 226 252 112 82 500 500 ARGB8888 226 252 107 82 500 500 ARGB8888 226 252 107 82 500 500 ARGB8888 226 252 107 82 500 500 ARGB8888 226 252 107 82 500 500 ARGB8888 190 239 69 100 500 500 ARGB8888 188 240 71 99 500 500 ARGB8888 201 239 64 100 500 500 ARGB8888 202 229 64 112 500 500 ARGB8888 200 233 65 80 500 500 0 0 0 0 0 0 ARGB8888 201 231 70 110 500 500 ARGB8888 201 229 79 112 500 500 0 0 0 0 0 0 ARGB8888 201 239 71 100 500 500 ARGB8888 197 226 53 80 500 500 ARGB8888 199 223 58 96 500 500 ARGB8888 216 239 50 80 500 500 ARGB8888 216 239 58 80 500 500 ARGB8888 216 239 50 80 500 500 0 0 0 0 0 0 ARGB8888 189 231 71 107 500 500 ARGB8888 189 231 71 107 500 500 ARGB8888 193 231 68 107 500 500 ARGB8888 250 271 91 68 500 500 ARGB8888 251 268 88 71 500 500 ARGB8888 251 268 88 71 500 500 ARGB8888 251 268 88 71 500 500 ARGB8888 251 268 88 71 500 500 ARGB8888 251 268 88 71 500 500 ARGB8888 251 268 88 71 500 500 ARGB8888 251 268 88 71 500 500 ARGB8888 251 268 88 71 500 500 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ARGB8888 197 260 58 75 500 500 0 0 0 0 0 0 ARGB8888 201 224 52 117 500 500 ARGB8888 201 224 52 117 500 500 ARGB8888 201 224 52 117 500 500 ARGB8888 201 224 52 117 500 500 ARGB8888 201 224 52 117 500 500 ARGB8888 201 224 52 117 500 500 ARGB8888 204 224 72 117 500 500 ARGB8888 204 224 78 117 500 500 ARGB8888 204 224 84 117 500 500 ARGB8888 204 224 78 117 500 500 ARGB8888 204 224 78 117 500 500 ARGB8888 204 224 78 117 500 500 ARGB8888 204 224 78 117 500 500 ARGB8888 204 224 78 117 500 500 ARGB8888 204 224 78 117 500 500 0 0 0 0 0 0 0 0 0 0 0 0 ARGB8888 208 224 45 117 500 500 ARGB8888 207 224 46 117 500 500 ARGB8888 207 224 46 117 500 500 0 0 0 0 0 0 ARGB8888 209 224 40 111 500 500 ARGB8888 211 224 40 111 500 500 ARGB8888 210 225 47 110 500 500 ARGB8888 208 225 46 112 500 500 ARGB8888 211 224 40 113 500 500 ARGB8888 216 224 31 113 500 500 ARGB8888 209 225 50 112 500 500 ARGB8888 206 225 49 112 500 500 ARGB8888 201 232 57 108 500 500 ARGB8888 188 235 70 105 500 500 ARGB8888 197 257 79 83 500 500 ARGB8888 198 263 77 77 500 500 ARGB8888 193 264 82 76 500 500 ARGB8888 193 264 81 76 500 500 ARGB8888 194 251 75 89 500 500 ARGB8888 198 226 88 114 500 500 ARGB8888 209 257 91 83 500 500 ARGB8888 212 260 79 80 500 500 ARGB8888 212 260 79 80 500 500 ARGB8888 205 249 69 91 500 500 ARGB8888 203 247 65 93 500 500 ARGB8888 202 213 68 127 500 500 ARGB8888 201 210 62 130 500 500 ARGB8888 201 210 62 130 500 500 ARGB8888 199 209 70 131 500 500 ARGB8888 190 206 77 134 500 500 ARGB8888 197 258 112 86 500 500 ARGB8888 198 250 110 96 500 500 ARGB8888 198 250 110 96 500 500 ARGB8888 198 250 110 96 500 500