-
Content Count
3059 -
Joined
-
Last visited
-
Medals
-
Medals
Everything posted by jshock
-
Removing gear from opfor
jshock replied to knifeprty's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Yes that would make even more sense now wouldn't it, at this point it would probably just be better to go with Beerkan's plan....lol :p -
Function to get empty position
jshock replied to Schatten's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Is this not essentially, just with the max object size added to it?: BIS_fnc_findSafePos -
lose weapons spawn on ground / in buildings and stuff
jshock replied to Rektavu's topic in ARMA 3 - MISSION EDITING & SCRIPTING
You could possibly achieve what you are looking for with this code snippet, you may have to make some alterations, but it seems to be what you want..? -
Force Ai to aatck if player is in trigger
jshock replied to mr_shadow's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Something with doTarget may be up for grabs, using the onAct and onDeact fields of your trigger with: //in trigger condition field player in thisList; -
Almost all of the BIS_fnc I have seen or used are called not spawned, because most return a value and don't need to be run on a scheduled environment.
-
Simple Randomized Mortar Script (no AI)
jshock replied to jshock's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Update to: Version 1.1 Changelog: v1.1 >>Code optimization and organization. And Mr. Foxhound, there are updated instructions and short descriptions on how to use the script and could you please change the author name to just: J.Shock, please sir. Also just leave the author website field blank. And there is no credit or thanks as well. Sorry for the extra hassle. -
Fast rope A3, is there a good mp script?
jshock replied to lightspeed_aust's topic in ARMA 3 - MISSION EDITING & SCRIPTING
If your using waypoints for both the group and the helicopter make sure that they are synced, so the transport unload (or whatever it is) with the get out (or blah) for the infantry is synced up, or at least I think that would work. And if not, this may set you on the right path for either an answer to your question or a better question: -
Well, if you see the timestamp in the above previous post of mine, I said I would have a beta version of this script that could be integrated and working with systems such as EOS/MCC/Zeus etc, over a month ago. So, sorry for the delay, but I do now currently have a testable version of the script. If you are interested in testing and reporting back issues with the script please PM me on here, if you are interested, however, I do expect that you have some knowledge as to what to look for when testing something, such as does the script work for JIP in a dedicated environment, so if you don't have any clue what I just stated, please don't PM me.
-
You would have thought I would have remember that, considering we went over that last night.... ---------- Post added at 00:40 ---------- Previous post was at 00:03 ---------- EDIT: Replace the ( ) on the "while" in the while loop to { }, my mistake, made the same mistake in another thread, damn Java class......
-
OMG....thanks again Iceman, sorry we are using Java in my CS class....ugh........and while loop syntax is with ( ) not { }
-
Well do you want it identified as "friend" when you have both the uniform and the weapon, or just one or the other? I would recommend that you have to have both because if it's either the unit will switch sides constantly if he has a "friendly" uniform on, but has an "enemy" weapon. Below is with the recommended changes: //Forgot the call line for this script goes in the unit's init field as: null = [this] execVM "scriptName.sqf"; _unit = (_this select 0); _eastGrp = createGroup EAST; _westGrp = createGroup WEST; if (isNull _unit) exitWith {}; while (true) do { if ((currentWeapon _unit == "Weapon_arifle_Katiba_F") && (currentUniform _unit == "Classname")) then { _unit joinSilent _eastGrp; };//<<Change classname to type of weapon you want to be identified for OPFOR side if ((currentWeapon _unit == "Weapon_arifle_MXM_F") && (currentUniform _unit == "Classname")) then { _unit joinSilent _westGrp; };//<<Change classname to type of weapon you want to be identified for BLUFOR side sleep 3; };
-
You could just do a for loop structure in a script: //name this script addFishBoat.sqf //and place the following in the boat's init field: null = [#, this] execVM "addFishBoat.sqf" //obviously # being the number of fish you would want _numFish = (_this select 0); _ship = (_this select 1); for "_i" from 0 to (_numFish) step 1 do { _fish = "Salema_F" createVehicle position _ship; _fish attachTo [_ship,[0.5,1.2,-1]]; _fish setDir (random 359); };
-
Change Weather on Dedicated Server
jshock replied to csk222's topic in ARMA 3 - MISSION EDITING & SCRIPTING
The arguments are the parameters being passed into your function (teg_fnc_rain), or at least I think so, or at least that's how I understand the wiki page on BIS_fnc_MP. -
_unit = (_this select 0); _eastGrp = createGroup EAST; _westGrp = createGroup WEST; if (isNull _unit) exitWith {}; while (true) do { if (currentWeapon _unit == "Weapon_arifle_Katiba_F") then { _unit joinSilent _eastGrp; };//<<Change classname to type of weapon you want to be identified for OPFOR side if (currentWeapon _unit == "Weapon_arifle_MXM_F") then { _unit joinSilent _westGrp; };//<<Change classname to type of weapon you want to be identified for BLUFOR side sleep 3; };
-
while (true) do { _tickCount = [WEST, 0, false] call BIS_fnc_respawnTickets; if (_tickCount <=0) exitWith {["END1", false, 2] call BIS_fnc_EndMission};//<<Change the false to true for a Successful Mission ending, false means it will display the Failed Mission ending. sleep 5; };
-
Removing gear from opfor
jshock replied to knifeprty's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hehe, lol, yea...brain feels a bit off today :p. -
Removing gear from opfor
jshock replied to knifeprty's topic in ARMA 3 - MISSION EDITING & SCRIPTING
More in-depth and ensuring the weapon doesn't have a IR Laser on it: //If using editor placed units, place the following in your init.sqf if (side _x = EAST) then { { _x removePrimaryWeaponItem "acc_pointer_IR"; _x addPrimaryWeaponItem "acc_flashlight"; _x enableGunLights "forceon";//<<Turns on the light as well. } foreach allUnits; }; -
What do you mean by name?
-
You mean like the "respawn_west" marker? You would just put this in your trigger's onAct field: "respawn_west" setMarkerPos (getPos newPos);//obviously define your new position And for your 3D markers question: drawIcon3D
-
Spectator mode after respawn tickets run out.
jshock replied to whiztler's topic in ARMA 3 - MISSION EDITING & SCRIPTING
This may be a stretch of a workaround, but maybe you could work something with it?: BIS_fnc_selectRespawnTemplate -
Try: In whatever box/bomb you are using, put this in its init field: this addAction ["Arm Bomb", "arm.sqf", [true, false], 5, false, true, "_this distance _target < 3"]; arm.sqf: _box = (_this select 0); _id = (_this select 2); _arming = (_this select 3) select 0; _defuse = (_this select 3) select 1; if (!_arming && _defuse) then { _box removeAction _id; _arming = false; _defuseID = _box addAction ["Arm Bomb", "arm.sqf", [true, false], 5, false, true, "_this distance _target < 3"]; }; while (_arming) do { systemChat "Bomb is armed."; _box removeAction _id; _defuseID = _box addAction ["Defuse Bomb", "arm.sqf", [false, true], 5, false, true, "_this distance _target < 3"]; _defuseTime = [] spawn { sleep 40; }; //40 seconds until bomb "explodes" waitUntil {scriptDone _defuseTime || _defuse}; //wait until 40 seconds is up or _defuse has been set to true if (!_arming && _defuse) exitWith { systemChat "Bomb Defused"; _box removeAction _defuseID; _box addAction ["Arm Bomb", "arm.sqf", [true, false], 5, false, true, "_this distance _target < 3"]; }; if (scriptDone _defuseTime) exitWith { _box setDamage 1; }; //explosion? sleep 3; }; To be honest I feel as if I'm missing something, but I'm too tired to think about it, but hopefully someone will come and find what I'm missing :p. I may also have some extra un-needed or improper checks, but as I said...
-
How do I make addaction available to all players?
jshock replied to csk222's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Just as a side question, why set the marker size to [1,1] if that's the default size? Unless your moving the marker from somewhere else, where it started smaller? -
Objects Fall Through Table
jshock replied to scooterperpetual's topic in ARMA 3 - MISSION EDITING & SCRIPTING
If you have just an normal editor placed object you have to use a non-local "this" so in other words take out the "_" and I also set the elevation to 0.8m so it sits nicely right above the surface of the table: this enableSimulation false; this allowDamage false; But along with what Iceman asked, are you placing objects on a table/surface, to then be able to pick them up and move them, then place them down again? -
Flare script help...please
jshock replied to BEAKSBY's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Alter what this video uses: -
[CODE SNIPPET] Using actionKeys && prevent players from reloading if magazine is full
jshock replied to dreadedentity's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Looking good there Dread :clap:.