Ich wollte mal nachfragen ob die Keyhandler so funktioniert. Wir möchten gerne auf shift 1 shift 2 und shift 3 ein Stopsignal haben leider sind die tasten schon belegt und ich habe eine weitere abfrage eingefügt.
Code
case 79: {
if (!_shift && !_ctrlKey && _alt && (vehicle player == player) && {!(animationState player isEqualTo "CL3_anim_Pee")}) then {
player playActionNow "CL3_anim_Pee";
if(_shift) then {
if(_cop && !life_cop_stoppls_active && {vehicle player != player}) then {
life_cop_stoppls_active = true;
_veh = vehicle player;
[_veh] remoteExec ["life_fnc_copstoppls",-2];
[] spawn {
sleep 20;
life_cop_stoppls_active = false;
};
};
};
_handled = true;
};
case 80: {
if (!_shift && !_ctrlKey && _alt && (vehicle player == player) && {!(animationState player isEqualTo "CL3_dubstepdance")}) then {
player playActionNow "CL3_dubstepdance";
if(_shift) then {
if(_cop && !life_cop_stop_active && {vehicle player != player}) then {
life_cop_stop_active = true;
_veh = vehicle player;
[_veh] remoteExec ["life_fnc_copstop",-2];
[] spawn {
sleep 20;
life_cop_stop_active = false;
};
};
};
_handled = true;
};
case 81: {
if (!_shift && !_ctrlKey && _alt && (vehicle player == player) && {!(animationState player isEqualTo "CL3_russiandance")}) then {
player playActionNow "CL3_russiandance";
if(_shift) then {
if(_cop && !life_cop_stfv_active && {vehicle player != player}) then {
life_cop_stfv_active = true;
_veh = vehicle player;
[_veh] remoteExec ["life_fnc_copStfv",-2];
[] spawn {
sleep 20;
life_cop_stfv_active = false;
};
};
};
_handled = true;
};
Alles anzeigen