Jump to content

Grumpy Old Man

Member
  • Content Count

    4333
  • Joined

  • Last visited

  • Medals

Everything posted by Grumpy Old Man

  1. Grumpy Old Man

    Audio in game

    Put a music snippet as mono .ogg inside a mission and make sure all volume sliders are set to max and be close to the playback object, then compare the loudness with playing the file in an audio player at max volume slider, perceived loudness should be the same. Cheers
  2. Indeed they are. Cheers
  3. Grumpy Old Man

    Addaction syntax check

    You've got a true where the priority parameter (number) should be. this addAction ["Enter", {player setPos (getPos entry_4b)},[],0,true,true,"","_this distance _target <0.5"]; Cheers
  4. Well you could also use the radiation function from this neat package: Might be what you're after. Cheers
  5. Grumpy Old Man

    MapSingleClick problem

    You could utilize onDoubleClick, works similar to onMapSingleClick, alternatively you could keep a timestamp for every single click and trigger your action if 2 timestamps happened within a certain timeframe to emulate a double click, quite a few ways actually. Cheers
  6. Grumpy Old Man

    MapSingleClick problem

    You're probably confusing global with public variables. Cheers
  7. Grumpy Old Man

    How to get markers on a unit's map?

    Well you can set up a simple associative array using the UID of the player which is also passed to the onPlayerConnected command. Already quite compact if you ask me, can be run on server only. Cheers
  8. You can simply modify the above snippet, setWaypointStatements will be executed when the group completes the waypoint. Cheers
  9. Alternatively you can use BIS_fnc_sunriseSunsetTime and go from there. Cheers
  10. Grumpy Old Man

    How to get markers on a unit's map?

    All info needed is to be found on the allMapMarkers wiki. Simply filter the strings of allMapMarkers to match the player ID generated from onPlayerConnected. Cheers
  11. Adjusted my snippet from above to delete entire groups: _groupLeaders = [Patrol_Evac_1,Patrol_Evac_2,Patrol_Evac_3];//only add one unit per group _waypoints = ["Move_Patrol_Evac_1","Move_Patrol_Evac_2","Move_Patrol_Evac_3"]; _delete = [_groupLeaders,_waypoints] spawn { params ["_groupLeaders","_waypoints"]; {_x move getMarkerPos (_waypoints#_forEachIndex)} forEach _groupLeaders; while {count _groupLeaders > 0} do { { if (count (units _x select {_x distance2D getMarkerpos (_waypoints#_forEachIndex) < 15}) > 0) then { {deleteVehicle _x} forEach units _x; } } forEach _groupLeaders; sleep 1 } }; Simply add one unit per group to the _groupLeaders array and make sure every group has a marker inside the waypoints array, when at least one unit is within 15m of the respective marker the entire group will be deleted. This will work with as many groups you'll need, as long as every group has their own waypoint. Alternatively and more clean solution would be to use scripted waypoints and onAct: _groupLeaders = [Patrol_Evac_1,Patrol_Evac_2,Patrol_Evac_3];//only add one unit per group _waypoints = ["Move_Patrol_Evac_1","Move_Patrol_Evac_2","Move_Patrol_Evac_3"]; { _mrk = _waypoints#_forEachIndex; //make sure no other waypoints exist while {count (waypoints group _x) > 0} do { deleteWaypoint ((waypoints group _x)#0); }; _wp = group _x addWaypoint [getMarkerPos _mrk,0]; [group _x,0] setWaypointType "MOVE"; [group _x,0] setWayPointStatements ["true","{deleteVehicle _x} forEach units this"] } forEach _groupLeaders; Cheers
  12. Grumpy Old Man

    Arma 3 DLC - CONTACT

    Personally I got into the franchise by buying Arma2: OA for Day z. Had been fun times trying to get used to the gritty controls while trying to survive and teaming up with others, until it turned into a kill on sight fest 6-7 months in. Discovered other game modes and had a blast playing takistan life where the map was split to the northern republic and southern rebels. Then I got curious about the editor and scripting and here I am. The diversity of gamemodes in this game is great, can be overwhelming almost. Really looking forward to this DLC, the map alone is worth the purchase, on top of that there's now shotguns (finally), a tractor and a tinfoil hat. Cheers
  13. @Nope.X Can't quote your post for some reason, forum fun, heh. The snippet should work for individual units, just add them to the units array and for each added unit add a marker for the unit to move towards. For deleting the entire group depends if you want to delete only units from the group that are within deletion range, or delete the entire group if at least one unit is within deletion range. As stated earlier, commandMove only moves a single unit, I don't see how this would work for entire groups, you'd need to use move instead, which will make the entire units group move towards the position. Cheers
  14. Grumpy Old Man

    Forum Home Page Not Logged In

    Had the auto log-off/on issue for the last few days. Depending on which forum page/subpage I visited I was either logged in or off, all while using a single tab in a single browser (multi tabs in multi browsers usually leads to fun). Cleared the browser cache, worked fine, suddenly same issues appeared again and are again resolved by clearing the cache. Now I ran into the issue of a non functioning quote button (try quoting this post, I can't for some reason) while the multi quote and like buttons work. Cheers
  15. Why are there invisible spaces in Patrol_Evac_1 etc.? commandMove will only move individual units, not groups. For individual units this will do the trick: _units = [Patrol_Evac_1,Patrol_Evac_2,Patrol_Evac_3]; _waypoints = ["Move_Patrol_Evac_1","Move_Patrol_Evac_2","Move_Patrol_Evac_3"]; _delete = [_units,_waypoints] spawn { params ["_units","_waypoints"]; {_x commandMove getMarkerPos (_waypoints#(_units find _x))} forEach _units; while {count _units > 0} do { {deleteVehicle (_units deleteAt (_units find _x))} forEach (_units select {_x distance2D getMarkerPos (_waypoints#(_units find _x)) < 10}); sleep 1; } }; Will delete units that are closer than 10m from their individual marker destinations and also exit the loop if no more units exist. Cheers
  16. Grumpy Old Man

    Toggle Cabin Light SOLVED

    You got Plight = 1; inside the setVectorDirAndUp, messing up the syntax. Cheers
  17. Grumpy Old Man

    The Puzzler!

    As @beno_83au stated, you could use setDate on the players client, since the command is local should work fine: player addAction ["Enter Tunnel",{ _midnight = date; //retrieve current date mid-mission ie. [2035,6,6,12,0] _midnight resize 3; //-> [2035,6,6] _midnight append [0,0]; // [2035,6,6,0,0] setDate _midnight; }]; Untested, might run into issues if the server syncs the date automatically, never messed around with this stuff, heh. Cheers
  18. Grumpy Old Man

    Mission File.

    I'm making an educated guess and say it's about some life mission, heh. Cheers
  19. Grumpy Old Man

    [Release] GOM - Vehicle Tuning V1.01

    Instructions are in the first post. Simply replace player with the object name of your choice. Cheers
  20. Grumpy Old Man

    CFGsound

    playSound3d is AG EG, no need for remoteExec. Cheers
  21. Grumpy Old Man

    CFGsound

    Well if you're using sounds that already are defined as CfgSound then you don't need to add it manually. You can also work with the path of the sound and use playSound3d (sound source will remain stationary though as none of the parameters make the sound follow a moving object), might not be what you want if you want the warning sound only audible for passengers/pilots of the aircraft, playSound should be just fine. If you want the sound to works with MP missions you need to use remoteExec. Cheers
  22. Grumpy Old Man

    AI Driving - Feedback topic

    On a sidenote: Don't test using setAccTime, since the AI controllers won't be able to properly compensate that, as far as I observed. Cheers
  23. Could be as simple as: bob addEventHandler ["Killed",{ hint "Bob is dead"; task_1 setTaskState "Succeeded"; }]; As stated above, the condition needs to be inside curly brackets. Just take a quick look at the wiki which was also linked by @sarogahtyp, provides proper syntax and alternate syntax for various commands. Those error messages can be confusing at first until you learn how to interpret them, simply check the line the error occurs in, go through all commands from that line, check for proper syntax and proper parameters, most of the time you'll find the error, heh. I also recommend some dedicated program to write .sqf script in, notepad++ with .sqf syntax is frequently used. Personally I'm using poseidon which is made and maintained by a BI dev and a real swiss army knife for .sqf. To learn scripting you can go through Mr. Murrays guide, which was made for A2 but still holds true in A3. Cheers
  24. As you already noticed, the error is in the line where the while loop starts. While loop condition requires curly brackets instead of round ones. That's the error. Also I'd add a sleep inside the while loop, alternatively you can completely replace the while loop with a killed eventhandler. Cheers
  25. Grumpy Old Man

    CFGsound

    The linked sound browser is using the already defined CfgSound entries. If you want to add your own sounds you need to add individual entries for each sound. Cheers
×