Jump to content
  • 0
Sign in to follow this  
Audrian Edvardsen Hellcase.com

VDM Scripts

Question

24 answers to this question

Recommended Posts

  • 0

if (vehicle _unit == _unit) then {
    if ( _source isKindOf "Air" OR _source isKindOf "Car" OR _source isKindOf "Motorcycle" OR _source isKindOf "Boat" OR _source isKindOf "Tank" ) then {
     
    } else {
        _isVehicle = vehicle _source;
        if (_isVehicle isKindOf "Air" OR _isVehicle isKindOf "Car" OR _isVehicle isKindOf "Boat" OR _isVehicle isKindOf "Motorcycle" OR _isVehicle isKindOf "Tank") then
        {
            _damage = _currdamage = damage player;
        };
    };
};

Like this?

Share this post


Link to post
Share on other sites
  • 0
Just now, Audrian Edvardsen Hellcase.com said:

if (vehicle _unit == _unit) then {
    if ( _source isKindOf "Air" OR _source isKindOf "Car" OR _source isKindOf "Motorcycle" OR _source isKindOf "Boat" OR _source isKindOf "Tank" ) then {
     
    } else {
        _isVehicle = vehicle _source;
        if (_isVehicle isKindOf "Air" OR _isVehicle isKindOf "Car" OR _isVehicle isKindOf "Boat" OR _isVehicle isKindOf "Motorcycle" OR _isVehicle isKindOf "Tank") then
        {
            _damage = _currdamage = damage player;
        };
    };
};

Like this?

:wutface:That is not what I said at all

Share this post


Link to post
Share on other sites
  • 0

 

5 minutes ago, TheBUTTERY_T said:

:wutface:That is not what I said at all

rivate["_unit","_damage","_source","_projectile","_part","_curWep"];
_unit = SEL(_this,0);
_part = SEL(_this,1);
_damage = SEL(_this,2);
_source = SEL(_this,3);
_projectile = SEL(_this,4);
_currdamage = damage player;

//Handle the tazer first (Top-Priority).
if(!isNull _source) then {

Something like this?

Share this post


Link to post
Share on other sites
  • 0
Just now, Audrian Edvardsen Hellcase.com said:

 

rivate["_unit","_damage","_source","_projectile","_part","_curWep"];
_unit = SEL(_this,0);
_part = SEL(_this,1);
_damage = SEL(_this,2);
_source = SEL(_this,3);
_projectile = SEL(_this,4);
_currdamage = damage player;

//Handle the tazer first (Top-Priority).
if(!isNull _source) then {

Something like this?

Give it a try and see if it works.

Share this post


Link to post
Share on other sites
  • 0

Here just switch your script for this

        if (vehicle _unit isEqualTo _unit) then
        {
            _vehicle = vehicle _source;
            if ( vehicle _vehicle isKindOf "Air" || vehicle _vehicle isKindOf "Car" || vehicle  _vehicle isKindOf "Boat" ) then
            {
                _damage = _currdamage;
            };
        };

 

Share this post


Link to post
Share on other sites
  • 0

Here

#include "..\..\script_macros.hpp"
/*
	File: fn_handleDamage.sqf
	Author: Bryan "Tonic" Boardwine

	Description:
	Handles damage, specifically for handling the 'tazer' pistol and nothing else.
*/
private["_unit","_damage","_source","_projectile","_part","_curWep"];
_unit = SEL(_this,0);
_part = SEL(_this,1);
_damage = SEL(_this,2);
_source = SEL(_this,3);
_projectile = SEL(_this,4);
_currdamage = damage player;

//Handle the tazer first (Top-Priority).
if(!isNull _source) then {
	if(_source != _unit) then {
		if (_unit getVariable["Revive",false]) exitWith {};
		_curWep = currentWeapon _source;
		if(_projectile in ["B_9x21_Ball","B_556x45_dual"] && _curWep in ["hgun_P07_snds_F","arifle_SDAR_F"]) then {
			if(side _source isEqualTo west && playerSide isEqualTo civilian) then {
				private["_distance"];
				_distance = if(_projectile == "B_556x45_dual") then {100} else {35};
				_damage = false;
				if(_unit distance _source < _distance) then {
					if(!life_istazed && !life_isknocked && !(_unit GVAR ["restrained",false])) then {
						if (vehicle player != player) then {
							if (typeOf (vehicle player) == "B_Quadbike_01_F") then {
								player action ["Eject",vehicle player];
								[_unit,_source] spawn life_fnc_tazed;
							};
						} else {
							[_unit,_source] spawn life_fnc_tazed;
						};
					};
				};
			};

			//Temp fix for super tasers on cops.
			if(side _source isEqualTo west && (playerSide isEqualTo west OR playerSide isEqualTo independent)) then {
				_damage = false;
			};
		};
        //anti-vdm
        if (vehicle _unit isEqualTo _unit) then
        {
            _vehicle = vehicle _source;
            if ( vehicle _vehicle isKindOf "Air" || vehicle _vehicle isKindOf "Car" || vehicle  _vehicle isKindOf "Boat" ) then
            {
                _damage = _currdamage;
            };
        };
	};
};


[] spawn life_fnc_hudUpdate;
_damage;

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...