private void Awake() { damagerR = AttackR.GetComponent <DamagerScript>(); damagerL = AttackL.GetComponent <DamagerScript>(); damagerR2 = AttackR2.GetComponent <DamagerScript>(); damagerL2 = AttackL2.GetComponent <DamagerScript>(); attackR = AttackR.GetComponent <TemporalEnablerScript>(); attackL = AttackL.GetComponent <TemporalEnablerScript>(); attackR2 = AttackR2.GetComponent <TemporalEnablerScript>(); attackL2 = AttackL2.GetComponent <TemporalEnablerScript>(); hii = SelectedItemDisplay.GetComponent <HeldItemImage>(); cc2 = GetComponent <CapsuleCollider2D>(); renderer = GetComponent <SpriteRenderer>(); rigidbody2D = GetComponent <Rigidbody2D>(); animator = GetComponent <Animator>(); inventory = GetComponent <PlayerInventoryScript>(); hps = GetComponent <HealthPointsScript>(); cam = Camera.GetComponent <Camera>(); pes = GetComponent <PotionEffectsScript>(); throwers.Clear(); throwers.Add("BOMB", Thrower_Bomb.GetComponent <PlayerThrowScript>()); throwers.Add("AF_P", Thrower_AF_P.GetComponent <PlayerThrowScript>()); throwers.Add("AF_M", Thrower_AF_M.GetComponent <PlayerThrowScript>()); throwers.Add("AF_F", Thrower_AF_F.GetComponent <PlayerThrowScript>()); throwers.Add("AF_A", Thrower_AF_A.GetComponent <PlayerThrowScript>()); throwers.Add("AF_H", Thrower_AF_H.GetComponent <PlayerThrowScript>()); throwers.Add("PT_V", Thrower_PT_V.GetComponent <PlayerThrowScript>()); throwers.Add("AR_R", Thrower_AR_R.GetComponent <PlayerThrowScript>()); throwers.Add("AR_H", Thrower_AR_H.GetComponent <PlayerThrowScript>()); throwers.Add("AR_F", Thrower_AR_F.GetComponent <PlayerThrowScript>()); throwers.Add("AR_P", Thrower_AR_P.GetComponent <PlayerThrowScript>()); throwers.Add("AR_M", Thrower_AR_M.GetComponent <PlayerThrowScript>()); GroundCheck1 = GroundCheck + new Vector2(0.15f, 0f); GroundCheck2 = GroundCheck + new Vector2(-0.15f, 0f); //GOD MODE if (GodMode) { hps.IncreaseMax(100000); dmgMult = 10000; IncreaseAttackMult(); } }
public void Collect(string item) { switch (item) { case "PV_100": gss.Increase(100); break; case "PV_200": gss.Increase(200); break; case "PV_500": gss.Increase(500); break; case "PV_1000": gss.Increase(1000); break; case "PV_2000": gss.Increase(2000); break; case "PV_3000": gss.Increase(3000); break; case "PV_5000": gss.Increase(5000); break; case "PV_10000": gss.Increase(10000); break; case "BO_H": hps.IncreaseMax(15); break; case "BO_J": pc.IncreaseJumpHeight(); break; case "BO_D": pc.IncreaseAttackMult(); break; case "CAT_1": gss.SaveCat(1); gss.Increase(2500); break; case "CAT_2": gss.SaveCat(2); gss.Increase(2500); break; case "CAT_3": gss.SaveCat(3); gss.Increase(2500); break; case "CAT_4": gss.SaveCat(0); gss.Increase(2500); break; default: pis.AddItem(item); break; } }