Code: Select all
case "da":
{
{_unit addmagazine _AKmag} for each [1,2];
_unit addweapon _AK;
};
Code: Select all
case "da":
{
{_unit addmagazine _AKmag} forEach [1,2];
_unit addweapon _AK;
};
I suggest launching ArmA2 with the -showScriptErrors parameter. Also consider using notepad++ or Eclipse for ArmAscript editing, you can download optional ArmA2script language support for both. Eclipse's has the nice bonus that you can hover over bits of code and it'll give you a small popup with what it does, like a mini-wiki. Perfect if you're still learning.