Jump to content

barn

Member
  • Content Count

    23
  • Joined

  • Last visited

  • Medals

Posts posted by barn


  1. 1 enableChannel true;

     

    Where should i put this ? in the ini.sqf or at the begining of my script ?

     

    Ok I think i find something:

     

    Work:

     

    _unit = _this select 0;
    [_unit," Voilà une information intéressante. Ca nous fait une belle jambe."] remoteExec ["sideChat",0];

    Doesn't work:
     

    _unit = _this select 0;
    
    _unitName = name _unit;
    [_unitName,"Voilà une information intéressante. Ca nous fait une belle jambe."] remoteExec ["sideChat",0];

    Doesn't work either with :

    _unit = _this select 0;
    [_unit," Voilà une information intéressante. Ca nous fait une belle jambe."] remoteExec ["sideChat",-2];

     

    What exactly is the "-2" ?


  2. 12 hours ago, ZaellixA said:

    One last thing. Please try to format your code in the forums to make it somewhat more readable.

     

    Sorry about that. I'll try to be more careful on the futur!

     

    Thanks both of you! I tried like this:

    [
    	puitdevin,
    	"<t color='#00FF00'>SEARCH</t>", 
    	"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_requestleadership_ca.paa",
    	"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_requestleadership_ca.paa",
    	"_caller distance _target < 3",
    	"_caller distance _target < 3",
    	{}, 
    	{},
    	{
    		[_caller] execVM "randompuits.sqf";
    		[(_this select 0),(_this select 2)] remoteExec ["bis_fnc_holdActionRemove",[0,-2] select isDedicated,true];
    	},
    	{},
    	[], 
    	2,
    	0,
    	true, 
    	false
    ] call BIS_fnc_holdActionAdd; 

    AND for testing I put this in my SQF:

     

    _unitName = _this select 0;
    
    [_unitName,"Voilà une information intéressante. Ca nous fait une belle jambe."] remoteExec ["sideChat",-2];
    
    format ["%1 TEST", _unitName] remoteExec ["hint"];

    And the HINT works! The name of the _caller appears. So it's apparently a sidechat code problem.. But i don't understand bescause it's the right way.. The sidechat isn't displayed at all. And no errors appears.

    Any idea ?


  3. So! Me again with this script.

     

    In the init object field i have now a perfect working script thanks to you guys 😉 :

    Quote

    [puitdevin,"<t color='#00FF00'>SEARCH</t>", "\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_requestleadership_ca.paa","\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_requestleadership_ca.paa","_this distance _target < 3","_this distance _target < 3",{}, {},{[_this select 1] execVM "randompuits.sqf";[(_this select 0),(_this select 2)] remoteExec ["bis_fnc_holdActionRemove",[0,-2] select isDedicated,true];},{},[], 2,0,true, false] call BIS_fnc_holdActionAdd;

     

    I'm trying now to pass the parameter _this select 1 from BIS_fnc_holdActionAdd to the script "randompuits.sqf".

     

    In my SQF:

    Quote

    _unitName = _this select 0;

    [_unitName,"Voilà une information intéressante. Ca nous fait une belle jambe."] remoteExec ["sideChat",-2];

     

    But nothing happend.

    If i'm not mistaking, for ExecVM the param is _this select 0 and i bring it from the BIS_fnc_holdActionAdd _this select 1.

    Can you help me to understand this?


  4. Hi!

     

    So i've finally had the time to make a test.

     

    HazJ, your script return an error "Error ] missing" on line :} forEach allPlayers - entities "HeadlessClient_F";

     

    So i tried with a execVM in the ini of the player and your script in a file "test.sqf". And now the error appears when the mission start. And i start the mission at the trigger without activating the action in my menu.

     

    EDIT: ok i tried with an other player in MP and with this command:

     

    Quote

    this addAction ["<t color='#00FF00'>ENTER WITH PLAYERS</t>",{{if (_x In allPlayers) then {if (_x inArea triggertower) then {_x setPos [(getPos Obelisk1 select 0) +5, (getPos Obelisk1 select 1) +0, (getPos Obelisk1 select 2) +2];};};} forEach allPlayers - entities "HeadlessClient_F"; setDate [2002, 4, 12, 23, 0];},nil,1.5,true, true,"", "true", 3, false, "", ""];

     

    Same result: The time change, the getpos is not working...

     


  5. Hi! Thanks for the reply it helps a lot !

     

    So i tried as you said and had some params to fix the distance view and change the date when activate:

     

    Quote

    this addAction
    [
        "<t color='#00FF00'>ENTER WITH PLAYERS</t>",
        {
            {
                if (_x In allPlayers) then {
                    if (_x inArea triggertower) then {
                        _x setPos [(getPos Obelisk1 select 0) +5, (getPos Obelisk1 select 1) +0, (getPos Obelisk1 select 2) +2];
                    };
                };
            } forEach allUnits; setDate [2002, 4, 12, 23, 0];
        },
        nil,
        1.5,
        true,
        true,
        "",
        "true",
        5,
        false,
        "",
        ""
    ];

     

    And compress it for the init of an object on mission:

    Quote

    this addAction ["<t color='#00FF00'>ENTER WITH PLAYERS</t>",{{if (_x In allPlayers) then {if (_x inArea triggertower) then {_x setPos [(getPos Obelisk1 select 0) +5, (getPos Obelisk1 select 1) +0, (getPos Obelisk1 select 2) +2];};};} forEach allUnits; setDate [2002, 4, 12, 23, 0];},nil,1.5,true, true,"", "true", 3, false, "", ""];

     

    No errors so far, so i will try it in MP !

    Thanks again!

     


  6. Hi everyone!

    Quick question:

    I have an addaction on an object "teleport with players nearby"

    I have a marker named: triggertower

    When i execute the action, it's suppose to teleport all the players in the marker on the object

     

    So i made a script like this:
     

    Quote

    this addAction ["ENTER WITH PLAYERS", {{if (isPlayer _x) then { if (_x inArea triggertower) then { _x setPos [(getPos Obelisk1 select 0) +5, (getPos Obelisk1 select 1) +0, (getPos Obelisk1 select 2) +2];}; }} forEach allUnits.

     

    It works on local and teleport the player, but on a server, no one is teleported not even the player doing the action.

     

    Can anybody help me understand what I am doing wrong ?

    Thanks.

     


  7. Hi,

     

    I need help for 2 questions please. I can't find the answer by searching the forum. I have 4 objects with this action "hack" and when the 4 computers are hacked, it's supposed to start an evac script.

     

    On one of the computer ini

    Quote

    hacking1 = [computer1,"<t color='#00FF00'>HACK COMPUTER</t>", "\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_unbind_ca.paa", "\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_unbind_ca.paa", "_this distance _target < 4","_caller distance _target < 4",{[["HACKING IN PROGRESS..."],safeZoneX, safeZoneH / 2,true,"<t font='PuristaBold'>%1</t>",[],{ false },true] spawn BIS_fnc_typeText2;},{},{ [] execVM "hacking.sqf" },{},[],10,0,true,false] call BIS_fnc_holdActionAdd;

     

    In my hacking.sqf file i wrote this

     

    Quote

    [hacking1,10 ] call BIS_fnc_holdActionRemove;

    hackingcount = hackingcount +1;

    if (hackingcount == 4) then
    { //script evac

    };

     

    In my init.sqf i wrote this

    Quote

    hackingcount = 0;

     

    So my first question is how can i detect in my script if the action is start by computer 1 or 2 or 3 or 4 and how can i check that the 4 computers are hack.

    And second question: the hackingcount is working in local and start the evac script but not in MP. Is there an other way to do it for MP?

     

    Thanks a lot for your help guys.

     

     

     


  8. Thanks Raptor for your mirror wink_o.gif

    Ofp.info will probably create mirror too if they put this island in news !

    If someone make or had missions on one of this island: Saint Remy, Torment Valley or Star light could you informe me ? I I seek somebody who make missions because i'm not very good to make missions whistle.gif

×