Jump to content

Ibragim A

Member
  • Content Count

    192
  • Joined

  • Last visited

  • Medals

Community Reputation

148 Excellent

About Ibragim A

  • Rank
    Sergeant

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. red army, your code doesn't work for several reasons: 1) you run the code with a sleep and while loop in an environment that does not accept these commands. In order to stop and loop the script, you need to spawn it or run it using execVM command. See: Scheduled Environment 2) the block in the count command should return true, but your block does not return anything, therefore the script does not work. See: count (Alternative Syntax), deleteVehicle (Main Syntax Return Value) So, try this code in init.sqf: [] spawn { waitUntil {time > 5}; while {true} do { { if ({alive _x} count crew _x < 1) then { deleteVehicleCrew _x; deleteVehicle _x; }; } forEach (nearestObjects [player,["Air"],14000]) sleep 5; }; };
  2. Use weaponsItemsCargo and magazinesAmmoCargo: _countWeapons = count ((weaponsItemsCargo ammo_box_1) select {typeOf _x == "arifle_Katiba_F"}); _countMagazines = count ((magazinesAmmoCargo ammo_box_1) select {_x == "30Rnd_65x39_caseless_green"});
  3. Ibragim A

    scrpting helicopter waypoints

    use this code (after creating of the crew of your patrol heli): (driver _veh) disableAI "LIGHTS"; _veh setPilotLight true;
  4. Ibragim A

    scrpting helicopter waypoints

    The script works with the BMP, because there is a commander in the crew of the BMP, but in helicopter there are only two pilots. Therefore, the script defines the helicopter pilot group as not existing, and therefore, the pilot does not receive waypoints. private _veh = createVehicle ["O_Heli_Light_02_dynamicLoadout_F", [0,0,0],["MKH1"]]; //create crew and group with vehicle createVehicleCrew _veh; private _grp = group driver _veh; //await 2 minute before helo move //private _hour = time + 180; waituntil { time >= 120 }; //create waypoints on empty marker position private _wpp = _grp addWaypoint [getMarkerPos "MKH2", 0]; _wpp setWaypointType "MOVE"; _wpp setWaypointSpeed "LIMITED"; _wpp setWaypointBehaviour "SAFE"; private _wpp = _grp addWaypoint [getMarkerPos "MKH3", 0]; _wpp setWaypointType "MOVE"; _wpp setWaypointSpeed "LIMITED"; _wpp setWaypointBehaviour "SAFE"; // on last waypoint helo land and crew disembark private _wpp = _grp addWaypoint [getMarkerPos "MKH4", 0]; _wpp setWaypointType "GETOUT"; _wpp setWaypointSpeed "LIMITED"; _wpp setWaypointBehaviour "SAFE";
  5. Ibragim A

    scrpting helicopter waypoints

    Show the script here. We can wonder for a long time where you make a mistake without it.
  6. Pay attention to your variables. You didn't use some variables correctly. _x from forEach is not passed to the event handler. Also, your HITECT variable is updated after each handler is added, and then you use it already updated for all units. Although in fact you don't need it at all, because it is passed to the handler code in the form of the _thisEventHandler variable. { _x addEventHandler [ "HitPart", { (_this select 0) params ["_target", "_shooter", "_projectile", "_position", "_velocity", "_selection", "_ammo"]; if (((_ammo select 4) in ["vn_560x15","vn_762x51"])) exitWith { [STB, ["MONOHIT",5]] remoteExec ["say3D", 0]; _target removeEventHandler [_thisEvent, _thisEventHandler]; }; } ]; } forEach (allUnits select {alive _x && (side _x) == east});
  7. Yes, there was a mistake in my code there: {typeOf _x == "rhsusf_m113_usarmy" && alive _x} count units convoyGroup == 0
  8. Make the convoy group variable global so that it can be used in the trigger activation code. {typeOf _x == "rhsusf_m113_usarmy" && !alive _x} count units convoyGroup == 0
  9. But in general, I advise you to read about the following commands: addWaypoint setWaypointType waypoint type Get In Nearest leaveVehicle setUnloadInCombat
  10. Try this mod - a lot of what you want to do can be done easily and simply in real time.
  11. Ibragim A

    condition any group member

    this addEventHandler ["EnemyDetected", { params ["_group", "_newTarget"]; if ({leader _group knowsAbout _x > 0} count units group _newTarget == 1) then { leader _group sideChat "Enemy detected!"; _soundFile = selectRandom ["in2a.ogg","in2b.ogg","in2c.ogg"]; playSound3D ["\A3\Dubbing_Radio_F\Sfx\" + _soundFile, player]; [] spawn { sleep 3; _soundFile = selectRandom ["out2a.ogg","out2b.ogg","out2c.ogg"]; playSound3D ["\A3\Dubbing_Radio_F\Sfx\" + _soundFile, player]; }; }; }]; this addEventHandler ["CombatModeChanged", { params ["_group", "_newMode"]; if (_newMode == "COMBAT") then { leader _group sideChat "Combat!"; _soundFile = selectRandom ["in2a.ogg","in2b.ogg","in2c.ogg"]; playSound3D ["\A3\Dubbing_Radio_F\Sfx\" + _soundFile, player]; [] spawn { sleep 3; _soundFile = selectRandom ["out2a.ogg","out2b.ogg","out2c.ogg"]; playSound3D ["\A3\Dubbing_Radio_F\Sfx\" + _soundFile, player]; }; }; }]; this addEventHandler ["UnitLeft", { params ["_group", "_oldUnit"]; if !(alive _oldUnit) then { leader _group sideChat "Lost one!"; _soundFile = selectRandom ["in2a.ogg","in2b.ogg","in2c.ogg"]; playSound3D ["\A3\Dubbing_Radio_F\Sfx\" + _soundFile, player]; [] spawn { sleep 3; _soundFile = selectRandom ["out2a.ogg","out2b.ogg","out2c.ogg"]; playSound3D ["\A3\Dubbing_Radio_F\Sfx\" + _soundFile, player]; }; }; }];
  12. Ibragim A

    condition any group member

    Don't use a trigger - use an event handler. In the initialization of the group, enter this code: this addEventHandler ["EnemyDetected", { params ["_group", "_newTarget"]; leader _group sideChat "Enemy detected!"; }]; this addEventHandler ["CombatModeChanged", { params ["_group", "_newMode"]; if (_newMode == "COMBAT") then {leader _group sideChat "Combat!"}; }]; this addEventHandler ["UnitLeft", { params ["_group", "_oldUnit"]; if !(alive _oldUnit) then {leader _group sideChat "Lost one!"}; }];
  13. I searched the forum, in the list of commands and functions, but could not find the answer. I am interested in whether there is a function or module that makes such icons on the map, when hovering over which the user can see more detailed information?
  14. Ibragim A

    artillery barrage script

    By the way, some time ago I discovered that the doArtilleryFire creates an invisible unknown enemy in place of the position and shoots at it in fact. I discovered this when I added an "EnemyDetected" event handler to the artillery group.
  15. Steam: https://steamcommunity.com/sharedfiles/filedetails/?id=2952853824 Tags: SP - Milsim - New Mechanics - Command Platoon Commander 2 mod gives the player the opportunity to command a platoon consisting of a player squad and three AI squads. With this mod, an ordinary [SP] mission with a linear plot can be turned into complete freedom of action up to multi-stage planning from landing to evacuation. About this mod in a nutshell: You get the opportunity to take command of friendly groups and manage them in much the same way as you manage the units of your group. Plus you get a number of new features. What you need to know: This mod is not about how to press the W key and LMB. Platoon Commander 2 shifts the gameplay vector from arcade, shooter and action to tactics and strategy. Platoon Commander 2 forces the player to monitor the actions of several squads, while the player himself rarely engages in battle personally. The player must learn how to use platoon squads as additional "hands" to solve different types of tactical tasks. Missions built with this mod are distinguished by freedom of action and collective synchronous actions of several squads. // This mod gives the player the opportunity to perform some actions that may disrupt the plot planned by the mission makers, like: // [*] make units of other groups join player and AI groups, including plot units // [*] join friendly groups to the platoon, including plot groups // [*] move units of your group or AI groups to other groups Differences from the old Platoon Commander mod: This mod can be used in all missions, not just those that were created with it initially. This mod can be used not only by mission makers, but by any user. This mod allows you to add or remove groups from the platoon at any time in the scenario. This mod adds voice-over of radio messages between platoon squads. This mod greatly (!) simplifies platoon control (control identical to vanilla). This mod saves vanilla control menus and complements them a little. This mod does not assign a specific role to specific squads. Any squad can have any purpose. This mod significantly saves performance. This mod adds some new features (a group of escorted persons, storage boxes, static weapons, etc.). This mod includes a more detailed platoon command bar. This mod limits the number of units in platoon squads (8) and the number of squads in platoon (4). There is no planning and rally points in this mod. There are no extended actions for the player's group in this mod. Languages: English Russian How to use: Put 1, 2, 3 or 4 groups. Then put the module Platoon Commander 2 and fill it in. Or just launch any mission and make groups join the platoon manually. Tutorial: Single Player >> Showcases >> Platoon Commander 2 - Tutorial. New player actions: Detonation of planted explosives by choice (not just all at once) The ability to exchange weapons with the group's units and others. New tactics of AI squads: Search of the dead Blowing up (buildings, boxes, bridges, railway, etc.) Mining of roads Retreat Occupation of buildings and others. New modes: Fire at the player's signal (for the player's group and AI groups) Running without returning fire (Go Go Go!) New action strategy: Command of the entire platoon in real time. A wide range of actions and tactics. The ability to plan actions at your discretion, not limited to linear plots. Synchronous actions, support by mortar, helicopters, armored vehicles and anything else. Settings: Complete freedom in platoon customization About 50 customizable gameplay and visualization parameters Visualization: Chat between platoon squads and their voiceover Use of appropriate animations and gestures Control via a vanilla-like command menu Ability to translate into other languages Optimization: Loops in scripts are made in such a way that they almost do not affect the frame rate Triggers are not used A special function for the stucked/bagged groups/fighters /* The mod includes a number of my other mods (do not add them): [*] Slow-Motion Menu [*] Fire on My Command [*] Go Go Go Mode [*] Stretch Grenade [*] Smoke and signal grenades behind the belt [*] Switch Weapons [*] Separate Detonator for ED [*] Capture Your Enemies */ Images:
×