Jump to content


  • Content Count

  • Joined

  • Last visited

  • Medals

Community Reputation

635 Excellent

About sarogahtyp

  • Rank
    Sergeant Major

Profile Information

  • Gender
  • Location
    Berlin, Germany
  • Interests
    arma :-)

Recent Profile Visitors

2927 profile views
  1. private _enemyGroup = [_pos, EAST, 7 ] call BIS_fnc_spawnGroup; private _enemyUnits = units _enemyGroup; { _x disableAI "Target"; } count _enemyGroup; private _players = allPlayers select {alive _x}; private _playerDistances = _players apply { private _plyr = _x; private _groupDistances = _enemyGroup apply { [_x distanceSqr _plyr, _x] }; _groupDistances sort true; [_groupDistances#0#1, _x, _groupDistances] }; _playerDistances sort true; private _enemyUnitsNotUsed = +_enemyUnits; scopeName "OutOfLoop"; { private _plyr = _x#1; _d = { if ( (_x in _enemyUnitsNotUsed) && { [_x, "VIEW"] checkVisibility [eyePos _x, eyePos _plyr] > 0 } ) then { _x doTarget _plyr; _enemyUnitsNotUsed = _enemyUnitsNotUsed - _x; }; if (_enemyUnitsNotUsed isEqualTo [] ) then {breakTo "OutOfLoop"}; } count _x#2; }count _playerDistances; WORK IN PROGRESS!
  2. not tested: private _group = [_pos, EAST, 7 ] call BIS_fnc_spawnGroup; private _units = units _group; private _unitIndex = _units findIf {["VIEW"] checkVisibility [eyePos _x,(AGLToASL _markerpos) vectorAdd [0,0,1.5]] > 0}; if (_unitIndex > -1) then { private _unit = _units select _unitIndex; _unit do something; };
  3. sarogahtyp

    Help with creating a array.

    myWantedCoolValue is a placeholder for whatever value u want those variable to have on init
  4. sarogahtyp

    Help with creating a array.

    _checkTime = 30; //check all 30 seconds for new objects allNeededObjectsAreSpawned = false; // set this to true to stop searching for private _classNames = ["land_sandbag_F", "Concretewall_long", "other_classname"] apply {toLower _x}; while {!allNeededObjectsAreSpawned} do { private _newObjects = allMissionObjects select { private _objClass = toLower (typeOf _x); private _obj =_x; (_classNames findIf { _x isEqualTo _objClass } > -1) && isNil {_obj getVariable "coolStuffVariableAsIWantItToHaveOnCoolObjects"} }; _d = {_x setVariable ["coolStuffVariableAsIWantItToHaveOnCoolObjects", myWantedCoolValue, true]} count _newObjects; sleep _checkTime; }; not tested but should set that variable to all new spawned objects
  5. sarogahtyp

    Help with creating a array.

    this can be used to set/get a variable on/of an object: https://community.bistudio.com/wiki/setVariable https://community.bistudio.com/wiki/getVariable you should just set those variable in ur sandbag-spawning-script...
  6. Your findif searches for the first player in the array which is in the area and does not see the object. At this point findif returns a value greater -1. You should search for the first player which sees it and show ur hint if the return value is -1 Also for performance reasons u should not use allPlayers but (allPlayers select {_x inArea ...}) if ( (allPlayers select { _x inArea [_marker,550,550,0,false] }) findIf { [objectParent _x, "VIEW"] checkVisibility [eyePos _x, (AGLToASL _marker) vectorAdd [0,0,1.5]] > 0 } isEqualTo -1) then { "x don't see the location" remoteExec ["hint"]; }; not tested
  7. The solution could be a global variable wherein u store all groups. In your setTriggerStatements-part u can't use the _x of the outer scope in the strings because that _x is not known there on the time of execution. You have to use a global variable to get the desired groups there.
  8. sarogahtyp

    unitTurret wiki correct?

    Thus command delivers all information about a vehicles crew and seats: https://community.bistudio.com/wiki/fullCrew
  9. sarogahtyp

    Trouble with say3D

    Thats just realism: https://en.wikipedia.org/wiki/Doppler_effect
  10. u have to build a mission with it... scripts are working in missions only and not by adding them to armas root folder.
  11. _nameString = ... <- name of ur desired player _playerObject = allPlayers select ( allPlayers findIf {(name _x) isEqualTo _nameString;} );
  12. sarogahtyp

    Enter a locked Vehicle

    If (side player isEqualTo civilian) then {player moveInAny _vehicleObject;}; this is not the solution but could be part of it. A good way to get a specific answer is to ask a specific question AND to show what you tried already. Only very few guys will do all the work for you and give you your all-in-one-solution...
  13. https://community.bistudio.com/wiki/serverCommand https://community.bistudio.com/wiki/Multiplayer_Server_Commands#Commands
  14. sarogahtyp

    Ai planes

    it's not the best idea to choose such a complex scenario to create if one has no idea how anything of it could be done... This is the way to go: https://forums.bohemia.net/forums/topic/229245-scripting-guides-tutorials-compilation-list/ https://forums.bohemia.net/forums/topic/183993-scripting-introduction-for-new-scripters/