Jump to content

blackmamb

Member
  • Content Count

    641
  • Joined

  • Last visited

  • Medals

Everything posted by blackmamb

  1. Well, the idea is here. It should create multiple boxes, but you do have some syntax issues. for "_i" from 1 to 10 do { _randomPos = [getMarkerPos "area", 5000] call fnc_randomPos; _box = "Box_NATO_Ammo_F" createVehicle (_randomPos); _mrk = createMarkerLocal [_mrk,_randomPos]; _mrk setMarkerType "mil_dot"; _mrk setMarkerShape "ICON"; _mrk setMarkerColor "ColorRed"; }; Should work, assuming that fnc_randomPos is defined somewhere.
  2. blackmamb

    Tactical Run Vs. Get The Hack Out Of Dodge Run

    Still don't get it. Sprinting is already in the game.
  3. blackmamb

    random in forEach

    Yeah, you do get a random number generated for each element in your array. Here's a quick test you could have performed: { _test = 0.1 + random 0.9; player sidechat format ["Iteration : %1 \nValue : %2", forEachIndex, _test]; } forEach [0,1,2,3,4,5,6];
  4. I'm pretty sure Norrin updated those scipts to work with Arma 3 when the alpha came out. Can't seem to find the thread, though. Edit: Nah, my bad, he did update some of his scripts but not those, apparently.
  5. _rIcon = getText (configfile >> "CfgRanks" >> "3" >> "texture"); will give you the path to the texture for a lieutenant. 0 is private, 1 is corporal, 2 is sergeant, etc. You can find all the paths in the config Viewer, in game.
  6. Regarding 2, I haven't tested, I'd be grateful if you do. It should indeed add a 148 to the cargo of the vehicle (it won't add it to the vehicle itself, if that's possible). It should be null = ["v_car", this] execVM "f\common\fa_ACRE_assignGear.sqf"; though. As for the ACRE specific questions, you're probably better off asking in Nou's thread. You'll get some more informed answers.
  7. Can't you just BIS_fnc_MP the creation of the marker? With _isPersistent set to true?
  8. The recognition overlay has been changed, and a new version will be available in 3-0-8.
  9. blackmamb

    Development Blog & Reveals

    Canton-Protocol Strategic Alliance Treaty.
  10. Try starting it from your init.sqf.
  11. Never used that command as far as I know, can't really tell. You could try something like that? (untested) _seats = getNumber (configFile >> "CfgVehicles" >>(typeOf _target) >> "transportSoldier"); _crew = crew _target; _d = if (isNull driver _target) then {[driver _target]} else {[]}; _g = if (isNull gunner _target) then {[gunner _target]} else {[]}; _c = if (isNull commander _target) then {[commander _target]} else {[]}; _crew = ((_crew - _d) - _g) -_c; _emptySeats = _seats - (count _crew);
  12. Looks like it returns the same kind of stuff as triggers. Which are actually kinda tricky when it comes to vehicles. Reminds me of this.
  13. This [ [ [], "gui/secopscallmenu.sqf" ], "BIS_fnc_execVM", _resel, false ] call BIS_fnc_MP; should work... except it should be [ [ [], "gui\secopscallmenu.sqf" ], "BIS_fnc_execVM", _resel, false ] call BIS_fnc_MP; Also you probably don't need to pass arguments if they're an empty array.
  14. Not really, no. Sakura's actually sticking icons everywhere. It's not a script issue, it's a config issue. You can't change the default actions by script is all.
  15. blackmamb

    KEYS: No action menu

    Guess my question came out wrong: was just wondering, since the default "medical system" goes through the action menu, if you were to deal with it (assign a key, treat it as default action) or just leave it as is. Anyway, if I ever get killed by a ladder, no matter the circumstances, rest assured that I'll blame it on you! :D Edit: Well, watching that video answered that.
  16. Have you tried simply: [[],"gui\secopscallmenu.sqf","BIS_fnc_execVM",_resel,false] spawn BIS_fnc_MP; Edit: Dammit, can't read.
  17. blackmamb

    Custom soldier template

    Aww sorry, I wentt a bit fast here, I think. Just to be clear, that function I wrote is totally incomplete. It was just an example as to what could be done. So, I'll detail the idea a bit. First, you need to decide on what exactly will your templates contain. My example went with a uniform, a weapon, some mags and a general AI skill. Now, that's probably not what you want, so I'll let you do that. For every single parameter that you want to adjust with your template, you need to find how that's done (e.g adding a uniform will be done with addUniform, and you need the config name of that uniform, AI skill will be adjusted with setSkill, and you need a number between 0 and 1). Check the wiki for all that. When you've decided on a list of parameters you need for a template, you write an array, containing every single one of the parameters needed: ["config name of your weapon", ["config name of your magazine", number of magazines], number between 0 and 1 for the skill, ...] (Note that addMagazines requires a magazine classname and a number of magazines to add. So I created another array inside the first array, the first value being the name of the mag, the second the number. That's not a mandatory way of doing things, I just find it less confusing) You write that same array, with different parameters, for every template you might want to use. Now, you need to store those arrays somewhere, and I chose the gamelogic, so you use the setvariable thing from my previous post. Then you write the function that's gonna translate that array into actual parameters for your unit: //retrieve the arguments passed to the function: this (your unit) and "templateName" (whatever you wrote in the init line) _unit = _this select 0; // Contains the unit you're gonna apply the template to _tempName = _this select 1; // Contains a template Name, that you've defined before hand _temp = YourTag_templates_logic getVariable _tempName //based on the name you passed, goes fetch the corresponding array of parameters // Then you retrieve all the values from the array _uniform = _temp select 0; _weap = _temp select 1; _mags = _temp select 2; _skill = _temp select 3; ... // Finally you apply those parameters _unit addUniform _uniform; _unit addWeapon _weap; _unit addMagazines _mags; _unit setSkill _skill // and this goes on until the unit looks exactly like what you want finally, when creating your mission, you just paste this into the init lines of your units: [this, "TemplateName"] spawn YourTag_fnc_setTemplate; (where TemplateName is actually one of the templates you've created earlier, e.g "Regular_Recruit"). (note here that I decided to register that function into the function library. If you're not confortable with that, you could for example write your function in a separate sqf file, say setTemplate.sqf. In which case this is what you'd put in the init line: [this, "TemplateName"] execVM "setTemplate.sqf"; I'm sorry I sometimes have trouble explaining all that stuff. But if you want, just paste here a complete list of the attributes you want your templates to define (like for example define precisely what you mean by "loadout & appearance") and I'll write something more adapted to what you need.
  18. swimInDepth is probably what you're looking for. Hmm. Need more coffee. As for crewing the SDV, just as for any other vehicle this moveindriver mySDV; this moveinCargo mySDV; in the divers' init lines.
  19. blackmamb

    Custom soldier template

    I've been working on something quite similar, even though I'm working on groups and not individual soldiers, so I'm not using the same parameters. Anyway, one solution to that would be to create your templates as an array. As to where to store that array, it's your choice, I myself use a gamelogic so that I'm sure it doesn't mess with anything else. So you'd create (probably easier to just place it in the editor) a gamelogic called YourTag_templates_logic. (can add YourTag_templatesInit_done = false; to its init line) Then, in a script (or directly in the init line of the gamelogic, but I don't recommend that as it's not very easy to work with): YourTag_templates_logic setVariable ["Regular_Recruit", ["uniform", "weapon", "magazines", AIskill (number between 0 and 1), etc...]]; YourTag_templates_logic setVariable ["Regular_Elite", ["uniform", "weapon", ["magazines", magazines number], AIskill (number between 0 and 1), etc...]]; etc. YourTag_templatesInit_done = true; etc. You can obviously set whatever you want in that array. For example you could decide to set every different AI skill individually (aimingAccuracy, aimingShake...). You could also define classname for that particular template, so that you could spawn them directly from a script. Then, you have in the init line of every unit: [this, "TemplateName"] spawn YourTag_fnc_setTemplate; then the function itself, YourTag_fnc_setTemplate waitUntil {YourTag_templatesInit_done}; _unit = _this select 0; _tempName = _this select 1; _temp = YourTag_templates_logic getVariable "Regular_Recruit"; _unit addUniform _temp select 0; _unit addWeapon _this select 1; _unit addMagazines [(_this select 2) select 0, (_this select 2) select 1]; _unit setSkill _temp select 3; etc. That function would be best defined from the description.ext, as to avoid any loading order issues. Of course, all that is very rough around the edges, but I have no idea as to how much you master scripting. In any case, you get the idea, or if you don't, just ask for clarifications!
  20. You could use the same trigger for playing the music and fading out (using the on deact. box). Then, in each trigger, instead of just playing the music, you could have something along the lines of On Act: 0 fademusic 1; playMusic "musicname"; On deAct: 10 fademusic 0;
  21. Also remember that in A3, you can directly set the elevation from the editor. If you're placing those in the editor.
  22. surfaceNormal expects a position iirc. It should be _obj setVectorUp (surfacenormal (getPosATL _obj)); Or from the editor init line: this setVectorUp (surfacenormal (getPosATL this)); Note that surfacenormal will only take into account the two first parameters of the position, so getPos could also work, but getPosATL is way faster.
  23. blackmamb

    PAPA BEAR callsign with Arma 3

    I'm still planning to play around with those, but have you tried radioChannelSetCallSign? (absolutely not sure it's relevant, but hey. It says callsign! :cool:) Edit: looks like it's only relevant to custom radio channels, so disregard.
  24. blackmamb

    Help with Loops in Loops

    _count = _count +1; line 26 of your code. It's never updated. Edit: Other than that, seems to work. You might want to use set instead of that array addition, though
  25. Sadly that's not possible, unless you somehow ram the unit with an (invisible?) object. The other workaround that can be used is to spawn an identical unit, hide the first one, move the second to it's place, kill it. But I find it way too clunky.
×