• Allumer/Eteindre les girophares avec la molette


    Bonjour, Bonsoir.

    Je vous présente un script qui vous permettera a Allumer/Eteindre les sirènes en Policer de votre Vehicule.

    Suivez cette étapes simple :

    Aller dans Altis–Life.Altislife/mpmission/core/setupaction.sqf

    Ajoutez dedans :

        //Allumer les girophares  
            life_actions = life_actions + [player addAction["<t color='#75F75A'>Gyrophares</t>",{  
                [vehicle player] call life_fnc_sirenLights;  
            },"",0,false,false,"",' vehicle player != player && ((typeOf vehicle player) in ["I_Quadbike_01_F","C_Offroad_01_F","C_SUV_01_F","B_MRAP_01_F","C_Hatchback_01_sport_F","I_MRAP_03_F","B_Heli_Light_01_F","B_Heli_Transport_03_unarmed_F","I_Heli_light_03_unarmed_F","O_Heli_Light_02_unarmed_F","B_Heli_Transport_01_F"]) && !isNil {vehicle player getVariable "lights"} && ((driver vehicle player) == player) && !(vehicle player getVariable ["lights", false]) ']];  
    
            //Allumer les girophares + sirenes  
            life_actions = [player addAction["<t color='#EBEE3E'>Sirene Courte</t>",{  
                _veh = vehicle player;  
                _veh call life_fnc_sirenLights;  
                titleText [localize "STR_MISC_SirensON","PLAIN"];  
                _veh setVariable["siren",true,true];  
                [[_veh],"life_fnc_copSiren3",nil,true] spawn life_fnc_MP;  
            },"",0,false,false,"",' vehicle player != player && ((typeOf vehicle player) in ["I_Quadbike_01_F","C_Offroad_01_F","C_SUV_01_F","B_MRAP_01_F","C_Hatchback_01_sport_F","I_MRAP_03_F","B_Heli_Light_01_F","B_Heli_Transport_03_unarmed_F","I_Heli_light_03_unarmed_F","O_Heli_Light_02_unarmed_F","B_Heli_Transport_01_F"]) && ((driver vehicle player) == player) && !isNil {vehicle player getVariable "lights"} && !(vehicle player getVariable ["lights", false]) ']];  
    
            //Allumer les girophares + sirenes  
            life_actions = [player addAction["<t color='#E18B22'>Sirene Controle</t>",{  
                _veh = vehicle player;  
                _veh call life_fnc_sirenLights;  
                titleText [localize "STR_MISC_SirensON","PLAIN"];  
                _veh setVariable["siren",true,true];  
                [[_veh],"life_fnc_copSiren",nil,true] spawn life_fnc_MP;  
            },"",0,false,false,"",' vehicle player != player && ((typeOf vehicle player) in ["I_Quadbike_01_F","C_Offroad_01_F","C_SUV_01_F","B_MRAP_01_F","C_Hatchback_01_sport_F","I_MRAP_03_F","B_Heli_Light_01_F","B_Heli_Transport_03_unarmed_F","I_Heli_light_03_unarmed_F","O_Heli_Light_02_unarmed_F","B_Heli_Transport_01_F"]) && ((driver vehicle player) == player) && !isNil {vehicle player getVariable "lights"} && !(vehicle player getVariable ["lights", false]) ']];  
    
            //Allumer les girophares + sirenes  
            life_actions = [player addAction["<t color='#E14C22'>Sirene Sommation</t>",{  
                _veh = vehicle player;  
                _veh call life_fnc_sirenLights;  
                titleText [localize "STR_MISC_SirensON","PLAIN"];  
                _veh setVariable["siren",true,true];  
                [[_veh],"life_fnc_copSiren2",nil,true] spawn life_fnc_MP;  
            },"",0,false,false,"",' vehicle player != player && ((typeOf vehicle player) in ["I_Quadbike_01_F","C_Offroad_01_F","C_SUV_01_F","B_MRAP_01_F","C_Hatchback_01_sport_F","I_MRAP_03_F","B_Heli_Light_01_F","B_Heli_Transport_03_unarmed_F","I_Heli_light_03_unarmed_F","O_Heli_Light_02_unarmed_F","B_Heli_Transport_01_F"]) && ((driver vehicle player) == player) && !isNil {vehicle player getVariable "lights"} && !(vehicle player getVariable ["lights", false]) ']];  
    
            //Eteindre tout  
            life_actions = life_actions + [player addAction["<t color='#E14C22'>Eteindre</t>",{  
                _veh = vehicle player;  
                _veh setVariable["lights",false,true];  
                _veh setVariable["siren",false,true];  
            },"",0,false,false,"",' vehicle player != player && ((typeOf vehicle player) in ["I_Quadbike_01_F","C_Offroad_01_F","C_SUV_01_F","B_MRAP_01_F","C_Hatchback_01_sport_F","I_MRAP_03_F","B_Heli_Light_01_F","B_Heli_Transport_03_unarmed_F","I_Heli_light_03_unarmed_F","O_Heli_Light_02_unarmed_F","B_Heli_Transport_01_F"]) && !isNil {vehicle player getVariable "lights"} && ((driver vehicle player) == player) && (vehicle player getVariable ["lights", false]) ']];```
    
    Si vous avez des problemes n'hesitez pas a m'en parler !
  • Met […code][…/code] sans les … (Pour afficher le code sur le forum) et en rouge @Shems

  • Jsuis sur tel je ferais ca dem matin

  • Tenez voici le code avec la balise :

    //Allumer les sirènes  
    life_actions = life_actions + [player addAction["Allumer les sirenes",{[vehicle player,"life_fnc_copLights",true,false] spawn BIS_fnc_MP;},"",0,false,false,"",' vehicle player != player && ((typeOf vehicle player) in ["I_Quadbike_01_F","C_Offroad_01_F","C_SUV_01_F","B_MRAP_01_F","C_Hatchback_01_sport_F","I_MRAP_03_F","B_Heli_Light_01_F","B_Heli_Transport_03_unarmed_F","I_Heli_light_03_unarmed_F","O_Heli_Light_02_unarmed_F","B_Heli_Transport_01_F"]) && !isNil {vehicle player getVariable "lights"} && ((driver vehicle player) == player) && !(vehicle player getVariable ["lights", false])']];  
    
    //Eteindre les sirènes  
    life_actions = life_actions + [player addAction["Eteindre les sirenes",{vehicle player setVariable["lights",false,true];},"",0,false,false,"", ' vehicle player != player && ((typeOf vehicle player) in ["I_Quadbike_01_F","C_Offroad_01_F","C_SUV_01_F","B_MRAP_01_F","C_Hatchback_01_sport_F","I_MRAP_03_F","B_Heli_Light_01_F","B_Heli_Transport_03_unarmed_F","I_Heli_light_03_unarmed_F","O_Heli_Light_02_unarmed_F","B_Heli_Transport_01_F"]) && !isNil {vehicle player getVariable "lights"} && ((driver vehicle player) == player) && (vehicle player getVariable ["lights", false]) ']];  
    
  • J’ai le truc pour mettre les sirenes dans le vehicules mais les sirenes ne se mettent pas en route :/

  • @Fridom Allumer les Lights pas le son :)

  • Il faut ajouter koi pour allumer le son aussi ?

  • up svp je voudrais la rep aussi

  • Ba tu allume le son avec la touche F c’est sa non ? Ou pour que sa allume la sirene plus les lumieres ?

  • non mais enfaite j’aurais voulus faire un boutons

    CODE 1 qui activerai sirene et gyrophare

    CODE 2 qui activerai que les gyrophare

    CODE 3 qui desactiverai tout

    et je voudrais enlever le F pour mettre la sirene et le SHIFT+L pour mette les gyrophare

  • @aazerty123 dès que j’ai mon materiel je testerais mes codes pour toi

  • oki merki

  • alors tu a pus tester ?

  • nn j’ai mon matériel toute a l’heure (l’ordi)

  • Le français le dit, gyphare = lupiote et sirène = animal maritime ( :P )

  • @aazerty123 dès que j’ai mon materiel je testerais mes codes pour toi

    Mon code …

  • Moi dsl mais mon code que j’ai fais ne marche pas. @Shems aurais tu le code pour allumer/eteindre les lights et les sirenes en même temps avec la molette ?

  • Oui, je le post ce soir (si j’ai de la memoire)…

Messages 87Vues 10048