Jump to content

Grumpy Old Man

Member
  • Content Count

    4333
  • Joined

  • Last visited

  • Medals

Everything posted by Grumpy Old Man

  1. It worked for a few hours at least, just imagine dr. evil mentioning a certain amount of dollars. No idea if it's imgur or this forum board breaking image links. As @Harzach stated this is something you could easily pick up on your own especially when getting help/advice from the forums, or you could post in the find or offer editing section to find someone to script it for you. Cheers
  2. Grumpy Old Man

    General Discussion (dev branch)

    Has been around for a while as stated by @Tankbuster, only solution, who'd have guessed, is to use a custom function to make MP stuff work in a MP game. Cheers
  3. Grumpy Old Man

    Ambient Light Source

    Goofed around a bit with @bad bensons snippet, this is what I came up with: //grab nearby trees _referencePos = getPosATL player; _trees = nearestTerrainObjects [_referencePos, ["Tree"], 25]; //filter trees to only get one tree every 7m because something something arma dynamic lights _finalTrees = []; while {count _trees > 0} do { _rndTree = selectRandom _trees; _trees = _trees select {_x distance2d _rndTree >= 7}; _finalTrees pushback _rndTree; }; _colorIntensity = 0.3;//play around with this, with multiple light sources this value should be kept rather low GOM_fnc_treeLights = []; { _lightAmbient = [_colorIntensity, 0, _colorIntensity];//tweak here _pos = getposATL _x; _light = "#lightpoint" createVehicleLocal _pos; _light setLightBrightness 0.75; _light setLightAmbient _lightAmbient; _light setLightColor _lightAmbient; _light setLightDayLight true; _light setLightUseFlare false; _light setLightFlareSize 5; _light setLightFlareMaxDistance 500; _light setLightAttenuation [2,4,4,0,9,10]; GOM_fnc_treeLights pushBack [_light,_lightAmbient]; } forEach _finalTrees; //fade colors over time GOM_fnc_changeColors = { params ["_light","_currentColor","_colors","_duration"]; _color = selectRandom _colors; _currentColor params ["_initR","_initG","_initB"]; _color params ["_targetR","_targetG","_targetB"]; _endTime = time + random [_duration / 2,_duration,_duration * 2]; _initTime = time; _finalColor = []; waitUntil { _finalColor = [ linearConversion [_initTime,_endTime,time,_initR,_targetR,true], linearConversion [_initTime,_endTime,time,_initG,_targetG,true], linearConversion [_initTime,_endTime,time,_initB,_targetB,true] ]; _light setLightAmbient _finalColor; time > _endTime };//pretty fluid for slow color transitions _recursionisonehelluvadrug = [_light,_finalColor,_colors,_duration] spawn GOM_fnc_changeColors; }; _colors = [[0.5,0,0.5],[0.3,0,0.3],[0,0.3,0],[0.3,0,0],[0,0,0.3]];//add or adjust the colors that will be used { _x params ["_light","_color"]; _change = [_light,_color,_colors,10] spawn GOM_fnc_changeColors;//color will change over the duration from 5 to 20 seconds randomly } forEach GOM_fnc_treeLights; Play with the according values, duration and colors should be clear. Arma does handle lots of dynamic lights rather poorly, you'll soon run into flickering with more than 10 lights, even on ultra settings. Probably also depends on other lights that are present within the mission. If wanted you can also add a sine function and make the lights pulsate, or even better, have each light pulse out of sync and let them run into sync every n seconds, if that's what you want. Cheers
  4. Grumpy Old Man

    Check health of all group members

    To check if at least one member is injured above 50%: _groupHasInjured = {damage _x >= 0.5} count units group player >= 1;//returns true if at least one soldier is hurt above 50% Cheers
  5. Grumpy Old Man

    AI Driving - Feedback topic

    Mission making in arma 3 is, for the most part, as basic as placing a few units, modules and triggers. Something most folks who grew up around PCs can pick up over 1-2 weekends. Adding voice acting, cutscenes and some animations isn't any more complicated either. If you talk about developing new game modes with custom score system, logistics or resource handling and dynamic missions for a persistent server, then yes, that's more advanced, but nothing the average joe is going to take on. Placing a convoy that simply works should be a baseline feature of a game that is mainly a military sandbox with AI. AI that somehow fails to do so for the first time in this series and for some reason is being left as is by the devs. It's a pity, considering how stunning the game can look. Looking at screenshots made by certain folks I still need to look twice to find out it's actually a game and not some RL military footage. You keep mentioning missions that are still working fine in the context of convoys. Care to name a few? I'd like to take a look at those. Cheers
  6. On a sidenote, any reason for using CfgAdvanced hint in the first place? Why not just hint or hintSilent during mission runtime since you don't seem to use any of the features from CfgAdvancedHint? Cheers
  7. Grumpy Old Man

    AI Driving - Feedback topic

    The correct question is: What will they do about it? Seeing how this is known for at least one year with little to no effort to work these things out, I doubt A3 will ever get out of its current state. Cheers
  8. Grumpy Old Man

    AI Lasers without Combat Behavior

    What's currently working as of 1.85 devbranch: group this enableIRLasers true;//will activate IR lasers if unit has IR lasers on rifle and enters combat behavior group this setBehaviour "COMBAT";//enters combat mode immediately Should result in the group enabling IR lasers. Only works when group is in combat behavior, no other behavior allows this... As to the suggestion from @pierremgi, unfortunately this isn't reliable at all. Last time I checked this the lasers will turn off after some time, no matter if using onEachFrame or EachFrame EH. It's still odd that so much stuff (script commands etc.) are tied to AI behavior/combat modes... Such a weird decision to make AI behavior override script commands. Mind boggling. Cheers
  9. What does "money" and "expe" actually hold? Are these global variables? That's true for format, but not for CfgHints. Cheers
  10. Grumpy Old Man

    Ambient Light Source

    Why so narrow minded? What's making arma great is the sheer endless variety of scenarios/mods/playstyles. Wanna play mil sim and knock your trackIR off your hat while saluting your commanding officer? No problem. Enjoy driving around? Play a cab driver on altis life. Do you miss call of duty/battlefield? Join any 20+ players wasteland/domination/koth server. Cheers
  11. Grumpy Old Man

    trigger, unexpected behaviour

    Might as well get rid of triggers in the first place, especially when you're already using .sqf to a greater extent. Something like you described has yet to happen using loops/eventhandlers. Cheers
  12. Grumpy Old Man

    General Discussion (dev branch)

    Exactly what I am getting. Radar unit with radar set to forced active, knowsabout value of target is 4. listRemoteTargets array is holding the target. Yet for some reason any vehicle on the map with radar to deactivated and "receive remote targets" set to active does not know about the target. Something went wrong I guess since this was working fine just one month ago. Cheers
  13. Grumpy Old Man

    General Discussion (dev branch)

    Just checked it, the operational time is around 3 minutes at maximum speed. This makes me worried about checking other vehicles. Where was this change mentioned/documented? Another unneeded change? Here's the function: GOM_fnc_calcVehOperationTime = { params ["_veh"]; _vehType = typeOf _veh; _rpm = _veh getSoundController "rpm"; _fuelConsumptionStats = _veh getVariable ["GOM_fnc_fuelConsumptionStats",[]]; if (_fuelConsumptionStats isEqualTo []) then { _fuelCapacity = getNumber (configfile >> "CfgVehicles" >> _vehType >> "fuelCapacity"); _fuelConsumptionRate = getNumber (configfile >> "CfgVehicles" >> _vehType >> "fuelConsumptionRate"); _idleRPM = getNumber (configfile >> "CfgVehicles" >> _vehType >> "idleRpm"); _redRPM = getNumber (configfile >> "CfgVehicles" >> _vehType >> "redRpm"); _veh setVariable ["GOM_fnc_fuelConsumptionStats",[_fuelCapacity,_fuelConsumptionRate,_idleRPM,_redRPM]]; _fuelConsumptionStats = _veh getVariable ["GOM_fnc_fuelConsumptionStats",[]]; }; _fuelConsumptionStats params ["_fuelCapacity","_fuelConsumptionRate","_idleRPM","_redRPM"]; _currentTime = (fuel _veh * _fuelCapacity) / (8E-7 * _rpm + 0.001); _idleTime = _fuelCapacity / (8E-7 * _idleRPM + 0.001); _maxRpmTime = _fuelCapacity / (8E-7 * _redRPM + 0.001); [_currentTime,_idleTime,_maxRpmTime]; }; onEachFrame { _times = [vehicle player] call GOM_fnc_calcVehOperationTime; _times params ["_currentTime","_idleTime","_maxRpmTime"]; hintsilent format ["Fuel Time:\nCurrent: %1\nIdleRpm: %2\nMaxRpm: %3",[_currentTime/3600] call BIS_fnc_timeToString,[_idleTime/3600] call BIS_fnc_timeToString,[_maxRpmTime/3600] call BIS_fnc_timeToString] }; Just execute this in the debug console, hop into a vehicle and watch the timers. Cheers
  14. Grumpy Old Man

    help on bubble script 2.0

    Don't obsess over performance if you don't experience performance issues. Cheers
  15. Grumpy Old Man

    Changing a Unit's Type Issue

    As @beno_83au stated, not possible without deletion. What are you trying to do, exactly? Cheers
  16. Grumpy Old Man

    Branching waypoint order

    A quick solution: //init.sqf or wherever you seem fit //this function grabs markers that fit the criteria, i.e. branch1, branch2 etc GOM_fnc_grabPositions = { params [["_filter",""]]; if (_filter isEqualTo "") exitWith {systemchat "Wrong filter set!"}; _wpMarkers = []; { if (toUpper _x find toUpper _filter >= 0) then {_wpMarkers pushback _x}; } forEach allMapMarkers; _wpMarkers sort true; systemchat format ["Selected branches: %1",_wpMarkers]; _return = _wpMarkers apply {getMarkerPos _x}; {deletemarker _x} forEach _wpMarkers; _return }; //this function assigns waypoints to the group that are of the input branch GOM_fnc_branchWP = { params ["_group","_branch"]; _positions = [_branch] call GOM_fnc_grabPositions; { _wp = _group addWaypoint [_x,0]; _wp setWaypointType "MOVE"; } forEach _positions; }; //now in a trigger or last waypoint before the branching do this [group test,selectRandom ["branch1","branch2","branch3"]] call GOM_fnc_branchWP; This will make the group chose a random branch, you can also use any condition you want to pick the appropriate branch. For branches simply place appropriate named markers as seen in the video (branch1, branch1_1, branch1_2 etc). By copy-pasting markers the automated naming will take care of the ascending order of marker names. You could easily enhance on this foundation, maybe add waypoint type filter into marker name, so a marker named "branch2_4_SAD" will make the waypoint of type seek and destroy if you add another check to the function etc. Demo mission. Cheers
  17. Grumpy Old Man

    Getting AI to land Chopper

    You need to put a doStop in front of the land command, so the chopper stops where he's heading to and lands instead. Also don't do this: _unit removeEventHandler ["Fired", 0]; Since you can't be sure at any time if the eventhandler you added has the ID 0, might be some addon/mod already using it. Use this instead: _unit removeEventHandler ["Fired", _thisEventHandler]; Is a rather new magic variable. Cheers
  18. Grumpy Old Man

    [Release] GOM - Aircraft Loadout V1.35

    Should be fixed, thanks for the hint! V1.35 Fixed: Players are no longer able to load presets created with a different pylon restriction setting, thanks @magicsrp Due to this change all presets needed to be reset Cheers
  19. Grumpy Old Man

    [Release] GOM - Aircraft Loadout V1.35

    Interesting, shouldn't happen in the first place, since every user downloads the script with the mission file. Can you provide the steps so I can reproduce it? Ah well had to read that twice, I'll look into it. Cheers
  20. And the problem is? What's up with all those abstract examples lately? Cheers
  21. Grumpy Old Man

    Setting Entire Sides as Captive

    Try this: {_x setCaptive false} forEach (allUnits select {side _x isEqualTo resistance}) Cheers
  22. Grumpy Old Man

    Arma 3 flinching mechanics

    Especially with COSLX that had flying bodyparts when shooting someone with the AA-12 HE rounds, heh. You can't flinch with something no longer attached to your body. Cheers
  23. Grumpy Old Man

    AI Driving - Feedback topic

    I'm aware of it. The whole point is, you shouldn't need to jump through hoops just to get a convoy moving, since your average mission maker that just wants to throw a quick mission together most likely doesn't want to have to learn advanced scripting for a simple convoy, which has been working fine at least early 2017. In A2 it's as simple as placing the vehicles in a group and set them a waypoint. It just works. When only one vehicle moves and the rest gets stuck, it's a sign that there's clearly something faulty going on in the AI. Cheers
  24. I'd be surprised if even the devs know, at this point. Cheers
  25. Grumpy Old Man

    AI Driving - Feedback topic

    Curious, when was the last time you set up a typical convoy, with hunter as lead and tail vehicle and 2 hemtt in between? Using safe mode, limited speed mode and formation column is basically all there is to it. Vehicles stop 9 out of 10 times, breaking the convoy and not leaving point A, let alone move towards their destination. What exactly do you expect the average mission maker to be? Making convoys fail safe and idiot proof (goes for AI in general in a game genre like this) is the job of the devs, mission makers should make... *snare roll* ...missions. Take a look at this one: Here's the mission file. Have at it. Cheers
×