-
Content Count
3985 -
Joined
-
Last visited
-
Medals
-
Medals
Everything posted by das attorney
-
Passing code to BIS_fnc_randomPos
das attorney replied to hcpookie's topic in ARMA 3 - ADDONS - CONFIGS & SCRIPTING
Try this (you can paste it in the debug console to check). Seems to work ok for me - let me know if you have any probs. Parameters are: initial position number of vehicles types of vehicles max dist from another vehicle min dist from another object player allowDamage false; // testing line fnc_spawnVehicles = { params ["_pos","_numbVeh","_vehTypes","_maxDist","_separation"]; _vehicles = []; for "_i" from 1 to _numbVeh do { _newPos = [_pos,0,_maxDist,_separation,0,1,0] call bis_fnc_findSafePos; if (_newPos distance _pos < _maxDist) then { _veh = createVehicle [selectRandom _vehTypes,_pos,[],0,"can_collide"]; _vehicles pushBack _veh; _pos = _newPos } }; _vehicles }; _vehTypes = [ "O_MRAP_02_F", "O_MRAP_02_gmg_F", "O_MRAP_02_hmg_F" ]; _pookiesNewVehicles = [getPos player,4,_vehTypes,30,12] call fnc_spawnVehicles; It returns the vehicles that were spawned -
Hi, Not trying to shout you down, but I think this kind of command would be extremely situational. It would work well if you are in open fields and came under fire, but if you consider building-to-building combat, then it would be really messy. Let's say you are crouched, then you would have some units in good cover suitable to their (and by extension, your stance), but then some other units crouching behind high (6' + tall objects). And the worst would be units crouching behind things they could go prone behind. But yes,agreed that sometimes you want them to do stuff and they act like dummies and stand there waiting to be mowed down. This game could really have done with some sort of cover-node system (defined in the models and used by the ai routines), but it looks like the left hand wasn't talking to the right hand, so all the objects got made, and then the guys that program the ai were told "that's what you've got, now make it work" xD edit: I meant to say that there was a mod for this back in Arma 2 (so you see how long people have wanted this)! It worked ok, but the criticism above applied. For your interest: http://www.armaholic.com/page.php?id=8484
- 5179 replies
-
- 3
-
- branch
- development
-
(and 1 more)
Tagged with:
-
Is a function more usefull
das attorney replied to Theassassinzz's topic in ARMA 3 - MISSION EDITING & SCRIPTING
It depends. If they are functions that can be ran within the script, and you don't need them elsewhere, then don't bother. If you need access in another script, then yes, define them in cfgFunctions or by some other method. -
Count string in string
das attorney replied to 7erra's topic in ARMA 3 - MISSION EDITING & SCRIPTING
I would do: _manipulate = "My first line<br/>My second line<br/>Third line<br/>you guessed it, fifth line<br/>I lied that was the fourth."; _manipulate = _manipulate splitString "<>"; _manipulate = _manipulate select {_x find "br/" == -1}; diag_log _manipulate Should return this: ["My first line","My second line","Third line","you guessed it, fifth line","I lied that was the fourth."] Then you can do all the endl stuff with forEach to use it in a tooltip or whatever. -
[SOLVED] getAllHitPointsDamage vs damage
das attorney replied to JB47394's topic in ARMA 3 - MISSION EDITING & SCRIPTING
That's what the spoiler tags are for. I have no idea without seeing some code, or it is all guess work and supposition. I have a similar system in my missions and it works no problem so no idea what's going wrong for you. Personally i feel discussion is moot and seeing the code would be much more helpful. However, that is your prerogative. Perhaps someone else can help you. -
[SOLVED] getAllHitPointsDamage vs damage
das attorney replied to JB47394's topic in ARMA 3 - MISSION EDITING & SCRIPTING
What's your code? -
I always phone it in on a Friday so no probs dudes - you might as well carry on and make a weekend out of it!
-
Object namespace or similar functionality.
das attorney replied to Ivanoff.N's topic in ARMA 3 - MISSION EDITING & SCRIPTING
..................- 17 replies
-
- 1
-
- namespace
- obejct data
-
(and 1 more)
Tagged with:
-
Check the syntax for this: _wp1 setwaypointstatements ["this land 'land'"]; It should be like the one later on in your script _wp3 setWaypointStatements ["true", "{deleteVehicle _x;} forEach thisList + [vehicle this];"]; like _wp1 setwaypointstatements ["true", "this land 'land'"];
-
Object namespace or similar functionality.
das attorney replied to Ivanoff.N's topic in ARMA 3 - MISSION EDITING & SCRIPTING
// set _myCampingLight setVariable ["direction",getDir _myCampingLight]; // get _dir = _myCampingLight getVariable ["direction",0];- 17 replies
-
- 1
-
- namespace
- obejct data
-
(and 1 more)
Tagged with:
-
Simple Object Checkbox Gone?
das attorney replied to phronk's topic in ARMA 3 - MISSION EDITING & SCRIPTING
That's a good explanation, but I think it could have been left in for objects initialised in 3den as they happen at mission start, so shouldn't really have any bearing on FPS in the game. But yes, agreed that during runtime it can be more of a burden than boon. -
Already mentioned in this thread - plus some input from one of the devs if you scroll down.
-
How to switch from one character to another in the same scenario with the Eden Editor?
das attorney replied to MadManYo's topic in ARMA 3 - EDEN EDITOR
Make them playable by ticking the box in the unit int, then read this link: https://community.bistudio.com/wiki/Team_Switch And put this in init.sqf (or some other init script ran globally) addMissionEventHandler ["teamswitch",{ (_this select 0) enableAI "teamswitch" }];- 7 replies
-
- 1
-
- eden editor
- character
-
(and 2 more)
Tagged with:
-
Any tips on how best to tweak difficulty?
das attorney replied to thirith's topic in ARMA 3 - MULTIPLAYER
Yes, you can do that in your own missions, or if not your own missions, then you can make a mod to enforce the values. -
Any tips on how best to tweak difficulty?
das attorney replied to thirith's topic in ARMA 3 - MULTIPLAYER
http://www.urbandictionary.com/define.php?term=dial it in So if you need to dial it in, then it a process of looking at works for you and what doesn't. In your case, you only get the chance to do that every two weeks, so it is a slow process. I would use rule of halves. So next time I play, I would drop all skills by 50% If still too hard/not fun, then halve it again. When you reach the level where it is semi-playable/semi-fun, then start thinking about whether they were too stupid but excellent shots or vice versa and increase/decrease accordingly. That's probably not the answer you want, but the reality is you only play every two weeks, so with the best will in the world, that is the timescale you are looking at. Maybe host a server for a while and make it public if you want faster feedback. I'm happy to tell you the values I like, but I feel that if you use them and don't like them, then it wastes another two weeks for you. Anyway, here you go (note that this is fiddling with even more subskills, so more to dial in if wrong for you) _unit setSkill 1; _unit setSkill ["aimingAccuracy",0.25]; _unit setSkill ["aimingShake",0.25]; _unit setSkill ["aimingSpeed",0.25]; _unit setSkill ["spotDistance",0.25]; _unit setSkill ["spotTime",0.25]; I can't really comment about AI mods as I don't bother with them so you might be better off checking the respective threads for those scripts/mods. -
Player character can't use chat.
das attorney replied to Raathgar's topic in ARMA 3 - MISSION EDITING & SCRIPTING
edit: ninja'd by gom -
Utilize engine funcion for connecting to server?
das attorney replied to zeroip's topic in ARMA 3 - MISSION EDITING & SCRIPTING
You can use this KK script to transfer from server to server, but there is some quirks that need to be ironed out (like periodically bugging the map out for some users). http://killzonekid.com/farewell-my-arma-friends/ As onEachFrame persists after mission has exited (definitely in MP, maybe in SP - needs to be checked), you could potentially modify this to work from SP to server. You would just need to know the IDD's and IDC's of buttons that would be clicked by user if you were to navigate the menus by clicking them with your mouse. If you want to find out about intercept, it would be quicker for you if you join the Arma discord and check with Dedman - he's active on there and is carrying on the work with intercept. Maybe he'll read this thread, but definitely is over there. -
Toggle inventory - for TAB users
das attorney posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
I use tab for open inventory button, but it's always bothered me that you can't use the same button to close it; instead you have to use Esc or the X button in the corner of the inventory. Here is some code so you can have a button that opens the inventory, and the same button closes it. Put it in initPlayerLocal.sqf or similar. Enjoy player addEventHandler ["InventoryOpened",{ _this spawn { waitUntil { not isNull (findDisplay 602) }; INVCLOSED = (findDisplay 602) displayAddEventHandler ["keydown", { if ((_this select 1) in (actionKeys "gear")) then { (findDisplay 602) displayRemoveEventHandler ["keydown",INVCLOSED]; closeDialog 0 } }] } }] -
Toggle inventory - for TAB users
das attorney replied to das attorney's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Ah ok - I put it in the first sentence of the preamble. Let me see if I can modify the topic description.. edit: That was pretty painless - done :) -
Toggle inventory - for TAB users
das attorney replied to das attorney's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Yes, I realised that so I wrote this script for me any any other people using tab -
nearEntities and city bench are not friends
das attorney replied to Cheitan's topic in ARMA 3 - MISSION EDITING & SCRIPTING
If it's benches (or anything really) baked into the map, then they aren't considered to be entities anymore even if their class should indicate that they are; so you can only find them with nearestObjects (empty array search) and nearestTerrainObjects. A lot of stuff baked into the map doesn't even have a class anymore, so if this is the case, then searching for them by class will fail. Some important stuff like houses do, but a lot of smaller objects are just declassed. Stand near a bench and do: {diag_log _x; diag_log typeOf _x} count (nearestObjects [player,[],100]); Then check your rpt. -
Toggle inventory - for TAB users
das attorney replied to das attorney's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Indeed! I was playing a lot over the weekend because it doesn't completely suck anymore and enjoying the toggle inv. Then I went back to Arma today and was like "ugh". -
[SOLVED] Help with Simple Sandbag Script
das attorney replied to Alpine_gremlin's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Ha ha whoops I didn't even look at the context! My bad, ^^This! -
[SOLVED] Help with Simple Sandbag Script
das attorney replied to Alpine_gremlin's topic in ARMA 3 - MISSION EDITING & SCRIPTING
It shouldn't broadcast anyway if it's done by addaction -
[SOLVED] Help with Simple Sandbag Script
das attorney replied to Alpine_gremlin's topic in ARMA 3 - MISSION EDITING & SCRIPTING
if (time == 5) then = is for assignation == is for comparison