Sporkyzz

[SOLVED] How do i lock tanks?!

10 posts in this topic

Hey i just added tanks to shop but when ppl buy it they cant lock the tank... someone know the fix?

Share this post


Link to post
Share on other sites

Posted (edited)

In config.cpp find string class CfgInteractionMenus, and then add the following

Spoiler

    class Tank
{
targetType=2;
target="Tank";
class Actions
{
class Lock: ExileAbstractAction
{
title="Lock";
condition="((locked ExileClientInteractionObject) isEqualTo 0) && ((locked ExileClientInteractionObject) != 1)";
action="true spawn ExileClient_object_lock_toggle";
};
class Unlock: ExileAbstractAction
{
title="Unlock";
condition="((locked ExileClientInteractionObject) isEqualTo 2) && ((locked ExileClientInteractionObject) != 1)";
action="false spawn ExileClient_object_lock_toggle";
};
class Repair: ExileAbstractAction
{
title="Repair";
condition="call ExileClient_object_vehicle_interaction_show";
action="_this call ExileClient_object_vehicle_Repair";
};
class Flip: ExileAbstractAction
{
title="Flip";
condition="call ExileClient_object_vehicle_interaction_show";
action="_this call Exileclient_object_vehicle_flip";
};
class Refuel: ExileAbstractAction
{
title="Refuel";
condition="call ExileClient_object_vehicle_interaction_show";
action="_this call ExileClient_object_vehicle_refuel";
};
class DrainFuel: ExileAbstractAction
{
title="Drain Fuel";
condition="call ExileClient_object_vehicle_interaction_show";
action="_this call ExileClient_object_vehicle_drain";
};
};
};
    

to get as

Spoiler

class CfgInteractionMenus
{
    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 = "call ExileClient_object_vehicle_interaction_show";
                action = "_this call ExileClient_object_vehicle_Repair";
            };

            // 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";
            };
        };
    };
    class Tank
{
targetType=2;
target="Tank";
class Actions
{
class Lock: ExileAbstractAction
{
title="Lock";
condition="((locked ExileClientInteractionObject) isEqualTo 0) && ((locked ExileClientInteractionObject) != 1)";
action="true spawn ExileClient_object_lock_toggle";
};
class Unlock: ExileAbstractAction
{
title="Unlock";
condition="((locked ExileClientInteractionObject) isEqualTo 2) && ((locked ExileClientInteractionObject) != 1)";
action="false spawn ExileClient_object_lock_toggle";
};
class Repair: ExileAbstractAction
{
title="Repair";
condition="call ExileClient_object_vehicle_interaction_show";
action="_this call ExileClient_object_vehicle_Repair";
};
class Flip: ExileAbstractAction
{
title="Flip";
condition="call ExileClient_object_vehicle_interaction_show";
action="_this call Exileclient_object_vehicle_flip";
};
class Refuel: ExileAbstractAction
{
title="Refuel";
condition="call ExileClient_object_vehicle_interaction_show";
action="_this call ExileClient_object_vehicle_refuel";
};
class DrainFuel: ExileAbstractAction
{
title="Drain Fuel";
condition="call ExileClient_object_vehicle_interaction_show";
action="_this call ExileClient_object_vehicle_drain";
};
};
};

 

Edited by xface
3 people like this

Share this post


Link to post
Share on other sites
Advertisement

this was included in last exile update, you just need to bind the 2 custom keys

1 person likes this

Share this post


Link to post
Share on other sites
On 10. 1. 2016 at 2:56 AM, red_ned said:

this was included in last exile update, you just need to bind the 2 custom keys

Hi how to lock BMP from mas vehicles?    Thnx!

class I_mas_BMP2_Ambul_01                    
 class O_mas_BMP2_Ambul_01              

Share this post


Link to post
Share on other sites
19 minutes ago, NeverAgain said:

Hi how to lock BMP from mas vehicles?    Thnx!

class I_mas_BMP2_Ambul_01                    
 class O_mas_BMP2_Ambul_01              

I have written above that it is necessary to make to close the tank and other tracked vehicles

Share this post


Link to post
Share on other sites
On 09/01/2016 at 2:56 AM, red_ned said:

this was included in last exile update, you just need to bind the 2 custom keys

I know about the "1" for lock unlock but can you tell me what is the second one?

Share this post


Link to post
Share on other sites
On 23. 3. 2016 at 4:41 PM, xface said:

I have written above that it is necessary to make to close the tank and other tracked vehicles

Worked !

Share this post


Link to post
Share on other sites

We have closed this thread and marked it as solved.

Share this post


Link to post
Share on other sites
Advertisement
Guest
This topic is now closed to further replies.

  • Recently Browsing   0 members

    No registered users viewing this page.