-
Content Count
12 -
Joined
-
Last visited
-
Medals
Community Reputation
10 GoodAbout Finland
-
Rank
Private First Class
-
Dead/Ace Spectator players don't see outro cameras
Finland posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
I made a mission with an intro/outro, but it has no respawns, and like the title says, players who have died don't see the outro. I've tried making it so that spectating is disabled when the outro is triggered, but then players just see from their dead bodies. Any idea how to make all players dead or alive see the outro video? Thanks in advance! -
Weapon Spawn Script Works in Single Player But Not Multiplayer.
Finland posted a topic in ARMA 2 & OA : ADDONS - Configs & Scripting
Hi, I'm trying to use this script I found and customized to fit a mission I'm making, and it works fine in SP, but when I try to use it in MP, it runs, and gives the initial "Waiting for gear to spawn" hint, but nothing spawns. Anyone know what might be causing it? Here's the script. Thanks in advance! ---------- Post added at 06:07 ---------- Previous post was at 04:23 ---------- Resolved, script was missing lines. -
Adding ACE Jerry Cans to weapon spawn script
Finland posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Just found this editing section, so my old thread can be deleted forums.bistudio.com/showthread.php?162159-Spawning-ACE-Jerry-Cans-in-random-item-spawn-script Hi everyone, I'm making a mission and I have already gotten a weapon/item spawn script that works to create randomly selected items in buildings. What I need is to also have it spawn ACE Jerry Cans in the mix. From what I understand the Jerry Can is classified as a vehicle, not a weapon or magazine, so I don't know how to add it to this script. Thanks in advance to anyone who can help! -
Spawning ACE Jerry Cans in random item spawn script?
Finland posted a topic in ARMA 2 & OA - QUESTIONS & ANSWERS
Hi everyone, I'm making a mission and I have already gotten a weapon/item spawn script that works to create randomly selected items in buildings. What I need is to also have it spawn ACE Jerry Cans in the mix. From what I understand the Jerry Can is classified as a vehicle, not a weapon or magazine, so I don't know how to add it to this script. Thanks in advance to anyone who can help! -
Random Weapon Spawns Inconsistent Between Players
Finland replied to Finland's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Okay, so I actually took the time to go over everything in the script, and I found a few syntax errors. I fixed those and now it works. I just have one more question, is there a way to make sure that every time a gun spawns, at least one magazine spawns with it? Thanks! ---------- Post added at 03:59 ---------- Previous post was at 03:25 ---------- Alright, I figured that one out too. Last question: If I want to add another category of weapon, let's say "weaponrare", would I just make a new line at the top like "_weaponsrare ["","",""];"? -
Random Weapon Spawns Inconsistent Between Players
Finland replied to Finland's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Hmm... Setting the debug to true doesn't show anything on the map, so I don't think it's working. Based on the information I gave last post, since I haven't changed anything since then, what do you think it might be? -
Random Weapon Spawns Inconsistent Between Players
Finland replied to Finland's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Okay, so I think I may be doing it wrong. I did change the classes in the categories, as well as some of the probabilities, so I'll include the script at the end. So I have the script saved as "weapons.sqf" in my mission folder. I have a game logic in the game with this in the init field "_nul = [guns,200,false] execVM "weapons.sqf";" And then a trigger in the middle of a town named "guns". Nothing spawns and there is no indication that the script even ran. Sorry to be so clueless, but you're being so helpful and I can't stop asking questions :rolleyes: if (!isServer) exitwith {}; _weapons = ["RH_RK95", "RH_AK47", "RH_AKS47", "RH_AKM", "RH_AKMs", "RH_AK74", "RH_AKs74", "ACE_M72", "RH_AKS74U","FN_FAL","huntingrifle","LeeEnfield","RH_M16A1", "RH_AR10s", "RH_M16A2","RH_M4A1","sa58p_EP1","Sa58V_EP1","RH_aks74sp", "RH_rpk47", "ACE_RPG22", "ACE_RPG27","ACE_RPG29","Saiga12K","SVD"]; _items = ["ItemMap","ItemWatch","ItemCompass","ItemGPS","Binocular", "ACE_Earplugs","ACE_GlassesGasMask_US"]; _med = ["ACE_Medkit","ACE_Morphine","ACE_Tourniquet","ACE_ Bandage","ACE_Epinephrine","ACE_Morphine"]; _radio = ["ACRE_PRC343"]; _pistol = ["Colt1911", "Makarov"]; _backpack = ["ACE_Coyote_Pack_Wood", "ACE_ALICE_Backpack"; _magazines = ["ACE_PG7VL_PGO7", "8Rnd_B_Saiga12_Pellets", "8Rnd_B_Saiga12_74Slug", "ACE_30Rnd_556x45_SB_Stanag", "RH_45Rnd_545x39_mag", "RH_75Rnd_762x39_mag", "30Rnd_762x39_SA58", "30Rnd_762x39_AK47", "30Rnd_545x39_AK", "10x_303", "10Rnd_762x54_SVD", "ACE_Bandage","ACE_Knicklicht_B","ACE_Knicklicht_Y","ACE_LargeBandage","ACE_Epinephrine","ACE_Medkit","ACE_Morphine","PipeBomb"]; _centerPoint = _this select 0; // define location for center. _spawnSize = _this select 1; // radius to find house positions from centerpoint. _debug = _this select 2; // if true a marker is shown on ititial spawn location. _houseList = getPos _centerPoint nearObjects ["House",_spawnSize]; _i = 0; { _c = 0; while { format ["%1", _x buildingPos _c] != "[0,0,0]" } do {_c = _c + 1}; if (_c > 0) then { _ranNum = floor(random _c); if (random 100 > 80) then { _weapon = _weapons select floor(random(count _weapons)); _mag = (getArray (configFile / "CfgWeapons" / _weapon / "magazines")) select 0; _weap = createVehicle ["WeaponHolder", [0,0], [], 0, "CAN_COLLIDE"]; _weap addMagazineCargoGlobal [_mag, (round (random 3))]; _weap addWeaponCargoGlobal [_weapon,1]; _weap setPos (_x buildingPos _ranNum); if (_debug) then { _marker = format ['_marker%1',_i]; _mkr = createMarker[_marker, getPos _weap]; _marker setMarkerType 'hd_dot'; _marker setMarkerSize[1, 1]; _marker setMarkerDir 1; _marker setMarkerColor 'ColorOrange'; _marker setMarkerText ''; _i = _i + 1; }; }; _ranNum = floor(random _c); if (random 100 > 60) then { _weapon = _pistol select floor(random(count _pistol)); _mag = (getArray (configFile / "CfgWeapons" / _weapon / "magazines")) select 0; _weap = createVehicle ["WeaponHolder", [0,0], [], 0, "CAN_COLLIDE"]; _weap addMagazineCargoGlobal [_mag, (round (random 4))]; _weap addWeaponCargoGlobal [_weapon,1]; _weap setPos (_x buildingPos _ranNum); if (_debug) then { _marker = format ['_marker%1',_i]; _mkr = createMarker[_marker, getPos _weap]; _marker setMarkerType 'hd_dot'; _marker setMarkerSize[1, 1]; _marker setMarkerDir 1; _marker setMarkerColor 'ColorOrange'; _marker setMarkerText ''; _i = _i + 1; }; }; _ranNum = floor(random _c); if (random 100 > 70) then { _weapon = _items select floor(random(count _items)); _weap = createVehicle ["WeaponHolder", [0,0], [], 0, "CAN_COLLIDE"]; _weap addWeaponCargoGlobal [_weapon,1]; _weap setPos (_x buildingPos _ranNum); if (_debug) then { _marker = format ['_marker%1',_i]; _mkr = createMarker[_marker, getPos _weap]; _marker setMarkerType 'hd_dot'; _marker setMarkerSize[1, 1]; _marker setMarkerDir 1; _marker setMarkerColor 'ColorOrange'; _marker setMarkerText ''; _i = _i + 1; }; }; _ranNum = floor(random _c); if (random 100 > 60) then { _weapon = _radio select floor(random(count _radio)); _weap = createVehicle ["WeaponHolder", [0,0], [], 0, "CAN_COLLIDE"]; _weap addWeaponCargoGlobal [_weapon,1]; _weap setPos (_x buildingPos _ranNum); if (_debug) then { _marker = format ['_marker%1',_i]; _mkr = createMarker[_marker, getPos _weap]; _marker setMarkerType 'hd_dot'; _marker setMarkerSize[1, 1]; _marker setMarkerDir 1; _marker setMarkerColor 'ColorOrange'; _marker setMarkerText ''; _i = _i + 1; }; }; _ranNum = floor(random _c); if (random 100 > 70) then { _weapon = _backpack select floor(random(count _backpack)); _weap = createVehicle ["WeaponHolder", [0,0], [], 0, "CAN_COLLIDE"]; _weap addWeaponCargoGlobal [_weapon,1]; _weap setPos (_x buildingPos _ranNum); if (_debug) then { _marker = format ['_marker%1',_i]; _mkr = createMarker[_marker, getPos _weap]; _marker setMarkerType 'hd_dot'; _marker setMarkerSize[1, 1]; _marker setMarkerDir 1; _marker setMarkerColor 'ColorOrange'; _marker setMarkerText ''; _i = _i + 1; }; }; _ranNum = floor(random _c); if (random 100 > 50) then { _weapon = _med select floor(random(count _med)); _weap = createVehicle ["WeaponHolder", [0,0], [], 0, "CAN_COLLIDE"]; _weap addMagazineCargoGlobal [_weapon,1]; _weap setPos (_x buildingPos _ranNum); if (_debug) then { _marker = format ['_marker%1',_i]; _mkr = createMarker[_marker, getPos _weap]; _marker setMarkerType 'hd_dot'; _marker setMarkerSize[1, 1]; _marker setMarkerDir 1; _marker setMarkerColor 'ColorOrange'; _marker setMarkerText ''; _i = _i + 1; }; }; _ranNum = floor(random _c); if (random 100 > 65) then { _weapon = _magazines select floor(random(count _magazines)); _weap = createVehicle ["WeaponHolder", [0,0], [], 0, "CAN_COLLIDE"]; _weap addMagazineCargoGlobal [_weapon,(round(random 2))]; _weap setPos (_x buildingPos _ranNum); if (_debug) then { _marker = format ['_marker%1',_i]; _mkr = createMarker[_marker, getPos _weap]; _marker setMarkerType 'hd_dot'; _marker setMarkerSize[1, 1]; _marker setMarkerDir 1; _marker setMarkerColor 'ColorOrange'; _marker setMarkerText ''; _i = _i + 1; }; }; _ranNum = floor(random _c); if (random 100 > 75) then { _weapon = _magazines select floor(random(count _magazines)); _weap = createVehicle ["WeaponHolder", [0,0], [], 0, "CAN_COLLIDE"]; _weap addMagazineCargoGlobal [_weapon,(round(random 3))]; _weap setPos (_x buildingPos _ranNum); if (_debug) then { _marker = format ['_marker%1',_i]; _mkr = createMarker[_marker, getPos _weap]; _marker setMarkerType 'hd_dot'; _marker setMarkerSize[1, 1]; _marker setMarkerDir 1; _marker setMarkerColor 'ColorOrange'; _marker setMarkerText ''; _i = _i + 1; }; }; _ranNum = floor(random _c); if (random 100 > 90) then { _weapon = _magazines select floor(random(count _magazines)); _weap = createVehicle ["WeaponHolder", [0,0], [], 0, "CAN_COLLIDE"]; _weap addMagazineCargoGlobal [_weapon,(round(random 3))]; _weap setPos (_x buildingPos _ranNum); if (_debug) then { _marker = format ['_marker%1',_i]; _mkr = createMarker[_marker, getPos _weap]; _marker setMarkerType 'hd_dot'; _marker setMarkerSize[1, 1]; _marker setMarkerDir 1; _marker setMarkerColor 'ColorOrange'; _marker setMarkerText ''; _i = _i + 1; }; }; }; sleep 0.123; } forEach _houseList; -
Random Weapon Spawns Inconsistent Between Players
Finland replied to Finland's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
So how do I set the location in this part? _centerPoint = _this select 0; // define location for center. _spawnSize = _this select 1; // radius to find house positions from centerpoint. _debug = _this select 2; // if true a marker is shown on ititial spawn location. And other than that, are there any other variables that I need to set? -
Random Weapon Spawns Inconsistent Between Players
Finland replied to Finland's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Using addweaponcargoglobal just makes it so the script doesn't execute, how am I supposed to use it? -
Random Weapon Spawns Inconsistent Between Players
Finland replied to Finland's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
This goes at the top or what? -
Random Weapon Spawns Inconsistent Between Players
Finland replied to Finland's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
That's what I'm trying to figure out how to do. I have the script being run through a game logic, and I'm the host, so how would I run the script server side? 2nd Ranger, I'll try that. Thanks! -
Random Weapon Spawns Inconsistent Between Players
Finland posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Hi everyone, This is my first post on the forums so I'm not sure if this is in the right spot, so feel free to move it if it belongs somewhere else. So I've been trying to make random weapons and items spawn in buildings across the map, and it works fine with the exception of one thing: Everyone sees different items. The best way I can think of to describe it is as the script being executed client side rather than server side. I don't really know how to script from scratch, so this is just other people's scripts they have posted on the forums which I have edited for my needs. _weapons = ["Colt1911", "Makarov", "AK_47_S", "AK_47_M", "AKS_74", "AK_74", "ACE_M72", "AKS_74_U","FN_FAL","huntingrifle","LeeEnfield","M16A2","M4A1","sa58p_EP1","Sa58V_EP1","ACE_RPK", "ACE_RPG22", "ACE_RPG27","ACE_RPG29", "AKS_74_pso","Saiga12K","SVD"]; _items = ["ACRE_PRC343", "ItemMap","ItemWatch","ItemCompass","ItemGPS","Binocular","ACE_ALICE_Backpack","ACE_Earplugs","ACE_GlassesGasMask_US","ACE_Map"]; _magazines = ["ACE_PG7VL_PGO7", "ACE_30Rnd_556x45_SB_Stanag", "ACE_75Rnd_545x39_S_RPK", "ACE_40Rnd_762x39_S_AK47", "30Rnd_762x39_SA58", "ACE_30Rnd_762x39_AP_AK47", "ACE_30Rnd_545x39_AP_AK", "10x_303", "10Rnd_762x54_SVD", "ACE_Bandage","ACE_Knicklicht_B","ACE_Knicklicht_Y","ACE_LargeBandage","ACE_Epinephrine","ACE_Medkit","ACE_Morphine","PipeBomb"]; hintsilent "placing loot"; _buildings = nearestObjects [player, ["house"], 60000]; _markernum = 0; { _building = _x; hintsilent "placing loot."; // search more positions _positions = 0; _i = 0; _loop = 1; while {_loop == 1} do { _next = _building buildingPos _i; if (((_next select 0) == 0) && ((_next select 1) == 0) && ((_next select 2) == 0)) then { _loop = 0; } else { _positions = _positions + 1; _i = _i + 1; }; }; _posnumber = floor (random _positions); _position = _building buildingpos _posnumber; hintsilent "placing loot.."; if (random 100 > 80) then { _weapon = _weapons call BIS_fnc_SelectRandom; _mag=(getArray (configFile/"Cfgweapons"/_weapon/"magazines")) select 0; _weap = "weaponHolder" createVehicle [0,0]; _weap addMagazineCargo [_mag,(round (random 2))]; _weap addWeaponCargo [_weapon,1]; _weap setPos [(_position select 0),(_position select 1),((_position select 2)-.14)]; }; _posnumber = floor (random _positions); _position = _building buildingpos _posnumber; hintsilent "placing loot..."; if (random 100 > 80) then { _weapon = _items call BIS_fnc_SelectRandom; _weap = "weaponHolder" createVehicle [0,0]; _weap addWeaponCargo [_weapon,1]; _weap setPos [(_position select 0),(_position select 1),((_position select 2)-.14)];; }; if (random 100 > 50) then { _weapon = _magazines call BIS_fnc_SelectRandom; _weap addMagazineCargo [_weapon,(round(random 3))]; _weap addMagazineCargo [_magazines, 2]; }; _posnumber = floor (random _positions); _position = _building buildingpos _posnumber; if (random 100 > 1) then { _weapon = _magazines call BIS_fnc_SelectRandom; _weap = "weaponHolder" createVehicle [0,0]; _weap addMagazineCargo [_weapon,(round(random 2))]; _weap setPos [(_position select 0),(_position select 1),((_position select 2)-.14)];; }; hintsilent "placing loot...."; } foreach _buildings; hint "Done!"; Any help would be appreciated!