Advertisement
Guest User

Untitled

a guest
Oct 1st, 2016
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.08 KB | None | 0 0
  1. private void drawMinimap() {
  2. aRSImageProducer_1164.initDrawingArea();
  3. if (minimapState == 2) {
  4. byte abyte0[] = mapBack.aByteArray1450;
  5. int ai[] = DrawingArea.pixels;
  6. int k2 = abyte0.length;
  7. for (int i5 = 0; i5 < k2; i5++) {
  8. if (abyte0[i5] == 0) {
  9. ai[i5] = 0;
  10. }
  11. }
  12.  
  13. compass.method352(33, minimapInt1, anIntArray1057, 256, anIntArray968, 25, 0, 0, 33, 25);
  14. aRSImageProducer_1165.initDrawingArea();
  15. return;
  16. }
  17. int i = minimapInt1 + minimapInt2 & 0x7ff;
  18. int j = 48 + myPlayer.x / 32;
  19. int l2 = 464 - myPlayer.y / 32;
  20. sprite.method352(151, i, anIntArray1229, 256 + minimapInt3, anIntArray1052, l2, 5, 25, 146, j);
  21. compass.method352(33, minimapInt1, anIntArray1057, 256, anIntArray968, 25, 0, 0, 33, 25);
  22. for (int j5 = 0; j5 < anInt1071; j5++) {
  23. int k = (anIntArray1072[j5] * 4 + 2) - myPlayer.x / 32;
  24. int i3 = (anIntArray1073[j5] * 4 + 2) - myPlayer.y / 32;
  25. markMinimap(aClass30_Sub2_Sub1_Sub1Array1140[j5], k, i3);
  26. }
  27.  
  28. for (int k5 = 0; k5 < 104; k5++) {
  29. for (int l5 = 0; l5 < 104; l5++) {
  30. NodeList class19 = groundArray[plane][k5][l5];
  31. if (class19 != null) {
  32. int l = (k5 * 4 + 2) - myPlayer.x / 32;
  33. int j3 = (l5 * 4 + 2) - myPlayer.y / 32;
  34. markMinimap(mapDotItem, l, j3);
  35. }
  36. }
  37.  
  38. }
  39.  
  40. for (int i6 = 0; i6 < npcCount; i6++) {
  41. NPC npc = npcArray[npcIndices[i6]];
  42. if (npc != null && npc.isVisible()) {
  43. EntityDef entityDef = npc.desc;
  44. if (entityDef.childrenIDs != null) {
  45. entityDef = entityDef.method161();
  46. }
  47. if (entityDef != null && entityDef.aBoolean87 && entityDef.aBoolean84) {
  48. int i1 = npc.x / 32 - myPlayer.x / 32;
  49. int k3 = npc.y / 32 - myPlayer.y / 32;
  50. markMinimap(mapDotNPC, i1, k3);
  51. }
  52. }
  53. }
  54.  
  55. for (int j6 = 0; j6 < playerCount; j6++) {
  56. Player player = playerArray[playerIndices[j6]];
  57. if (player != null && player.isVisible()) {
  58. int j1 = player.x / 32 - myPlayer.x / 32;
  59. int l3 = player.y / 32 - myPlayer.y / 32;
  60. boolean flag1 = false;
  61. long l6 = StringHelper.longForName(player.name);
  62. for (int k6 = 0; k6 < friendsCount; k6++) {
  63. if (l6 != friendsListAsLongs[k6] || friendsNodeIDs[k6] == 0) {
  64. continue;
  65. }
  66. flag1 = true;
  67. break;
  68. }
  69.  
  70. boolean flag2 = false;
  71. if (myPlayer.team != 0 && player.team != 0 && myPlayer.team == player.team) {
  72. flag2 = true;
  73. }
  74. if (flag1) {
  75. markMinimap(mapDotFriend, j1, l3);
  76. } else if (flag2) {
  77. markMinimap(mapDotTeam, j1, l3);
  78. } else {
  79. markMinimap(mapDotPlayer, j1, l3);
  80. }
  81. }
  82. }
  83.  
  84. if (anInt855 != 0 && loopCycle % 20 < 10) {
  85. if (anInt855 == 1 && anInt1222 >= 0 && anInt1222 < npcArray.length) {
  86. NPC class30_sub2_sub4_sub1_sub1_1 = npcArray[anInt1222];
  87. if (class30_sub2_sub4_sub1_sub1_1 != null) {
  88. int k1 = class30_sub2_sub4_sub1_sub1_1.x / 32 - myPlayer.x / 32;
  89. int i4 = class30_sub2_sub4_sub1_sub1_1.y / 32 - myPlayer.y / 32;
  90. method81(mapMarker, i4, k1);
  91. }
  92. }
  93. if (anInt855 == 2) {
  94. int l1 = ((anInt934 - baseX) * 4 + 2) - myPlayer.x / 32;
  95. int j4 = ((anInt935 - baseY) * 4 + 2) - myPlayer.y / 32;
  96. method81(mapMarker, j4, l1);
  97. }
  98. if (anInt855 == 10 && anInt933 >= 0 && anInt933 < playerArray.length) {
  99. Player class30_sub2_sub4_sub1_sub2_1 = playerArray[anInt933];
  100. if (class30_sub2_sub4_sub1_sub2_1 != null) {
  101. int i2 = class30_sub2_sub4_sub1_sub2_1.x / 32 - myPlayer.x / 32;
  102. int k4 = class30_sub2_sub4_sub1_sub2_1.y / 32 - myPlayer.y / 32;
  103. method81(mapMarker, k4, i2);
  104. }
  105. }
  106. }
  107. if (destX != 0) {
  108. int j2 = (destX * 4 + 2) - myPlayer.x / 32;
  109. int l4 = (destY * 4 + 2) - myPlayer.y / 32;
  110. markMinimap(mapFlag, j2, l4);
  111. }
  112. DrawingArea.method336(3, 78, 97, 0xffffff, 3);
  113. aRSImageProducer_1165.initDrawingArea();
  114. }
  115.  
  116. private void npcScreenPos(Entity entity, int i) {
  117. calcEntityScreenPos(entity.x, i, entity.y);
  118.  
  119. //aryan entity.entScreenX = spriteDrawX; entity.entScreenY = spriteDrawY;
  120. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement