Advertisement
Guest User

Untitled

a guest
Oct 4th, 2017
317
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.07 KB | None | 0 0
  1. Setups the hud for the player?
  2. */
  3. disableSerialization;
  4.  
  5. cutRsc ["playerHUD", "PLAIN", 2, false];
  6. [] call life_fnc_hudUpdate;
  7.  
  8. [] spawn
  9. {
  10. private ["_dam", "_playerBloodVolume", "_damage"];
  11. player setVariable["DamageLife",[0,0,0,0,0,0],true];
  12. while {true} do
  13. {
  14.  
  15. _dam = player getVariable["ACE_medical_bloodVolume",100];
  16. _damage = player getVariable "DamageLife";
  17. waitUntil {sleep 0.1; ((player getVariable["ACE_medical_bloodVolume",100]) != _dam)};
  18.  
  19. if (!(player getVariable["ACE_medical_bodyPartStatus", [0,0,0,0,0,0]] isEqualTo _damage){ //&& life_can_take_damage) then {
  20.  
  21. _damage = (player getVariable["ACE_medical_bodyPartStatus", [0,0,0,0,0,0]]);
  22. player setVariable["DamageLife",_damage,true];
  23.  
  24. if ((_damage select 0) > 2.2 ) then {
  25. _playerBloodVolume = (player getVariable["ACE_medical_bloodVolume",100]) - 50;
  26. } else {
  27. _playerBloodVolume = (player getVariable["ACE_medical_bloodVolume",100]) - 10;
  28. };
  29.  
  30. player setVariable["ACE_medical_bloodVolume",_playerBloodVolume];
  31.  
  32. };
  33.  
  34. [] call life_fnc_hudUpdate;
  35. };
  36. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement