Inheritance: MonoBehaviour
    public BossBehaviourIdle(Boss boss)
    {
        boss.animator.SetFloat("X", 0);
        boss.animator.SetFloat("Y", 0);

        stateTimer = 2.0f;
    }
 void Awake()
 {
     boss = bossObj.GetComponent<Boss>();
     gamecon = GameObject.FindGameObjectWithTag(Tags.gameController)
         .GetComponent<GameController>();
     exiting = false;
 }
    public DialogueBox dialog;  //JUSTIN

    // Use this for initialization
    void Start()
    {
        b = GetComponent<Boss>();
        b.tiltEnabled = false;
        attackQueue = new List<int>();
        StartCoroutine(FlyIn());
    }
Beispiel #4
0
        public TextController(string bossName)
            : base(NSObject.AllocAndInitInstance("TextController"))
        {
            m_boss = ObjectModel.Create(bossName);
            Unused.Value = NSBundle.loadNibNamed_owner(NSString.Create("text-editor"), this);

            m_textView = new IBOutlet<NSTextView>(this, "textView");
            m_lineLabel = new IBOutlet<NSButton>(this, "lineLabel");
            m_decPopup = new IBOutlet<NSPopUpButton>(this, "decsPopup");
            m_scrollView = new IBOutlet<NSScrollView>(this, "scrollView");
            m_restorer = new RestoreViewState(this);

            var wind = m_boss.Get<IWindow>();
            wind.Window = window();

            m_applier = new ApplyStyles(this, m_textView.Value);
            DoSetTextOptions();

            Broadcaster.Register("text default color changed", this);
            Broadcaster.Register("languages changed", this);
            Broadcaster.Register("directory prefs changed", this);
            DoUpdateDefaultColor(string.Empty, null);

            m_textView.Value.Call("onOpened:", this);

            ActiveObjects.Add(this);
        }
Beispiel #5
0
 public StyleRuns(Boss boss, string path, int edit, StyleRun[] runs)
 {
     Boss = boss;
     Path = path;
     Edit = edit;
     Runs = runs;
 }
Beispiel #6
0
        protected override void ApplyBullet(Boss.BaseBoss enemy)
        {
            enemy.BossHit(damage, damage * 1f, direction, true);
            SoundManager.PlaySFX("bullet_collision");

            JumpToNextEnemy(enemy);
        }
        public string[] DoFindFullNames(Boss windowBoss, string typeName, int max)
        {
            if (typeName.Contains("."))
                return new string[]{typeName};

            Boss boss = ObjectModel.Create("DirectoryEditorPlugin");
            var finder = boss.Get<IFindDirectoryEditor>();
            boss = finder.GetDirectoryEditor(windowBoss);
            if (boss == null)
                throw new InvalidOperationException("Couldn't find a directory window associated with the text window.");

            IEnumerable<string> names;
            var database = boss.Get<IDatabase>();
            using (Database db = database.GetDatabase())
            {
                string sql = string.Format(@"
                    SELECT root_name
                        FROM Types
                    WHERE name = '{0}'
                    LIMIT {1}", typeName, max);
                string[][] rows = db.QueryRows(sql);

                names = from r in rows select r[0];
            }

            return names.ToArray();
        }
Beispiel #8
0
        public void Instantiated(Boss boss)
        {
            m_boss = boss;

            NSUserDefaults defaults = NSUserDefaults.standardUserDefaults();
            m_showSpaces = defaults.boolForKey(NSString.Create("show spaces"));
            m_showTabs = defaults.boolForKey(NSString.Create("show tabs"));
        }
 public KrakenRegularState(Boss boss)
     : base(boss)
 {
     waveAttackPercent = 15;
     directAttackPercent = 60;
     throwComboPercent = 25;
     standandCooldown = 5f;
 }
	// called during fixed update in boss
	void IBossBehavior.Update(Boss b) {
		// calculate unit vector direction
		Vector3 attackDirection = target.transform.position - b.transform.position;
		attackDirection.Normalize ();

		b.transform.Translate (attackVelocity * attackDirection);

	}
Beispiel #11
0
    void Awake()
    {
        boss = GetComponent<Boss> ();
        Rifle = transform.GetChild (0).FindChild ("AWP").GetComponent<Weapon>();
        Uzi = transform.GetChild (0).FindChild ("Uzi").GetComponent<Weapon>();

        // Set default waypoint to go to
        MovingTowardsWaypoint = 1;
    }
Beispiel #12
0
	public virtual void Init(int type, int currentHP, int maxHP) {
		this.type = type;
		this.maxHP = maxHP;
		this.currentHP = currentHP;
		Transform bossTrans = MyPoolManager.Instance.Spawn(GetBossPrefabName(slotMachineScreen.gameType, type), transform);
		boss = bossTrans.GetComponent<Boss>();
		boss.Init();
		UpdateHPBar();
	}
 //Create hp bars for players and bosses
 // Use this for initialization
 void Start()
 {
     player = FindObjectOfType<Player>(); //find player
     enemy = GetComponent<Boss>();
     moveController = GetComponent<MoveController>();
     damageTextOffset = new Vector3(0, 2, 0);
     currentHealth = maxhp; //+ player.getLevel()/3
     Update_Maxhp();
 }
Beispiel #14
0
        /// <summary>
        /// Simulates a fight between the wizard and the boss.
        /// </summary>
        /// <param name="spellSelector">A delegate to a method to use to select the next spell to conjure.</param>
        /// <param name="difficulty">The difficulty to play with.</param>
        /// <returns>
        /// A <see cref="Tuple{T1, T2}"/> that returns whether the wizard won and the amount of mana spent by the wizard.
        /// </returns>
        internal static Tuple<bool, int> Fight(Func<Wizard, ICollection<string>, string> spellSelector, string difficulty)
        {
            Wizard wizard = new Wizard(spellSelector);
            Boss boss = new Boss();

            Player winner = Fight(wizard, boss, difficulty, (f, a) => { });

            return Tuple.Create(winner == wizard, wizard.ManaSpent);
        }
Beispiel #15
0
 public KrakenAttackState(Boss boss)
     : base(StateIds.Attacking, boss)
 {
     NextStateIds.Add(StateIds.Idle);
     NextStateIds.Add(StateIds.Stunned);
     NextStateIds.Add (StateIds.Hurt);
     random = new System.Random();
     kraken = boss as Kraken;
 }
Beispiel #16
0
        public ShortForm(Boss boss, TextWriter writer)
        {
            m_boss = boss;
            m_writer = writer;

            var editor = m_boss.Get<IDirectoryEditor>();
            m_addSpace = editor.AddSpace;
            m_addBraceLine = editor.AddBraceLine;
        }
Beispiel #17
0
        public static string GetDatabasePath(Boss boss)
        {
            var editor = boss.Get<IDirectoryEditor>();
            string name = Path.GetFileName(editor.Path);

            string path = Paths.GetAssemblyDatabase(name);

            return path;
        }
 // Use this for initialization
 void Start()
 {
     //取得
     shot_part = GameObject.Find ("shot_rota").GetComponent<shot_part8>();
     gread = shot_part.gread;
     boss_cs = GameObject.Find ("baby").GetComponent<Boss>();
     boss_hp = boss_cs.HP;
     heat_max = shot_part.heat_max;
     heat = shot_part.heat;
 }
 public static BossSkillFactory Map(Boss owner)
 {
     switch (owner.Id)
     {
         case BossId.Radiation:
             return BossRadiationSkillFactory._;
         default:
             Debug.LogError(LogMessages.EnumUndefined(owner.Id));
             return null;
     }
 }
Beispiel #20
0
    void Start()
    {
        menu = GameObject.Find("Canvas").transform.Find("Menu").gameObject;
        winScreen = GameObject.Find("Canvas").transform.Find("Victory").gameObject;
        defeatScreen = GameObject.Find("Canvas").transform.Find("Defeat").gameObject;
        fpsController = GameObject.Find("/Player").GetComponent<FirstPersonController>();
        boss = GameObject.Find("/Boss").GetComponent<Boss>();

        Cursor.visible = false;
        gameState = GameStates.Playing;
    }
Beispiel #21
0
        public void Instantiated(Boss boss)
        {
            m_boss = boss;

            Thread thread = new Thread(this.DoComputeStyles);
            thread.Name = "CSharpStyler.DoComputeStyles";
            thread.IsBackground = true;		// allow the app to quit even if the thread is still running
            thread.Start();

            Broadcaster.Register("parsed file", this);
        }
        public static Arena Apply(IHero hero)
        {
            if (!isBossDefeated)
            {
                Boss enemy = new Boss();

                return new Arena(string.Format("Going for the {0}", BuildingName), new FightRules(1, 1), hero, enemy);
            }

            return null;
        }
Beispiel #23
0
    public EnragedState(Boss boss, IState enragedState)
        : base(StateIds.Enraged, boss)
    {
        NextStateIds.Add(StateIds.Dead);
        NextStateIds.Add(StateIds.Waiting);
        NextStateIds.Add (StateIds.Regular);

        stateMachine = new StateMachine(enragedState);
        stateMachine.AddState(new StunnedState(boss));
        stateMachine.AddState(new HurtState(boss));
        stateMachine.AddState(new IdleState(boss));
    }
    void Awake()
    {
        sem = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<SEManager>();
        bgm = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<BGMManager>();
        startTime = Time.time;
        bossState = 0;
        status = transform.parent.gameObject.GetComponent<Boss>();
        boss = transform.parent;
        StageRefPoint = GameObject.FindGameObjectWithTag("StageRefPoint").transform.position;

        status.isInvicible = true;
    }
 // Use this for initialization
 void Start()
 {
     animator = GetComponent<Animator>();
     Duration -= 1;
     max = new Vector3(20, 5, 10);
     player = FindObjectOfType<Player>().gameObject;
     rigBod = GetComponent<Rigidbody>();
     // moveCon = GetComponent<MoveController>();
     mal = FindObjectOfType<Boss>();
     direction = new Vector3(0, 0, 0);
     rigBod.velocity = direction;
 }
Beispiel #26
0
	// Use this for initialization
	void Start () 
    {
        boss = GameObject.Find("Boss").GetComponent<Boss>();
        active = true;

        Vector3 spawnPos = boss.transform.FindChildRecursive("WeaponTarget").position;
        spawnPos.y = boss.target.transform.position.y;

        transform.position = spawnPos;
        transform.LookAt(boss.target);

        float dist = Vector3.Distance(transform.position, boss.target.transform.position);
        lifeTime = (dist / speed + 0.15f) > 0.5f ? (dist / speed + 0.15f) : 0.5f;
	}
        public void Instantiated(Boss boss)
        {
            m_boss = boss;

            Boss b = ObjectModel.Create("Stylers");
            m_white = b.Get<IWhitespace>();

            Thread thread = new Thread(this.DoComputeStyles);
            thread.Name = "ComputeRegexStyles.DoComputeStyles";
            thread.IsBackground = true;		// allow the app to quit even if the thread is still running
            thread.Start();

            Broadcaster.Register("text changed", this);
        }
Beispiel #28
0
 // Use this for initialization
 void Start () {
     btnObj = GameObject.Find("Canvas/Result/Button");
     btnObj.SetActive(false);
     Button btn = btnObj.GetComponent<Button>();
     btn.onClick.AddListener(delegate () {
         OnClick(btnObj);
     });
     victory = GameObject.Find("Canvas/Result/ImageVictory");
     victory.SetActive(false);
     fail = GameObject.Find("Canvas/Result/ImageFail");
     fail.SetActive(false);
     GameObject bossGO = GameObject.Find("foregrounds/UFO/env_PlatformUfo");
     boss = bossGO.GetComponent<Boss>();
 }
        /// <summary>
        /// Allows the game to perform any initialization it needs to before starting to run.
        /// This is where it can query for any required services and load any non-graphic
        /// related content.  Calling base.Initialize will enumerate through any components
        /// and initialize them as well.
        /// </summary>
        protected override void Initialize()
        {
            
            //Initiate characters
            player = new Hero("Hero", Content.Load<Texture2D>(@"Characters\ninja_boy_little"),
                                  new Vector2(playerInitialPosX, playerInitialPosY), true, 100);

            bgCoder = new Boss("BGCoder", Content.Load<Texture2D>(@"Characters\BGcoder"),
                               new Vector2(Window.ClientBounds.Width-200, Window.ClientBounds.Height / 2), null);

            activeCharacters = new List<Character>();
            Dictionary<Abilities, int> introHMAbilities = new Dictionary<Abilities, int>();
            introHMAbilities.Add(Abilities.BrainPower, 3);
            introHMAbilities.Add(Abilities.Motivation, 3);
            introHMAbilities.Add(Abilities.Patience, 3);
            introHMAbilities.Add(Abilities.WorkDedication, 3);

            NonPlayerCharacter shopAbilities = new NonPlayerCharacter("Shop of Abilities", Content.Load<Texture2D>(@"Characters\shopicon"),
                               new Vector2(10, 300), NonPlayerCharacterTypes.Shop);

            HomeWork introHW = new HomeWork("Intro HW", Content.Load<Texture2D>(@"Characters\homework1"), new Vector2(500f, 0f), 2, null, Knowledges.IKnowConsole, introHMAbilities);
            HomeWork typesAndVarHW = new HomeWork("Data types and Varaibles", Content.Load<Texture2D>(@"Characters\homework2"), new Vector2(300f, 500f), 2, Knowledges.IKnowConsole, Knowledges.IKnowTypes, introHMAbilities);
            HomeWork operatorsHW = new HomeWork("Operators", Content.Load<Texture2D>(@"Characters\homework3"), new Vector2(50f, 500f), 2, Knowledges.IKnowTypes, Knowledges.IKnowOperators, introHMAbilities);
            HomeWork conditionsHW = new HomeWork("Conditions", Content.Load<Texture2D>(@"Characters\homework4"), new Vector2(200f, 0f), 2, Knowledges.IKnowOperators, Knowledges.IKnowConditions, introHMAbilities);
            HomeWork loopsHW = new HomeWork("Loops", Content.Load<Texture2D>(@"Characters\homework5"), new Vector2(750f, 30f), 2, Knowledges.IKnowConditions, Knowledges.IKnowLoops, introHMAbilities);
            HomeWork classesHW = new HomeWork("Classes", Content.Load<Texture2D>(@"Characters\homework6"), new Vector2(600f, 500f), 2, Knowledges.IKnowLoops, Knowledges.IKnowClasses, introHMAbilities);

            activeCharacters.Add(introHW);
            activeCharacters.Add(typesAndVarHW);
            activeCharacters.Add(operatorsHW);
            activeCharacters.Add(conditionsHW);
            activeCharacters.Add(loopsHW);
            activeCharacters.Add(classesHW);
            activeCharacters.Add(bgCoder);
            activeCharacters.Add(shopAbilities);

            //Initiate screns
            SCREEN_MANAGER.add_screen(new StartMenuScreen(GraphicsDevice,this));
            SCREEN_MANAGER.add_screen(new ChooseHeroScreen(GraphicsDevice, this));
            SCREEN_MANAGER.add_screen(new MapScreen(GraphicsDevice, this));
            SCREEN_MANAGER.add_screen(new ShopScreen(GraphicsDevice, this));
            SCREEN_MANAGER.add_screen(new DuelScreen(GraphicsDevice, this));
            SCREEN_MANAGER.add_screen(new FinalDuelScreen(GraphicsDevice, this));

            SCREEN_MANAGER.goto_screen("StartMenu");
           // SCREEN_MANAGER.goto_screen("Map");

            base.Initialize();
        }
    public BossBehaviourSpawnTurret( Boss boss )
    {
        this.boss = boss;

        currentState = State.START;
        stateTimer = AnimationLibrary.Get().SearchByName("B_Projectile").colStart;

        for(int i = 0; i < spawns.Length; i++)
        {
            spawns[i] = GameObject.Find("Spawn" + i + 1).transform;
        }

        boss.animator.SetInteger("AttackId", 5);
        boss.animator.SetTrigger("Attack");
    }
Beispiel #31
0
 void Start()
 {
     boss   = GameObject.Find("Boss").GetComponent <Boss>();
     player = GameObject.Find("Player").GetComponent <Player>();
 }
Beispiel #32
0
 private void Awake()
 {
     _boss          = GameObject.Find("Boss").GetComponent <Boss>();
     _bossTransform = GameObject.Find("Boss").GetComponent <Transform>();
 }
 public static void MakeBossNormalToType(Boss boss, TowerType type)
 {
     boss.State.SetVulnerability(type, Vulnerability.Normal);
 }
Beispiel #34
0
        public override void Update(GameTime gameTime)
        {
            base.Update(gameTime);

            _shootBulletTimer.Update(gameTime);

            var newPosition = new Vector2(
                Boss.Game.GameManager.Random.Next((int)(Boss.Width() / 2f), GameConfig.VirtualResolution.X - (int)(Boss.Width() / 2f)),
                Boss.Game.GameManager.Random.Next((int)(Boss.Height() / 2f) + 200, (int)(Boss.Height() / 2f) + 300)
                );

            Boss.MoveTo(newPosition, 1.5f);
        }
Beispiel #35
0
        public HomeWorld(Player myPlayer = null)
        {
            levelType = LevelName.Home;

            if (PlayerStats.firstTime)
            {
                PlayerStats.firstTime = false;
                myPlayer           = new Player(new Vector2(0, 0), Game1.A_CreateListOfAnimations(Game1.ANIMATION_DICTIONARY["PlayerAnimation"]));
                PlayerStats.hill   = new Level(LevelName.Hills, myPlayer, true);
                PlayerStats.snow   = new Level(LevelName.Ice, myPlayer, true);
                PlayerStats.desert = new Level(LevelName.Desert, myPlayer, true);
                PlayerStats.forest = new Level(LevelName.Forest, myPlayer, true);
            }
            myPlayer.Position = new Vector2(0, 0);

            AddObjectToHandler("Player", myPlayer);
            AddObjectToHandler("Cursor", new Cursor(new Vector2(200, 0), Game1.IMAGE_DICTIONARY["cursor"]));
            AddObjectToHandler("Ground", new GameObject(Game1.A_CreateListOfAnimations(Game1.ANIMATION_DICTIONARY["homeWorld"]), new Vector2(0, 500), "EdgeTile"));
            AddObjectToHandler("Grass", new GameObject(Game1.A_CreateListOfAnimations(Game1.ANIMATION_DICTIONARY["Grass"]), new Vector2(0, 485), "Grass"));
            LevelObjectDictionary["Grass"].FramesPerSecond = 2;
            LevelObjectDictionary["Grass"].A_BeginAnimation();
            LevelObjectDictionary["Grass"].ZOrder = 3;
            // Don't spawn the portal if the level is complete.

            AddObjectToHandler("PortalHills", new LevelPortal(new Vector2(1500, 366), Game1.A_CreateListOfAnimations(Game1.ANIMATION_DICTIONARY["Portal"]), PlayerStats.hill, (LevelObjectDictionary["Player"] as Player)));

            AddObjectToHandler("PortalIce", new LevelPortal(new Vector2(1700, 366), Game1.A_CreateListOfAnimations(Game1.ANIMATION_DICTIONARY["Portal"]), PlayerStats.snow, (LevelObjectDictionary["Player"] as Player)));

            AddObjectToHandler("PortalDesert", new LevelPortal(new Vector2(1900, 366), Game1.A_CreateListOfAnimations(Game1.ANIMATION_DICTIONARY["Portal"]), PlayerStats.desert, (LevelObjectDictionary["Player"] as Player)));

            AddObjectToHandler("PortalForest", new LevelPortal(new Vector2(2100, 366), Game1.A_CreateListOfAnimations(Game1.ANIMATION_DICTIONARY["Portal"]), PlayerStats.forest, (LevelObjectDictionary["Player"] as Player)));

            //Close the portals if they player has completed them
            if (PlayerStats.hillComplete)
            {
                (LevelObjectDictionary["PortalHills"] as LevelPortal).Closed = true;
            }
            if (PlayerStats.snowComplete)
            {
                (LevelObjectDictionary["PortalIce"] as LevelPortal).Closed = true;
            }
            if (PlayerStats.desertComplete)
            {
                (LevelObjectDictionary["PortalDesert"] as LevelPortal).Closed = true;
            }
            if (PlayerStats.forestComplete)
            {
                (LevelObjectDictionary["PortalForest"] as LevelPortal).Closed = true;
            }

            if (PlayerStats.hillComplete && PlayerStats.snowComplete && PlayerStats.desertComplete && PlayerStats.forestComplete)
            {
                Boss myBoss = new Boss(Game1.A_CreateListOfAnimations(Game1.ANIMATION_DICTIONARY["BossCenter"]), new Vector2(3050, 200), this, myPlayer);

                AddObjectToHandler("Boss", myBoss);
            }


            skillTree = new SkillTree(new Vector2(800, 400), LevelObjectDictionary["Player"] as Player, this);



            SortByZorder();
        }
 private static void MakeBossEnfeeble(Boss boss)
 {
     boss.State.Enfeeble      = true;
     boss.State.EnfeebleTimer = 0;
 }
        /// <summary>
        /// Parses all the data again and link related stuff to each other
        /// </summary>
        private void fillMissingData()
        {
            var agentsLookup = agent_data.getAllAgentsList().ToDictionary(a => a.getAgent());

            bool golem_mode = isGolem(boss_data.getID());

            // Set Agent instid, first_aware and last_aware
            var combat_list = combat_data.getCombatList();

            foreach (CombatItem c in combat_list)
            {
                if (agentsLookup.TryGetValue(c.getSrcAgent(), out var a))
                {
                    if (a.getInstid() == 0 && (c.isStateChange() == ParseEnum.StateChange.Normal || (golem_mode && isGolem(a.getID()) && c.isStateChange() == ParseEnum.StateChange.MaxHealthUpdate)))
                    {
                        a.setInstid(c.getSrcInstid());
                    }
                    if (a.getInstid() != 0)
                    {
                        if (a.getFirstAware() == 0)
                        {
                            a.setFirstAware(c.getTime());
                            a.setLastAware(c.getTime());
                        }
                        else
                        {
                            a.setLastAware(c.getTime());
                        }
                    }
                }
            }

            foreach (CombatItem c in combat_list)
            {
                if (c.getSrcMasterInstid() != 0)
                {
                    var master = agent_data.getAllAgentsList().Find(x => x.getInstid() == c.getSrcMasterInstid() && x.getFirstAware() < c.getTime() && c.getTime() < x.getLastAware());
                    if (master != null)
                    {
                        if (agentsLookup.TryGetValue(c.getSrcAgent(), out var minion) && minion.getFirstAware() < c.getTime() && c.getTime() < minion.getLastAware())
                        {
                            minion.setMasterAgent(master.getAgent());
                        }
                    }
                }
            }

            agent_data.clean();

            // Set Boss data agent, instid, first_aware, last_aware and name
            List <AgentItem> NPC_list      = agent_data.getNPCAgentList();
            HashSet <ulong>  multiple_boss = new HashSet <ulong>();

            foreach (AgentItem NPC in NPC_list)
            {
                if (NPC.getProf().EndsWith(boss_data.getID().ToString()))
                {
                    if (boss_data.getAgent() == 0)
                    {
                        boss_data.setAgent(NPC.getAgent());
                        boss_data.setInstid(NPC.getInstid());
                        boss_data.setFirstAware(NPC.getFirstAware());
                        boss_data.setName(NPC.getName());
                        boss_data.setTough(NPC.getToughness());
                    }
                    multiple_boss.Add(NPC.getAgent());
                    boss_data.setLastAware(NPC.getLastAware());
                }
            }
            if (multiple_boss.Count > 1)
            {
                agent_data.cleanInstid(boss_data.getInstid());
            }

            AgentItem bossAgent = agent_data.GetAgent(boss_data.getAgent());

            boss = new Boss(bossAgent);
            List <Point> bossHealthOverTime = new List <Point>();

            // a hack for buggy golem logs
            if (golem_mode)
            {
                ulong redirection = 0;

                foreach (AgentItem a in agent_data.getAllAgentsList())
                {
                    if (a.getID() == 19603)
                    {
                        redirection = a.getAgent();
                    }
                }

                if (redirection != 0)
                {
                    foreach (CombatItem c in combat_list)
                    {
                        if (c.getDstAgent() == 0 && c.getDstInstid() == 0 && c.isStateChange() == ParseEnum.StateChange.Normal && c.getIFF() == ParseEnum.IFF.Foe && c.isActivation() == ParseEnum.Activation.None)
                        {
                            c.setDstAgent(bossAgent.getAgent());
                            c.setDstInstid(bossAgent.getInstid());
                        }
                    }
                }
            }
            // Grab values threw combat data
            foreach (CombatItem c in combat_list)
            {
                if (c.getSrcInstid() == boss_data.getInstid() && c.isStateChange() == ParseEnum.StateChange.MaxHealthUpdate)//max health update
                {
                    boss_data.setHealth((int)c.getDstAgent());
                }
                switch (c.isStateChange())
                {
                case ParseEnum.StateChange.PointOfView:
                    if (log_data.getPOV() == "N/A")    //Point of View
                    {
                        ulong pov_agent = c.getSrcAgent();
                        if (agentsLookup.TryGetValue(pov_agent, out var p))
                        {
                            log_data.setPOV(p.getName());
                        }
                    }
                    break;

                case ParseEnum.StateChange.LogStart:
                    log_data.setLogStart(c.getValue());
                    break;

                case ParseEnum.StateChange.LogEnd:
                    log_data.setLogEnd(c.getValue());
                    break;

                case ParseEnum.StateChange.HealthUpdate:
                    //set health update
                    if (c.getSrcInstid() == boss_data.getInstid())
                    {
                        bossHealthOverTime.Add(new Point((int)(c.getTime() - boss_data.getFirstAware()), (int)c.getDstAgent()));
                    }
                    break;
                }
            }

            // Dealing with second half of Xera | ((22611300 * 0.5) + (25560600 * 0.5)
            if (boss_data.getID() == 16246)
            {
                int xera_2_instid = 0;
                foreach (AgentItem NPC in NPC_list)
                {
                    if (NPC.getProf().Contains("16286"))
                    {
                        bossHealthOverTime = new List <Point>();//reset boss health over time
                        xera_2_instid      = NPC.getInstid();
                        boss_data.setHealth(24085950);
                        boss.addPhaseData(boss_data.getLastAware());
                        boss.addPhaseData(NPC.getFirstAware());
                        boss_data.setLastAware(NPC.getLastAware());
                        foreach (CombatItem c in combat_list)
                        {
                            if (c.getSrcInstid() == xera_2_instid)
                            {
                                c.setSrcInstid(boss_data.getInstid());
                            }
                            if (c.getDstInstid() == xera_2_instid)
                            {
                                c.setDstInstid(boss_data.getInstid());
                            }
                            //set health update
                            if (c.getSrcInstid() == boss_data.getInstid() && c.isStateChange() == ParseEnum.StateChange.HealthUpdate)
                            {
                                bossHealthOverTime.Add(new Point((int)(c.getTime() - boss_data.getFirstAware()), (int)c.getDstAgent()));
                            }
                        }
                        break;
                    }
                }
            }
            //Dealing with Deimos split
            if (boss_data.getID() == 17154)
            {
                int deimos_2_instid = 0;
                foreach (AgentItem NPC in agent_data.getGadgetAgentList())
                {
                    if (NPC.getProf().Contains("08467") || NPC.getProf().Contains("08471"))
                    {
                        deimos_2_instid = NPC.getInstid();
                        long oldAware = boss_data.getLastAware();
                        if (NPC.getLastAware() < boss_data.getLastAware())
                        {
                            // No split
                            break;
                        }
                        boss.addPhaseData(NPC.getFirstAware() >= oldAware ? NPC.getFirstAware() : oldAware);
                        boss_data.setLastAware(NPC.getLastAware());
                        //List<CombatItem> fuckyou = combat_list.Where(x => x.getDstInstid() == deimos_2_instid ).ToList().Sum(x);
                        //int stop = 0;
                        foreach (CombatItem c in combat_list)
                        {
                            if (c.getTime() > oldAware)
                            {
                                if (c.getSrcInstid() == deimos_2_instid)
                                {
                                    c.setSrcInstid(boss_data.getInstid());
                                }
                                if (c.getDstInstid() == deimos_2_instid)
                                {
                                    c.setDstInstid(boss_data.getInstid());
                                }
                            }
                        }
                        break;
                    }
                }
            }
            boss_data.setHealthOverTime(bossHealthOverTime);//after xera in case of change

            // Re parse to see if the boss is dead and update last aware
            foreach (CombatItem c in combat_list)
            {
                //set boss dead
                if (c.isStateChange() == ParseEnum.StateChange.Reward)//got reward
                {
                    log_data.setBossKill(true);
                    boss_data.setLastAware(c.getTime());
                    break;
                }
                //set boss dead
                if (c.getSrcInstid() == boss_data.getInstid() && c.isStateChange() == ParseEnum.StateChange.ChangeDead && !log_data.getBosskill())//change dead
                {
                    log_data.setBossKill(true);
                    boss_data.setLastAware(c.getTime());
                }
            }

            //players
            if (p_list.Count == 0)
            {
                //Fix Disconected players
                var playerAgentList = agent_data.getPlayerAgentList();

                foreach (AgentItem playerAgent in playerAgentList)
                {
                    List <CombatItem> lp     = combat_data.getStates(playerAgent.getInstid(), ParseEnum.StateChange.Despawn, boss_data.getFirstAware(), boss_data.getLastAware());
                    Player            player = new Player(playerAgent);
                    bool skip = false;
                    foreach (Player p in p_list)
                    {
                        if (p.getAccount() == player.getAccount())//is this a copy of original?
                        {
                            skip = true;
                        }
                    }
                    if (skip)
                    {
                        continue;
                    }
                    if (lp.Count > 0)
                    {
                        //make all actions of other instances to original instid
                        foreach (AgentItem extra in NPC_list)
                        {
                            if (extra.getAgent() == playerAgent.getAgent())
                            {
                                var extra_login_Id = extra.getInstid();
                                foreach (CombatItem c in combat_list)
                                {
                                    if (c.getSrcInstid() == extra_login_Id)
                                    {
                                        c.setSrcInstid(playerAgent.getInstid());
                                    }
                                    if (c.getDstInstid() == extra_login_Id)
                                    {
                                        c.setDstInstid(playerAgent.getInstid());
                                    }
                                }
                                break;
                            }
                        }

                        player.SetDC(lp[0].getTime());
                        p_list.Add(player);
                    }
                    else//didnt dc
                    {
                        if (player.GetDC() == 0)
                        {
                            p_list.Add(player);
                        }
                    }
                }
            }
            // Sort
            p_list = p_list.OrderBy(a => a.getGroup()).ToList();
        }
 public static void MakeBossResistantToType(Boss boss, TowerType type)
 {
     boss.State.SetVulnerability(type, Vulnerability.Resistant);
 }
Beispiel #39
0
 public XmasBallBehaviour1(Boss boss) : base(boss)
 {
 }
Beispiel #40
0
        public override void Update(GameTime gameTime)
        {
            base.Update(gameTime);


            if (!Boss.TargetingPosition)
            {
                var newPosition = new Vector2(
                    Boss.Game.GameManager.Random.Next((int)(Boss.Width() / 2f), GameConfig.VirtualResolution.X - (int)(Boss.Width() / 2f)),
                    Boss.Game.GameManager.Random.Next((int)(Boss.Height() / 2f) + 100, 500 - (int)(Boss.Height() / 2f))
                    );

                Boss.MoveTo(newPosition, 1.5f);
            }

            if (_bulletFrequence.TotalMilliseconds > 0)
            {
                _bulletFrequence -= gameTime.ElapsedGameTime;
            }
            else
            {
                _bulletFrequence = TimeSpan.FromSeconds(0.5f);
                Boss.Game.GameManager.MoverManager.TriggerPattern("XmasBall/pattern1", BulletType.Type2, false, Boss.Position());
            }
        }
        public override void ComputeAdditionalPlayerData(Player p, ParsedLog log)
        {
            // big bomb
            CombatReplay      replay  = p.CombatReplay;
            List <CombatItem> bigbomb = log.GetBoonData(37966).Where(x => (x.DstInstid == p.InstID && x.IsBuffRemove == ParseEnum.BuffRemove.None)).ToList();

            foreach (CombatItem c in bigbomb)
            {
                int bigStart = (int)(c.Time - log.FightData.FightStart);
                int bigEnd   = bigStart + 6000;
                replay.Actors.Add(new CircleActor(true, 0, 300, new Tuple <int, int>(bigStart, bigEnd), "rgba(150, 80, 0, 0.2)", new AgentConnector(p)));
                replay.Actors.Add(new CircleActor(true, bigEnd, 300, new Tuple <int, int>(bigStart, bigEnd), "rgba(150, 80, 0, 0.2)", new AgentConnector(p)));
            }
            // small bomb
            List <CombatItem> smallbomb = log.GetBoonData(38247).Where(x => (x.DstInstid == p.InstID && x.IsBuffRemove == ParseEnum.BuffRemove.None)).ToList();

            foreach (CombatItem c in smallbomb)
            {
                int smallStart = (int)(c.Time - log.FightData.FightStart);
                int smallEnd   = smallStart + 6000;
                replay.Actors.Add(new CircleActor(true, 0, 80, new Tuple <int, int>(smallStart, smallEnd), "rgba(80, 150, 0, 0.3)", new AgentConnector(p)));
            }
            // fixated
            List <CombatItem> fixatedSam = GetFilteredList(log, 37868, p);
            int fixatedSamStart          = 0;

            foreach (CombatItem c in fixatedSam)
            {
                if (c.IsBuffRemove == ParseEnum.BuffRemove.None)
                {
                    fixatedSamStart = Math.Max((int)(c.Time - log.FightData.FightStart), 0);
                }
                else
                {
                    int fixatedSamEnd = (int)(c.Time - log.FightData.FightStart);
                    replay.Actors.Add(new CircleActor(true, 0, 80, new Tuple <int, int>(fixatedSamStart, fixatedSamEnd), "rgba(255, 80, 255, 0.3)", new AgentConnector(p)));
                }
            }
            //fixated Ghuldem
            List <CombatItem> fixatedGuldhem = GetFilteredList(log, 38223, p);
            int  fixationGuldhemStart        = 0;
            Boss guldhem = null;

            foreach (CombatItem c in fixatedGuldhem)
            {
                if (c.IsBuffRemove == ParseEnum.BuffRemove.None)
                {
                    fixationGuldhemStart = (int)(c.Time - log.FightData.FightStart);
                    guldhem = Targets.FirstOrDefault(x => x.ID == (ushort)ParseEnum.TrashIDS.Guldhem && c.Time >= x.FirstAware && c.Time <= x.LastAware);
                }
                else
                {
                    int fixationGuldhemEnd    = (int)(c.Time - log.FightData.FightStart);
                    Tuple <int, int> duration = new Tuple <int, int>(fixationGuldhemStart, fixationGuldhemEnd);
                    if (guldhem != null)
                    {
                        replay.Actors.Add(new LineActor(0, 10, duration, "rgba(255, 100, 0, 0.3)", new AgentConnector(p), new AgentConnector(guldhem)));
                    }
                }
            }
            //fixated Rigom
            List <CombatItem> fixatedRigom = GetFilteredList(log, 37693, p);
            int  fixationRigomStart        = 0;
            Boss rigom = null;

            foreach (CombatItem c in fixatedRigom)
            {
                if (c.IsBuffRemove == ParseEnum.BuffRemove.None)
                {
                    fixationRigomStart = (int)(c.Time - log.FightData.FightStart);
                    rigom = Targets.FirstOrDefault(x => x.ID == (ushort)ParseEnum.TrashIDS.Rigom && c.Time >= x.FirstAware && c.Time <= x.LastAware);
                }
                else
                {
                    int fixationRigomEnd      = (int)(c.Time - log.FightData.FightStart);
                    Tuple <int, int> duration = new Tuple <int, int>(fixationRigomStart, fixationRigomEnd);
                    if (rigom != null)
                    {
                        replay.Actors.Add(new LineActor(0, 10, duration, "rgba(255, 0, 0, 0.3)", new AgentConnector(p), new AgentConnector(rigom)));
                    }
                }
            }
        }
Beispiel #42
0
        public override void Update(GameTime gameTime)
        {
            base.Update(gameTime);

            if (Boss.Invincible && Boss.IsOutside)
            {
                Boss.Invincible = false;
            }

            // Go from a side to another side of the screen
            if (!Boss.TargetingPosition)
            {
                if (!Boss.StartShootTimer)
                {
                    Boss.StartShootTimer = true;
                }

                if (Boss.CurrentAnimator.Position.X > GameConfig.VirtualResolution.X + Boss.Width())
                {
                    GetNewYRandomPosition();
                    Boss.Direction.X = -1;
                }
                else if (Boss.CurrentAnimator.Position.X < -Boss.Width())
                {
                    GetNewYRandomPosition();
                    Boss.Direction.X = 1;
                }
            }
        }
 public XmasCandyBehaviour4(Boss boss) : base(boss)
 {
 }
Beispiel #44
0
        public override void Start()
        {
            base.Start();

            Boss.Speed = GameConfig.BossDefaultSpeed * 2.5f;

            _shootBulletTimer            = new CountdownTimer(1);
            _shootBulletTimer.Completed += (sender, args) =>
            {
                Boss.Game.GameManager.MoverManager.TriggerPattern("XmasSanta/pattern1", BulletType.Type2, false, Boss.Position());
                _shootBulletTimer.Restart();
            };

            Boss.CurrentAnimator.Play("Idle");
        }
Beispiel #45
0
        public async Task SiegeStartCommand([Remainder] string overrideString = "")
        {
            ulong fileId = Context.IsPrivate ? Context.User.Id : Context.Guild.Id;

            if (_gamesService.Sieges.ContainsKey(fileId) && _gamesService.Sieges[fileId].Active)
            {
                await SendErrorAsync("A battle is currently ongoing!");

                return;
            }

            if (!File.Exists($"Data{Path.DirectorySeparatorChar}{fileId}.siege"))
            {
                await SendErrorAsync($"**{Context.User.Username}**, no-one is signed up!");

                return;
            }

            // Get marbles
            List <(ulong id, string name)> rawMarbleData;

            using (var marbleList = new StreamReader($"Data{Path.DirectorySeparatorChar}{fileId}.siege"))
            {
                var formatter = new BinaryFormatter();
                if (marbleList.BaseStream.Length == 0)
                {
                    await SendErrorAsync($"**{Context.User.Username}**, no-one is signed up!");

                    return;
                }

                rawMarbleData = (List <(ulong id, string name)>)formatter.Deserialize(marbleList.BaseStream);
            }

            if (rawMarbleData.Count == 0)
            {
                await SendErrorAsync($"**{Context.User.Username}**, no-one is signed up!");

                return;
            }

            var marbles       = new List <SiegeMarble>();
            var marbleOutput  = new StringBuilder();
            var mentionOutput = new StringBuilder();
            int stageTotal    = 0;

            foreach ((ulong id, string name) in rawMarbleData)
            {
                var user = (await MarbleBotUser.Find(Context, id)) !;
                stageTotal += user.Stage;
                marbles.Add(new SiegeMarble(id, name, 0)
                {
                    Shield = user.GetShield(),
                    Spikes = user.GetSpikes()
                });

                marbleOutput.AppendLine($"**{name}** [{user.Name}#{user.Discriminator}]");

                SocketUser socketUser = Context.Client.GetUser(id);
                if (user.SiegePing && socketUser != null && socketUser.Status != UserStatus.Offline)
                {
                    mentionOutput.Append($"<@{user.Id}> ");
                }
            }

            Boss boss;

            if (!_gamesService.Sieges.TryGetValue(fileId, out Siege? currentSiege))
            {
                // Pick boss & set battle stats based on boss
                if (overrideString.Contains("override") &&
                    (_botCredentials.AdminIds.Any(id => id == Context.User.Id) || Context.IsPrivate))
                {
                    boss = Boss.GetBoss(overrideString.Split(' ')[1].RemoveChar(' '));
                }
                else
                {
                    // Choose a stage 1 or stage 2 boss depending on the stage of each participant
                    float stage = stageTotal / (float)marbles.Count;
                    if (Math.Abs(stage - 1f) < float.Epsilon)
                    {
                        boss = ChooseStageOneBoss(marbles);
                    }
                    else if (Math.Abs(stage - 2f) < float.Epsilon)
                    {
                        boss = ChooseStageTwoBoss(marbles);
                    }
                    else
                    {
                        stage--;
                        boss = _randomService.Rand.NextDouble() < stage
                            ? ChooseStageTwoBoss(marbles)
                            : ChooseStageOneBoss(marbles);
                    }
                }

                _gamesService.Sieges.TryAdd(fileId,
                                            currentSiege = new Siege(Context, _gamesService, _randomService, boss, marbles));
            }
            else
            {
                boss = currentSiege.Boss;
                currentSiege.Marbles = marbles;
            }

            int marbleHealth = ((int)boss.Difficulty + 2) * 5;

            foreach (SiegeMarble marble in marbles)
            {
                marble.MaxHealth = marbleHealth;
            }

            var builder = new EmbedBuilder()
                          .WithColor(GetColor(Context))
                          .WithDescription("Get ready! Use `mb/siege attack` to attack and `mb/siege grab` to grab power-ups when they appear!")
                          .WithTitle("The Siege has begun! :crossed_swords:")
                          .WithThumbnailUrl(boss.ImageUrl)
                          .AddField($"Marbles: **{marbles.Count}**", marbleOutput.ToString())
                          .AddField($"Boss: **{boss.Name}**", new StringBuilder()
                                    .AppendLine($"Health: **{boss.Health}**")
                                    .AppendLine($"Attacks: **{boss.Attacks.Length}**")
                                    .AppendLine($"Difficulty: **{boss.Difficulty} {(int)boss.Difficulty}**/10")
                                    .ToString());

            // Siege Start
            IUserMessage countdownMessage = await ReplyAsync("**3**");

            await Task.Delay(1000);

            await countdownMessage.ModifyAsync(m => m.Content = "**2**");

            await Task.Delay(1000);

            await countdownMessage.ModifyAsync(m => m.Content = "**1**");

            await Task.Delay(1000);

            await countdownMessage.ModifyAsync(m => m.Content = "**BEGIN THE SIEGE!**");

            await ReplyAsync(embed : builder.Build());

            currentSiege.Start();

            if (mentionOutput.Length != 0 && _botCredentials.AdminIds.Any(id => id == Context.User.Id) &&
                !overrideString.Contains("noping"))
            {
                await ReplyAsync(mentionOutput.ToString());
            }
        }
 private static void MakeBossResistantToFire(Boss boss)
 {
     MakeBossResistantToType(boss, TowerType.Fire);
 }
Beispiel #47
0
 public static void InsertEmployees(Boss boss)
 {
     dalEmployees.InsertAdmin(boss);
 }
Beispiel #48
0
 // OnStateEnter is called when a transition starts and the state machine starts to evaluate this state
 override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
 {
     Boss          = animator.GetComponent <Boss>();
     eggmanBoss    = animator.GetComponentInChildren <DrEggmanBoss>();
     Boss.canBeHit = false;
 }
Beispiel #49
0
 public void BossActive(Boss _boss, string _password)
 {
     boss       = _boss;
     word       = _password;
     wordActive = true;
 }
Beispiel #50
0
        static void Main(string[] args)
        {
            Console.WriteAscii("DUNGEONS", Color.IndianRed);
            Console.WriteLine("A game so boring that you would rather read it's source code.\n", Color.IndianRed);

            // Clear database and load new bosses from xml if argument is present
            bool clearDb = false;

            for (int i = 0; i < args.Length; i++)
            {
                string flag = args.GetValue(i).ToString();
                clearDb = flag == "newxml";
            }
            ;

            //Setup database
            DbOperations dbOperations = new DbOperations();

            dbOperations.InitiateDatabase(clearDb);

            Characters playerChar = null;

            //Check for saved character
            if (dbOperations.ContainsSaves() != null)
            {
                Console.WriteLineFormatted("Character save found: {0} ({1}, {2}, {3}, {4})\nDo you want to load this character (Y/N)?\nSelecting NO will result in deleting saves and creating new character.\n", Color.DarkGray, dbOperations.ContainsSaves());
                var  input   = Console.ReadKey(true);
                bool isValid = true;
                do
                {
                    switch (input.Key)
                    {
                    case ConsoleKey.Y:
                        playerChar = dbOperations.GetLatestSavedCharacter();
                        break;

                    case ConsoleKey.N:
                        dbOperations.DeleteSaves();
                        playerChar = new Characters(200, 30);
                        break;

                    default:
                        Console.WriteLine("Invalid input!\n", Color.OrangeRed);
                        isValid = false;
                        break;
                    }
                } while (isValid == false);
            }
            else
            {
                //Create player character
                playerChar = new Characters(200, 30);
            }

            string message;

            while (playerChar.Alive())
            {
                // Create enemy from database
                Boss boss = dbOperations.GetBossFromDB();
                if (boss == null)
                {
                    Console.WriteLine("You defeated all bosses. Restart game to start over", Color.DarkGray);
                    Console.ReadLine();
                    Environment.Exit(0);
                }
                Characters enemy = playerChar.GenerateEnemy(boss);

                //Initiate combat
                bool combatResult = Combat.InitiateCombat(playerChar, enemy);
                if (!combatResult)
                {
                    message = "You have defeated {0}.\n";
                    Formatter enemyName = new Formatter(enemy.Name, Color.OrangeRed);
                    Console.WriteLineFormatted(message, enemyName, Color.DarkGray);
                    dbOperations.SetAlive(boss, combatResult);
                    // Saves character progress after each combat
                    dbOperations.SavePlayerProgress(playerChar);
                }
            }
            Console.WriteAscii("YOU DIED", Color.OrangeRed);
            //Character died, remove saved progress
            dbOperations.DeleteSaves();
            Console.ReadLine();
        }
Beispiel #51
0
    // Use this for initialization

    void Awake()
    {
        LazerCollider.gameObject.SetActive(false);
        boss = GetComponent <Boss>();
    }
Beispiel #52
0
 // OnStateEnter is called when a transition starts and the state machine starts to evaluate this state
 override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
 {
     player = GameObject.FindGameObjectWithTag("Player").transform;
     rb     = animator.GetComponent <Rigidbody2D>();
     boss   = animator.GetComponent <Boss>();
 }
        public override List <PhaseData> GetPhases(ParsedLog log, bool requirePhases)
        {
            long             start         = 0;
            long             end           = 0;
            long             fightDuration = log.FightData.FightDuration;
            List <PhaseData> phases        = GetInitialPhase(log);
            Boss             mainTarget    = Targets.Find(x => x.ID == (ushort)ParseEnum.BossIDS.Samarog);

            if (mainTarget == null)
            {
                throw new InvalidOperationException("Main target of the fight not found");
            }
            phases[0].Targets.Add(mainTarget);
            if (!requirePhases)
            {
                return(phases);
            }
            // Determined check
            List <CombatItem> invulsSam = GetFilteredList(log, 762, mainTarget);

            for (int i = 0; i < invulsSam.Count; i++)
            {
                CombatItem c = invulsSam[i];
                if (c.IsBuffRemove == ParseEnum.BuffRemove.None)
                {
                    end = c.Time - log.FightData.FightStart;
                    phases.Add(new PhaseData(start, end));
                    if (i == invulsSam.Count - 1)
                    {
                        mainTarget.AddCustomCastLog(new CastLog(end, -5, (int)(fightDuration - end), ParseEnum.Activation.None, (int)(fightDuration - end), ParseEnum.Activation.None), log);
                    }
                }
                else
                {
                    start = c.Time - log.FightData.FightStart;
                    phases.Add(new PhaseData(end, start));
                    mainTarget.AddCustomCastLog(new CastLog(end, -5, (int)(start - end), ParseEnum.Activation.None, (int)(start - end), ParseEnum.Activation.None), log);
                }
            }
            if (fightDuration - start > 5000 && start >= phases.Last().End)
            {
                phases.Add(new PhaseData(start, fightDuration));
            }
            string[] namesSam = new [] { "Phase 1", "Split 1", "Phase 2", "Split 2", "Phase 3" };
            for (int i = 1; i < phases.Count; i++)
            {
                PhaseData phase = phases[i];
                phase.Name      = namesSam[i - 1];
                phase.DrawArea  = i == 1 || i == 3 || i == 5;
                phase.DrawStart = i == 3 || i == 5;
                phase.DrawEnd   = i == 1 || i == 3;
                if (i == 2 || i == 4)
                {
                    List <ushort> ids = new List <ushort>
                    {
                        (ushort)Rigom,
                        (ushort)Guldhem
                    };
                    AddTargetsToPhase(phase, ids, log);
                }
                else
                {
                    phase.Targets.Add(mainTarget);
                }
            }
            return(phases);
        }
Beispiel #54
0
 public XmasSantaBehaviour1(Boss boss) : base(boss)
 {
     InitialBehaviourLife = GameConfig.BossDefaultBehaviourLife * 0.5f;
 }
Beispiel #55
0
        public override void Start()
        {
            base.Start();

            Boss.Speed = GameConfig.BossDefaultSpeed * 2.5f;

            Boss.ShootTimerFinished += ShootTimerFinished;
            Boss.ShootTimerTime      = 0.5f;

            Boss.CurrentAnimator.Play("Idle");

            Boss.MoveTo(
                new Vector2(
                    -Boss.Width() - 10f,
                    Boss.Game.GameManager.Random.Next((int)(Boss.Height() / 2f), GameConfig.VirtualResolution.Y - (int)(Boss.Height() / 2f))
                    ),
                true
                );

            Boss.Invincible = true;
        }
Beispiel #56
0
 public XmasBellBehaviour2(Boss boss) : base(boss)
 {
 }
 private void ShootTimerFinished(object sender, float e)
 {
     Boss.TriggerPattern("XmasCandy/pattern4", BulletType.Type2, false, Boss.ActionPointPosition());
 }
Beispiel #58
0
 private void ShootTimerFinished(object sender, float e)
 {
     Boss.Game.GameManager.MoverManager.TriggerPattern("XmasBell/pattern1", BulletType.Type2, false, Boss.ActionPointPosition());
 }
        public override void Update(GameTime gameTime)
        {
            base.Update(gameTime);

            Boss.MoveTo(Boss.GetPlayerPosition(), true);
        }
Beispiel #60
0
 public Pattern02(Boss m_Boss)
 {
     this.m_Boss          = m_Boss;
     circleBulletLauncher = new CircleBulletLancher(m_Boss);
     missileBulletLancher = new MissileBulletLancher(m_Boss);
 }