Jump to content

thy_

Member
  • Content Count

    344
  • Joined

  • Last visited

  • Medals

Everything posted by thy_

  1. So you need a restrictive Supply/resupply system, where you can designate ammo/fuel ground vehicles to deliver limited supply where the source of that supply is a side-main-base where that supply is infinite. Hm...
  2. Wait. If I understood well, once you have a vehicle/plane/aircraft/helicopter/whatever with magazines or not, you VO can easily be any asset in Arma to rearming, refueling and repairing any air, ground, nautical or drone vehicles. Well... you know what you need. Cheers.
  3. @kibaBG you can use this script (below). I'm using the Aircraft Loadout associated with this down below exactly for what you're asking:
  4. thy_

    isNil forEach

    Trust me, I do with 50+ pages, including how works spawn-delay (this issue we are talking about). 😅 But you know only advanced editors will check documentation... Topic solved! 😎 See you at my next unsolved challenge, hehe.
  5. thy_

    isNil forEach

    This is the case! That sets an array because the user can add more than one trigger. They actually can do: [my_trigger_1, my_target_1, 10] // There are 3 ways to activate a spawn here: by trigger, by killing/destroying, by timer (minutes); The operation among the options is "OR", never "AND"; [my_trigger_1, my_trigger_2, my_trigger_3] // Max 3 elements. [my_target_1, my_target_2, my_target_3] [10] [0] or [] // no spawn delay, insta spawn Interesting. I will do some tests here now.
  6. thy_

    isNil forEach

    No worries. This post is all I need to find the problem! And be sure if I find where the inconsistency is, I register the information here. S2.
  7. thy_

    isNil forEach

    If there's that trigger, everything runs as expected: well. Yes, I'm aware of it. VSCode flags this thing. Just for example (below) but here in my code this is not the problem.
  8. thy_

    isNil forEach

    That was a typo. It should be: ["_spwnDelayMethods", [0]] or ["_spwnDelayMethods", []] That zero is important for other stuff. Anyway, that's why I'm checking each value this function is receiving once many levels of Mission Editors are using this script and might sometimes face typos where they have no clue what's happening. I don't get the question. Yes, I'm checking if it's an array. Why?
  9. thy_

    isNil forEach

    At first, thank you @mrcurry and @pierremgi to be here. Well, it's obvious I'm missing something, so let's show the entire flow from the row where we set the trigger (that should be a reference of a true Eden trigger) until the validation of that. Error itself: File where we set the trigger: THY_fnc_CSWR_add_group function: THY_fnc_CSWR_spawn_and_go function: Both files on GitHub (i think it's not needed but): https://github.com/aldolammel/Arma-3-Controlled-Spawn-And-Waypoints-Randomizr-Script/blob/main/cswr_for_your_mission/CSWRandomizr/fn_CSWR_population.sqf https://github.com/aldolammel/Arma-3-Controlled-Spawn-And-Waypoints-Randomizr-Script/blob/main/cswr_for_your_mission/CSWRandomizr/fn_CSWR_globalFunctions.sqf
  10. thy_

    isNil forEach

    Nothing yet... still printing out the same error. _spwnDelayMethods = [this_trigger_doesnt_exist]; { if ( isNil (str _x) ) exitWith { missionNamespace setVariable ["_x", nil]; }; } forEach _spwnDelayMethods; // Output: Arma is printing out the error "_x is an undefined variable!". nothing... same error. _spwnDelayMethods = [this_trigger_doesnt_exist]; { if ( isNull _x ) exitWith {}; } forEach _spwnDelayMethods; // Output: Arma is printing out the error "_x is an undefined variable!". Nothing, @mrcurry, both of your tries are printing out the same error! This this_trigger_doesnt_exist comes from Eden, so it should be not a string in the array. If I'm reading right on biki, isNil is the way to check it, and to use isNil this value (the variable-name of the trigger) should be a string. So I guess I am doing go about the isNil, but something I am clearly mission.
  11. thy_

    Help on "setFormation"

    This information should be on Biki too! 🙂 S2
  12. I found the problem. It should be fixed in this new released 😉 v2.5
  13. Hi there, Vehicles Overhauling (VO) is a system of repairing, refueling, and rearming vehicles by proximity and with any asset of your choice. Also, the services are divided by doctrine: Ground, Air, and Nautical. Each doctrine and even service is easily turned Off or On, according to the editor's needs. If needed, the editor can allow repairing just for ground vehicles while unavailable for air ones, for example. Triggering or code via Eden Editor is needless. VO is configured through only one file, prioritizing implementation simplicity and quick change management that the mission editor might want. How to install / Documentation: https://github.com/aldolammel/Arma-3-Vehicles-Overhauling-Script/blob/main/_VO_Script_Documentation.pdf What to expect from VO script: Set what vehicle type has automatic access to ground, air, or nautical services (rearm, repair, refuel); Set what service each station (asset) will provide: repair, refuel, or rearm or all of them (full service); Every object/asset on Eden Editor can be traceable as a station automatically, it's up to the mission-editor; Once configured which assets are stations, on Eden you just drag and drop the asset and the script will track them; All repair, refueling, and rearming of Arma 3 and its DLCs and CDLCs assets are already tracked; All repair, refueling, and rearming of RHS and CUP assets are already tracked as well; 100% compatible with CBA+ACE. No code or triggers are needed on Eden Editor; Just one file to set your mission easily: fn_VO_management.sqf; A parking-helper system for planes/jets, no matter where or what is the plane station (including carriers); Script working as gold on hosted and dedicated servers; The script automatically recognizes assets and their roles from: Arma 3; Expansion Apex; DLC Tanks; DLC Helicopters; DLC Karts; DLC Laws of War; DLC Contact; CDLC Western Sahara; CDLC Reaction Forces; CDLC Expeditionary Forces; Mod RHS; Mod CUP. Demo: Main file > fn_VO_parameters.sqf: Dependencies: None! Download: From Github: https://github.com/aldolammel/Arma-3-Vehicles-Overhauling-Script From Steam Workshop: https://steamcommunity.com/sharedfiles/filedetails/?id=2758919670 Missions running it: Tanks & Helicopters (Light) Tanks Theater TvT Bradley Furious - - - - - - - - - - - Changelog: Dec 7th 2024 - v2.5: news, fixes and notes here. Known issues: Critical > RHS on > Air Doctrine > RHS airplanes are NOT rearming properly. ------ (RHS was abandoned, so sorry!) Important > Dedicated Server > If two or more players are in the same armed vehicle, the vehicle will rearm two or more times after spending some ammo ------ (WIP) Important > ACE on > Repairing > If the vehicle got damage only in wheels/tracks, guns and/or turret, the repairing doesn't run; Minor > ACE on > Repairing > If the vehicle starts to cook off with a repair station too close, the vehicle gets repaired, but still cooking. Cheers, thy
  14. thy_

    isNil forEach

    Actually I am facing a similar issue here! All I need is to ignore or delete this "this_trigger_doesnt_exist" from the array _spwnDelayMethods. _spwnDelayMethods = [this_trigger_doesnt_exist]; { if ( isNil "_x" ) exitWith { missionNamespace setVariable ["_x", nil]; }; } forEach _spwnDelayMethods; // Output: Arma is printing out the error "_x is an undefined variable!".
  15. The script has been updated! The first message of the topic was updated too. v2.5 - Dec 7th 2024: - Fixed the "Error Undefined variable" in dedicated servers. Some publicVariables declarations were missing; - Added support for CDLC Western Sahara fuel, ammo, and repair assets; - Added support for CDLC Reaction Forces fuel, ammo, and repair assets; - Added support for CDLC Expeditionary Forces fuel, ammo, and repair assets; - Performance improvements; - The 'fn_VO_paremeters.sqf' file was renamed to 'fn_VO_management.sqf'; - New structure of folders to make the installation easier; - Documentation updated. New assets recognized automatically by VO script 😉
  16. Well, looking at how BIS built its BIS_fnc_wpArtillery function internally (via Eden Editor > Function viewer), I figured out there's a currentCommand returns that's not registered on the Wiki (?) and that makes totally difference to check if the vehicle team is shooting or not. That missing return is literally "FIRE AT POSITION". Not sure if another return (like "FIRE") has the same effect, I didn't test it. // If no more _fmTeam members are shooting, flag it: if ( currentCommand _veh isEqualTo "FIRE AT POSITION" ) then { _isNotShooting = false }; So, my solution was to include this snippet above each looping check and everything run as I needed without any publicVariable/global variable. Here is a simpler version of the real function built for the Dynamic Artillery Pieces (DAP) script, but the essential is here below: THY_fnc_DAP_firing = { // This function makes the specific fire-mission-team shelling down a specific target position once before return. // Returns true after all alive team vehicles shoot: bool. params ["_fmTeam", "_pos", "_rounds", "_mag"]; private ["_isNotShooting", "_veh", "_alreadyShoot"]; // Initial values: _isNotShooting = nil; _veh = objNull; _alreadyShoot = []; // Wait until no more _veh are shooting: waituntil { // Each new loop, assuming no one is shooting: _isNotShooting = true; // Check each unit in charge of _veh: { _veh = vehicle _x; // Escape > Skip those units that is not in charge in _veh: if ( _x isNotEqualTo (effectiveCommander _veh) ) then { continue }; // If _veh doesn't fire yet: if !(_veh in _alreadyShoot) then { // Fire: _veh doArtilleryFire [_pos, _mag, _rounds]; // Flag it already shoot: _alreadyShoot pushBack _veh; }; // If no more _fmTeam members are shooting, flag it: if ( currentCommand _veh isEqualTo "FIRE AT POSITION" ) then { _isNotShooting = false }; } foreach units _fmTeam; // Next check: sleep 10; // Stop waiting if: cycle completed. _isNotShooting; }; // waitUntil ends. // Return: true; }; Topic solved. Thanks, folks.
  17. How do we know if a vehicle is shooting? fnc_isSomeTeamMemberShooting = { params ["_teamVeh"]; private [...]; _isShooting = false; { if ( incapacitatedState (gunner _x) isEqualTo "SHOOTING" ) then { _isShooting = true }; // output is an empty string "" when the artillery vehicle is sending 155mm bullets through the sky... } forEach _teamVeh; // return: _isShooting; }; // IMPORTANT: this _teamVeh is NOT composed by member of the same Group (e.g. "Alpha-1-1"). https://community.bistudio.com/wiki/incapacitatedState I know I could use findIf to avoid this forEach, but for another reason (not relevant now), I need to check _isShooting through each member.
  18. The script and its information in the main post have been updated! Dec 4th 2024 | v1.5: Added native support to artillery-pieces from CDLC Expeditionary Forces; Added automatic schedule management that allows multiple fire-missions at the same time; Added rearming management by caliber (with 3D sound effects); Added option to prevent pieces self-propelled from moving from their original positions; Added virtual-fire-mission option (WIP: only HE and CLUSTER options and LIGHT and MEDIUM calibers nowadays); Improved the fire-mission feedback messages; Improved, each fire-mission was given a codename (customizable) to help identify what the feedback is about; Improved, each artillery-piece automatically renamed to the custom side name; Improved, the caliber 'ANY' was renamed to 'COMBINED' for better understanding and use; Improved, performance; Improved the mission-example; Fixed if a fire-mission is aborted, no more artillery-pieces keep shelling the target without losing their capacity to engage local threats (with coaxial if appliable); Fixed the debug target-markers-counter that was considering DAP markers from disabled sides as well; Fixed the debug artillery-pieces-counter that was considering DAP vehicles from disabled sides as well; Removed rhs_9k79, rhs_9k79_K, and rhs_9k79_B from the DAP Library. They're bugged; Documentation updated; Dec 5th 2024 | v1.5.1: Added the position checker for artillery and target-markers to verify whether they were within the map borders; Added auto-fix if the editor includes multiple artillery-pieces in the same group; Added tolerance to 'hd_destroy' marker-type as target too; Improved, if the editor turns off accidentally all sides through the management file, DAP turns the script off automatically; Fixed the error when the editor, for any reason, removes part of the artillery crew; Fixed the behavior where DAP was turning itself off if no artillery for it (Now DAP can be used only for virtual artillery). Dec 6th 2024 | v1.5.2: HOTFIX > Fixed, a specific typo in artillery variable-name ("dapp" or "ddap") was printed out an error; HOTFIX > Fixed, artillery-groups were losing their custom names after v1.5.1; Added option to Group Leader players see the fire-mission impact zone temporarilly on their maps; Added option to make all DAP artillery editable by Zeus automatically. If Debug Mode is activated, the pieces will be editable by Zeus too; Documentation updated;
  19. DAP is an Arma 3 script that allows the Mission Editor (you) to create real (or virtual) artillery/mortar fire-missions faster and smarter for one or multiple sides, using Eden marker’s positions and an external fire-missions list where you plan the caliber, ammo type, rounds, cycle of repetition and more. DAP doesn't change any original Arma AI behavior, saving server performance, and preserving the Arma integrity and compatibility with any mod. Why use DAP to manage artillery: unlike other scripts, DAP does not require the editor to specify artillery-pieces for each fire-mission. As soon as a fire-mission is triggered, DAP searches for artillery-pieces available at that time that fit the requested caliber, the requested ammunition-type, and have range to the target. This means that for the same target, DAP can use different pieces on the map; just as the same an artillery-piece can be used for multiple fire-missions with different targets. And DAP is absolutely scalable. How to install / Documentation: https://github.com/aldolammel/Arma-3-Dynamic-Artillery-Pieces-Script/blob/main/_DAP_Script_Documentation.pdf What you set for each fire mission with DAP: Real or virtual fire mission; The side that owns each fire-mission; Potential target sectors (Eden markers); How many artillery-pieces you want in each fire-mission; What caliber these pieces will be (Light, Medium, Heavy, Super Heavy or Combined); Ammunition type (HE, Cluster, Smoke, Flare etc); Control the volume of rounds per piece; How many repetition cycles does a fire mission have; Triggers will release the fire-mission (trigger activation, timer, kill/destruction). What you set globally with DAP: Custom callsign for each artillery side; Which piece calibers can use CommandChat to report (On/Off); Infinite ammunition (On/Off); Prevent artillery-pieces self-propelled to change position (On/Off); Prevent artillery-pieces from starting match with no magazines (On/Off); NEW! Fire-mission areas visible on the player map (On/Off); Custom cooldown by caliber among cycles of fire-mission repetition; Pre-defined whitelist of pieces working (Arma, DLCs, CDLCs, RHS, CUP, etc); Pre-defined whitelist of ammunition working (Arma, DLCs, CDLCs, RHS, CUP, etc); Pre-defined blacklist of currently bugged vehicles/static turrets; Pre-defined blacklist of currently bugged ammunition; Debug mode with simple or deep detailing; Etc… Automatically DAP Library supports content from: Arma 3; Expansion Apex; DLC Tanks; DLC Contact; CDLC Western Sahara; CDLC Reaction Forces; CDLC Expeditionary Forces; CDLC Global Mobilization; Mod RHS; Mod CUP. How DAP works technically: Before installation for advanced editors’ valuation, there's a workflow in the first pages of the documentation. Video demo: Soon! Check the file above on GitHub. Check the file above on GitHub. Documentation, link on this post header. Dependencies: None 😉 Download: - On GitHub: https://github.com/aldolammel/Arma-3-Dynamic-Artillery-Pieces-Script - On Steam Workshop: https://steamcommunity.com/sharedfiles/filedetails/?id=3371824030 Missions using it: - Soon. - - - - - - - - - - - Changelog: Dec, 6th 2024 | v1.5.2: news, fixes and notes. Known issues: - If you delete some original artillery crew (the driver, for example), it will print out an error (WIP). So, use the original crew of vehicles you want to use; - - - - - - - - - - - Video tutorials (playlist): - Soon in my secret YouTube channel hehe
  20. I'm trying but still not working and not understand the EH logic.
  21. thy_

    safezone multiplayer

    Hey. I developed this script that considers if you are in a mission with respawn-points or not, always working for single and multiplayer. You can check the video demo over there too.
  22. I had a few issues with canFire. I'll read it again later. Hmm, good. Even I got to know about the EH, now I think I finally got it. So, yes, it looks like work here: fnc_isSomeTeamMemberShooting = { params ["_teamVeh"]; private [...]; _isShooting = false; { _x addEventHandler ["Fired", { //params ["_unit", "_weapon", "_muzzle", "_mode", "_ammo", "_magazine", "_projectile", "_gunner"]; _isShooting = true; }]; } forEach _teamVeh; // return: _isShooting; }; About the code above: the output (_isShooting) is always "false", even between addEventHandler and forEach if I ask for _isShooting over there. Context: The _teamVeh is a bunch of artillery pieces from different types. That said, imagine 4 vehs where 2 are howitzers and 2 MRLs, firing times absolutely different. 12 rounds for an MRL is about 10 seconds against +60s for howitzers. I wanna make the group wait in a waitUntil loop until NO _teamVehs member is firing anymore. while { ... } do { ... ...The entire group firing a lot... waitUntil { sleep 20; [_teamVeh] call fnc_isSomeTeamMemberShooting }; // restarting the shooting a few times more, but the entire group together/at the same time. }; Thought about EH:
  23. Interesting... This week I gonna drop DAP v1.2 but maybe later I could implement this feature too. Good.
  24. Documentation is complete for now. You have all you need. Tomorrow I will be working on a v1.1. Cheers.
  25. The documentation has been update. Next update in a few hours (Pocket guide ammunition section)
×