-
Content Count
123 -
Joined
-
Last visited
-
Medals
Posts posted by Melmarkian
-
-
I stopped using ZEUS after the last patch because something is screwed with it because of the AI changes in 1.59.
-
This way it doesn´t show errors:
{if (((side _x) != West) && (not alive _x)) then { _jok = random 10; if (_jok >= 5) then {_x addaction ["Look for a clude", "Clude.sqf"]; sleep 100; }}} forEach allUnits;
But I don´t know about the functionality.
-
if you want it really simple do this:
into init field of unit:
this addAction ["Arty Shot", "artyshot.sqf", laserTarget player, 6, false, true, "", "currentweapon player == 'Laserdesignator'"];
artyshot.sqf
_round = "sh_120_he" createVehicle [getpos cursorTarget select 0, getpos cursorTarget select 1, 5];
You will get the action when you use the Designator. Point at something and boom!
If you want to do real artillery action take a look at this:
-
Sorry, but you should really do a syntax check.
What do you want to do?
Check on all units if they are not west and not alive. If true addaction to all units?
-
Your code will not work because you forgot arguments at settriggerstatements and triggeractivation doesn´t work that way.
Take a look at that:
and createTrigger with the subcommands
btw. you would better use a program like ArmaEdit or Squint to write your scripts. It will make your life a lot easier.
-
Ok,
He plays it one more time after the switchtrigger. But this has worked:
1. Into init-field:
an2 addEventHandler ["AnimStateChanged", {an2 switchMove "UnaErcVelitelProslov1"}];
2. Trigger opfor detected by blufor with
an2 switchMove ""; an2 removeEventHandler ["AnimStateChanged", 0];
I used this for captives in one of my missions.
-
I would do it this way:
1. Create a waypoint after the cycle
2. Place a Trigger with OPFOR detected by BLUFOR. Set Type to Switch and sync it with the cycle waypoint. Maybe place in the on act. Field unit switchmove "";
3. In case of friendly fire I would use the firednear eventhandler with switchmove "";
or set a variable to true with the firednear eventhandler and make it another condition for the trigger at 2. (this OR hasfired)
-
Yes, RPG7 fly how far? 150-200 meters before they drop. Not exactly forever flying.
-
_tempRuckMagList + [_tempclass];
this should be changed to
_tempRuckMagList = _tempRuckMagList + [_tempclass];
-
just use addaction:
player addaction ["TAKE PHOTO", "Photoscript.sqf", [], 0, false, false, "", "player distance target1 < 100"];
photoscript:
titletext ["", "WHITE OUT"]; titletext ["", "WHITE IN"]; phototaken = true;
Don´t know about a sound. You have to look through the soundfiles or add one.
-
Demonized is right. Just spawn stuff if you use it.
I found something helpful to get rid of an area of objects:
I placed a gamelogic called "sidemission" at the center of the area I want to delete and create a trigger with the following On Act.
{deleteVehicle _x} foreach (position sidemission nearEntities 200); {deleteVehicle _x} foreach (position sidemission nearObjects 200);
Deletes even furniture and crews of vehicles.
-
This works:
stealm18 = createVehicle ["Ka52Black", getMarkerPos "helimarker", [], 0, "NONE"]; stealm18 setvehiclevarname "stealm18"; stealm18 setFuel 0; stealm18 allowDamage false;
why more complicated?
And what is _vehicle in your code? It don´t see where it points.
Or just:
_vehicle = createVehicle ["Ka52Black", getMarkerPos "helimarker", [], 0, "NONE"]; _vehicle setvehiclevarname "stealm18"; _vehicle Call Compile Format ["%1=_This ; PublicVariable ""%1""","stealm18"]; _vehicle setFuel 0; _vehicle allowDamage false;
-
I noticed when you spawn explosives a few meters above the ground they do more damage.
-
-
hm, don´t think so.
I joined a unit to the player group and called SHK_fnc_readdFAModules.
The First Aid action shows up but doesn´t respond.
-
Shuko do you think your code would work also on spawned AI soldiers that join the player group?
-
Hi,
to get a string out of it I would do:
thearray = ["1","2","3","4"]; thestring = format ["%1,%2,%3,%4", thearray select 0, thearray select 1, thearray select 2, thearray select 3];
To do this dynamic.. I don´t know. You can get the number of array elements with
count thearray
I don´t know about string manipulation in arma/sqf.
EDIT: Wasn´t that hard:
thearray = ["1","2","3","4","5"]; _string = ""; for "_i" from 0 to (count thearray) -1 do { _string1 = format ["%1,", thearray select _i]; _string = _string + _string1; }; hint _string;
EDIT2: And if you want to get rid of the last comma:
thearray = ["1","2","3"]; _string = ""; for "_i" from 0 to (count thearray) -1 do { if (_i == ((count thearray) -1)) then { _string1 = format ["%1", thearray select _i]; _string = _string + _string1; }else { _string1 = format ["%1,", thearray select _i]; _string = _string + _string1; }; }; hint _string;
-
Try to insert a few hints to see what works in your script and what not.
1. What is _sw and _hide for?
2. while (alive local player)
does this ever return true? I don´t know much about the mp stuff but biki says it checks if someone is local. I don´t think this one checks the right condition.
-
Please give us more information.
What is your side? OPFOR?
Have you set Resistance friendly to OPFOR?
-
-
I forgot one important addon is use:
You can basicly test everything ingame with this tool.
-
I see you are using the RESISTANCE side for the spawned groups. Are you sure you set them to hostile to the right side?
-
Hi,
I tried your script today and noticed something strange:
Most of the groups I place in the editor without waypoints start to run to some random position a few hundred meters away when I start the mission.
It seems like this isn´t a problem in your code but some new ai behaviour, because when I use the RMM_Reducer from Rommel they do the same.
I include a sample mission:
http://www.mediafire.com/?852yzuqix29ftj6
When I start the mission, the USMC unit starts to run to a place near the airport and the russian one stays at its starting point.
Edit:
When I create a waypoint for the USMC group he first runs to his random spot and then moves to the waypoint.
Edit2:
Just tested it: The remaining unit is fleeing (tested with fleeing _unit) when all his friends disapear.
Edit3:
I have inserted two lines of code into the fsm:
At "Cache Units" :
_cep_grp allowFleeing 0;
before the group is deleted
and
At "Normalise Units":
(group _cep_leader) allowFleeing 0.3;
as last line.
This way it works even when the AI skill is low. I would like to set the allowFleeing to the value it was before the unit is cached but I don´t know how to get the number.
-
When there are no editor placed units of a faction, they really behave abnormal.
Just place a unit of the faction and set possiblility of presence to 0.
Could be your problem.
Am I the only one who disliked the futuristic approach?
in ARMA 3 - GENERAL
Posted
I will certainly love it. Future, past or present! I play arma because of way the fights are handled, the way the AI works and the possibilities with infantry, helis and tanks. I don´t play arma because the weaponnames are realistic.