Jump to content

Dan86

Member
  • Content Count

    41
  • Joined

  • Last visited

  • Medals

Posts posted by Dan86


  1. You can try with following values:

    MinBandwidth= 10000000

    MaxBandwidth= 20000000

    MaxMsgSend = 512

    MaxSizeGuaranteed = 256

    MaxSizeNonguaranteed = 128

    Thats something for begin with. But you may need tweak those values to get best results depending on how many ppl gonna be on the server.

    Also you may wanna check out wiki for more detailed description.

    http://community.bistudio.com/wiki/basic.cfg

    heres a part of it:

    MaxMsgSend=<limit>;

    Maximum number of messages that can be sent in one simulation cycle.

    Increasing this value can decrease lag on high upload bandwidth servers.

    Default: 128

    MaxSizeGuaranteed=<limit>;

    Maximum size of guaranteed packet in bytes (without headers). Small messages

    are packed to larger frames. Guaranteed messages are used for non-repetitive

    events like shooting.

    Default: 512

    MaxSizeNonguaranteed=<limit>;

    Maximum size of non-guaranteed packet in bytes (without headers).

    Non-guaranteed messages are used for repetitive updates like soldier or

    vehicle position. Increasing this value may improve bandwidth requirement,

    but it may increase lag.

    Default: 256

    MinBandwidth=<bottom_limit>;

    Bandwidth the server is guaranteed to have (in bps). This value helps server

    to estimate bandwidth available. Increasing it to too optimistic values can

    increase lag and CPU load, as too many messages will be sent but discarded.

    Default: 131072

    MaxBandwidth=<top_limit>;

    Bandwidth the server is guaranteed to never have. This value helps the server

    to estimate bandwidth available.

    MinErrorToSend=<limit>;

    Minimal error to send updates across network. Using a smaller value can make

    units observed by binoculars or sniper rifle to move smoother.

    Default: 0.01

    MaxCustomFileSize=<size_in_bits>;

    Users with custom face or custom sound larger than this size are kicked when

    trying to connect.


  2. Thanks man, this worked.

    For any more interested in respawning air vehicle folded and locked.

    //Cobra Fold
    _vehicle = _this select 0;
    if (isengineOn _vehicle) exitwith {hint format ["Cannot fold when engine is running %1!", _type_name]};
    _vehicle animate ["mainrotor_folded",0];
    _vehicle animate ["mainrotor_unfolded",1];
    _vehicle animate ["rotorshaft_unfolded",1];
    _vehicle setVehicleLock "LOCKED";
    

    //Cobra UnFold
    _vehicle = _this select 0;
    if (isengineOn _vehicle) exitwith {hint format ["Cannot fold when engine is running %1!", _type_name]};
    _vehicle animate ["mainrotor_folded",1];
    _vehicle animate ["mainrotor_unfolded",0];
    _vehicle animate ["rotorshaft_unfolded",0];
    _vehicle setVehicleLock "UNLOCKED";

    //Osprey fold
    _vehicle = _this select 0;
    if (isengineOn _vehicle) exitwith {hint format ["Cannot fold when engine is running %1!", _type_name]};
    _vehicle setVehicleLock "LOCKED";
    _vehicle = [_vehicle,1] execvm "\ca\air2\mv22\scripts\pack.sqf";

    //Osprey Unfold
    _vehicle = _this select 0;
    if (isengineOn _vehicle) exitwith {hint format ["Cannot fold when engine is running %1!", _type_name]};
    _vehicle = [_vehicle,0] execvm "\ca\air2\mv22\scripts\pack.sqf";
    _vehicle setVehicleLock "UNLOCKED";

    //UH1Y Fold
    _vehicle = _this select 0;
    if (isengineOn _vehicle) exitwith {hint format ["Cannot fold when engine is running %1!", _type_name]};
    _xtype = [_vehicle,1] execVM "\Ca\air2\UH1Y\Scripts\fold.sqf";
    _vehicle setVehicleLock "LOCKED";

    //UH1Y UnFold
    _vehicle = _this select 0;
    if (isengineOn _vehicle) exitwith {hint format ["Cannot fold when engine is running %1!", _type_name]};
    _xtype = [_vehicle,0] execVM "\Ca\air2\UH1Y\Scripts\fold.sqf";
    _vehicle setVehicleLock "UNLOCKED";

    You can call this scripts when vehicle gets respawned by Xeno respawn script.

    This is for Cobra (ahfold.sqf is the name of folding cobra file)

    Cobra init:

    handle = [this, 220] execVM "x_scripts\x_vehirespawnAH.sqf"; nul=[this,1] execVM "ahfold.sqf"; this addAction ["Fold", "ahfold.sqf", [], 0, false, true, ""]; this addAction ["Unfold", "ahunfold.sqf", [], 0, false, true, ""];
    

    // by Xeno
    private ["_delay","_disabled","_moved","_newveh","_startdir","_startpos","_type","_vehicle"];
    if (!isServer) exitWith{};
    
    _vehicle = _this select 0;
    _delay = _this select 1;
    _moved = false;
    _startpos = getpos _vehicle;
    _startdir = getdir _vehicle;
    _type = typeof _vehicle;
    
    while {true} do {
    sleep (_delay + random 15);
    
    _moved = (if (_vehicle distance _startpos > 5) then {true} else {false});
    
    _empty = (if (({alive _x} count (crew _vehicle)) > 0) then {false} else {true});
    
    _disabled = (if (damage _vehicle > 0) then {true} else {false});
    
    if ((_disabled && _empty) || (_moved && _empty) || (_empty && !(alive _vehicle))) then {
    	deletevehicle _vehicle;
    	_vehicle = objNull;
    	sleep 0.5;
    	_vehicle = _type createvehicle _startpos;
    	_vehicle setpos _startpos;
    	_vehicle setdir _startdir;
    	_vehicle addAction ["Fold", "ahfold.sqf",[],0,false];
    	_vehicle addAction ["Unfold", "ahunfold.sqf",[],0,false];
    	[_vehicle] execVM "ahfold.sqf";
    	//_vehicle addeventhandler ["killed", {_this execVM "ahfold.sqf"}];
    };
    };
    


  3. Like in the topic:

    "respawnvehicle.sqf" calls "ahfold.sqf" to respawn with folded rotor.

    //respawnvehicle
    
    deletevehicle _vehicle;
    _vehicle = objNull;
    sleep 0.5;
    _vehicle = _type createvehicle _startpos;
    _vehicle setpos _startpos;
    _vehicle setdir _startdir;
    _vehicle addAction ["Fold", "ahfold.sqf",[],0,false];
    _vehicle addAction ["Unfold", "ahunfold.sqf",[],0,false];
    [b]_vehicle execVM "ahfold.sqf";[/b]
    

    //Fold
    
    _vehicle = _this select 0;
    _vehicle animate ["mainrotor_folded",0];
    _vehicle animate ["mainrotor_unfolded",1];
    _vehicle animate ["rotorshaft_unfolded",1];
    _vehicle setVehicleLock "LOCKED";
    

    however this dosn't work like i wish to work. Vehicle is being respawned without folded rotor and unlocked.


  4. This is for A10

    this fire "BombLauncherA10";

    put that code in waypoint init field. However this is pretty simple and can not work every time.

    Here is full script:

    ;Note: You have to put an empty Heli-H on the map called "ASTarget", and you have to place a //marker called "Firedirection". 
    ;If you want the Airstrike to hit a fixed position, just delete the 
    ;setfire-part and put the "ASTarget" on the position that you want to hit. Hope it works...
    _player = player;
    setfire=true;
    titleText ["Click on map to send coordinates","plain down"];
    onMapSingleClick "ASTarget setPos _pos; setfire=false";
    @!setfire;
    "Firedirection" setmarkerpos getPos ASTarget;
    onMapSingleClick "";
    titleText ["", "plain down"];
    ;=========DEFINE=======================
    _dropPosition = getpos ASTARGET;
    ~0.1
    _dropPosX = _dropPosition select 0;
    _dropPosY = _dropPosition select 1;
    _dropPosZ = _dropPosition select 2;
    ~0.1
    ;Aircraft1
    _planespawnpos = [_dropPosX -3000, _dropPosY, _dropPosZ + 200];
    _pilotspawnpos = [_dropPosX -3000, _dropPosY, _dropPosZ + 200];
    ~1.1
    ;Aircraft2
    _planespawnpos2 = [_dropPosX -3000, _dropPosY, _dropPosZ + 230];
    _pilotspawnpos2 = [_dropPosX -3000, _dropPosY, _dropPosZ + 230];
    ;=========CREATE=======================
    _PlaneG = creategroup WEST;
    _PlaneG2 = creategroup WEST;
    ~0.1
    _plane = createVehicle ["A10",_planespawnpos,[], 0, "FLY"];
    _plane setPos [(getPos _plane select 0),(getPos _plane select 1),200];
    _pilot = "USMC_Soldier_Pilot" createUnit [getMarkerPos "Firedirection", _PlaneG, "P1=this"];
    _plane setDir (getdir _player);
    _Plane setVelocity [220,0,0];
    _PlaneG = [_plane,1] execvm "CA\Data\ParticleEffects\SCRIPTS\misc\aircraftvapour.sqf";
    ~0.5
    _plane2 = createVehicle ["A10",_planespawnpos2,[], 0, "FLY"];
    _plane2 setPos [(getPos _plane2 select 0),(getPos _plane2 select 1),230];
    _pilot2 = "USMC_Soldier_Pilot" createUnit [getMarkerPos "Firedirection", _PlaneG2, "P2=this"];
    _plane2 setDir (getdir _player);
    _Plane2 setVelocity [220,0,0];
    _PlaneG2 = [_plane2,1] execvm "CA\Data\ParticleEffects\SCRIPTS\misc\aircraftvapour.sqf";
    ~0.1
    ;Aircraft1
    P1 moveinDriver _plane;
    P1 setDamage 0;
    P1 action ["gear_up", vehicle P1];
    _plane setSpeedMode "FULL";
    p1 setBehaviour "RED";
    ;Aircraft2
    P2 moveinDriver _plane2;
    P2 setDamage 0;
    P2 action ["gear_up", vehicle P2];
    _plane2 setSpeedMode "FULL";
    p2 setBehaviour "RED";
    ~1
    #CHECK
    ;hintsilent "Strafing with 30mm Anti-Personnel";
    ;Aircraft1
    _plane setVehicleAmmo 1;
    _plane fire "Gau8";
    ;Aircraft2
    _plane2 setVehicleAmmo 1;
    _plane2 fire "Gau8";
    ;Aircraft1
    _plane flyinheight 140;
    P1 doMove getPos ASTarget;
    P1 doTarget ASTarget;
    P1 doWatch ASTarget;
    P1 setBehaviour "RED";
    ? (_plane distance ASTarget) < 1300 : goto "DROP"
    ;Aircraft2
    _plane2 flyinheight 140;
    P2 doMove getPos ASTarget;
    P2 doTarget ASTarget;
    P2 doWatch ASTarget;
    P2 setBehaviour "RED";
    ? (_plane2 distance ASTarget) < 1300 : goto "DROP"
    goto "CHECK"
    ;=========FIRE=======================
    #DROP
    _i = 0
    ;Aircraft1
    _plane flyinheight 100;
    ;Aircraft2
    _plane2 flyinheight 100;
    #FIRE
    _i=_i+1
    ;Aircraft1
    _plane setVehicleAmmo 1;
    _plane fire "BombLauncherA10";
    ;Aircraft2
    _plane2 setVehicleAmmo 1;
    _plane2 fire "BombLauncherA10";
    ;hintsilent "Bombs Dropped";
    ~3
    ;Aircraft1
    ;p1 action ["useWeapon",vehicle _plane,driver vehicle p1,1];
    ;Aircraft2
    ;p2 action ["useWeapon",vehicle _plane2,driver vehicle p2,1];
    ? _i <= 6 : goto "FIRE"
    ;=========FLY AWAY=======================
    ASTarget setPos [0,0,0];
    "Firedirection" setMarkerPos [0,0];
    ;Aircraft1
    _plane setSpeedMode "FULL";
    ;Aircraft2
    _plane2 setSpeedMode "FULL";
    ~5
    P1 doMove getPos ASTarget;
    P2 doMove getPos ASTarget;
    #Check2
    ;Aircraft1
    _plane flyinheight 200;
    ;Aircraft2
    _plane2 flyinheight 200;
    ;Aircraft1
    _plane setDamage 0;
    _plane setVehicleAmmo 1;
    _Plane setFuel 1;
    P1 setDamage 0;
    ? (_plane distance Player) > 2500 : goto "ENDE"
    ;Aircraft2
    _plane2 setDamage 0;
    _plane2 setVehicleAmmo 1;
    _Plane2 setFuel 1;
    P2 setDamage 0;
    ? (_plane2 distance Player) > 2500 : goto "ENDE"
    goto "Check2"
    ;=========DELETE========================
    #ENDE
    hintSilent "'A10' is returning to base - over";
    ;Aircraft1
    deleteVehicle _plane;
    deleteGroup _PlaneG;
    deleteVehicle P1;
    ;Aircraft2
    deleteVehicle _plane2;
    deleteGroup _PlaneG2;
    deleteVehicle P2;
    exitWith

    USAGE Note:

    You have to put an empty Heli-H on the map called "ASTarget", and you have to place a marker called "Firedirection".

    If you want the Airstrike to hit a fixed position, just delete the

    setfire-part and put the "ASTarget" on the position that you want to hit. Hope it works...


  5. Ammobox here is named "ammo".

    Parachute is named "para".

    You need to name both things, the name can be whatever you want.

    In ammobox init:

    ammo attachTo [para,[0,0,3]];

    In parachute init:

    this setpos [(getpos this select 0),(getpos this select 1),370];

    all you can find in editor, no need for other stuff, how ever this very "cheap" way to do it

    but you can write some easy script for that to delay or trigger drop.

    Anyway I think kylania did found some better way to do it.


  6. Or you can cover carrier area with trigger and tweak following code from Weasel [PXS] to match your needs.

    // Written by Weasel [PXS] - andy@andymoore.ca
    
    // This script rearms, refuels, and repairs vehicles.
    // Vehicles must be less than height 2 (typically landed, if air vehicles) and must remain in the
    // trigger area for 3 seconds. It then drains all fuel, repairs, rearms, and refuels.
    //
    // Setup a trigger area to activate this (F3 in map editor) with the following settings:
    //
    // Trigger REPEATEDLY, BLUFOR, PRESENT
    // Name: Rearmlist
    // Condition: this;
    // Activation: {[_x] execVM "rearm.sqf"} foreach thislist;
    //
    // Warning: If this trigger area overlaps another trigger area (such as ammo-transport Scripts), sometimes
    // things don't work as planned. Keep this seperate if you can.
    
    _unit = _this select 0;
    
    // Don't start the script until the unit is below a height of 2, and make sure they hold that
    // height for at least 1 seconds.
    WaitUntil{(getPos _unit select 2)<2};
    sleep 1;
    if((getPos _unit select 2)>2 || not (_unit in list Rearmlist)) exitWith{};
    
    //_unit setFuel 0;
    _unit VehicleChat "Repairing...";
    sleep 3.5;
    _unit setDammage 0;
    _unit VehicleChat "Rearming...";
    sleep 3.5;
    _unit setVehicleAmmo 1;
    _unit VehicleChat "Refueling...";
    sleep 3.5;
    _unit setFuel 1;
    _unit VehicleChat "Finished.";
    
    if(true) exitWith{};


  7. You will find that variable in:

    i_server.sqf

    // allmost the same like above
    // first element the max number of ai "foot" groups that will get spawned, second element minimum number (no number for vehicles in group necessary)
    d_footunits_guard = [
    #ifndef __TT__
    [4,2], // basic groups
    [1,0] // specop groups
    #else
    [4,2], // basic groups
    [1,0] // specop groups
    #endif

    and much more...


  8. You can also use UPS script from Kronzky (urban patrol script), you only need make marker ex.200x200, and put:

    Required parameters:

    unit = Unit to patrol area (1st argument)

    markername = Name of marker that covers the active area. (2nd argument)

    In the init field of group leader you put:

    nul=[this,"town"] execVM "ups.sqf"

    and they start to patrol marker area random ways.

    There are also more parameters you can define:

    Optional parameters:

    random = Place unit at random start position.

    randomdn = Only use random positions on ground level.

    randomup = Only use random positions at top building positions.

    min:n/max:n = Create a random number (between min and max) of 'clones'.

    init:string = Custom init string for created clones.

    nomove = Unit will stay at start position until enemy is spotted.

    nofollow = Unit will only follow an enemy within the marker area.

    delete:n = Delete dead units after 'n' seconds.

    nowait = Do not wait at patrol end points.

    noslow = Keep default behaviour of unit (don't change to "safe" and "limited").

    noai = Don't use enhanced AI for evasive and flanking maneuvers.

    showmarker = Display the area marker.

    trigger = Display a message when no more units are left in sector.

    empty:n = Consider area empty, even if 'n' units are left.

    track = Display a position and destination marker for each unit.


  9. Yes medic animation was completed but mg was locked so i couldnt get in there. After setting it as UNLOCKED it was 90degree 'bug' afterthat tried setDir/getdir and it fix that problem.

    _player = plr6;
    _player playMove "AinvPknlMstpSlayWrflDnon_medic";
    waitUntil{!(alive _player) || animationState _player == "AinvPknlMstpSlayWrflDnon_medic"};
    if(alive _player)then{
    sleep 4;
    _newMG = createVehicle ["Fort_Nest_M240",(getPos _player),[],0,"NONE"];
    _newMG setDir (getdir _player);
    _newMG setVehicleLock "UNLOCKED"
    };

    Now works great, this wouldnt be possible without your help, thanks'a'ton Big Dawg


  10. Damn Big Dawg you're a real champ in that. Was some problems on beggining but i change the _player = plr6 to match the in game variable and it worked.

    But now when i set the "_newMG" as unlocked to be able to get in, solider look 90degress left, he is not looking forward where the gun is pointing, that is very strange.

    _player = plr6;
    _player playMove "AinvPknlMstpSlayWrflDnon_medic";
    waitUntil{!(alive _player) || animationState _player == "AinvPknlMstpSlayWrflDnon_medic"};
    if(alive _player)then{
    sleep 4;
    _newMG = createVehicle ["Fort_Nest_M240",(getPos _player),[],0,"CAN_COLLIDE"];
    _newMG setVectorDir (vectorDir _player);
    _newMG setVehicleLock "UNLOCKED"
    };


  11. Hello, i was wonering if there is any way to make for example MG gunner be able to put MG nest (like in domination from Xeno).I already tried the

    _this = player
    _this createvehicle "Fort_Nest_M240"
    _pos = getpos player
    _dir = getdir player
    player playMove "AinvPknlMstpSlayWrflDnon_medic";
    sleep 4;
    hint "DONE"
    

    but knowing my scripting skills this is not how it should look like, any ideas?


  12. Yea but when i start dedicated server without or with -profiles parameter it dosnt use difficulty setting i set up there. Looks like it loads default difficulty setting( and i dont like that i want enemy waste some ammo before they can hit me or any1 from squad, want battle more immersive with bullets soniccracks near my head not in my head after second shot of enemy AI)

    @echo on
    "D:\Gry\ArmA 2\arma2server.exe" -cpucount=4 -cfg=gca2dst_basic.cfg -config=server.cfg -profiles=C:\Users\Dan\Documents\ArmA 2 -name=Dan -port=2302 -mod=@editor;@my;@hifi -netlog
    FOR /F "TOKENS=1* DELIMS= " %%A IN ('DATE/T') DO SET DATE=%%B
    FOR /F "TOKENS=*" %%A IN ('TIME/T') DO SET TIME=%%A
    ECHO 3 %TIME% 0.33 %DATE%
    GOTO RESTART

×