示例#1
0
        public override int GetHashCode()
        {
            int hash = 17;

            hash = hash * 23 + Id.GetHashCode();
            hash = hash * 23 + Name.GetHashCode();
            hash = hash * 23 + Seats.GetHashCode();
            hash = hash * 23 + Region.GetHashCode();
            hash = hash * 23 + CoatOfArms.GetHashCode();
            hash = hash * 23 + Words.GetHashCode();
            hash = hash * 23 + Titles.GetHashCode();
            hash = hash * 23 + CurrentLord.GetHashCode();
            hash = hash * 23 + Founder.GetHashCode();
            hash = hash * 23 + Founded.GetHashCode();
            hash = hash * 23 + Heir.GetHashCode();
            hash = hash * 23 + Overlord.GetHashCode();
            hash = hash * 23 + DiedOut.GetHashCode();
            hash = hash * 23 + AncestralWeapons.GetHashCode();
            hash = hash * 23 + CadetBranches.GetHashCode();

            return(hash);
        }
示例#2
0
        public override Actor createActor(int id, Vector2 position, Microsoft.Xna.Framework.Vector2?velocity = null, double color = -1)
        {
            Actor a = null;

            if ((position.X >= 0 && position.X < world.width * Tile.size && position.Y >= 0 && position.Y < world.height * Tile.size))
            {
                switch (id)
                {
                case 0:
                    a = new Player(world, position);
                    return(a);

                case 1:
                    a = new Octo(world, position);
                    break;

                case 2:
                    a = new Blob(world, position, velocity ?? Vector2.Zero, color);
                    break;

                case 3:
                    a = new Sentinel(world, position);
                    break;

                case 4:
                    a = new Spikon(world, position);
                    break;

                case 5:
                    a = new Arrow(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 6:
                    a = new OctoBall(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 7:
                    a = new HealthOrb(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 8:
                    a = new FireShuriken(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 9:
                    a = new IceSpike(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 10:
                    a = new Numbers(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 11:
                    a = new FirstBoss(world, position);
                    return(a);

                case 12:
                    a = new LevelUp(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 13:
                    a = new Laser(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 14:
                    a = new FirePillar(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 15:
                    a = new ManaOrb(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 16:
                    a = new Zazzle(world, position);
                    return(a);

                case 17:
                    a = new ZazzleShot(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 18:
                    a = new Basilisk(world, position);
                    return(a);

                case 19:
                    a = new BlobSpawner(world, position);
                    return(a);

                case 20:
                    a = new Charger(world, position);
                    return(a);

                case 21:
                    a = new Grapple(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 22:
                    a = new Generator(world, position);
                    return(a);

                case 23:
                    a = new Explosion(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 24:
                    a = new Torch(world, position);
                    return(a);

                case 25:
                    a = new MagicPrimary(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 26:
                    a = new WizBlob(world, position);
                    return(a);

                case 27:
                    a = new LaserArrow(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 28:
                    a = new DiscoBlob(world, position, velocity ?? Vector2.Zero, color, checkpointCount++);
                    break;

                case 29:
                    a = new FireBlob(world, position, velocity ?? Vector2.Zero);
                    break;

                case 30:
                    a = new MrHammer(world, position, velocity ?? Vector2.Zero);
                    break;

                case 31:
                    a = new GigaBlob(world, position, velocity ?? Vector2.Zero);
                    break;

                case 32:
                    a = new MagicPrimary(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 33:
                    a = new DarkLucyPortrait(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 34:
                    a = new BloodyArrow(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 35:
                    a = new LucyFirePillar(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 36:
                    a = new WeddingPhoto(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 37:
                    a = new FancyPortrait(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 38:
                    a = new CoatOfArms(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 39:
                    a = new TandemBike(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 40:
                    a = new KnightStatue(world, position, velocity ?? Vector2.Zero);
                    return(a);

                case 41:
                    a = new SwordSlash(world, position, velocity ?? Vector2.Zero);
                    return(a);
                }
            }

            return(a);
        }
示例#3
0
 public void Awake()
 {
     sigil = (CoatOfArms)target;
 }