コード例 #1
0
ファイル: MovableObject.cs プロジェクト: willbur415/POO_TP1
 /// <summary>
 /// Determines whether the object is an enemy ship.
 /// </summary>
 /// <param name="objet">The objet.</param>
 /// <returns></returns>
 protected bool IsEnemyShip(Objet2D objet)
 {
     if (objet.GetType() == typeof(LittleShip) || objet.GetType() == typeof(BigShip) || objet.GetType() == typeof(BigBossShip))
     {
         return(true);
     }
     return(false);
 }
コード例 #2
0
ファイル: MovableObject.cs プロジェクト: willbur415/POO_TP1
 /// <summary>
 /// Determines whether the object is an enemy ship.
 /// </summary>
 /// <param name="objet">The objet.</param>
 /// <returns></returns>
 protected bool IsEnemyShip(Objet2D objet)
 {
     if (objet.GetType() == typeof(LittleShip) || objet.GetType() == typeof(BigShip) || objet.GetType() == typeof(BigBossShip))
     {
         return true;
     }
     return false;
 }
コード例 #3
0
ファイル: MovableObject.cs プロジェクト: willbur415/POO_TP1
 protected bool IsPlayer(Objet2D objet)
 {
     if (objet.GetType() == typeof(PlayerShip))
     {
         return true;
     }
     return false;
 }
コード例 #4
0
ファイル: MovableObject.cs プロジェクト: willbur415/POO_TP1
 protected bool IsEnemyBullet(Objet2D objet)
 {
     if (objet.GetType() == typeof (Bullet))
     {
         return true;
     }
     return false;
 }
コード例 #5
0
ファイル: MovableObject.cs プロジェクト: willbur415/POO_TP1
 /// <summary>
 /// Determines whether the specified objet is asteroid.
 /// </summary>
 /// <param name="objet">The objet.</param>
 /// <returns></returns>
 protected bool IsAsteroid(Objet2D objet)
 {
     if (objet.GetType() == typeof(Asteroid))
     {
         return true;
     }
     return false;
 }
コード例 #6
0
ファイル: MovableObject.cs プロジェクト: willbur415/POO_TP1
 protected bool IsEnemyBullet(Objet2D objet)
 {
     if (objet.GetType() == typeof(Bullet))
     {
         return(true);
     }
     return(false);
 }
コード例 #7
0
ファイル: MovableObject.cs プロジェクト: willbur415/POO_TP1
 protected bool IsPlayer(Objet2D objet)
 {
     if (objet.GetType() == typeof(PlayerShip))
     {
         return(true);
     }
     return(false);
 }
コード例 #8
0
ファイル: MovableObject.cs プロジェクト: willbur415/POO_TP1
 /// <summary>
 /// Determines whether the specified objet is asteroid.
 /// </summary>
 /// <param name="objet">The objet.</param>
 /// <returns></returns>
 protected bool IsAsteroid(Objet2D objet)
 {
     if (objet.GetType() == typeof(Asteroid))
     {
         return(true);
     }
     return(false);
 }