Auto Delete Wrecked Vehicles Script (HOW ?)

Thx man will test it tonight

Edit : No sry it won't work ...

Gesendet von meinem GT-I9100 mit Tapatalk
 
Working codes for Epoch 1.0.3.1

Code:
_object_damage = {
    private["_hitpoints","_array","_hit","_selection","_key","_damage"];
        _hitpoints = _object call vehicle_getHitpoints;
        _damage = damage _object;
        _array = [];
        {
            _hit = [_object,_x] call object_getHit;
            _selection = getText (configFile >> "CfgVehicles" >> (typeOf _object) >> "HitPoints" >> _x >> "name");
            if (_hit > 0) then {_array set [count _array,[_selection,_hit]]};
            _object setHit ["_selection", _hit]
        } forEach _hitpoints;
   
        _key = format["CHILD:306:%1:%2:%3:",_objectID,_array,_damage];
        //diag_log ("HIVE: WRITE: "+ str(_key));
        _key call server_hiveWrite;
    _object setVariable ["needUpdate",false,true];
    if ( _damage >= 1 ) then { _object spawn { sleep 15; deleteVehicle _this; }; };
    };

or

Code:
[CODE]
_object_damage = {
    private["_hitpoints","_array","_hit","_selection","_key","_damage"];
        _hitpoints = _object call vehicle_getHitpoints;
        _damage = damage _object;
        _array = [];
        {
            _hit = [_object,_x] call object_getHit;
            _selection = getText (configFile >> "CfgVehicles" >> (typeOf _object) >> "HitPoints" >> _x >> "name");
            if (_hit > 0) then {_array set [count _array,[_selection,_hit]]};
            _object setHit ["_selection", _hit]
        } forEach _hitpoints;
 
        _key = format["CHILD:306:%1:%2:%3:",_objectID,_array,_damage];
        //diag_log ("HIVE: WRITE: "+ str(_key));
        _key call server_hiveWrite;
        if ( _damage >= 1 ) then { deleteVehicle _object; };
    _object setVariable ["needUpdate",false,true];
    };
[/CODE]
 
I've got a problem with the cleanup. For some reason it doesn't work anymore. Besides that, on my TSW the cars don't move, just the players. This leads me to believe that there is something wrong with my database (thus it doesn't delete vehicles from the game cause they aren't in the database?)
Any idea where I should look for a solution to this problem?

my instance_id = 1
world_vehicle_id = 8
world_id = 8
 
Last edited:
AlienX, you know how to put the option of rearm the helis in these containers: CDF_WarfareBVehicleServicePoint and USMC_WarfareBVehicleServicePoint.
is that I put the Gunners little bird, black bird, AN2 and UH1H.
 
Back
Top