Smi-ChetDev

new gloves for cheat

Aug 20th, 2019
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.21 KB | None | 0 0
  1.  
  2.  
  3.  
  4. #include "Glove.h"
  5. #include "../SDKinc.h"
  6. #include "../../SDK/IBaseClientDll.h"
  7. #include "../..//Skeet programm/SkeetMenu.h"
  8. #define RandomInt(nMin, nMax) (rand() % (nMax - nMin + 1) + nMin);
  9.  
  10. void glovechnanger()
  11. {
  12. PlayerInfo_s localPlayerInfo;
  13.  
  14. C_BaseEntity* pLocal = g_pEntityList->GetClientEntity(g_pEngine->GetLocalPlayer());
  15. if (pLocal)
  16. {
  17. if (g_pEngine->GetPlayerInfo(g_pEngine->GetLocalPlayer(), &localPlayerInfo))
  18. {
  19. DWORD* hMyWearables = (DWORD*)((size_t)pLocal + 0x2F04);//fixed
  20.  
  21. if (hMyWearables)
  22. {
  23. if (!g_pEntityList->GetClientEntityFromHandle((DWORD)hMyWearables[0]))
  24. {
  25. static ClientClass* pClass;
  26.  
  27. if (!pClass)
  28. pClass = g_pClientDll->GetAllClasses();
  29. while (pClass)
  30. {
  31. if (pClass->ClassID == 54)
  32. break;
  33. pClass = pClass->pNext;
  34. }
  35.  
  36. int iEntry = g_pEntityList->GetHighestEntityIndex() + 1;
  37. int iSerial = RandomInt(0x0, 0xFFF);
  38.  
  39. pClass->pCreateFn(iEntry, iSerial);
  40. hMyWearables[0] = iEntry | (iSerial << 16);
  41.  
  42. C_BaseEntity* pEnt = (C_BaseEntity * )g_pEntityList->GetClientEntityFromHandle((DWORD)hMyWearables[0]);
  43.  
  44. if (pEnt)
  45. {
  46. int modelindex = 0;
  47.  
  48. /*Blood Houd*/ if (options::menu.SkinTab.gloves.GetIndex() == 1)
  49. {
  50. modelindex = g_pModelInfo->GetModelIndex(("models/weapons/v_models/arms/glove_bloodhound/v_glove_bloodhound.mdl"));
  51. }
  52. /*Sporty*/ else if (options::menu.SkinTab.gloves.GetIndex() == 2)
  53. {
  54. modelindex = g_pModelInfo->GetModelIndex(("models/weapons/v_models/arms/glove_sporty/v_glove_sporty.mdl"));
  55. }
  56. /*Slick*/ else if (options::menu.SkinTab.gloves.GetIndex() == 3)
  57. {
  58. modelindex = g_pModelInfo->GetModelIndex(("models/weapons/v_models/arms/glove_slick/v_glove_slick.mdl"));
  59. }
  60. /*Leathery*/ else if (options::menu.SkinTab.gloves.GetIndex() == 4)
  61. {
  62. modelindex = g_pModelInfo->GetModelIndex(("models/weapons/v_models/arms/glove_handwrap_leathery/v_glove_handwrap_leathery.mdl"));
  63. }
  64. /*Motorcylce*/ else if (options::menu.SkinTab.gloves.GetIndex() == 5)
  65. {
  66. modelindex = g_pModelInfo->GetModelIndex(("models/weapons/v_models/arms/glove_motorcycle/v_glove_motorcycle.mdl"));
  67. }
  68. /*Specialist*/ else if (options::menu.SkinTab.gloves.GetIndex() == 6)
  69. {
  70. modelindex = g_pModelInfo->GetModelIndex(("models/weapons/v_models/arms/glove_specialist/v_glove_specialist.mdl"));
  71. }
  72.  
  73. int ItemDefinitionIndex;
  74. if (options::menu.SkinTab.gloves.GetIndex() == 1)
  75. {
  76. ItemDefinitionIndex = 5027;
  77. }
  78. else if (options::menu.SkinTab.gloves.GetIndex() == 2)
  79. {
  80. ItemDefinitionIndex = 5030;
  81. }
  82. else if (options::menu.SkinTab.gloves.GetIndex() == 3)
  83. {
  84. ItemDefinitionIndex = 5031;
  85. }
  86. else if (options::menu.SkinTab.gloves.GetIndex() == 4)
  87. {
  88. ItemDefinitionIndex = 5032;
  89. }
  90. else if (options::menu.SkinTab.gloves.GetIndex() == 5)
  91. {
  92. ItemDefinitionIndex = 5033;
  93. }
  94. else if (options::menu.SkinTab.gloves.GetIndex() == 6)
  95. {
  96. ItemDefinitionIndex = 5034;
  97. }
  98. else
  99. ItemDefinitionIndex = 0;
  100.  
  101. int paintkit;
  102. if (options::menu.SkinTab.gloves.GetIndex() == 1)
  103. {
  104. switch (options::menu.SkinTab.skingloves.GetIndex())
  105. {
  106. case 0:
  107. paintkit = 10006;
  108. break;
  109. case 1:
  110. paintkit = 10007;
  111. break;
  112. case 2:
  113. paintkit = 10008;
  114. break;
  115. case 3:
  116. paintkit = 10039;
  117. break;
  118. }
  119. }
  120. else if (options::menu.SkinTab.gloves.GetIndex() == 2)
  121. {
  122. switch (options::menu.SkinTab.skingloves.GetIndex())
  123. {
  124. case 4:
  125. paintkit = 10018;
  126. break;
  127. case 5:
  128. paintkit = 10019;
  129. break;
  130. case 6:
  131. paintkit = 10037;
  132. break;
  133. case 7:
  134. paintkit = 10038;
  135. break;
  136. }
  137. }
  138. else if (options::menu.SkinTab.gloves.GetIndex() == 3)
  139. {
  140. switch (options::menu.SkinTab.skingloves.GetIndex())
  141. {
  142. case 8:
  143. paintkit = 10013;
  144. break;
  145. case 9:
  146. paintkit = 10015;
  147. break;
  148. case 10:
  149. paintkit = 10016;
  150. break;
  151. case 11:
  152. paintkit = 10040;
  153. break;
  154. }
  155. }
  156. else if (options::menu.SkinTab.gloves.GetIndex() == 4)
  157. {
  158. switch (options::menu.SkinTab.skingloves.GetIndex())
  159. {
  160. case 12:
  161. paintkit = 10009;
  162. break;
  163. case 13:
  164. paintkit = 10010;
  165. break;
  166. case 14:
  167. paintkit = 10021;
  168. break;
  169. case 15:
  170. paintkit = 10036;
  171. break;
  172. }
  173. }
  174. else if (options::menu.SkinTab.gloves.GetIndex() == 5)
  175. {
  176. switch (options::menu.SkinTab.skingloves.GetIndex())
  177. {
  178. case 16:
  179. paintkit = 10024;
  180. break;
  181. case 17:
  182. paintkit = 10026;
  183. break;
  184. case 18:
  185. paintkit = 10027;
  186. break;
  187. case 19:
  188. paintkit = 10028;
  189. break;
  190. }
  191. }
  192. else if (options::menu.SkinTab.gloves.GetIndex() == 6)
  193. {
  194. switch (options::menu.SkinTab.skingloves.GetIndex())
  195. {
  196. case 20:
  197. paintkit = 10030;
  198. break;
  199. case 21:
  200. paintkit = 10033;
  201. break;
  202. case 22:
  203. paintkit = 10034;
  204. break;
  205. case 23:
  206. paintkit = 10035;
  207. break;
  208. }
  209. }
  210. else paintkit = 0;
  211. *pEnt->fixskins() = ItemDefinitionIndex;
  212. *pEnt->ItemIDHigh() = -1;
  213. *pEnt->GetEntityQuality() = 4;
  214. *pEnt->GetAccountId() = localPlayerInfo.xuidLow;
  215. *pEnt->FallbackWear() = 0.00000001f;
  216. *pEnt->FallbackSeed() = 0;
  217. *pEnt->FallbackStartTrak() = -1;
  218. *pEnt->FallbackPaintKit() = paintkit;
  219. pEnt->SetModelIndex(modelindex);
  220. pEnt->PreDataUpdate(0);
  221. }
  222. }
  223. }
  224.  
  225. }
  226. }
  227.  
  228. }
Add Comment
Please, Sign In to add comment