shepher

Perga Ressu - Shepher & The Rev' -[Your Destiny Project.dll]

Jun 29th, 2011
266
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.08 KB | None | 0 0
  1. // By Shepher & The Rev'
  2. // 1.0
  3. void PergaRessu(int clientid)
  4. {
  5. time_t start,end;
  6. time(&start);
  7. while(1)
  8. {
  9. time(&end);
  10. double dif = difftime (end,start);
  11. if(dif>= 2) // Se a diferença for maior que 2(sempre)
  12. {
  13. for(int i=0; i<130; i++) // loop dos players online
  14. {
  15. int addr_bclient = i * 0x0410; // Pega o address do client do usuário
  16. if(PInt(i * 0x0410 + 0x15C6A04) == 0) // Verifica se ele está com hp 0
  17. {
  18. int itenslot = FindInv(i, ITEM); // Se estiver, busca o item
  19. if(itenslot != -1) // Se achou
  20. {
  21. MOB *player = (MOB*)GetMobFromIndex(i);
  22. if(player->Inventory[itenslot].EF1 == 61)// Verifica as unidades
  23. {
  24. player->Inventory[itenslot].EFV1 -= 1; // Diminui uma
  25. /*PInt(i * 0x0410 + 0x15C6A04)*/
  26. PInt(i * 0x0410 + 0x15C6A04) = PInt(i * 0x0410 + 0x15C6A00) / 2 ; //HP
  27. SendALL(i); // SendALL
  28. break;
  29. }
  30. }
  31. else
  32. {
  33. // printf("Não encontrado");
  34. }
  35. }
  36. else
  37. {
  38. // printf("Hp não é igual a 0");
  39. }
  40. }
  41. }
  42. }
  43. Sleep(1000);
  44. }
Advertisement
Add Comment
Please, Sign In to add comment