Sasuke_Uchiha

Excels's attachment y_ini

Oct 24th, 2014
2,542
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 16.62 KB | None | 0 0
  1. //Player Attachments system by Excel
  2. //==============================================================================
  3. #include <a_samp>
  4. #include <mSelection>
  5. #include <sscanf2>
  6. #include <YSI\y_ini>
  7. #include <zcmd>
  8. //==============================================================================
  9. #define DIALOG_ATTACH_INDEX             13500
  10. #define DIALOG_ATTACH_INDEX_SELECTION   DIALOG_ATTACH_INDEX+1
  11. #define DIALOG_ATTACH_EDITREPLACE       DIALOG_ATTACH_INDEX+2
  12. #define DIALOG_ATTACH_MODEL_SELECTION   DIALOG_ATTACH_INDEX+3
  13. #define DIALOG_ATTACH_BONE_SELECTION    DIALOG_ATTACH_INDEX+4
  14. #define DIALOG_ATTACH_OBJECT_SELECTION  DIALOG_ATTACH_INDEX+5
  15. #define DIALOG_ATTACH_OBJECT2_SELECTION DIALOG_ATTACH_INDEX+6
  16. //==============================================================================
  17. #define MAX_OSLOTS  MAX_PLAYER_ATTACHED_OBJECTS
  18. //==============================================================================
  19. #define     COL_WHITE       "{FFFFFF}"
  20. #define     COL_BLACK       "{0E0101}"
  21. #define     COL_GREY        "{C3C3C3}"
  22. #define     COL_GREEN       "{6EF83C}"
  23. #define     COL_RED         "{F81414}"
  24. #define     COL_YELLOW      "{F3FF02}"
  25. #define     COL_ORANGE      "{FFAF00}"
  26. #define     COL_LIME        "{B7FF00}"
  27. #define     COL_CYAN        "{00FFEE}"
  28. #define     COL_BLUE        "{0049FF}"
  29. #define     COL_MAGENTA     "{F300FF}"
  30. #define     COL_VIOLET      "{B700FF}"
  31. #define     COL_PINK        "{FF00EA}"
  32. #define     COL_MARONE      "{A90202}"
  33. //==============================================================================
  34. new AttachmentObjectsList[] = {
  35. 18632,
  36. 18633,
  37. 18634,
  38. 18635,
  39. 18636,
  40. 18637,
  41. 18638,
  42. 18639,
  43. 18640,
  44. 18975,
  45. 19136,
  46. 19274,
  47. 18641,
  48. 18642,
  49. 18643,
  50. 18644,
  51. 18645,
  52. 18865,
  53. 18866,
  54. 18867,
  55. 18868,
  56. 18869,
  57. 18870,
  58. 18871,
  59. 18872,
  60. 18873,
  61. 18874,
  62. 18875,
  63. 18890,
  64. 18891,
  65. 18892,
  66. 18893,
  67. 18894,
  68. 18895,
  69. 18896,
  70. 18897,
  71. 18898,
  72. 18899,
  73. 18900,
  74. 18901,
  75. 18902,
  76. 18903,
  77. 18904,
  78. 18905,
  79. 18906,
  80. 18907,
  81. 18908,
  82. 18909,
  83. 18910,
  84. 18911,
  85. 18912,
  86. 18913,
  87. 18914,
  88. 18915,
  89. 18916,
  90. 18917,
  91. 18918,
  92. 18919,
  93. 18920,
  94. 18921,
  95. 18922,
  96. 18923,
  97. 18924,
  98. 18925,
  99. 18926,
  100. 18927,
  101. 18928,
  102. 18929,
  103. 18930,
  104. 18931,
  105. 18932,
  106. 18933,
  107. 18934,
  108. 18935,
  109. 18936,
  110. 18937,
  111. 18938,
  112. 18939,
  113. 18940,
  114. 18941,
  115. 18942,
  116. 18943,
  117. 18944,
  118. 18945,
  119. 18946,
  120. 18947,
  121. 18948,
  122. 18949,
  123. 18950,
  124. 18951,
  125. 18952,
  126. 18953,
  127. 18954,
  128. 18955,
  129. 18956,
  130. 18957,
  131. 18958,
  132. 18959,
  133. 18960,
  134. 18961,
  135. 18962,
  136. 18963,
  137. 18964,
  138. 18965,
  139. 18966,
  140. 18967,
  141. 18968,
  142. 18969,
  143. 18970,
  144. 18971,
  145. 18972,
  146. 18973,
  147. 18974,
  148. 18976,
  149. 18977,
  150. 18978,
  151. 18979,
  152. 19006,
  153. 19007,
  154. 19008,
  155. 19009,
  156. 19010,
  157. 19011,
  158. 19012,
  159. 19013,
  160. 19014,
  161. 19015,
  162. 19016,
  163. 19017,
  164. 19018,
  165. 19019,
  166. 19020,
  167. 19021,
  168. 19022,
  169. 19023,
  170. 19024,
  171. 19025,
  172. 19026,
  173. 19027,
  174. 19028,
  175. 19029,
  176. 19030,
  177. 19031,
  178. 19032,
  179. 19033,
  180. 19034,
  181. 19035,
  182. 19036,
  183. 19037,
  184. 19038,
  185. 19039,
  186. 19040,
  187. 19041,
  188. 19042,
  189. 19043,
  190. 19044,
  191. 19045,
  192. 19046,
  193. 19047,
  194. 19048,
  195. 19049,
  196. 19050,
  197. 19051,
  198. 19052,
  199. 19053,
  200. 19085,
  201. 19086,
  202. 19090,
  203. 19091,
  204. 19092,
  205. 19093,
  206. 19094,
  207. 19095,
  208. 19096,
  209. 19097,
  210. 19098,
  211. 19099,
  212. 19100,
  213. 19101,
  214. 19102,
  215. 19103,
  216. 19104,
  217. 19105,
  218. 19106,
  219. 19107,
  220. 19108,
  221. 19109,
  222. 19110,
  223. 19111,
  224. 19112,
  225. 19113,
  226. 19114,
  227. 19115,
  228. 19116,
  229. 19117,
  230. 19118,
  231. 19119,
  232. 19120,
  233. 19137,
  234. 19138,
  235. 19139,
  236. 19140,
  237. 19141,
  238. 19142,
  239. 19160,
  240. 19161,
  241. 19162,
  242. 19163,
  243. 19317,
  244. 19318,
  245. 19319,
  246. 19330,
  247. 19331,
  248. 19346,
  249. 19347,
  250. 19348,
  251. 19349,
  252. 19350,
  253. 19351,
  254. 19352,
  255. 19487,
  256. 19488,
  257. 19513,
  258. 19515,
  259. 331,
  260. 333,
  261. 334,
  262. 335,
  263. 336,
  264. 337,
  265. 338,
  266. 339,
  267. 341,
  268. 321,
  269. 322,
  270. 323,
  271. 324,
  272. 325,
  273. 326,
  274. 343,
  275. 346,
  276. 347,
  277. 348,
  278. 349,
  279. 350,
  280. 351,
  281. 352,
  282. 353,
  283. 355,
  284. 356,
  285. 372,
  286. 357,
  287. 358,
  288. 361,
  289. 363,
  290. 364,
  291. 365,
  292. 366,
  293. 367,
  294. 368,
  295. 369,
  296. 371
  297. };
  298. //==============================================================================
  299. new AttachmentBones[][24] = {
  300. {"Spine"},
  301. {"Head"},
  302. {"Left upper arm"},
  303. {"Right upper arm"},
  304. {"Left hand"},
  305. {"Right hand"},
  306. {"Left thigh"},
  307. {"Right thigh"},
  308. {"Left foot"},
  309. {"Right foot"},
  310. {"Right calf"},
  311. {"Left calf"},
  312. {"Left forearm"},
  313. {"Right forearm"},
  314. {"Left clavicle"},
  315. {"Right clavicle"},
  316. {"Neck"},
  317. {"Jaw"}
  318. };
  319.  
  320. enum attachmentInfo
  321. {
  322.     Amodel,
  323.     Abone,
  324.     Float:AfOffsetX,
  325.     Float:AfOffsetY,
  326.     Float:AfOffsetZ,
  327.     Float:AfRotX,
  328.     Float:AfRotY,
  329.     Float:AfRotZ,
  330.     Float:AfScaleX,
  331.     Float:AfScaleY,
  332.     Float:AfScaleZ
  333. }
  334. new aInfo[MAX_PLAYERS][MAX_OSLOTS][attachmentInfo];
  335. //==============================================================================
  336. CMD:o(playerid,params[])
  337. {
  338.     new string[128];
  339.     new dialog[500];
  340.     for(new x;x<MAX_OSLOTS;x++)
  341.     {
  342.         if(IsPlayerAttachedObjectSlotUsed(playerid, x))
  343.         {   format(string, sizeof(string), ""COL_WHITE"Slot:%d :: "COL_GREEN"Used Slot\n", x);    }
  344.         else format(string, sizeof(string), ""COL_WHITE"Slot:%d\n", x);
  345.         strcat(dialog,string);
  346.     }
  347.     ShowPlayerDialog(playerid, DIALOG_ATTACH_INDEX_SELECTION, DIALOG_STYLE_LIST,"Player Objects/Attachment: (Select Slot)", dialog, "Select", "Close(X)");
  348.     return 1;
  349. }
  350. CMD:att(playerid,params[])
  351. {
  352.     return cmd_o(playerid,params);
  353. }
  354. CMD:attachments(playerid,params[])
  355. {
  356.     return cmd_o(playerid,params);
  357. }
  358. //==============================================================================
  359. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  360. {
  361.     switch(dialogid)
  362.     {
  363.         case DIALOG_ATTACH_INDEX_SELECTION:
  364.         {
  365.             if(response)
  366.             {
  367.                 if(IsPlayerAttachedObjectSlotUsed(playerid, listitem))
  368.                 {
  369.                     ShowPlayerDialog(playerid, DIALOG_ATTACH_EDITREPLACE, DIALOG_STYLE_MSGBOX, \
  370.                     "Player Objects/Attachment: (Delete/Edit)", ""COL_WHITE"Do you wish to edit the attachment in that slot, or delete it?", "Edit(!)", "Delete(X)");
  371.                 }
  372.                 else
  373.                 {
  374.                     ShowPlayerDialog(playerid,DIALOG_ATTACH_OBJECT_SELECTION,DIALOG_STYLE_LIST,"Player Objects/Attachment: (Select Object Path)","Path:1 :: "COL_GREY"Server Objects Menu\n"COL_WHITE"Path:2 :: "COL_GREY"Custom Object","Next(>>)","Back(<<)");
  375.                 }
  376.                 SetPVarInt(playerid, "AttachmentIndexSel", listitem);
  377.             }
  378.             return 1;
  379.         }
  380.         case DIALOG_ATTACH_OBJECT_SELECTION:
  381.         {
  382.             if(!response)
  383.             {
  384.                 cmd_o(playerid,"");
  385.             }
  386.             if(response)
  387.             {
  388.                 if(listitem==0) ShowModelSelectionMenuEx(playerid, AttachmentObjectsList, 228+38, "Player Objects", DIALOG_ATTACH_MODEL_SELECTION, 0.0, 0.0, 0.0, 1.0, 0x00000099, 0x000000EE, 0xACCBF1FF);
  389.                 if(listitem==1) ShowPlayerDialog(playerid,DIALOG_ATTACH_OBJECT2_SELECTION,DIALOG_STYLE_INPUT,"Player Objects/Attachment: (Insert objectid)",""COL_WHITE"Put your custom objectid below, You can also take help from ''http://wiki.sa-mp.com''.","Edit","Back(<<)");
  390.             }
  391.         }
  392.         case DIALOG_ATTACH_OBJECT2_SELECTION:
  393.         {
  394.             if(!response)
  395.             {   ShowPlayerDialog(playerid,DIALOG_ATTACH_OBJECT_SELECTION,DIALOG_STYLE_LIST,"Player Objects/Attachment: (Select Object Path)","Path:1 :: "COL_GREY"Server Objects Menu\n"COL_WHITE"Path:2 :: "COL_GREY"Custom Object","Next(>>)","Back(<<)");    }
  396.             if(response)
  397.             {
  398.                 if(!strlen(inputtext))return SendClientMessage(playerid,-1,"PLAYER: You can't leave the coloumn blank."),ShowPlayerDialog(playerid,DIALOG_ATTACH_OBJECT2_SELECTION,DIALOG_STYLE_INPUT,"Player Objects/Attachment: (Insert objectid)",""COL_WHITE"Put your custom objectid below, You can also take help from ''http://wiki.sa-mp.com''.","Edit","Back(<<)");
  399.                 if(!IsNumeric(inputtext)) return SendClientMessage(playerid,-1,"PLAYER: You can't fill a object name, only object id's allowed."),ShowPlayerDialog(playerid,DIALOG_ATTACH_OBJECT2_SELECTION,DIALOG_STYLE_INPUT,"Player Objects/Attachment: (Insert objectid)",""COL_WHITE"Put your custom objectid below, You can also take help from ''http://wiki.sa-mp.com''.","Edit","Back(<<)");
  400.                 new obj;
  401.                 if(!sscanf(inputtext, "i", obj))
  402.                 {
  403.                     if(GetPVarInt(playerid, "AttachmentUsed") == 1) EditAttachedObject(playerid, obj);
  404.                     else
  405.                     {
  406.                         SetPVarInt(playerid, "AttachmentModelSel", obj);
  407.                         new string[256+1];
  408.                         new dialog[500];
  409.                         for(new x;x<sizeof(AttachmentBones);x++)
  410.                         {
  411.                             format(string, sizeof(string), "Bone:%s\n", AttachmentBones[x]);
  412.                             strcat(dialog,string);
  413.                         }
  414.                         ShowPlayerDialog(playerid, DIALOG_ATTACH_BONE_SELECTION, DIALOG_STYLE_LIST, \
  415.                         "{FF0000}Attachment Modification - Bone Selection", dialog, "Select", "Cancel");
  416.                     }
  417.                 }
  418.             }
  419.         }
  420.         case DIALOG_ATTACH_EDITREPLACE:
  421.         {
  422.             if(response) EditAttachedObject(playerid, GetPVarInt(playerid, "AttachmentIndexSel"));
  423.             else
  424.             {
  425.                 RemovePlayerAttachedObject(playerid, GetPVarInt(playerid, "AttachmentIndexSel"));
  426.                 new file[256];
  427.                 new name[24];
  428.                 new x=GetPVarInt(playerid, "AttachmentIndexSel");
  429.                 new f1[15],f2[15],f3[15],f4[15],f5[15],f6[15],f7[15],f8[15],f9[15],f10[15],f11[15];
  430.                 GetPlayerName(playerid,name,24);
  431.                 format(file,sizeof(file),"Player Objects/%s.ini",name);
  432.                 if(!fexist(file)) return 1;
  433.                 new INI:ini=INI_Open(file);
  434.                 format(f1,15,"O_Model_%d",x);
  435.                 format(f2,15,"O_Bone_%d",x);
  436.                 format(f3,15,"O_OffX_%d",x);
  437.                 format(f4,15,"O_OffY_%d",x);
  438.                 format(f5,15,"O_OffZ_%d",x);
  439.                 format(f6,15,"O_RotX_%d",x);
  440.                 format(f7,15,"O_RotY_%d",x);
  441.                 format(f8,15,"O_RotZ_%d",x);
  442.                 format(f9,15,"O_ScaleX_%d",x);
  443.                 format(f10,15,"O_ScaleY_%d",x);
  444.                 format(f11,15,"O_ScaleZ_%d",x);
  445.                 INI_RemoveEntry(ini,f1);
  446.                 INI_RemoveEntry(ini, f2);
  447.                 INI_RemoveEntry(ini, f3);
  448.                 INI_RemoveEntry(ini, f4);
  449.                 INI_RemoveEntry(ini, f5);
  450.                 INI_RemoveEntry(ini, f6);
  451.                 INI_RemoveEntry(ini, f7);
  452.                 INI_RemoveEntry(ini, f8);
  453.                 INI_RemoveEntry(ini, f9);
  454.                 INI_RemoveEntry(ini, f10);
  455.                 INI_RemoveEntry(ini, f11);
  456.                 DeletePVar(playerid, "AttachmentIndexSel");
  457.             }
  458.             return 1;
  459.         }
  460.         case DIALOG_ATTACH_BONE_SELECTION:
  461.         {
  462.             if(response)
  463.             {
  464.                 SetPlayerAttachedObject(playerid, GetPVarInt(playerid, "AttachmentIndexSel"), GetPVarInt(playerid, "AttachmentModelSel"), listitem+1);
  465.                 EditAttachedObject(playerid, GetPVarInt(playerid, "AttachmentIndexSel"));
  466.                 SendClientMessage(playerid, 0xFFFFFFFF, "PLAYER: You can also hold SPAWN and use MOUSE to view from either sides.");
  467.             }
  468.             DeletePVar(playerid, "AttachmentIndexSel");
  469.             DeletePVar(playerid, "AttachmentModelSel");
  470.             return 1;
  471.         }
  472.     }
  473.     return 0;
  474. }
  475. //==============================================================================
  476. public OnPlayerEditAttachedObject( playerid, response, index, modelid, boneid,
  477.                                    Float:fOffsetX, Float:fOffsetY, Float:fOffsetZ,
  478.                                    Float:fRotX, Float:fRotY, Float:fRotZ,
  479.                                    Float:fScaleX, Float:fScaleY, Float:fScaleZ )
  480. {
  481.     /*new debug_string[256+1];
  482.     format(debug_string,256,"SetPlayerAttachedObject(playerid,%d,%d,%d,%f,%f,%f,%f,%f,%f,%f,%f,%f)",
  483.         index,modelid,boneid,fOffsetX,fOffsetY,fOffsetZ,fRotX,fRotY,fRotZ,fScaleX,fScaleY,fScaleZ);*/
  484.  
  485.     SetPlayerAttachedObject(playerid,index,modelid,boneid,fOffsetX,fOffsetY,fOffsetZ,fRotX,fRotY,fRotZ,fScaleX,fScaleY,fScaleZ);
  486.     SendClientMessage(playerid, 0xFFFFFFFF, "PLAYER: You have finished editing attachments, it has been saved to your database.");
  487.  
  488.     new file[256];
  489.     new name[24];
  490.     new f1[15],f2[15],f3[15],f4[15],f5[15],f6[15],f7[15],f8[15],f9[15],f10[15],f11[15];
  491.     GetPlayerName(playerid,name,24);
  492.     format(file,sizeof(file),"Player Objects/%s.ini",name);
  493.     new INI:data = INI_Open(file);
  494.     format(f1,15,"O_Model_%d",index);
  495.     format(f2,15,"O_Bone_%d",index);
  496.     format(f3,15,"O_OffX_%d",index);
  497.     format(f4,15,"O_OffY_%d",index);
  498.     format(f5,15,"O_OffZ_%d",index);
  499.     format(f6,15,"O_RotX_%d",index);
  500.     format(f7,15,"O_RotY_%d",index);
  501.     format(f8,15,"O_RotZ_%d",index);
  502.     format(f9,15,"O_ScaleX_%d",index);
  503.     format(f10,15,"O_ScaleY_%d",index);
  504.     format(f11,15,"O_ScaleZ_%d",index);
  505.     INI_SetTag(data,"Attachments");
  506.     INI_WriteInt(data,f1,modelid);
  507.     INI_WriteInt(data,f2,boneid);
  508.     INI_WriteFloat(data,f3,fOffsetX);
  509.     INI_WriteFloat(data,f4,fOffsetY);
  510.     INI_WriteFloat(data,f5,fOffsetZ);
  511.     INI_WriteFloat(data,f6,fRotX);
  512.     INI_WriteFloat(data,f7,fRotY);
  513.     INI_WriteFloat(data,f8,fRotZ);
  514.     INI_WriteFloat(data,f9,fScaleX);
  515.     INI_WriteFloat(data,f10,fScaleY);
  516.     INI_WriteFloat(data,f11,fScaleZ);
  517.     INI_Close(data);
  518.     return 1;
  519. }
  520. //==============================================================================
  521. public OnPlayerConnect(playerid)
  522. {
  523.     new file[256];
  524.     new name[24];
  525.     GetPlayerName(playerid,name,24);
  526.     format(file,sizeof(file),"Player Objects/%s.ini",name);
  527.     if(!fexist(file))
  528.     {
  529.         for(new i;i<MAX_OSLOTS;i++)
  530.         {
  531.             if(IsPlayerAttachedObjectSlotUsed(playerid, i))
  532.             {
  533.                 aInfo[playerid][i][Amodel]=0;
  534.                 aInfo[playerid][i][Abone]=0;
  535.                 aInfo[playerid][i][AfOffsetX]=0;
  536.                 aInfo[playerid][i][AfOffsetY]=0;
  537.                 aInfo[playerid][i][AfOffsetZ]=0;
  538.                 aInfo[playerid][i][AfRotX]=0;
  539.                 aInfo[playerid][i][AfRotY]=0;
  540.                 aInfo[playerid][i][AfRotZ]=0;
  541.                 aInfo[playerid][i][AfScaleY]=0;
  542.                 aInfo[playerid][i][AfScaleZ]=0;
  543.             }
  544.         }
  545.     }
  546. }
  547. //==============================================================================
  548. public OnPlayerSpawn(playerid)
  549. {
  550.     new file[256];
  551.     new name[24];
  552.     GetPlayerName(playerid,name,24);
  553.     format(file,sizeof(file),"Player Objects/%s.ini",name);
  554.     if(fexist(file))
  555.     {
  556.         INI_ParseFile(file,"Load_%s", .bExtra = true, .extra = playerid);
  557.         for(new i=0;i<MAX_OSLOTS;i++)
  558.         {          
  559.             if(aInfo[playerid][i][Amodel] !=0)
  560.             {
  561.                 SetPlayerAttachedObject(playerid,i,aInfo[playerid][i][Amodel],aInfo[playerid][i][Abone],aInfo[playerid][i][AfOffsetX],aInfo[playerid][i][AfOffsetY],aInfo[playerid][i][AfOffsetZ],aInfo[playerid][i][AfRotX],aInfo[playerid][i][AfRotY],aInfo[playerid][i][AfRotZ],aInfo[playerid][i][AfScaleX],aInfo[playerid][i][AfScaleY],aInfo[playerid][i][AfScaleZ]);
  562.             }
  563.         }
  564.     }  
  565.     return 1;
  566. }
  567. //==============================================================================
  568. public OnPlayerModelSelectionEx(playerid, response, extraid, modelid)
  569. {
  570.     if(extraid==DIALOG_ATTACH_MODEL_SELECTION)
  571.     {
  572.         if(!response)
  573.         {   ShowPlayerDialog(playerid,DIALOG_ATTACH_OBJECT_SELECTION,DIALOG_STYLE_LIST,"Player Objects/Attachment: (Select Object Path)","Path:1 :: "COL_GREY"Server Objects Menu\n"COL_WHITE"Path:2 :: "COL_GREY"Custom Object","Next(>>)","Back(<<)");    }
  574.         if(response)
  575.         {
  576.             if(GetPVarInt(playerid, "AttachmentUsed") == 1) EditAttachedObject(playerid, modelid);
  577.             else
  578.             {
  579.                 SetPVarInt(playerid, "AttachmentModelSel", modelid);
  580.                 new string[256+1];
  581.                 new dialog[500];
  582.                 for(new x;x<sizeof(AttachmentBones);x++)
  583.                 {
  584.                     format(string, sizeof(string), "Bone:%s\n", AttachmentBones[x]);
  585.                     strcat(dialog,string);
  586.                 }
  587.                 ShowPlayerDialog(playerid, DIALOG_ATTACH_BONE_SELECTION, DIALOG_STYLE_LIST, \
  588.                 "{FF0000}Attachment Modification - Bone Selection", dialog, "Select", "Cancel");
  589.             }//else DeletePVar(playerid, "AttachmentIndexSel");
  590.         }
  591.     }
  592.     return 1;
  593. }
  594. //==============================================================================
  595. stock IsNumeric(string[])
  596. {
  597.     for (new i = 0, j = strlen(string); i < j; i++)
  598.     {
  599.         if (string[i] > '9' || string[i] < '0') return 0;
  600.     }
  601.     return 1;
  602. }
  603. //==============================================================================
  604. forward Load_Attachments(playerid, name[], value[]);
  605. public Load_Attachments(playerid, name[], value[])
  606. {
  607.     new string[15];
  608.     for(new i=0; i < MAX_OSLOTS; i++)
  609.     {
  610.         format(string,15,"O_Model_%d",i);
  611.         INI_Int(string,aInfo[playerid][i][Amodel]);
  612.         format(string,15,"O_Bone_%d",i);
  613.         INI_Int(string,aInfo[playerid][i][Abone]);
  614.         format(string,15,"O_OffX_%d",i);
  615.         INI_Float(string,aInfo[playerid][i][AfOffsetX]);
  616.         format(string,15,"O_OffY_%d",i);
  617.         INI_Float(string,aInfo[playerid][i][AfOffsetY]);
  618.         format(string,15,"O_OffZ_%d",i);
  619.         INI_Float(string,aInfo[playerid][i][AfOffsetZ]);
  620.         format(string,15,"O_RotX_%d",i);
  621.         INI_Float(string,aInfo[playerid][i][AfRotX]);
  622.         format(string,15,"O_RotY_%d",i);
  623.         INI_Float(string,aInfo[playerid][i][AfRotY]);
  624.         format(string,15,"O_RotZ_%d",i);
  625.         INI_Float(string,aInfo[playerid][i][AfRotZ]);
  626.         format(string,15,"O_ScaleX_%d",i);
  627.         INI_Float(string,aInfo[playerid][i][AfScaleX]);
  628.         format(string,15,"O_ScaleY_%d",i);
  629.         INI_Float(string,aInfo[playerid][i][AfScaleY]);
  630.         format(string,15,"O_ScaleZ_%d",i);
  631.         INI_Float(string,aInfo[playerid][i][AfScaleZ]);
  632.     }  
  633.     return 1;
  634. }
Advertisement
Add Comment
Please, Sign In to add comment