scn ZLACRModKitshort acrMenuButtonshort acrBarrelButtonshort acrOpticsButtonshort acrSilencerButtonshort acrMenuLevelshort acrBarrelshort acrOpticsshort acrSilencershort EquippedACRfloat ACRConditionref PlayerEquippedACRref PlayerNewACRBegin ScriptEffectStart player.additem ACRModKit 1 set PlayerEquippedACR to Player.GetEquippedObject 5 if (PlayerEquippedACR == ZLACR105) || (PlayerEquippedACR == ZLACR105SI) || (PlayerEquippedACR == ZLACR105ACOG) || (PlayerEquippedACR == ZLACR105ACOGSI) || (PlayerEquippedACR == ZLACR105Scope) || (PlayerEquippedACR == ZLACR105ScopeSI) || (PlayerEquippedACR == ZLACR145) || (PlayerEquippedACR == ZLACR145SI) || (PlayerEquippedACR == ZLACR145ACOG) || (PlayerEquippedACR == ZLACR145ACOGSI) || (PlayerEquippedACR == ZLACR145Scope) || (PlayerEquippedACR == ZLACR145ScopeSI) || (PlayerEquippedACR == ZLACR18) || (PlayerEquippedACR == ZLACR18SI) || (PlayerEquippedACR == ZLACR18ACOG) || (PlayerEquippedACR == ZLACR18ACOGSI) || (PlayerEquippedACR == ZLACR18Scope) || (PlayerEquippedACR == ZLACR18ScopeSI) set EquippedACR to 1 endif set ACRCondition to Player.GetWeaponHealthPerc / 100 if EquippedACR == 1 ShowMessage ZLACRMainModMenu else ShowMessage ZLACREquipError endif EndBegin GameMode if acrMenuLevel == 0 set acrMenuButton to GetButtonPressed if acrMenuButton == -1 return elseif acrMenuButton == 0 ShowMessage ZLACRMainModMenuBarrel set acrMenuLevel to 1 elseif acrMenuButton == 1 ShowMessage ZLACRMainModMenuOptics set acrMenuLevel to 2 elseif acrMenuButton == 2 ShowMessage ZLACRMainModMenuSilencer set acrMenuLevel to 3 elseif acrMenuButton == 3 set acrMenuLevel to 4 endif elseif acrMenuLevel == 1 set acrBarrelButton to GetButtonPressed if acrBarrelButton == -1 return ;10.5" Barrel elseif acrBarrelButton == 0 set acrBarrel to 0 ;14.5" Barrel elseif acrBarrelButton == 1 set acrBarrel to 1 ;18" Barrel elseif acrBarrelButton == 2 set acrBarrel to 2 endif ShowMessage ZLACRMainModMenu set acrMenuLevel to 0 return elseif acrMenuLevel == 2 set acrOpticsButton to GetButtonPressed if acrOpticsButton == -1 return ;Iron Sights elseif acrOpticsButton == 0 set acrOptics to 0 ;ACOG elseif acrOpticsButton == 1 set acrOptics to 1 ;Sniper Scope elseif acrOpticsButton == 2 set acrOptics to 2 endif ShowMessage ZLACRMainModMenu set acrMenuLevel to 0 return elseif acrMenuLevel == 3 set acrSilencerButton to GetButtonPressed if acrSilencerButton == -1 return elseif acrSilencerButton == 0 set acrSilencer to 0 elseif acrSilencerButton == 1 set acrSilencer to 1 endif ShowMessage ZLACRMainModMenu set acrMenuLevel to 0 return elseif acrMenuLevel == 4 ;ACR swapping code goes here if acrBarrel == 0 if acrOptics == 0 if acrSilencer == 0 set PlayerNewACR to ZLACRBar105 elseif acrSilencer == 1 set PlayerNewACR to ZLACRBar105SI endif elseif acrOptics == 1 if acrSilencer == 0 set PlayerNewACR to ZLACRBar105ACOG elseif acrSilencer == 1 set PlayerNewACR to ZLACRBar105ACOGSI endif elseif acrOptics == 2 if acrSilencer == 0 set PlayerNewACR to ZLACRBar105Scope elseif acrSilencer == 1 set PlayerNewACR to ZLACRBar105ScopeSI endif endif elseif acrBarrel == 1 if acrOptics == 0 if acrSilencer == 0 set PlayerNewACR to ZLACRBar145 elseif acrSilencer == 1 set PlayerNewACR to ZLACRBar145SI elseif acrOptics == 1 if acrSilencer == 0 set PlayerNewACR to ZLACRBar145ACOG elseif acrSilencer == 1 set PlayerNewACR to ZLACRBar145ACOGSI elseif acrOptics == 2 if acrSilencer == 0 set PlayerNewACR to ZLACRBar145Scope elseif acrSilencer == 1 set PlayerNewACR to ZLACRBar145ScopeSI endif endif elseif acrBarrel == 2 if acrOptics == 0 if acrSilencer == 0 set PlayerNewACR to ZLACRBar18 elseif acrSilencer == 1 set PlayerNewACR to ZLACRBar18SI elseif acrOptics == 1 if acrSilencer == 0 set PlayerNewACR to ZLACRBar18ACOG elseif acrSilencer == 1 set PlayerNewACR to ZLACRBar18ACOGSI elseif acrOptics == 2 if acrSilencer == 0 set PlayerNewACR to ZLACRBar18Scope elseif acrSilencer == 1 set PlayerNewACR to ZLACRBar18ScopeSI endif endif endif endif player.removeitem PlayerEquippedACR 1 1 player.additemhealthpercent PlayerNewACR 1 ACRCondition 1 player.equipitem PlayerNewACR PlaySound WPNRifle0Equip End
PlaySound WPNRifle0Equip endif endif endif endifEnd
Begin ScriptEffectStart player.additem ACRModKit 1 set PlayerEquippedACR to Player.GetEquippedObject 5 if PlayerEquippedACR == IsInList ACROrderedList set EquippedACR to 1 endif set ACRCondition to Player.GetWeaponHealthPerc / 100 if EquippedACR == 1 set acrMenuLevel to 0 ShowMessage ZLACRMainModMenu else ShowMessage ZLACREquipError endif End
player.removeitem PlayerEquippedACR 1 1 player.additemhealthpercent PlayerNewACR 1 ACRCondition 1 player.equipitem PlayerNewACR