Results 1 to 3 of 3
  1. #1
    rGAERGAErgergergerg's Avatar
    Join Date
    Jul 2012
    Gender
    male
    Posts
    49
    Reputation
    10
    Thanks
    5
    My Mood
    Amused

    Anyone Know A Menu With Player Control? Or How To Add This Code To A Menu?

    _mycv = cameraView;

    _n2sh = 10;
    _n2c = "Select Player:";
    shnext = false;
    nlist = [];
    selecteditem = "";

    if (isNil "spectate") then {spectate = true;} else {spectate = !spectate;};
    if (spectate) then
    {

    {if (_x != player) then {nlist set [count nlist, name _x];};} forEach playableUnits;

    shnmenu =
    {
    _pmenu = [["",true],[_n2c, [-1], "", -5, [["expression", ""]], "1", "0"]];
    for "_i" from (_this select 0) to (_this select 1) do
    {_arr = [format['%1',nlist select (_i)], [_i - (_this select 0) + 2], "", -5, [["expression", format["selecteditem = nlist select %1;",_i]]], "1", "1"];_pmenu set [_i+2, _arr];};
    if (count nlist > (_this select 1)) then {_pmenu set [(_this select 1)+2, ["Next", [12], "", -5, [["expression", "shnext = true;"]], "1", "1"]];}
    else {_pmenu set [(_this select 1)+2, ["", [-1], "", -5, [["expression", ""]], "1", "0"]];};
    _pmenu set [(_this select 1)+3, ["Exit", [13], "", -5, [["expression", "selecteditem = 'exitscript';"]], "1", "1"]];
    showCommandingMenu "#USER:_pmenu";
    };
    _j = 0; _n2sh = 10; if (_n2sh>9) then {_n2sh=10;};
    while {selecteditem==""} do
    {
    [_j,(_j+_n2sh) min (count nlist)] call shnmenu;_j=_j+_n2sh;
    WaitUntil {selecteditem!="" or shnext};
    shnext = false;
    };


    if (selecteditem!= "exitscript") then
    {
    _name = selecteditem;
    {
    if(format[name _x] == _name) then
    {
    _player = player;
    [_x] join group player;
    player remoteControl effectiveCommander _x;
    selectPlayer _x;

    F3_EH = (findDisplay 46) displayAddEventHandler ["KeyDown","if ((_this select 1) == 0x3D) then {spectate = false;};"];
    (vehicle _x) switchCamera "EXTERNAL";
    titleText ["Controlling...Press F3 to get back to your body","PLAIN DOWN"];titleFadeOut 4;
    player remoteControl _x;

    waitUntil { !(alive _x) or !(alive player) or !(spectate)};
    (findDisplay 46) displayRemoveEventHandler ["KeyDown", F3_EH];

    objNull remoteControl effectiveCommander _x;
    player switchCamera _mycv;
    selectPlayer _player;
    };
    } forEach playableUnits;
    };
    spectate = false;

    };
    if (!spectate) then
    {
    titleText ["Back to player...","PLAIN DOWN"];titleFadeOut 4;

  2. #2
    Willybob's Avatar
    Join Date
    Jan 2013
    Gender
    male
    Location
    C:\MPGH\Simplicity.
    Posts
    284
    Reputation
    10
    Thanks
    174
    My Mood
    Amused
    please put the code in spoiler tags

  3. #3
    rGAERGAErgergergerg's Avatar
    Join Date
    Jul 2012
    Gender
    male
    Posts
    49
    Reputation
    10
    Thanks
    5
    My Mood
    Amused
    Quote Originally Posted by Willybob View Post
    please put the code in spoiler tags
    hOW DO i MAKE A SPOILER :/ SORRY

Similar Threads

  1. [Tutorial] How to add Sprites in a D3D Menu!
    By Swag in forum CrossFire Hack Coding / Programming / Source Code
    Replies: 60
    Last Post: 08-10-2013, 05:45 AM
  2. [Help] Anyone know any servers with BE disbled?
    By OoMarkLoO in forum DayZ Mod & Standalone Hacks & Cheats
    Replies: 0
    Last Post: 12-19-2012, 09:28 AM
  3. Does anyone know how to play music with out useing your mic??
    By dk173 in forum Suggestions, Requests & General Help
    Replies: 14
    Last Post: 02-02-2010, 06:21 AM
  4. does anyone knows with a server with no pb?
    By duva in forum Call of Duty 4 - Modern Warfare (MW) Hacks
    Replies: 4
    Last Post: 03-16-2009, 04:34 PM
  5. Anyone know how to shot with knockels?
    By EyalZamir in forum WarRock Korea Hacks
    Replies: 9
    Last Post: 05-20-2007, 12:12 PM