Guest User

Untitled

a guest
May 7th, 2020
212
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. //Variables//
  2. DWORD DashColor = 0xFF008A00;
  3. DWORD DashColor2 = 0xFF000000;
  4. struct RGB {
  5. int R, G, B;
  6. int RotationStart;
  7. };
  8. RGB MenuColour2 = { 0, 0, 255 };
  9. RGB MenuColour = { 255, 0, 0 };
  10. RGB Rotation = { 50 };
  11. DWORD Rotations = 50;
  12. int ToggleRotations = 0;
  13. int Rainbow = 0;
  14. int Rainbow2 = 0;
  15. BOOL r = 255, g = 0, b = 0;
  16. BOOL r2 = 0, g2 = 0, b2 = 0;
  17. //Variables End//
  18.  
  19.  
  20. //Dash Set Fill//
  21. HRESULT SetFill(HXUIOBJ hObj, DWORD Color1, DWORD Color2, BOOL Gradient, BOOL RainbowMode) {
  22. XUI_FILL_TYPE fillType = XUI_FILL_TYPE::XUI_FILL_SOLID;
  23. //if (INI::Gradient)
  24. fillType = (Gradient) ? XUI_FILL_TYPE::XUI_FILL_LINEAR_GRADIENT : XUI_FILL_TYPE::XUI_FILL_SOLID;
  25.  
  26. D3DXVECTOR2 pvScalingFactor(1.0f, 1.0f), pTrnas(0.0f, 0.0f);
  27.  
  28. XUIGradientStop gs[2];
  29. gs[0].dwColor = Color1;
  30. gs[0].fPos = 0.0f;
  31.  
  32. gs[1].dwColor = Color2;
  33. gs[1].fPos = 1.0f;
  34.  
  35. if (RainbowMode) {
  36. if (Rainbow < GetTickCount() - 15) {
  37. if (MenuColour.R > 0 && MenuColour.B == 0) {
  38. MenuColour.R--;
  39. MenuColour.G++;
  40. }
  41. if (MenuColour.G > 0 && MenuColour.R == 0) {
  42. MenuColour.G--;
  43. MenuColour.B++;
  44. }
  45. if (MenuColour.B > 0 && MenuColour.G == 0) {
  46. MenuColour.R++;
  47. MenuColour.B--;
  48. }
  49. if (MenuColour2.R > 0 && MenuColour2.B == 0) {
  50. MenuColour2.R--;
  51. MenuColour2.G++;
  52. }
  53. if (MenuColour2.G > 0 && MenuColour2.R == 0) {
  54. MenuColour2.G--;
  55. MenuColour2.B++;
  56. }
  57. if (MenuColour2.B > 0 && MenuColour2.G == 0) {
  58. MenuColour2.R++;
  59. MenuColour2.B--;
  60. }
  61. DashColor = D3DCOLOR_ARGB(0xFF, MenuColour.R, MenuColour.G, MenuColour.B);
  62. DashColor2 = D3DCOLOR_ARGB(0xFF, MenuColour2.R, MenuColour2.G, MenuColour2.B);
  63. Rainbow = GetTickCount();
  64. }
  65. if (ToggleRotations < GetTickCount() - 25) {
  66. Rotations++;
  67. ToggleRotations = GetTickCount();
  68. }
  69. }
  70.  
  71. return Dashboard_Calls::XuiFigureSetFill(hObj, fillType, Color1, gs, 2, Rotations, &pvScalingFactor, &pTrnas);
  72. }
  73. //Dash Set Fill End//
  74.  
  75. //HUD Set Fill//
  76. HRESULT SetFill(HXUIOBJ hObj, DWORD Color1, DWORD Color2, BOOL Gradient, BOOL RainbowMode) {
  77. XUI_FILL_TYPE fillType = XUI_FILL_TYPE::XUI_FILL_SOLID;
  78.  
  79. fillType = (Gradient) ? XUI_FILL_TYPE::XUI_FILL_LINEAR_GRADIENT : XUI_FILL_TYPE::XUI_FILL_SOLID;
  80.  
  81. D3DXVECTOR2 pvScalingFactor(1.0f, 1.0f), pTrnas(0.0f, 0.0f);
  82.  
  83. XUIGradientStop gs[2];
  84. gs[0].dwColor = Color1;
  85. gs[0].fPos = 0.0f;
  86.  
  87. gs[1].dwColor = Color2;
  88. gs[1].fPos = 1.0f;
  89.  
  90. if (RainbowMode) {
  91. if (Rainbow < GetTickCount() - 15) {
  92. if (MenuColour.R > 0 && MenuColour.B == 0) {
  93. MenuColour.R--;
  94. MenuColour.G++;
  95. }
  96. if (MenuColour.G > 0 && MenuColour.R == 0) {
  97. MenuColour.G--;
  98. MenuColour.B++;
  99. }
  100. if (MenuColour.B > 0 && MenuColour.G == 0) {
  101. MenuColour.R++;
  102. MenuColour.B--;
  103. }
  104. if (MenuColour2.R > 0 && MenuColour2.B == 0) {
  105. MenuColour2.R--;
  106. MenuColour2.G++;
  107. }
  108. if (MenuColour2.G > 0 && MenuColour2.R == 0) {
  109. MenuColour2.G--;
  110. MenuColour2.B++;
  111. }
  112. if (MenuColour2.B > 0 && MenuColour2.G == 0) {
  113. MenuColour2.R++;
  114. MenuColour2.B--;
  115. }
  116. DashColor = D3DCOLOR_ARGB(0xFF, MenuColour.R, MenuColour.G, MenuColour.B);
  117. DashColor2 = D3DCOLOR_ARGB(0xFF, MenuColour2.R, MenuColour2.G, MenuColour2.B);
  118. Rainbow = GetTickCount();
  119. }
  120. if (ToggleRotations < GetTickCount() - 25) {
  121. Rotations++;
  122. ToggleRotations = GetTickCount();
  123. }
  124. }
  125.  
  126. return XuiFigureSetFill(hObj, fillType, Color1, gs, 2, Rotations, &pvScalingFactor, &pTrnas);
  127. }
  128. //HUD Set Fill End//
RAW Paste Data