Français Solved Issue with fn_setupActions.sqf

  • Auteur de la discussion Auteur de la discussion Nolan
  • Date de début Date de début

Nolan

User
16/1/21
8
0
250
Bonsoir, je ne peux ni regardé le fichier plaque, permis et trafic depuis mon vehicule, je ne peut également m'assoir sur des chaises, voici mon fichier
Code:
life_actions = [];

switch (playerSide) do {

    //Civilian
    case civilian: {
        //Drop fishing net
        life_actions pushBack (player addAction[localize "STR_pAct_DropFishingNet",life_fnc_dropFishingNet,"",0,false,false,"",'
        (surfaceisWater (getPos vehicle player)) && (vehicle player isKindOf "Ship") && life_carryWeight < life_maxWeight && speed (vehicle player) < 2 && speed (vehicle player) > -1 && !life_net_dropped ']);

        //Rob person
        life_actions pushBack (player addAction[localize "STR_pAct_RobPerson",life_fnc_robAction,"",0,false,false,"",'
        !isNull cursorObject && player distance cursorObject < 3.5 && isPlayer cursorObject && animationState cursorObject == "Incapacitated" && !(cursorObject getVariable ["robbed",false]) ']);
        
        life_actions pushBack (player addAction["<t color='#0099FF'>S'asseoir</t>",{[cursorObject,player] execVM "script\Sitting\sitdown.sqf"},true,1,true,true,"""",'player distance cursorObject < 3 && {([str cursorObject,"bench"] call KRON_StrInStr || [str cursorObject,"chair"] call KRON_StrInStr)} ']);
    };
    
    //Cops
    case west: {
        life_actions pushBack (player addAction["Fichier plaques",{createDialog "max_search_plate"},"",0,false,false,"",'(vehicle player isKindOf "Car")']);
        
        life_actions pushBack (player addAction["Fichier permis",max_permisPoints_fnc_searchPlayersMenu,"",0,false,false,"",'(vehicle player isKindOf "Car")']);
        
        life_actions pushBack (player addAction["Gestion traffic",traffic_system_fnc_controlMenu,"",0,false,false,"",'(vehicle player isKindOf "Car")']);
        
        life_actions pushBack (player addAction["<t color='#0099FF'>S'asseoir</t>",{[cursorObject,player] execVM "script\Sitting\sitdown.sqf"},true,1,true,true,"""",'player distance cursorObject < 3 && {([str cursorObject,"bench"] call KRON_StrInStr || [str cursorObject,"chair"] call KRON_StrInStr)} ']);
    };
    
    //EMS
    case independent: { };
        life_actions pushBack (player addAction["<t color='#0099FF'>S'asseoir</t>",{[cursorObject,player] execVM "script\Sitting\sitdown.sqf"},true,1,true,true,"""",'player distance cursorObject < 3 && {([str cursorObject,"bench"] call KRON_StrInStr || [str cursorObject,"chair"] call KRON_StrInStr)} ']);
    };
};
 
Solution
Bonsoir, regarde tu a une erreur dans ton fichier sur la case independent.

Code:
    //EMS
    case independent: { }; //<====== ERREUR (il faut que tu places l'action a l'intérieur des accolades)
        life_actions pushBack (player addAction["<t color='#0099FF'>S'asseoir</t>",{[cursorObject,player] execVM "script\Sitting\sitdown.sqf"},true,1,true,true,"""",'player distance cursorObject < 3 && {([str cursorObject,"bench"] call KRON_StrInStr || [str cursorObject,"chair"] call KRON_StrInStr)} ']);
    };

    case independent: { //<======  Comme ceci, tu pourras donc tu peux corriger la case independent
        life_actions pushBack (player addAction["<t color='#0099FF'>S'asseoir</t>",{[cursorObject,player] execVM...
Bonsoir, regarde tu a une erreur dans ton fichier sur la case independent.

Code:
    //EMS
    case independent: { }; //<====== ERREUR (il faut que tu places l'action a l'intérieur des accolades)
        life_actions pushBack (player addAction["<t color='#0099FF'>S'asseoir</t>",{[cursorObject,player] execVM "script\Sitting\sitdown.sqf"},true,1,true,true,"""",'player distance cursorObject < 3 && {([str cursorObject,"bench"] call KRON_StrInStr || [str cursorObject,"chair"] call KRON_StrInStr)} ']);
    };

    case independent: { //<======  Comme ceci, tu pourras donc tu peux corriger la case independent
        life_actions pushBack (player addAction["<t color='#0099FF'>S'asseoir</t>",{[cursorObject,player] execVM "script\Sitting\sitdown.sqf"},true,1,true,true,"""",'player distance cursorObject < 3 && {([str cursorObject,"bench"] call KRON_StrInStr || [str cursorObject,"chair"] call KRON_StrInStr)} ']);
    };
 
Dernière édition:
Solution