Jump to content

Phal

Member
  • Content Count

    39
  • Joined

  • Last visited

  • Medals

Everything posted by Phal

  1. Phal

    FHQ TaskTracker

    Hi Varanon, firstly thanks for making this script it's an awesome piece of work and makes tasks/briefings so much easier. One thing I've come across just now that I'm not sure if it's my error or the game's but when I have this in the activation of a trigger: [PlayerGroup2,["task", "task text", "task title", "", ""]] call FHQ_TT_addTasks; It triggers in that the task is added to my tasklist, with the correct info as I have put - But the notification that pops up is completely blank. No "task created" or "task assigned" along with the task title etc. Just empty boxes show up like a normal notification. But if in the trigger I add the following after the code above... ["task", "assigned"] call FHQ_TT_setTaskState; It will show a notification with the correct details for the task as expected, but then following that it does the blank notification thing again. Any ideas?
  2. Phal

    Movement speed tweaking

    Happy to help Smookie. Want infantry movement to be as good as possible before Beta starts so you can start focusing on other things. It'll be good to get infantry feeling super solid and polished, since it's such a large part of the game.
  3. Anyone know how to fix the black screen issue? (leaving and coming back isn't an option when you're hosting a server)
  4. Phal

    Movement speed tweaking

    [Playing: Dev Build 0.55.104462] Feedback: Below are the changes I found from quickly moving about as infantry in the new build. Not commenting on things that appear unchanged since last build. RIFLE (Upright) Running & Tactical Pace move speeds are good (Crouch) Running speed too fast, feels like the same speed as Upright (should be noticeably slower in comparison) (Crouch) Tactical Pace move speed is good PISTOL (Upright) Running & Tactical Pace move speeds are good (running animation plays too fast) (Crouch) Running move speed too fast, feels like the same speed as Upright (should be noticeably slower in comparison) (Crouch) Tactical Pace move speed seems ok (animation plays too fast) OBSERVATIONS > (Crouch Pistol) Soldier currently does some kind of "butt thrust" when going from stationary to moving while in tactical pace. > (Crouch Pistol) Using a "Crouch / Stand" key whilst moving left in Tactical Pace will cause the soldier will go forward a few paces and stand up. > Using "Crouch Toggle" you can't stand up after crouching with either a rifle or pistol in hand > Transition into prone with pistol feels a bit fast
  5. Really good mod, has helped make my missions much more interesting and diversify the locations a bit more. But some buildings are missing, are you not planning on adding the rest?
  6. Phal

    Movement speed tweaking

    [Playing: Dev Build 55.104268] I like: + Slower Combat run - This actually feels a lot better, and makes the speed increase in sprint more noticeable. + Faster Casual Tactical run - It feels faster and more useful now, before it was too slow. You may as well have never used it since Combat run was faster and you could quickly go into shooting mode. + Slower Crouched speeds - Moving while crouched was far too fast before, it's much more believable now. You are low down and not as easily balanced in as you are when stood up, you would expect to not be so agile! I don't like: - Pistol Animations - These look and feel incomplete. I preferred the old sprinting animation with the pistol held low, at least for when crouched. The crouched pistol animations look really awkward because the back is too straight and stretched out while moving normally - And then even worse while moving in Tactical Pace! - Pistol Crouched speeds - These need the same love you gave to the rifle tweaks. Movement speed while crouched with a pistol is too fast, similar to how it was with a rifle in previous builds. - Transitions/Connections between Combat/Casual states - Lowering and raising your weapon should be a seamless action to perform, you wouldn't think of it as a taxing thing for a soldier to have to do. Yet in-game it is currently very counter-intuitive. Your soldier will often get stuck between Tactical states, pause for a moment, stop responding to movement keys and sometimes even change stance when trying to do a ToggleRaiseWeapon action. - Lack of visual feedback when fatigued - I'm not talking about adding a whole new set of animations for soldiers who are tired, but I use a toggle to sprint and when my soldier becomes fatigued he resumes the normal running animation. This is fine, except the sprint toggle is not switched off automatically making it confusing as it means I always have to press the sprint toggle again (with no visual feedback), simply to tell the game to stop trying to sprint. - Idle variety animations play too quickly - I like that you're adding a bit of "life" to the soldiers when they enter a Casual/Relaxed state, but I think these animations play too quickly after the soldier is idle. The result being that you will see the same animation multiple times between slight movements (which halt the animation). It can be distracting and a little odd to watch. Suggestions: > Improve the Transitions/Connections between Combat/Casual states - To improve the flow of movement. > Slow down Casual Rifle walk - Right now it's too fast and looks awkward. > Allow player to switch between Casual Rifle walk animations - You have more than one in there, and the Tactical Pace key can switch between animations while running so why not walk too? > Allow for a "Burst Sprint" when soldier is not fatigued - Unlike the 0.51 implementation of sprint, the current sprint is not a very good tool for getting out of danger. I think if the soldier is not fatigued he/she should benefit from a faster sprint for a short duration. This would help with going from cover to cover, and also avoiding incoming fire (getting TO cover). > Turn off Sprint Toggle when fatigued - The toggle should automatically switch off if the soldier can no longer sprint. I made a ticket a few weeks ago that I think is relevant here. It talks about grouping animations to improve the infantry experience. Link: Feedback Ticket: 0006724 Also another to do with idle variety animations: Link: Feedback Ticket: 0006845
  7. Phal

    Rifle Collision Addon

    Nice mod Norrin. I want to use it but.. I just don't like the idea of this being in mod form.. it causing errors, having to update it, it not being "officially" supported (as in the animations system not really allowing for quick seamless transitions as required from a mechanic like this)... I really wish they would just include this in vanilla, CQB is still so clunky and I hate getting "stuck" all the time.
  8. Screen just fades to black after death with this script.... When someone quits and rejoins though the script seems to work as expected. Any ideas?
  9. Haven't had a chance to test the script with 'if (!isServer) exitWith {};' until now. And any other player other than myself receives no gear. I tried this before by surrounding the script with a 'if (isServer) then {' and I had the same result, I didn't think that an exitWith if !isServer would give different results - or if it did it wouldn't make any sense from what I understand. So I'm back to the drawing board again then? Why can the server not just execute this code and give all units gear? It seems like if the code isn't executed on the client calling the script they don't receive anything.. And then as soon as you let each client run the code then everyone generates different numbers for each other and you run into inconsistencies. Here is the code I'm using: //---------- Script Start ---------------| private ["_unit"]; _unit = _this select 0; while {true} do { waitUntil{(alive _unit)}; if (!isServer) exitWith {}; removeAllAssignedItems _unit; Removeuniform _unit; Removevest _unit; Removegoggles _unit; Removeheadgear _unit; Removeallweapons _unit; //---------- Uniform --------------------| _uniform = (ceil (random 9)); switch (_uniform ) do { case 0: { _unit adduniform "U_C_Commoner1_1"; }; case 1: { _unit adduniform "U_C_Commoner1_1"; }; case 2: { _unit adduniform "U_C_Commoner1_2"; }; case 3: { _unit adduniform "U_C_Commoner1_3"; }; case 4: { _unit adduniform "U_C_Poloshirt_blue"; }; case 5: { _unit adduniform "U_C_Poloshirt_burgundy"; }; case 6: { _unit adduniform "U_C_Poloshirt_redwhite"; }; case 7: { _unit adduniform "U_C_Poloshirt_salmon"; }; case 8: { _unit adduniform "U_C_Poloshirt_stripped"; }; case 9: { _unit adduniform "U_C_Poloshirt_tricolour"; }; }; //---------- Body Armour ----------------| _armour = (ceil (random 9)); switch (_armour ) do { case 0: { _unit addvest "V_Chestrig_khk"; }; case 1: { _unit addvest "V_BandollierB_rgr"; }; case 2: { _unit addvest "V_BandollierB_cbr"; }; case 3: { _unit addvest "V_BandollierB_khk"; }; case 4: { _unit addvest "V_TacVest_brn"; }; case 5: { _unit addvest "V_TacVest_oli"; }; case 6: { _unit addvest "V_TacVest_khk"; }; case 7: { _unit addvest "V_ChestrigB_rgr"; }; case 8: { _unit addvest "V_PlateCarrierGL_rgr"; }; case 9: { _unit addvest "V_PlateCarrier1_cbr"; }; }; //---------- Eyewear --------------------| _eyewear = (ceil (random 5)); switch (_eyewear ) do { case 0: { _unit addGoggles "G_Shades_Black"; }; case 1: { _unit addGoggles "G_Shades_Blue"; }; case 2: { _unit addGoggles "G_Sport_Blackred"; }; case 3: { _unit addGoggles "G_Tatical_Clear"; }; }; //---------- Helmet/Hat -----------------| _hat = (ceil (random 5)); switch (_hat ) do { case 0: { _unit addheadgear "H_Cap_brn_SERO"; }; case 1: { _unit addheadgear "H_Cap_blu"; }; case 2: { _unit addheadgear "H_Cap_red"; }; case 3: { _unit addheadgear "H_Cap_headphones"; }; }; //---------- Extra Items ----------------| _items = (ceil (random 7)); switch (_items ) do { case 0: { _unit addItem "FirstAidKit"; }; case 1: { _unit addItem "FirstAidKit"; _unit addItem "ItemMap"; _unit assignItem "ItemMap"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; }; case 2: { _unit addItem "FirstAidKit"; _unit addItem "ItemMap"; _unit assignItem "ItemMap"; }; case 3: { _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; _unit addItem "FirstAidKit"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; }; case 4: { _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; }; case 5: { _unit addItem "ItemMap"; _unit assignItem "ItemMap"; _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; }; case 6: { _unit addItem "ItemMap"; _unit assignItem "ItemMap"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; }; case 7: { _unit addItem "FirstAidKit"; _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; }; }; //---------- Weapon ---------------------| _weapon = (ceil (random 10)); switch (_weapon ) do { case 0: { _unit addMagazines ["30Rnd_65x39_caseless_green",6]; _unit addweapon "arifle_Khaybar_F"; }; case 1: { _unit addMagazines ["30Rnd_65x39_caseless_green",6]; _unit addweapon "arifle_Khaybar_C_F"; }; case 2: { _unit addMagazines ["30Rnd_65x39_caseless_mag",6]; _unit addweapon "arifle_MX_F"; }; case 3: { _unit addMagazines ["30Rnd_65x39_caseless_mag",6]; _unit addweapon "arifle_MXC_F"; }; case 4: { _unit addMagazines ["20Rnd_762x45_Mag",6]; _unit addweapon "arifle_MXM_F"; }; case 5: { _unit addMagazines ["30Rnd_65x39_case_mag",6]; _unit addweapon "arifle_TRG20_F"; }; case 6: { _unit addMagazines ["30Rnd_65x39_case_mag",6]; _unit addweapon "arifle_TRG21_F"; }; case 7: { _unit addMagazines ["20Rnd_762x45_Mag",6]; _unit addweapon "srifle_EBR_F"; }; case 8: { _unit addMagazines ["30Rnd_556x45_Stanag",6]; _unit addweapon "arifle_SDAR_F"; }; case 9: { _unit addMagazines ["16Rnd_9x21_Mag",6]; _unit addweapon "hgun_P07_F"; }; case 10: { _unit addMagazines ["16Rnd_9x21_Mag",6]; _unit addweapon "hgun_Rook40_F"; }; }; //---------- Bonus 1 ----------| // Chance to get a pistol if given a rifle if (_weapon < 9) then { _bonuswep = (ceil (random 7)); switch (_bonuswep ) do { case 0: { _unit addMagazines ["16Rnd_9x21_Mag",3]; _unit addweapon "hgun_P07_F"; }; case 1: { _unit addMagazines ["16Rnd_9x21_Mag",3]; _unit addweapon "hgun_Rook40_F"; }; }; }; //---------- Bonus 2 ----------| // Chance to get a weapon attachment if given a rifle if (_weapon < 8) then { _attachments = (ceil (random 6)); switch (_attachments ) do { case 0: { _unit addPrimaryWeaponItem "optic_Holosight"; }; case 1: { _unit addPrimaryWeaponItem "optic_Aco"; }; case 2: { _unit addPrimaryWeaponItem "acc_flashlight"; }; case 3: { _unit addPrimaryWeaponItem "acc_pointer_IR"; }; }; }; //---------- Grenades -------------------| _grenades = (ceil (random 12)); switch (_grenades ) do { case 0: { _unit addMagazines ["HandGrenade",1]; }; case 1: { _unit addMagazines ["HandGrenade",2]; }; case 2: { _unit addMagazines ["SmokeShell",1]; }; case 3: { _unit addMagazines ["SmokeShell",2]; }; case 4: { _unit addMagazines ["HandGrenade",1]; _unit addMagazines ["SmokeShell",1]; }; }; //---------- Script Done ----------------| waitUntil{(!alive _unit)}; }; -Edit: There is no addweaponglobal command
  10. Hi all, This issue has been boggling me for several days now and between me and a few buddies we can't seem to figure out what the issue is, and I can't find anything relating to this exact problem on the web. Anyway, here's the issue: In this mission the players control civilians, who start with no gear. I want them all to spawn with random gear, and what I have works. The only problem is the weapon given by the script is often different to the weapon other players see, if that makes sense. So for example I get given a NATO MXM 7.62mm, but other players see my character holding a pistol, nothing at all, or a different assault rifle etc. To run this script, in the initialization of the unit I do: nul = [this] execVM "Player_Equipment.sqf"; In Player_Equipment.sqf, this is the code: //---------- Script Start --------- private ["_unit"]; _unit = _this select 0; waitUntil {!isNull _unit}; removeAllAssignedItems _unit; Removeuniform _unit; Removevest _unit; Removegoggles _unit; Removeheadgear _unit; Removeallweapons _unit; //------------ Uniform ------------ _uniform = (ceil (random 9)); switch (_uniform ) do { case 0: { _unit adduniform "U_C_Commoner1_1"; }; case 1: { _unit adduniform "U_C_Commoner1_1"; }; case 2: { _unit adduniform "U_C_Commoner1_2"; }; case 3: { _unit adduniform "U_C_Commoner1_3"; }; case 4: { _unit adduniform "U_C_Poloshirt_blue"; }; case 5: { _unit adduniform "U_C_Poloshirt_burgundy"; }; case 6: { _unit adduniform "U_C_Poloshirt_redwhite"; }; case 7: { _unit adduniform "U_C_Poloshirt_salmon"; }; case 8: { _unit adduniform "U_C_Poloshirt_stripped"; }; case 9: { _unit adduniform "U_C_Poloshirt_tricolour"; }; }; //------------ Body Armour ------------ _armour = (ceil (random 9)); switch (_armour ) do { case 0: { _unit addvest "V_Chestrig_khk"; }; case 1: { _unit addvest "V_BandollierB_rgr"; }; case 2: { _unit addvest "V_BandollierB_cbr"; }; case 3: { _unit addvest "V_BandollierB_khk"; }; case 4: { _unit addvest "V_TacVest_brn"; }; case 5: { _unit addvest "V_TacVest_oli"; }; case 6: { _unit addvest "V_TacVest_khk"; }; case 7: { _unit addvest "V_ChestrigB_rgr"; }; case 8: { _unit addvest "V_PlateCarrierGL_rgr"; }; case 9: { _unit addvest "V_PlateCarrier1_cbr"; }; }; //------------ Eyewear ------------ _eyewear = (ceil (random 5)); switch (_eyewear ) do { case 0: { _unit addGoggles "G_Shades_Black"; }; case 1: { _unit addGoggles "G_Shades_Blue"; }; case 2: { _unit addGoggles "G_Sport_Blackred"; }; case 3: { _unit addGoggles "G_Tatical_Clear"; }; }; //------------ Helmet/Hat ------------ _hat = (ceil (random 5)); switch (_hat ) do { case 0: { _unit addheadgear "H_Cap_brn_SERO"; }; case 1: { _unit addheadgear "H_Cap_blu"; }; case 2: { _unit addheadgear "H_Cap_red"; }; case 3: { _unit addheadgear "H_Cap_headphones"; }; }; //------------ Weapon ------------ _weapon = (ceil (random 10)); switch (_weapon ) do { case 0: { _unit addMagazines ["30Rnd_65x39_caseless_green",6]; _unit addweapon "arifle_Khaybar_F"; }; case 1: { _unit addMagazines ["30Rnd_65x39_caseless_green",6]; _unit addweapon "arifle_Khaybar_C_F"; }; case 2: { _unit addMagazines ["30Rnd_65x39_caseless_mag",6]; _unit addweapon "arifle_MX_F"; }; case 3: { _unit addMagazines ["30Rnd_65x39_caseless_mag",6]; _unit addweapon "arifle_MXC_F"; }; case 4: { _unit addMagazines ["20Rnd_762x45_Mag",6]; _unit addweapon "arifle_MXM_F"; }; case 5: { _unit addMagazines ["30Rnd_65x39_case_mag",6]; _unit addweapon "arifle_TRG20_F"; }; case 6: { _unit addMagazines ["30Rnd_65x39_case_mag",6]; _unit addweapon "arifle_TRG21_F"; }; case 7: { _unit addMagazines ["30Rnd_556x45_Stanag",6]; _unit addweapon "arifle_SDAR_F"; }; case 8: { _unit addMagazines ["20Rnd_762x45_Mag",6]; _unit addweapon "srifle_EBR_F"; }; case 9: { _unit addMagazines ["16Rnd_9x21_Mag",6]; _unit addweapon "hgun_P07_F"; }; case 10: { _unit addMagazines ["16Rnd_9x21_Mag",6]; _unit addweapon "hgun_Rook40_F"; }; }; //------------ Attachments ------------ _extras = (ceil (random 7)); switch (_extras ) do { case 0: { _unit addPrimaryWeaponItem "optic_Holosight"; }; case 1: { _unit addPrimaryWeaponItem "optic_Aco"; }; case 2: { _unit addPrimaryWeaponItem "acc_flashlight"; }; case 3: { _unit addPrimaryWeaponItem "acc_pointer_IR"; }; case 4: { _unit addMagazines ["HandGrenade",2]; }; case 5: { _unit addMagazines ["HandGrenade",1]; }; }; //------------ Extra Items ------------ _items = (ceil (random 7)); switch (_items ) do { case 0: { _unit addItem "FirstAidKit"; }; case 1: { _unit addItem "FirstAidKit"; _unit addItem "ItemMap"; _unit assignItem "ItemMap"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; }; case 2: { _unit addItem "FirstAidKit"; _unit addItem "ItemMap"; _unit assignItem "ItemMap"; }; case 3: { _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; _unit addItem "FirstAidKit"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; }; case 4: { _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; }; case 5: { _unit addItem "ItemMap"; _unit assignItem "ItemMap"; _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; }; case 6: { _unit addItem "ItemMap"; _unit assignItem "ItemMap"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; }; case 7: { _unit addItem "FirstAidKit"; _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; }; }; //------------ Script Done ------------ I'd really like it to work, I've tried all sorts of things like running it on the server and not on each client - In which case only I spawn with weapons and no one else, as I'm the host. I've tried various sleep times and WaitUntil IsNull Player, things like that to give the game enough time to sync, but no luck. If any scripting wizz on here has any ideas it'd be much appreciated. Probably the most annoying thing is everything else matches up, players see the correct clothing, vest, hats, etc. for each player, it's JUST the weapon. Thanks, -Phal
  11. While continuing to playtest I noticed that sometimes (and it's a rare occasion) a random player will spawn as if the script hasn't executed, and I have no idea why. It doesn't happen often enough to be too much of a bother, just would be nice it didn't happen at all! In that latest code Tuliq is there any reason why you removed: waitUntil {(player == _unit)}; ? I haven't tested it yet but I will try to tomorrow, just wondered what the switch in code would do (if anything) in terms of clientside execution and inconsistent items across players etc.
  12. Ok so I've just tested it with one other person and it seems to work. The gun he sees on me is the gun I have, hooray! All other gear is synced too just like before. Only thing now is the AI obviously spawn with nothing as they're not considered players! But this is a minor issue I can think up a workaround for later. Thanks for the help Tuliq. The final code I have is: //---------- Script Start ---------------| private ["_unit"]; _unit = _this select 0; //---------------------------------------| waitUntil {(player == _unit)}; //---------------------------------------| removeAllAssignedItems _unit; Removeuniform _unit; Removevest _unit; Removegoggles _unit; Removeheadgear _unit; Removeallweapons _unit; //---------- Uniform --------------------| _uniform = (ceil (random 9)); switch (_uniform ) do { case 0: { _unit adduniform "U_C_Commoner1_1"; }; case 1: { _unit adduniform "U_C_Commoner1_1"; }; case 2: { _unit adduniform "U_C_Commoner1_2"; }; case 3: { _unit adduniform "U_C_Commoner1_3"; }; case 4: { _unit adduniform "U_C_Poloshirt_blue"; }; case 5: { _unit adduniform "U_C_Poloshirt_burgundy"; }; case 6: { _unit adduniform "U_C_Poloshirt_redwhite"; }; case 7: { _unit adduniform "U_C_Poloshirt_salmon"; }; case 8: { _unit adduniform "U_C_Poloshirt_stripped"; }; case 9: { _unit adduniform "U_C_Poloshirt_tricolour"; }; }; //---------- Body Armour ----------------| _armour = (ceil (random 9)); switch (_armour ) do { case 0: { _unit addvest "V_Chestrig_khk"; }; case 1: { _unit addvest "V_BandollierB_rgr"; }; case 2: { _unit addvest "V_BandollierB_cbr"; }; case 3: { _unit addvest "V_BandollierB_khk"; }; case 4: { _unit addvest "V_TacVest_brn"; }; case 5: { _unit addvest "V_TacVest_oli"; }; case 6: { _unit addvest "V_TacVest_khk"; }; case 7: { _unit addvest "V_ChestrigB_rgr"; }; case 8: { _unit addvest "V_PlateCarrierGL_rgr"; }; case 9: { _unit addvest "V_PlateCarrier1_cbr"; }; }; //---------- Eyewear --------------------| _eyewear = (ceil (random 5)); switch (_eyewear ) do { case 0: { _unit addGoggles "G_Shades_Black"; }; case 1: { _unit addGoggles "G_Shades_Blue"; }; case 2: { _unit addGoggles "G_Sport_Blackred"; }; case 3: { _unit addGoggles "G_Tatical_Clear"; }; }; //---------- Helmet/Hat -----------------| _hat = (ceil (random 5)); switch (_hat ) do { case 0: { _unit addheadgear "H_Cap_brn_SERO"; }; case 1: { _unit addheadgear "H_Cap_blu"; }; case 2: { _unit addheadgear "H_Cap_red"; }; case 3: { _unit addheadgear "H_Cap_headphones"; }; }; //---------- Extra Items ----------------| _items = (ceil (random 7)); switch (_items ) do { case 0: { _unit addItem "FirstAidKit"; }; case 1: { _unit addItem "FirstAidKit"; _unit addItem "ItemMap"; _unit assignItem "ItemMap"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; }; case 2: { _unit addItem "FirstAidKit"; _unit addItem "ItemMap"; _unit assignItem "ItemMap"; }; case 3: { _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; _unit addItem "FirstAidKit"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; }; case 4: { _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; }; case 5: { _unit addItem "ItemMap"; _unit assignItem "ItemMap"; _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; }; case 6: { _unit addItem "ItemMap"; _unit assignItem "ItemMap"; _unit addItem "ItemCompass"; _unit assignItem "ItemCompass"; }; case 7: { _unit addItem "FirstAidKit"; _unit addItem "ItemWatch"; _unit assignItem "ItemWatch"; }; }; //---------- Weapon ---------------------| _weapon = (ceil (random 10)); switch (_weapon ) do { case 0: { _unit addMagazines ["30Rnd_65x39_caseless_green",6]; _unit addweapon "arifle_Khaybar_F"; }; case 1: { _unit addMagazines ["30Rnd_65x39_caseless_green",6]; _unit addweapon "arifle_Khaybar_C_F"; }; case 2: { _unit addMagazines ["30Rnd_65x39_caseless_mag",6]; _unit addweapon "arifle_MX_F"; }; case 3: { _unit addMagazines ["30Rnd_65x39_caseless_mag",6]; _unit addweapon "arifle_MXC_F"; }; case 4: { _unit addMagazines ["20Rnd_762x45_Mag",6]; _unit addweapon "arifle_MXM_F"; }; case 5: { _unit addMagazines ["30Rnd_65x39_case_mag",6]; _unit addweapon "arifle_TRG20_F"; }; case 6: { _unit addMagazines ["30Rnd_65x39_case_mag",6]; _unit addweapon "arifle_TRG21_F"; }; case 7: { _unit addMagazines ["20Rnd_762x45_Mag",6]; _unit addweapon "srifle_EBR_F"; }; case 8: { _unit addMagazines ["30Rnd_556x45_Stanag",6]; _unit addweapon "arifle_SDAR_F"; }; case 9: { _unit addMagazines ["16Rnd_9x21_Mag",6]; _unit addweapon "hgun_P07_F"; }; case 10: { _unit addMagazines ["16Rnd_9x21_Mag",6]; _unit addweapon "hgun_Rook40_F"; }; }; //---------- Bonus 1 ----------| // Chance to get a pistol if given a rifle if (_weapon < 9) then { _bonuswep = (ceil (random 7)); switch (_bonuswep ) do { case 0: { _unit addMagazines ["16Rnd_9x21_Mag",3]; _unit addweapon "hgun_P07_F"; }; case 1: { _unit addMagazines ["16Rnd_9x21_Mag",3]; _unit addweapon "hgun_Rook40_F"; }; }; }; //---------- Bonus 2 ----------| // Chance to get a weapon attachment if given a rifle if (_weapon < 8) then { _attachments = (ceil (random 6)); switch (_attachments ) do { case 0: { _unit addPrimaryWeaponItem "optic_Holosight"; }; case 1: { _unit addPrimaryWeaponItem "optic_Aco"; }; case 2: { _unit addPrimaryWeaponItem "acc_flashlight"; }; case 3: { _unit addPrimaryWeaponItem "acc_pointer_IR"; }; }; }; //---------- Grenades -------------------| _grenades = (ceil (random 12)); switch (_grenades ) do { case 0: { _unit addMagazines ["HandGrenade",1]; }; case 1: { _unit addMagazines ["HandGrenade",2]; }; case 2: { _unit addMagazines ["SmokeShell",1]; }; case 3: { _unit addMagazines ["SmokeShell",2]; }; case 4: { _unit addMagazines ["HandGrenade",1]; _unit addMagazines ["SmokeShell",1]; }; }; //---------- Script Done ----------------| When I can I'll test this with larger player counts but for now it seems to be working as expected. Fingers crossed.
  13. I did try moving the waitUntil to the top when I tested your first suggestion, still did the same thing.. I put in the {(player == _unit)}; Will have to wait until tomorrow now to test though so will post results then. Cheers
  14. Hi Tuliq, Thanks for trying to help. I applied your proposed fix and it worked for the first try with my friend, then every subsequent test he spawned in as if the script hadn't even executed (so he hadn't even been stripped and assigned new clothes etc. let alone a weapon), meanwhile the script executes fine for myself. And yeah that makes sense, except the only thing that seems to differ between clients is the weapon. I've tested this multiple times by asking other players what they see others wearing and their descriptions match. It's completely bonkers (aka annoyingly inconsistent, and it's driving me mad!). Even after reverting from your changes and making it into a .pbo instead of just hosting it raw from the editor, other players sometimes still spawn as if the script hasn't executed. :[
×