Jump to content
  • 0

Sorting out humanity


Shawn

Question

So I am currently trying to get humanity working well as there are many humanity boosting methods open, but I cannot figure what to do from here. This is what I've worked up to so far. If anyone could direct me in the correct direction, it would be appreciated.

_HFKiller = _this select 0;
_HFVictim = _this select 1;

if (!alive _HFKiller) exitWith {};

_humanityK = _HFKiller getVariable ["humanity",0];
_humanityV = _HFVictim getVariable ["humanity",0];



switch true do {
    case ((_humanityK > 5000) AND (_humanityV > 5000)): {
		_HFKiller setVariable ["humanity",(_humanityK - 200),true];
		}; // hero vs hero
		
    case ((_humanityK < -5000) AND (_humanityV > 5000)): {
		_HFKiller setVariable ["humanity",(_humanityK - 200),true];
		}; // bandit vs hero
		
    case ((_humanityK > 5000) AND (_humanityV < -5000)): {
		_HFKiller setVariable ["humanity",(_humanityK + 200),true];
		}; // hero vs bandit
		
    case ((_humanityK < -5000) AND (_humanityV < -5000)): {
		_HFKiller setVariable ["humanity",(_humanityK + 200),true];
		}; // bandit vs bandit
		
    case ((_humanityK > -5000) AND(_humanityK < 5000) AND (_humanityV > 5000)): {
		_HFKiller setVariable ["humanity",(_humanityK + 200),true];
		}; // civilian vs hero
		
    case ((_humanityK > -5000) AND(_humanityV < 5000) AND (_humanityV < -5000)): {
		_HFKiller setVariable ["humanity",(_humanityK + 200),true];
		}; // civilian vs bandit
		
    case ((_humanityV > -5000) AND(_humanityV < 5000) AND (_humanityK > 5000)): {
		_HFKiller setVariable ["humanity",(_humanityK - 200),true];
		}; // hero vs civilian
		
    case ((_humanityV > -5000) AND(_humanityV < 5000) AND (_humanityK < -5000)): {
		_HFKiller setVariable ["humanity",(_humanityK - 200),true];
		}; // bandit vs civilian
		
    case ((_humanityV > -5000) AND(_humanityV < 5000) AND (_humanityK > -5000) AND (_humanityK < 5000)): {
		_HFKiller setVariable ["humanity",(_humanityK - 200),true];
		}; // civilian vs civilian
    default (true);
};

 

Link to comment
Share on other sites

6 answers to this question

Recommended Posts

  • 0

hey shawn.. im usin it to change humanity... maybe u can use too,,
 see lines in blue

  Reveal hidden contents

 

Link to comment
Share on other sites

  • 0

Yeah, seelenapparat is correct. I think humanity is given based on damage handled, because if you continue to spray someone in the head with a gun, it will give you about -20k humanity. This is massively abused, especially when load outs on my server are unlocked with higher/lower humanity. I want it to give a set amount, say -200 or +200 depending on if they are a hero or not.

Any ideas? 

Link to comment
Share on other sites

  • 0

as I wrote, you should check out the file:

player_death.sqf

especially this part:

  Reveal hidden contents

 

Im not sure, if this is everything though.

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Discord

×
×
  • Create New...