dwringer 45 Posted March 26, 2008 I've been gradually expanding a script over the last few days that allows me to make short work of gearing units in the editor with weapons that came with various weapons packs and addons I've downloaded. Even though it's so basic a middle schooler with basic knowledge of scripting could write it, it still took me a while (although I'm sure it's not the most elegant solution), so I figured I'd release it on here for others to use/improve on/ignore/flame/ban me for. Well, I hope I wouldn't get banned for it, but since it has classnames of weapons out of other addons I don't know if I should have gotten permission from the various addon makers out there. I will immediately remove the link if anyone has a problem with the fact that it's on here. Anyhow, here it is: wep.rar And the readme (so you can see how incomplete it is, and also who I really owe thanks to:) Quote[/b] ]--= ARMORY SCRIPT =-- This is a simple script I put together to make arming my units with weapons out of addon weapon packs simple. It is FAR from complete, and there are generally only 1 or 2 variants of each weapon type. The script should be pretty straightforward, so it's easy to add more weapons if you should so choose. If you put in invalid weapon names, you'll find that the script will abort leaving much of the unit's arming to be unfinished. I haven't implemented very much by way of error handling. Syntax: [unitname, "primaryweapon", "secondaryweapon"] exec "wep.sqs" -= Assault Rifles =- sig551 PKW Sig 551 Carbine m4aim RH M4 Aimpoint m4eotech RH M4 EOTech m16a4 RH M16A4 scar-l SIX Scar-L scar-h SIX Scar-H hk416 SIX HK 416 hk416aim SIX HK 416 Aimpoint hk416eotech SIX HK 416 EOTech hk416gl SIX HK 416 EOTech + M203 hk416acog SIX HK 416 Acog hk416leu SIX HK 416 Leopold hk417 SIX HK 417 hk417acog SIX HK 417 Acog hk417gl SIX HK 417 Acog + M203 hk417leu SIX HK 417 Leopold ak47 RH AK-47 akm RH AKM ak74 RH AK-74 ak74gl RHS AK-74 + GP25 ak74k RH AK-74 Kobra ak74sp RH AK-74 Sniper an94 RH AN-94 oc14 RH OC-14 gr1 RH GR-1 -= Long Rifles =- m14sop SIX M14 SOPMOD m14acog SIX M14 SOPMOD Acog m14cmore SIX M14 SOPMOD Reflex m14dmg SIX M14 SOPMOD Scoped m14elcan SIX M14 SOPMOD Elcan m21 PKW M21 m21sd PKW M21 SD m21police SIX M21 Police m25 M25 Sniper Rifle by Dan, ArmA conversion by stock762 svd RH SVD svdgold RH Gold Plated SVD vss RHS VSS aws LLBrig31 AWS Covert (Woodland) g22 LLBrig31 G22 (Woodland) g24 LLBrig31 G24 (Woodland) BMG g24ap LLBrig31 G24 (Woodland) API g24he LLBrig31 G24 (Woodland) HE -= Submachine Guns =- mp5sd6 SIX MP5SD6 asval RHS AS "Val" asvalk RHS AS "Val" Kobra -= Machine Guns =- para PKW M249 "Para" Elcan pkp RHS PKP Pecheneg pkps RHS PKP Pecheneg + 1p29 (Scoped) -= Explosive Ordinace =- m32 SIX M32 Grenade Launcher 6g30 BIS [Queen's Gambit] 6g30 Grenade Launcher -= Handguns =- m9 RH M9 m9sd RH M9 Silenced glock PKW Glock 17 glocksd PKW Glock 17 Silenced 1911 SIX Colt 1911 deagle RH Desert Eagle mk22 RH MK 22 usp RH USP uspm RH USP Match uspsd RH USP Silenced m93r RH M93r (Repeating) g18 RH Glock 18 mk2 RH Mk 2 tt33 RH TT33 Tokarev vz61 RH VZ 61 tec9 RH Tec-9 muzi RH Micro Uzi gren 5 extra launcher grenades [if you type "gren" but aren't using a weapon with a grenade launcher, you will be given a Beretta M9 with 8 magazines] And the link again, in case you don't want to scroll back up: wep.rar So yes, thank you to all the addon makers who made these weapons. And if it's not cool that I posted this, I'm sorry, I'll take it right down - I'm still not totally clear on how addon permissions/licensing works in regards to something like this. It's just a single .sqs file, so I hope it's not a problem Edit: I probably should add that you don't need all the above mentioned addons to use the script. If you don't, the only problem would arise if you tried to use a weapon you don't have, in which case ArmA will yell at you. Share this post Link to post Share on other sites
W0lle 1052 Posted March 26, 2008 You don't need permission from an addonmaker to use his classnames in a script, that would be... Share this post Link to post Share on other sites