Guest

[Release] Player corpse falls from destroyed vehicle script

42 posts in this topic

As the title says it is about a Salvage vehicle script. Player corpse falls from destroyed vehicle.

Step 1

Copy the Folder custom to you Exile.YourMap Folder

Step 2

in the Config.cpp in the ection CfgInteractionMenus you Modify

Spoiler

    class Car
    {
        targetType = 2;
        target = "Car";

        class Actions
        {
            class ScanLock: ExileAbstractAction
            {
                title = "Scan Lock";
                condition = "('Exile_Item_ThermalScannerPro' in (magazines player)) && !ExilePlayerInSafezone && ((locked ExileClientInteractionObject) != 1)";
                action = "_this call ExileClient_object_lock_scan";
            };

            // Locks a vehicle
            class Lock: ExileAbstractAction
            {
                title = "Lock";
                condition = "((locked ExileClientInteractionObject) isEqualTo 0) && ((locked ExileClientInteractionObject) != 1)";
                action = "true spawn ExileClient_object_lock_toggle";
            };

            // Unlocks a vehicle
            class Unlock: ExileAbstractAction
            {
                title = "Unlock";
                condition = "((locked ExileClientInteractionObject) isEqualTo 2) && ((locked ExileClientInteractionObject) != 1)";
                action = "false spawn ExileClient_object_lock_toggle";
            };

            // Repairs a vehicle to 100%. Requires Duckttape
            class Repair: ExileAbstractAction
            {
                title = "Repair";
                condition = "true";
                action = "['RepairVehicle', _this select 0] call ExileClient_action_execute";
            };            
            
            // Hot-wires a vehicle
            class Hotwire: ExileAbstractAction
            {
                title = "Hotwire";
                condition = "((locked ExileClientInteractionObject) isEqualTo 2) && ((locked ExileClientInteractionObject) != 1)";
                action = "['HotwireVehicle', _this select 0] call ExileClient_action_execute";
            };

            // Flips a vehicle so the player doesnt have to call an admin
            // Check if vector up is fucked
            class Flip: ExileAbstractAction
            {
                title = "Flip";
                condition = "call ExileClient_object_vehicle_interaction_show";
                action = "_this call ExileClient_object_vehicle_flip";
            };

            // Fills fuel from a can into a car
            class Refuel: ExileAbstractAction
            {
                title = "Refuel";
                condition = "call ExileClient_object_vehicle_interaction_show";
                action = "_this call ExileClient_object_vehicle_refuel";
            };

            // Drains fuel from a car into an empty jerry can
            class DrainFuel: ExileAbstractAction
            {
                title = "Drain Fuel";
                condition = "call ExileClient_object_vehicle_interaction_show";
                action = "_this call ExileClient_object_vehicle_drain";
            };
        };
    };

Change it to

Spoiler

    class Car
    {
        targetType = 2;
        target = "Car";

        class Actions
        {
            class ScanLock: ExileAbstractAction
            {
                title = "Scan Lock";
                condition = "('Exile_Item_ThermalScannerPro' in (magazines player)) && !ExilePlayerInSafezone && ((locked ExileClientInteractionObject) != 1)";
                action = "_this call ExileClient_object_lock_scan";
            };

            // Locks a vehicle
            class Lock: ExileAbstractAction
            {
                title = "Lock";
                condition = "((locked ExileClientInteractionObject) isEqualTo 0) && ((locked ExileClientInteractionObject) != 1)";
                action = "true spawn ExileClient_object_lock_toggle";
            };

            // Unlocks a vehicle
            class Unlock: ExileAbstractAction
            {
                title = "Unlock";
                condition = "((locked ExileClientInteractionObject) isEqualTo 2) && ((locked ExileClientInteractionObject) != 1)";
                action = "false spawn ExileClient_object_lock_toggle";
            };

            // Repairs a vehicle to 100%. Requires Duckttape
            class Repair: ExileAbstractAction
            {
                title = "Repair";
                condition = "true";
                action = "['RepairVehicle', _this select 0] call ExileClient_action_execute";
            };
            
            // Salvage a vehicle
            class Salvage: ExileAbstractAction
            {
                title = "Salvage Vehicle";
                condition = "(!(alive (ExileClientInteractionObject)))";
                action = "_this call SV_fnc_SalvageVehicle";
            };            
            
            // Hot-wires a vehicle
            class Hotwire: ExileAbstractAction
            {
                title = "Hotwire";
                condition = "((locked ExileClientInteractionObject) isEqualTo 2) && ((locked ExileClientInteractionObject) != 1)";
                action = "['HotwireVehicle', _this select 0] call ExileClient_action_execute";
            };

            // Flips a vehicle so the player doesnt have to call an admin
            // Check if vector up is fucked
            class Flip: ExileAbstractAction
            {
                title = "Flip";
                condition = "call ExileClient_object_vehicle_interaction_show";
                action = "_this call ExileClient_object_vehicle_flip";
            };

            // Fills fuel from a can into a car
            class Refuel: ExileAbstractAction
            {
                title = "Refuel";
                condition = "call ExileClient_object_vehicle_interaction_show";
                action = "_this call ExileClient_object_vehicle_refuel";
            };

            // Drains fuel from a car into an empty jerry can
            class DrainFuel: ExileAbstractAction
            {
                title = "Drain Fuel";
                condition = "call ExileClient_object_vehicle_interaction_show";
                action = "_this call ExileClient_object_vehicle_drain";
            };
        };
    };

Step 3

Copy this code in your initPlayerLocal.sqf

SV_fnc_SalvageVehicle = compileFinal preprocessFileLineNumbers "custom\SalvageVehicle\SalvageVehicle.sqf";

GitHub-Code: https://github.com/serveratze/-EXILE-Salvage-a-vehicle-script

20170702031232_1.jpg20170702031407_1.jpg20170702031435_1.jpg

 

Have Fun with this Modification :)

 

Edited by 110
1 person likes this

Share this post


Link to post
Share on other sites

What does this actually do? It just seems to delete the vehicle?

Share this post


Link to post
Share on other sites
Advertisement
49 minutes ago, kuplion said:

Was macht das eigentlich? Es scheint nur das Fahrzeug zu löschen?

It clears the vehicle so that one comes to his player's body.

Share this post


Link to post
Share on other sites

we use something similar but, unless you flip the crashed heli before you salvage, your body will be unreachable in the air.

Does this operate any differently or, does the pilot body still float out of range?

Share this post


Link to post
Share on other sites
15 minutes ago, BaroN said:

we use something similar but, unless you flip the crashed heli before you salvage, your body will be unreachable in the air.

Does this operate any differently or, does the pilot body still float out of range?

I'm assuming that it's an arma future. :PI know the problem and do not know a solution.

Share this post


Link to post
Share on other sites
54 minutes ago, BaroN said:

we use something similar but, unless you flip the crashed heli before you salvage, your body will be unreachable in the air.

Does this operate any differently or, does the pilot body still float out of range?

Set the POS to the terrain level. Or I have something else that will work for you.

Share this post


Link to post
Share on other sites
On ‎02‎/‎07‎/‎2017 at 3:19 AM, 110 said:

20170702031435_1.jpg

 

@110, can you make sure that at the end of the salvage you get some money like on wasteland ?

Share this post


Link to post
Share on other sites
3 hours ago, M-RYS said:

@110, can you make sure that at the end of the salvage you get some money like on wasteland ?

No why too.

Share this post


Link to post
Share on other sites
Advertisement

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.