Advertisement
Nebulazer

Untitled

Aug 26th, 2016
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
SQF 3.21 KB | None | 0 0
  1. //End Mission
  2. neb_fnc_core_ticketCounter = {
  3. _quarterScore = round (endScore / 4);
  4. _midscore = round (endScore / 2);
  5. _threeQuarter = round (endScore / 4) * 3;
  6. _almostEnd = round (endScore / 4) * round 3.8;
  7. _amountleftEnd = endScore - _almostEnd;
  8.     // Blu is at Quarter Score
  9.     if (bluScore == _quarterScore) then {
  10.         _scoreText = format [ "Blu Is Now At %1 Out of %2 Points To Win The Game", _quarterScore, endScore ];
  11.         ["<t color='#B8AB67' size = '.8'>" + _scoreText + "</t>",-1,-1,4,1,0,825] spawn BIS_fnc_dynamicText;
  12.     };
  13.     // Red is at Quarter Score
  14.     if (redScore == _quarterScore) then {
  15.         _scoreText = format [ "Red Is Now At %1 Out of %2 Points To Win The Game", _quarterScore, endScore ];
  16.         ["<t color='#B8AB67' size = '.8'>" + _scoreText + "</t>",-1,-1,4,1,0,833] spawn BIS_fnc_dynamicText;
  17.         };
  18.  
  19.     // Blu Has Half points needed to win
  20.     if (bluScore == _midScore) then {
  21.         _scoreText = format [ "Blu Is Now At %1 Out of %2 Points To Win The Game", _midScore, endScore ];
  22.         ["<t color='#B8AB67' size = '.8'>" + _scoreText + "</t>",-1,-1,4,1,0,845] spawn BIS_fnc_dynamicText;
  23.         };
  24.  
  25.     // Red Has Half points needed to win
  26.     if (redScore == _midScore) then {
  27.         _scoreText = format [ "Red Is Now At %1 Out of %2 Points To Win The Game", _midScore, endScore ];
  28.         ["<t color='#B8AB67' size = '.8'>" + _scoreText + "</t>",-1,-1,4,1,0,855] spawn BIS_fnc_dynamicText;
  29.         };
  30.  
  31.     if (bluScore == _threeQuarter) then {
  32.         _scoreText = format [ "Blu Is Now At %1 Out of %2 Points To Win The Game", _threeQuarter, endScore ];
  33.         ["<t color='#B8AB67' size = '.8'>" + _scoreText + "</t>",-1,-1,4,1,0,860] spawn BIS_fnc_dynamicText;
  34.         };
  35.  
  36.     if (redScore == _threeQuarter) then {
  37.         _scoreText = format [ "Red Is Now At %1 Out of %2 Points To Win The Game", _threeQuarter, endScore ];
  38.         ["<t color='#B8AB67' size = '.8'>" + _scoreText + "</t>",-1,-1,4,1,0,870] spawn BIS_fnc_dynamicText;
  39.         };
  40.    
  41.     if (bluScore == _almostEnd) then {
  42.         _scoreText = format [ "Blu Only Needs %1 Points To Win The Game!!", _amountleftEnd, endScore ];
  43.         ["<t color='#B8AB67' size = '.8'>" + _scoreText + "</t>",-1,-1,4,1,0,875] spawn BIS_fnc_dynamicText;
  44.         };
  45.  
  46.     if (redScore == _almostEnd) then {
  47.         _scoreText = format [ "Red Only Needs %1 Points To Win The Game!!", _amountleftEnd, endScore ];
  48.         ["<t color='#B8AB67' size = '.8'>" + _scoreText + "</t>",-1,-1,4,1,0,880] spawn BIS_fnc_dynamicText;
  49.         };
  50.    
  51.     if (bluScore >= endScore) then {
  52.         //Crate Saving
  53.     _crate = player getVariable [ "NEB_shopCrate", objNull ];
  54.     if !( isNull _crate ) then {
  55.         profileNamespace setVariable[ "NEB_telecache",
  56.             [
  57.                 magazineCargo _crate call BIS_fnc_consolidateArray,
  58.                 itemCargo _crate call BIS_fnc_consolidateArray,
  59.                 weaponCargo _crate call BIS_fnc_consolidateArray
  60.             ]
  61.         ];
  62.     };
  63.     saveProfileNamespace;
  64.     endMission "END1";
  65.         };
  66.     if (redScore >= endScore) then {
  67.         //Crate Saving
  68.     _crate = player getVariable [ "NEB_shopCrate", objNull ];
  69.     if !( isNull _crate ) then {
  70.         profileNamespace setVariable[ "NEB_telecache",
  71.             [
  72.                 magazineCargo _crate call BIS_fnc_consolidateArray,
  73.                 itemCargo _crate call BIS_fnc_consolidateArray,
  74.                 weaponCargo _crate call BIS_fnc_consolidateArray
  75.             ]
  76.         ];
  77.     };
  78.     saveProfileNamespace;
  79.     endMission "END1";
  80.         };
  81.  
  82. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement