示例#1
0
文件: DBTMod.cs 项目: Fructure/DBT
        public override void Load()
        {
            if (!Main.dedServ)
            {
                StylePreviewGFX.LoadPreviewGFX(this);
                WishMenuGFX.LoadWishGFX(this);

                SteamHelper.Initialize();

                #region HotKeys

                characterMenuKey    = RegisterHotKey("Character Menu", "K");
                energyChargeKey     = RegisterHotKey("Energy Charge", "C");
                speedToggleKey      = RegisterHotKey("Speed Toggle", "Z");
                transformDownKey    = RegisterHotKey("Transform Down", "V");
                transformUpKey      = RegisterHotKey("Transform Up", "X");
                flightToggleKey     = RegisterHotKey("Flight Toggle", "Q");
                instantTransmission = RegisterHotKey("Instant Transmission", "I");

                #endregion

                kiBar = new KiBar();
                kiBar.Activate();

                kiBarInterface = new UserInterface();
                kiBarInterface.SetState(kiBar);
                kiBarInterface = new UserInterface();
                kiBarInterface.SetState(kiBar);

                kiBar.Visible = true;

                overloadBar = new OverloadBar();
                overloadBar.Activate();
                overloadBarInterface = new UserInterface();
                overloadBarInterface.SetState(overloadBar);

                dbtMenu = new DBTMenu();
                dbtMenu.Activate();

                characterTransformationsMenu = new CharacterTransformationsMenu(this);
                characterTransformationsMenu.Activate();
                characterMenuInterface = new UserInterface();
                characterMenuInterface.SetState(characterTransformationsMenu);

                wishMenu = new WishMenu();
                wishMenu.Activate();
                wishMenuInterface = new UserInterface();
                wishMenuInterface.SetState(wishMenu);

                Instance = this;

                circle = new CircleShader(new Ref <Effect>(GetEffect("Effects/CircleShader")), "Pass1");
            }
        }
示例#2
0
        public override void Load()
        {
            // loads the mod's configuration file.
            ConfigModel.Load();
            SteamHelper.Initialize();

            //Loot.EMMLoader.RegisterMod(this);
            //Loot.EMMLoader.SetupContent(this);

            tremorLoaded           = ModLoader.GetMod("Tremor") != null;
            thoriumLoaded          = ModLoader.GetMod("ThoriumMod") != null;
            enigmaLoaded           = ModLoader.GetMod("Laugicality") != null;
            battlerodsLoaded       = ModLoader.GetMod("UnuBattleRods") != null;
            expandedSentriesLoaded = ModLoader.GetMod("ExpandedSentries") != null;

            MyPlayer.kaiokenKey          = RegisterHotKey("Kaioken", "J");
            MyPlayer.energyCharge        = RegisterHotKey("Energy Charge", "C");
            MyPlayer.transform           = RegisterHotKey("Transform", "X");
            MyPlayer.powerDown           = RegisterHotKey("Power Down", "V");
            MyPlayer.speedToggle         = RegisterHotKey("Speed Toggle", "Z");
            MyPlayer.quickKi             = RegisterHotKey("Quick Ki", "N");
            MyPlayer.transMenu           = RegisterHotKey("Transformation Menu", "K");
            MyPlayer.instantTransmission = RegisterHotKey("Instant Transmission", "I");
            //MyPlayer.ProgressionMenuKey = RegisterHotKey("Progression Menu", "P");
            MyPlayer.flyToggle  = RegisterHotKey("Flight Toggle", "Q");
            MyPlayer.armorBonus = RegisterHotKey("Armor Bonus", "Y");

            if (!Main.dedServ)
            {
                GFX.LoadGFX(this);
                KiBar.visible = true;

                ActivateTransMenu();
                ActivateWishmenu();
                ActivateProgressionMenu();
                ActivateKiBar();
                ActivateOverloadBar();
                ActivateHairMenu();

                _instantTransmissionMapTeleporter = new InstantTransmissionMapHelper();

                circle = new CircleShader(new Ref <Effect>(GetEffect("Effects/CircleShader")), "Pass1");

                Filters.Scene["DBZMOD:GodSky"]        = new Filter(new ScreenShaderData("FilterMiniTower").UseColor(0.9f, 0.1f, 0.1f).UseOpacity(0.7f), EffectPriority.VeryHigh);
                SkyManager.Instance["DBZMOD:GodSky"]  = new GodSky();
                Filters.Scene["DBZMOD:WishSky"]       = new Filter(new ScreenShaderData("FilterMiniTower").UseColor(0.1f, 0.1f, 0.1f).UseOpacity(0.7f), EffectPriority.VeryHigh);
                SkyManager.Instance["DBZMOD:WishSky"] = new WishSky();
            }
        }
示例#3
0
文件: DBTMod.cs 项目: LinkatriX/DBT
        public override void Load()
        {
            if (!Main.dedServ)
            {
                HairGFX.LoadHairGFX(this);
                WishMenuGFX.LoadWishGFX(this);

                SteamHelper.Initialize();

                #region HotKeys

                characterMenuKey    = RegisterHotKey("Character Menu", "K");
                energyChargeKey     = RegisterHotKey("Energy Charge", "C");
                speedToggleKey      = RegisterHotKey("Speed Toggle", "Z");
                transformDownKey    = RegisterHotKey("Transform Down", "V");
                transformUpKey      = RegisterHotKey("Transform Up", "X");
                flightToggleKey     = RegisterHotKey("Flight Toggle", "Q");
                instantTransmission = RegisterHotKey("Instant Transmission", "I");
                techniqueMenuKey    = RegisterHotKey("Technique Menu", "N");

                #endregion

                kiBar = new KiBar();
                kiBar.Activate();

                kiBarInterface = new UserInterface();
                kiBarInterface.SetState(kiBar);
                kiBarInterface = new UserInterface();
                kiBarInterface.SetState(kiBar);

                kiBar.Visible = true;

                overloadBar = new OverloadBar();
                overloadBar.Activate();
                overloadBarInterface = new UserInterface();
                overloadBarInterface.SetState(overloadBar);

                dbtMenu = new DBTMenu();
                dbtMenu.Activate();

                characterTransformationsMenu = new CharacterTransformationsMenu(this);
                characterTransformationsMenu.Activate();
                characterMenuInterface = new UserInterface();
                characterMenuInterface.SetState(characterTransformationsMenu);

                techniqueMenu = new TechniqueMenu(this);
                techniqueMenu.Activate();
                techniqueMenuInterface = new UserInterface();
                techniqueMenuInterface.SetState(techniqueMenu);

                wishMenu = new WishMenu();
                wishMenu.Activate();
                wishMenuInterface = new UserInterface();
                wishMenuInterface.SetState(wishMenu);

                hairMenu = new HairMenu();
                hairMenu.Activate();
                hairMenuInterface = new UserInterface();
                hairMenuInterface.SetState(hairMenu);

                namekBookUI = new NamekianBookUI();
                namekBookUI.Activate();
                namekBookInterface = new UserInterface();
                namekBookInterface.SetState(namekBookUI);

                Ref <Effect> screenRef = new Ref <Effect>(GetEffect("Effects/ShockwaveEffect"));

                Filters.Scene["Shockwave"] = new Filter(new ScreenShaderData(screenRef, "Shockwave"), EffectPriority.VeryHigh);
                Filters.Scene["Shockwave"].Load();

                circle = new CircleShader(new Ref <Effect>(GetEffect("Effects/CircleShader")), "Pass1");

                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/MusicBoxes/BirthOfAGod"), ModContent.ItemType <AngelStaffBoxItem>(), ModContent.TileType <AngelStaffBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/MusicBoxes/HeadChala"), ModContent.ItemType <OneStarBoxItem>(), ModContent.TileType <OneStarBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/MusicBoxes/Budokai2"), ModContent.ItemType <TwoStarBoxItem>(), ModContent.TileType <TwoStarBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/MusicBoxes/Budokai3"), ModContent.ItemType <ThreeStarBoxItem>(), ModContent.TileType <ThreeStarBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/MusicBoxes/SSJ3Song"), ModContent.ItemType <FourStarBoxItem>(), ModContent.TileType <FourStarBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/MusicBoxes/Challenge"), ModContent.ItemType <FiveStarBoxItem>(), ModContent.TileType <FiveStarBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/MusicBoxes/LostCourage"), ModContent.ItemType <SixStarBoxItem>(), ModContent.TileType <SixStarBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/MusicBoxes/VegetaSSJ"), ModContent.ItemType <SevenStarBoxItem>(), ModContent.TileType <SevenStarBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/MusicBoxes/XV2Villain"), ModContent.ItemType <DragonBallsBoxItem>(), ModContent.TileType <DragonBallsBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/MusicBoxes/BurstLimit"), ModContent.ItemType <BabidisMagicBoxItem>(), ModContent.TileType <BabidisMagicBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/TheBarrenWastelands"), ModContent.ItemType <WastelandsBoxItem>(), ModContent.TileType <WastelandsBoxTile>());
                AddMusicBox(GetSoundSlot(SoundType.Music, "Sounds/Music/TheUnexpectedArrival"), ModContent.ItemType <FFBoxItem>(), ModContent.TileType <FFBoxTile>());
            }
        }