コード例 #1
0
        public override void Load()
        {
            SteamHelper.Initialize();

            On.Terraria.Main.DrawTiles += Main_DrawTiles;

            On.Terraria.Main.DrawBlack += Main_DrawBlack;

            On.Terraria.Main.DrawWalls += Main_DrawWalls;

            //VoiceRecognitionSystem.Load();
            TBAInputs.Load(this);
            TimeStopManagement.Load();

            if (!Main.dedServ)
            {
                Textures.Load();

                Ref <Effect> screenRef = new Ref <Effect>(GetEffect("Effects/ShockwaveEffect")); // The path to the compiled shader file.
                Filters.Scene["Shockwave"] = new Filter(new ScreenShaderData(screenRef, "Shockwave"), EffectPriority.VeryHigh);
                Filters.Scene["Shockwave"].Load();

                SkyManager.Instance["TBA:TimeStopInvert"] = new PerfectlyNormalSky();
                Filters.Scene["TBA:TimeStopInvert"]       = new Filter(new ScreenShaderData("FilterInvert"), EffectPriority.High);

                UIManager.Load();

                Filters.Scene["TBA:FreezeSky"]       = new Filter(new ScreenShaderData("FilterMiniTower").UseColor(.7f, .7f, .7f), EffectPriority.VeryHigh);
                SkyManager.Instance["TBA:FreezeSky"] = new FreezeSky();

                AddEquipTexture(null, EquipType.Head, "DiavoloHead", "TerrarianBizzareAdventure/Items/Armor/Vanity/Vinegar/DiavoloHead_Head");
                AddEquipTexture(null, EquipType.Body, "DiavoloBody", "TerrarianBizzareAdventure/Items/Armor/Vanity/Vinegar/DiavoloChest_Body", "TerrarianBizzareAdventure/Items/Armor/Vanity/Vinegar/DiavoloChest_Arms");
            }
        }
コード例 #2
0
        public override void Unload()
        {
            Instance = null;

            On.Terraria.Main.DrawTiles -= Main_DrawTiles;
            On.Terraria.Main.DrawBlack -= Main_DrawBlack;
            On.Terraria.Main.DrawWalls -= Main_DrawWalls;

            TBAInputs.Unload();
            TimeStopManagement.Unload();

            Textures.Unload();

            StandLoader.Instance.Unload();
        }