Deploy bike... change the option to deploy it

LTGNick

Valued Member!
So lately im getting tired of scroll wheeling through 3-4 options just to get into a car and was wondering if there was a way to deploy the bike by right click on the toolbox in ur inventory instead of scroll wheeling?
 
So lately im getting tired of scroll wheeling through 3-4 options just to get into a car and was wondering if there was a way to deploy the bike by right click on the toolbox in ur inventory instead of scroll wheeling?

Yes, there is a way.

You'll have to re-define the CfgMagazines.hpp in your mission Folder (i have no clue how, sorry) and the rest is pretty simple. All you do is write a class for your Item or Edit the existing class. You add a sub class inside the class and that's named "ItemActions". Example:


PHP:
class WoodenArrow : CA_Magazine {
        scope = public;
        displayName = $STR_ITEMWOODENARROW_CODE_NAME;
        model = "\dayz_weapons\models\bolt_gear";
        picture = "\z\addons\dayz_communityassets\pictures\equip_warrow_ca.paa";
        ammo = "WoodenArrow";
        count = 1;
        initSpeed = 150;
        descriptionShort = $STR_ITEMWOODENARROW_CODE_DESC;
       
        class ItemActions {
            class CreateQuiver {
                text = $STR_ACTION_CREATEQUIVER;
                script = "spawn player_createquiver;";
            };
        };
    };

Example 2:

PHP:
class WoodenArrow : CA_Magazine {
        scope = public;
        displayName = $STR_ITEMWOODENARROW_CODE_NAME;
        model = "\dayz_weapons\models\bolt_gear";
        picture = "\z\addons\dayz_communityassets\pictures\equip_warrow_ca.paa";
        ammo = "WoodenArrow";
        count = 1;
        initSpeed = 150;
        descriptionShort = $STR_ITEMWOODENARROW_CODE_DESC;
      
        class ItemActions {
            class Action1 {
                text = "Custom Text";
                script = "spawn path\to\file\player_createquiver;";
            };
            class Action2 {
                text = "Another Custom Text";
                script = "spawn path\to\file\other_script;";
            };
            class Action3 {
                text = "You can have as many";
                script = "spawn actions\as\you\want;";
            };
        };
    };
 
Back
Top