Esempio n. 1
0
 /// <inheritdoc />
 public virtual void OnRobotDeath(RobotDeathEvent evnt)
 {
 }
Esempio n. 2
0
 public void OnRobotDeath(RobotDeathEvent evnt)
 {
     robot.others = robot.peer.GetOthers();
 }
Esempio n. 3
0
        /// <summary>
        /// This method is called by the game when another robot dies.
        /// </summary> 
        /// <param name="robotDeathEvent">The robot death event containing data about the robot that died.</param>
        public override void OnRobotDeath(RobotDeathEvent robotDeathEvent)
        {
            // Gets the name of the robot that died
            var deadRobotName = robotDeathEvent.Name;

            // Remove the robot data for the robot that died from the enemy dictionary and access list
            enemyDictionary.Remove(deadRobotName);
            accessedEnemyList.Remove(deadRobotName);

            // Remove the data entry for the oldest scanned robot, if we have such an entry
            if (oldestScanned != null && oldestScanned.name.Equals(deadRobotName))
            {
                oldestScanned = null;
            }
            if (target != null && target.name.Equals(deadRobotName))
            {
                target = null;
            }
        }
Esempio n. 4
0
 public void OnRobotDeath(RobotDeathEvent evnt)
 {
     robot.others = robot.peer.GetOthers();
 }
Esempio n. 5
0
 public override void OnRobotDeath(RobotDeathEvent e)
 {
     enemyCount--;
 }
Esempio n. 6
0
 public void OnRobotDeath(RobotDeathEvent evnt)
 {
     count(evnt);
 }
 /// <summary>
 /// Handle robot death event.
 /// </summary>
 /// <param name="evnt"></param>
 /// <inheritdoc/>
 public override void OnRobotDeath(RobotDeathEvent evnt)
 {
     var name = evnt.Name;
     this.enemies.Remove(name);
 }
Esempio n. 8
0
 public override void OnRobotDeath(RobotDeathEvent evnt)
 {
     publisher.publish(evnt);
 }
		public override void OnRobotDeath(RobotDeathEvent deadRobot)
		{
			if (deadRobot.Name == Enemy.Name) {
				Enemy.Clear();
			}
		}