public static void Init() { Gun gun = ETGMod.Databases.Items.NewGun("Junk Sword", "junk1_sword"); Game.Items.Rename("outdated_gun_mods:junk_sword", "spapi:junk_sword"); gun.gameObject.AddComponent <JunkSwordController>(); GunExt.SetShortDescription(gun, "Next Time... What is This?"); GunExt.SetLongDescription(gun, "Just a sword made out of junk. Some of the junk seems enchanted and may react different the more normal junk is around."); GunExt.SetupSprite(gun, null, "junk1_sword_idle_001", 8); GunExt.SetAnimationFPS(gun, gun.shootAnimation, 8); GunExt.AddProjectileModuleFrom(gun, "wonderboy", true, true); gun.DefaultModule.projectiles[0].baseData.damage = 5; gun.DefaultModule.shootStyle = ProjectileModule.ShootStyle.SemiAutomatic; gun.DefaultModule.angleVariance = 0; gun.DefaultModule.ammoType = GameUIAmmoType.AmmoType.MEDIUM_BULLET; gun.DefaultModule.numberOfShotsInClip = 999; gun.reloadTime = 0; gun.InfiniteAmmo = true; gun.quality = PickupObject.ItemQuality.C; gun.barrelOffset.transform.localPosition = new Vector3(1.750f, 0.3f, 0f); gun.muzzleFlashEffects = (PickupObjectDatabase.GetById(574) as Gun).muzzleFlashEffects; gun.encounterTrackable.EncounterGuid = "junkan1_sword"; gun.OverrideNormalFireAudioEvent = "Play_WPN_blasphemy_shot_01"; gun.gunClass = GunClass.SILLY; gun.gunSwitchGroup = "Shotgun"; gun.IsHeroSword = true; gun.HeroSwordDoesntBlank = true; ETGMod.Databases.Items.Add(gun, null, "ANY"); gun.AddToTrorkShop(); gun.AddToBlacksmithShop(); JunkSwordController.NormalSwordId = gun.PickupObjectId; JunkSwordController.InitFormes(); gun.RemovePeskyQuestionmark(); gun.PlaceItemInAmmonomiconAfterItemById(417); }
private static void InitFormes() { JunkSwordController.InitForme2(); JunkSwordController.InitForme3(); JunkSwordController.InitForme4(); JunkSwordController.InitForme5(); JunkSwordController.InitForme6(); JunkSwordController.InitForme7(); JunkSwordController.InitForme8(); JunkSwordController.InitForme9(); }