alexluthor
Member-
Content Count
20 -
Joined
-
Last visited
-
Medals
Community Reputation
10 GoodAbout alexluthor
-
Rank
Private First Class
-
Spawning units in random direction - Dedicated Server
alexluthor replied to alexluthor's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Update - The trigger worked perfectly. Thanks again. -
Spawning units in random direction - Dedicated Server
alexluthor replied to alexluthor's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Thanks for the clarification and for the framework. They`ll be good additions to my library : ) I`ve remembered that I`ve read here that the triggers send the commands to all machines, so I figure it might solve my problem. I`ve changed the idea from the addactions to radio activated triggers. For that, I`ve placed the following code into the activation field of a radio activation trigger nul = [(Instructor), 8] execVM "ContatoFrente.sqf"; Whereas Instructor is the name of the Instructor model. And I`ve pretty much copied Kylania`s script as follows. if (isServer) then { // Select instructor and number of enemies _sourcePoint = _this select 0; _enemyCount = _this select 1; // Select random enemy position in front of player. _randDir = getDir vehicle _sourcePoint - 45; _randDir = _randDir + random(90); _randDist = (random 100) + 200; _enemyLoc = [(getPos vehicle _sourcePoint select 0) + (_randDist * sin(_randDir)), (getPos vehicle _sourcePoint select 1) + (_randDist * cos(_randDir)), 0]; // Create group and reveal players position grp = [_enemyLoc, east, _enemyCount] call BIS_fnc_spawnGroup; null = [grp,(getPos vehicle _sourcePoint)] call BIS_fnc_taskAttack; grp reveal _sourcePoint; }; It is working in my machine again. Once I test it on a dedicated server I`ll post the results below. Thanks again for the help. -
Spawning units in random direction - Dedicated Server
alexluthor posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Guys, I'm having some problems using a script in multiplayer. My intent is to use this on a training mission, where the instructor would be able to spawn units in front of the players in a somewhat random position. He should be able to do it by using an addaction I've built a script using samples from Kylania (http://www.kylania.com/site/) and it works fine in my machine, but when I play it on the dedicated server the units never spawn. Below follow the code: Addaction placed on the init of the instructor this addAction ["ContactFront","ContactFront.sqf",(3)]; ContactFron.sqf in the mission folder // Select the user of the addaction and the number of enemy units. _sourcePoint = _this select 1; _enemyCount = _this select 3; // Select random direction in front of the addaction’s user. _randDir = getDir vehicle _sourcePoint - 45; _randDir = _randDir + random(90); _randDist = (random 100) + 200; _enemyLoc = [(getPos vehicle _sourcePoint select 0) + (_randDist * sin(_randDir)), (getPos vehicle _sourcePoint select 1) + (_randDist * cos(_randDir)), 0]; // Create attack group and lead them to the player’s location. grp = [_enemyLoc, east, _enemyCount] call BIS_fnc_spawnGroup; null = [grp,(getPos vehicle _sourcePoint)] call BIS_fnc_taskAttack; grp reveal _sourcePoint; Does anyone have a clue why it is not working in the dedicated server? Appreciate the help guys. -
A pilot unit may have skills Engineer?
alexluthor replied to jetherjr's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
I've tried to search for something like this but I couldn't find an answer. I noticed, though, that all engineers have a variable called 'engineer' set to 1 in its .pbo, which is probably what will tell the game that he is an engineer ... but I have no experience modifying addons and didn't want to try and place this variable in another class. Perhaps you could follow up on this. Hope it helps a bit. -
Thank you for the clarifications : )
-
Guys, can anyone help me interpret the results of the ballistic chart. Below are the weapon and firing characteristics Weapon: M4A1 Ammo: B_556x45_Ball Elevation: 0.65 X-offset: 0.2 Target Distance: 300m Avg. speed: 739 m/s firing position: prone I take it that the elevation represents the angle of rifle relative to the ground. From what I've read in the the forums, the M4 and M16 rifles were supposed to be zeroed at 300m. Does this mean that the closer the elevation is from 0 in the zeroed distance the better? What does X-offset mean? Would this by any chance be the wind differential from the aiming point? Now, for the results: Distance Height of impact (?) 0 - 0 50 - 0.167336 109 - 0.443062 152 - 0.606375 204 - 0.757908 254 - 0.84304 300 - 0.865608 Does the second column represent the height of bullet impact? And this case, does it mean I hit the riflemen at 0.9m, roughly in the chest area? Thanks in advance for the help : )
-
calling ace wounds functions via trigger
alexluthor replied to alexluthor's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Thanks for the help man, appreciate it. -
calling ace wounds functions via trigger
alexluthor replied to alexluthor's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Hey man, thanks for the help, unfortunately, it didn't work : ( It ocurred to me that I was trying the function only on AI units. When I tried it on a player controlled unit the function worked. Your script worked like a charm with a player controlled unit as well, so I guess the ACE functions works differently depending of who controls the units. Researching the developer's site: http://ace.dev-heaven.net/wagn/Wounding_System+notes I found that there is a global variable that monitors whether AI units are subject to the ACE wounds effects (ace_sys_wounds_noai). The problem is that I don't know how to check if these variable is in the missionNamespace or how to erase it from there. Do you have any idea how to work with these variable? -
calling ace wounds functions via trigger
alexluthor posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Guys, I’m trying to create the following scenario. The informant is a tribal leader and will only give up some valuable information if the allied medics heal his soldiers. To represent the wounded soldiers, I placed the following function on a few soldiers (replacing the name where applicable): [soldier1, 0.6] call ace_sys_wounds_fnc_addDamage; I’m using the ACE Wounds System Module and the function works fine if I place it on the init line of the unit. The problem is that this phase of the mission requires a half hour of gameplay and by the time the players reach the area, the victims have all died from the untreated injuries. I figured I could solve this by calling the function only when the players are nearing the victims. So I placed the same function via trigger, by having it detect bluefor in the trigger radius and, on the activation field, placed the same code. Unfortunately, when run by the trigger it doesn’t work. Anyone have any ideas about what I'm doing wrong or suggestions to get around this? thanks in advance AlexLuthor -
Teleporting a whole group?
alexluthor replied to alexluthor's topic in ARMA - MISSION EDITING & SCRIPTING
Thanks professor, worked like a charm : ) -
Hello all, I'm in need of help regarding an attempt to teleport a soldier and his group to an LHD carrier. I found a great script on the net to teleport a single player using an add action in the init line of a flag. The original script goes like this: Teleporting script I tried to modify it a bit, specially the last line so that it would do the same action to every member of the player's group using the code forEach command as described below: The code is not working. It teleports the player to the desired position but the members of his group are still left behind. Do you guys see what I'm doing wrong? Thanks in advance for any help AlexLuthor
-
AI not using weapons
alexluthor replied to alexluthor's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Thanks Rail82, not having to link the unit to another AI unit is actually much better : ) In order for it to work tough, I had to use createCenter first. Here's the code I'm using in the activation field of a trigger. The civilian character is a rocker, hence the name. HQ = createCenter East; HQ1 = createGroup East; [bon_Jovi] joinsilent HQ1; Bon_Jovi addMagazine "7Rnd_45ACP_1911"; Bon_Jovi addWeapon "Colt1911"; Bon_Jovi selectWeapon "Colt1911"; -
AI not using weapons
alexluthor replied to alexluthor's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Hey man, thanks a lot. It worked. I think that maximizing the skill slider is what did the trick. thanks again. -
Hello guys, I’m wondering if you could help me with a certain mission. The concept revolves around the evacuation of American civilians from a city soon to be overtaken by the enemy. Only American civilians are to be rescued and this causes the civilians left behind to revolt. I want to simulate this revolt by having two or three citizens draw weapons on the players, who portray the American soldiers. For this to work I have to tackle two problems: A. Turning a couple civilians to the enemy side B. Making them draw concealed weapons Problem A was taken care by making the civilians join an enemy unit with a soldier with a higher ranking then the civilians. This turns the group into enemy soldiers. I tried to solve problem B by creating a trigger which had an addweapon command in its activation field. I wanted to simulate the fact that the civilians had a pistol concealed and adding the trigger while in mission simulated this effect. The problem, though, is that the civilian do not shoot the players, he stands his ground and just watches me. He only picks his pistol if I wound him first. If I give the civilian a rifle, he waits a couple seconds and eventually seems to shoot my player. But I think it would be a hard pill to swallow for the guy to hide an assault rifle within his jacket. If I add the code in the initialization field of the unit, the unit keeps the pistol in his hand, thus, spoiling the surprise effect, but at least it shoots his pistol. I have no idea how to solve it, can anyone help please. Thanks in advance, Alex
-
How do I make my PMC units Bluefor
alexluthor replied to SpecterM's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Thank you very much guys.