// Token: 0x06003216 RID: 12822
 public void Highlight()
 {
     if (this.OriTarget)
     {
         Characters.Ori.MoveOriToPosition(this.OriTarget.position, this.OriDuration);
     }
     if (Characters.Sein.Abilities.SpiritFlame)
     {
         Characters.Sein.Abilities.SpiritFlame.AddLock("savePedestal");
     }
     Characters.Ori.GetComponent <Rigidbody>().velocity = Vector3.zero;
     Characters.Ori.EnableHoverWobbling = false;
     if (this.OriEnterAction)
     {
         this.OriEnterAction.Perform(null);
     }
     if (this.m_hint == null)
     {
         this.m_hint = UI.Hints.Show(this.SaveAndTeleportHintMessage, HintLayer.HintZone, 3f);
     }
     if (this.OnOriEnter)
     {
         Sound.Play(this.OnOriEnter.GetSound(null), base.transform.position, null);
     }
     if (this.m_sceneTeleporter)
     {
         TeleporterController.Activate(this.m_sceneTeleporter.Identifier);
     }
 }
    public static void TeleportPickup(string Value)
    {
        int    shardCount = -1;
        char   colorChar  = ' ';
        string shardPart  = "";

        if (Value == "Ginso")
        {
            Characters.Sein.Inventory.SetRandomizerItem(1024, 1);
            shardCount = RandomizerBonus.WaterVeinShards();
            shardPart  = "Water Vein";
            colorChar  = '*';
        }
        if (Value == "Forlorn")
        {
            Characters.Sein.Inventory.SetRandomizerItem(1025, 1);
            shardCount = RandomizerBonus.GumonSealShards();
            shardPart  = "Gumon Seal";
            colorChar  = '#';
        }
        if (Value == "Horu")
        {
            Characters.Sein.Inventory.SetRandomizerItem(1026, 1);
            shardCount = RandomizerBonus.SunstoneShards();
            shardPart  = "Sunstone";
            colorChar  = '@';
        }

        if (Randomizer.Shards && shardCount >= 0 && shardCount < 2)
        {
            if (shardCount == 1)
            {
                shardPart = "1 more " + shardPart + " shard to activate";
            }
            else
            {
                shardPart = "2 " + shardPart + " shards to activate";
            }
            PickupMessage(colorChar + "Broken " + Value + " teleporter\nCollect " + shardPart + colorChar, 300);
            return;
        }
        TeleporterController.Activate(Randomizer.TeleportTable[Value].ToString(), false);
        PickupMessage(colorChar + Value + " teleporter activated" + colorChar);
    }
