Jump to content

Hank_2011

Member
  • Content Count

    4
  • Joined

  • Last visited

  • Medals

Community Reputation

10 Good

About Hank_2011

  • Rank
    Rookie
  1. Hi all. Description: This script gives information "Hint": Shooter. Victim. Distance (from the shooter to the victim). But I do not know how to add information about the weapons the shooter. I will be glad of any help and advice. init.sqf: [] exec "killer.sqs" init_unit: this addeventhandler["killed",{obj_killed = _this select 0;obj_killer = _this select 1;{publicvariable _x}foreach["obj_killed","obj_killer"]}]; killer.sqs: #init obj_killed = objnull obj_killer = objnull @obj_killed == obj_killed && obj_killer == obj_killer ? obj_killer != obj_killed : hint format["Shooter: %1\n%2\n%3", name obj_killer, name obj_killed, round (obj_killed distance obj_killer) ] goto "init"
  2. In this variant displays information about the main weapon of the arrow: private ["_group","_unit"]; _group = _this select 0; whoDunnit = { private ["_deatharray","_side", "_victim","_killer","_namvictim","_dis"]; _deatharray =_this select 0; _victim = _deatharray select 0; _killer = _deatharray select 1; _killgun = primaryWeapon _killer; _dis = round (_killer distance _victim); _killer globalchat format ["> *%1* < hit the target > *%2* < distance of > *%3* < meters > weapon *%4* <", name _killer, name _victim, _dis, _killgun]; }; for [{_i=0},{_i<=count units _group},{_i=_i+1}] do { _unit = units _group select _i; _unit addeventhandler ["KILLED",{nul=[_this] call whoDunnit}]; sleep 0.01; }; For the script in multiplayer need expert help !
  3. Great script! Is it still possible to add information about the weapon which killed?
×