Exemple #3
0
 public static void TeleportPickup(string Value)
 {
     TeleporterController.Activate(Randomizer.TeleportTable[Value].ToString());
     Randomizer.showHint(Value + " teleporter activated");
 }
    // Token: 0x0600376D RID: 14189 RVA: 0x000E2764 File Offset: 0x000E0964
    public static void UpgradeID(int ID)
    {
        bool flag = ID < 0;

        if (flag)
        {
            ID = -ID;
        }
        if (ID >= 100)
        {
            RandomizerBonusSkill.FoundBonusSkill(ID);
            return;
        }
        switch (ID)
        {
        case 0:
            if (!flag)
            {
                Characters.Sein.Mortality.Health.SetAmount((float)(Characters.Sein.Mortality.Health.MaxHealth + 20));
                Randomizer.showHint("Mega Health");
                return;
            }
            break;

        case 1:
            if (!flag)
            {
                Characters.Sein.Energy.SetCurrent(Characters.Sein.Energy.Max + 5f);
                Randomizer.showHint("Mega Energy");
                return;
            }
            break;

        case 2:
            Randomizer.returnToStart();
            Randomizer.showHint("Go Home!");
            return;

        case 20:
            break;

        case 6:
            if (!flag)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
                Randomizer.showHint("Attack Upgrade (" + RandomizerBonus.SpiritFlameLevel().ToString() + ")");
                return;
            }
            if (RandomizerBonus.SpiritFlameLevel() > 0)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
                Randomizer.showHint("Attack Upgrade (" + RandomizerBonus.SpiritFlameLevel().ToString() + ")");
                return;
            }
            break;

        case 8:
            Randomizer.showHint("Explosion Power Upgrade");
            if (!RandomizerBonus.ExplosionPower())
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
                return;
            }
            break;

        case 9:
            if (!flag)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
            }
            else if (Characters.Sein.Inventory.GetRandomizerItem(ID) > 0)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
            }
            if (Characters.Sein.Inventory.GetRandomizerItem(ID) == 1)
            {
                Randomizer.showHint("Spirit Light Efficiency");
            }
            else
            {
                Randomizer.showHint("Spirit Light Efficiency (" + Characters.Sein.Inventory.GetRandomizerItem(ID).ToString() + ")");
            }
            break;

        case 10:
            Randomizer.showHint("Extra Air Dash");
            if (!RandomizerBonus.DoubleAirDash())
            {
                Characters.Sein.Inventory.SetRandomizerItem(ID, 1);
                return;
            }
            break;

        case 11:
            Randomizer.showHint("Charge Dash Efficiency");
            if (!RandomizerBonus.ChargeDashEfficiency())
            {
                Characters.Sein.Inventory.SetRandomizerItem(ID, 1);
                return;
            }
            break;

        case 12:
            if (!flag)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
                if (RandomizerBonus.DoubleJumpUpgrades() == 1)
                {
                    Randomizer.showHint("Extra Double Jump");
                    return;
                }
                Randomizer.showHint("Extra Double Jump (" + RandomizerBonus.DoubleJumpUpgrades().ToString() + ")");
                return;
            }
            else if (RandomizerBonus.DoubleJumpUpgrades() > 0)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
                if (RandomizerBonus.DoubleJumpUpgrades() == 1)
                {
                    Randomizer.showHint("Extra Double Jump");
                    return;
                }
                Randomizer.showHint("Extra Double Jump (" + RandomizerBonus.DoubleJumpUpgrades().ToString() + ")");
                return;
            }
            break;

        case 13:
            if (!flag)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
                Randomizer.showHint("Health Regeneration (" + RandomizerBonus.HealthRegeneration().ToString() + ")");
                return;
            }
            if (RandomizerBonus.HealthRegeneration() > 0)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
                Randomizer.showHint("Health Regeneration (" + RandomizerBonus.HealthRegeneration().ToString() + ")");
                return;
            }
            break;

        case 15:
            if (!flag)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
                Randomizer.showHint("Energy Regeneration (" + RandomizerBonus.EnergyRegeneration().ToString() + ")");
                return;
            }
            if (RandomizerBonus.EnergyRegeneration() > 0)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
                Randomizer.showHint("Energy Regeneration (" + RandomizerBonus.EnergyRegeneration().ToString() + ")");
                return;
            }
            break;

        case 17:
            if (flag)
            {
                if (RandomizerBonus.WaterVeinShards() > 0)
                {
                    Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
                    Randomizer.showHint("*Water Vein Shard (" + RandomizerBonus.WaterVeinShards().ToString() + "/3)*");
                }
            }
            else if (RandomizerBonus.WaterVeinShards() >= 3)
            {
                Randomizer.showHint("*Water Vein Shard (extra)*");
            }
            else
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
                Randomizer.showHint("*Water Vein Shard (" + RandomizerBonus.WaterVeinShards().ToString() + "/3)*", 300);
                if (Characters.Sein.Inventory.GetRandomizerItem(1024) == 1 && RandomizerBonus.WaterVeinShards() == 2)
                {
                    TeleporterController.Activate(Randomizer.TeleportTable["Ginso"].ToString());
                    Randomizer.MessageQueue.Enqueue("*Ginso teleporter activated*");
                }
            }
            Keys.GinsoTree = (RandomizerBonus.WaterVeinShards() >= 3);
            if (Keys.GinsoTree)
            {
                RandomizerStatsManager.FoundEvent(0);
            }
            return;

        case 19:
            if (flag)
            {
                if (RandomizerBonus.GumonSealShards() > 0)
                {
                    Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
                    Randomizer.showHint("#Gumon Seal Shard (" + RandomizerBonus.GumonSealShards().ToString() + "/3)#");
                }
            }
            else if (RandomizerBonus.GumonSealShards() >= 3)
            {
                Randomizer.showHint("#Gumon Seal Shard (extra)#");
            }
            else
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
                Randomizer.showHint("#Gumon Seal Shard (" + RandomizerBonus.GumonSealShards().ToString() + "/3)#", 300);
                if (Characters.Sein.Inventory.GetRandomizerItem(1025) == 1 && RandomizerBonus.GumonSealShards() == 2)
                {
                    TeleporterController.Activate(Randomizer.TeleportTable["Forlorn"].ToString());
                    Randomizer.MessageQueue.Enqueue("#Forlorn teleporter activated#");
                }
            }
            Keys.ForlornRuins = (RandomizerBonus.GumonSealShards() >= 3);
            if (Keys.ForlornRuins)
            {
                RandomizerStatsManager.FoundEvent(2);
            }
            return;

        case 21:
            if (flag)
            {
                if (RandomizerBonus.SunstoneShards() > 0)
                {
                    Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
                    Randomizer.showHint("@Sunstone Shard (" + RandomizerBonus.SunstoneShards().ToString() + "/3)@");
                }
            }
            else if (RandomizerBonus.SunstoneShards() >= 3)
            {
                Randomizer.showHint("@Sunstone Shard (extra)@");
            }
            else
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
                Randomizer.showHint("@Sunstone Shard (" + RandomizerBonus.SunstoneShards().ToString() + "/3)@", 300);
                if (Characters.Sein.Inventory.GetRandomizerItem(1026) == 1 && RandomizerBonus.SunstoneShards() == 2)
                {
                    TeleporterController.Activate(Randomizer.TeleportTable["Horu"].ToString());
                    Randomizer.MessageQueue.Enqueue("@Horu teleporter activated@");
                }
            }
            Keys.MountHoru = (RandomizerBonus.SunstoneShards() >= 3);
            if (Keys.MountHoru)
            {
                RandomizerStatsManager.FoundEvent(4);
            }
            return;

        case 28:
            if (!flag)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
            }
            else if (RandomizerBonus.WarmthFrags() > 0)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
            }
            if (Randomizer.fragKeyFinish < RandomizerBonus.WarmthFrags())
            {
                Randomizer.showHint("@Warmth Fragment (extra)@", 300);
                return;
            }
            Randomizer.showHint(string.Concat(new object[] { "@Warmth Fragment (", RandomizerBonus.WarmthFrags().ToString(), "/", Randomizer.fragKeyFinish, ")@" }), 300);
            break;

        case 29:
            return;

        case 30:
            if (!flag)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
                Randomizer.showHint("Bleeding x" + RandomizerBonus.Bleeding().ToString());
                return;
            }
            if (RandomizerBonus.Bleeding() > 0)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
                Randomizer.showHint("Bleeding x" + RandomizerBonus.Bleeding().ToString());
                return;
            }
            break;

        case 31:
            if (!flag)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
            }
            else if (RandomizerBonus.Lifesteal() > 0)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
            }
            if (Lifesteal() == 1)
            {
                Randomizer.showHint("Health Drain");
            }
            else
            {
                Randomizer.showHint("Health Drain x" + RandomizerBonus.Lifesteal().ToString());
            }
            break;

        case 32:
            if (!flag)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
            }
            else if (RandomizerBonus.Manavamp() > 0)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
            }
            if (Manavamp() == 1)
            {
                Randomizer.showHint("Energy Drain");
            }
            else
            {
                Randomizer.showHint("Health Drain x" + RandomizerBonus.Manavamp().ToString());
            }
            break;
            break;

        case 33:
            if (!flag)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
                Randomizer.showHint("Skill Velocity Upgrade x" + RandomizerBonus.Velocity().ToString());
                return;
            }
            if (RandomizerBonus.Velocity() > 0)
            {
                Characters.Sein.Inventory.IncRandomizerItem(ID, -1);
                Randomizer.showHint("Skill Velocity Upgrade x" + RandomizerBonus.Velocity().ToString());
                return;
            }
            break;

        case 34:
            Characters.Sein.Inventory.SetRandomizerItem(34, 1);
            Randomizer.showHint("Return to start disabled!");
            break;

        case 35:
            Characters.Sein.Inventory.SetRandomizerItem(34, 0);
            Randomizer.showHint("Return to start enabled!");
            break;

        case 36:
            Randomizer.showHint("Underwater Skill Usage");
            Characters.Sein.Inventory.SetRandomizerItem(36, 1);
            break;

        case 40:
            if (!Characters.Sein || flag)
            {
                return;
            }
            Randomizer.showHint("@Wall Jump Lost!!@", 240);
            Characters.Sein.PlayerAbilities.WallJump.HasAbility = false;
            return;

        case 41:
            if (!Characters.Sein || flag)
            {
                return;
            }
            Randomizer.showHint("@ChargeFlame Lost!!@", 240);
            Characters.Sein.PlayerAbilities.ChargeFlame.HasAbility = false;
            return;

        case 42:
            if (!Characters.Sein || flag)
            {
                return;
            }
            Randomizer.showHint("@DoubleJump Lost!!@", 240);
            Characters.Sein.PlayerAbilities.DoubleJump.HasAbility = false;
            return;

        case 43:
            if (!Characters.Sein || flag)
            {
                return;
            }
            Randomizer.showHint("@Bash Lost!!@", 240);
            Characters.Sein.PlayerAbilities.Bash.HasAbility = false;
            return;

        case 44:
            if (!Characters.Sein || flag)
            {
                return;
            }
            Randomizer.showHint("@Stomp Lost!!@", 240);
            Characters.Sein.PlayerAbilities.Stomp.HasAbility = false;
            return;

        case 45:
            if (!Characters.Sein || flag)
            {
                return;
            }
            Randomizer.showHint("@Glide Lost!!@", 240);
            Characters.Sein.PlayerAbilities.Glide.HasAbility = false;
            return;

        case 46:
            if (!Characters.Sein || flag)
            {
                return;
            }
            Randomizer.showHint("@Climb Lost!!@", 240);
            Characters.Sein.PlayerAbilities.Climb.HasAbility = false;
            return;

        case 47:
            if (!Characters.Sein || flag)
            {
                return;
            }
            Randomizer.showHint("@Charge Jump Lost!!@", 240);
            Characters.Sein.PlayerAbilities.ChargeJump.HasAbility = false;
            return;

        case 48:
            if (!Characters.Sein || flag)
            {
                return;
            }
            Randomizer.showHint("@Dash Lost!!@", 240);
            Characters.Sein.PlayerAbilities.Dash.HasAbility = false;
            return;

        case 49:
            if (!Characters.Sein || flag)
            {
                return;
            }
            Randomizer.showHint("@Grenade Lost!!@", 240);
            Characters.Sein.PlayerAbilities.Grenade.HasAbility = false;
            return;

        case 81:
            Characters.Sein.Inventory.IncRandomizerItem(ID, 1);
            string s_color = "";
            string g_color = "";
            if (Characters.Sein.PlayerAbilities.HasAbility(AbilityType.Stomp))
            {
                s_color = "$";
            }
            if (Characters.Sein.PlayerAbilities.HasAbility(AbilityType.Grenade))
            {
                g_color = "$";
            }
            Randomizer.showHint(s_color + "Stomp: " + Randomizer.StompZone + s_color + g_color + "    Grenade: " + Randomizer.GrenadeZone + g_color, 480);
            break;

        default:
            return;
        }
    }