Installation Text for Celisuis Alignment System

In Playermobile.cs

Find:

 private int m_GuildMessageHue, m_AllianceMessageHue;

below it add:

  #region Alignment

        private bool m_LawfulGood;
        [CommandProperty(AccessLevel.GameMaster)]
        public bool LawfulGood
     {
        get { return m_LawfulGood; }
        set { m_LawfulGood = value; }
     }

        private bool m_NeutralGood;
        [CommandProperty(AccessLevel.GameMaster)]
        public bool NeutralGood
        {
            get { return m_NeutralGood; }
            set { m_NeutralGood = value; }
        }

        private bool m_ChaoticGood;
        [CommandProperty(AccessLevel.GameMaster)]
        public bool ChaoticGood
        {
            get { return m_ChaoticGood; }
            set { m_ChaoticGood = value; }
        }

        private bool m_LawfulNeutral;
        [CommandProperty(AccessLevel.GameMaster)]
        public bool LawfulNeutral
        {
            get { return m_LawfulNeutral; }
            set { m_LawfulNeutral = value; }
        }

        private bool m_TrueNeutral;
        [CommandProperty(AccessLevel.GameMaster)]
        public bool TrueNeutral
        {
            get { return m_TrueNeutral; }
            set { m_TrueNeutral = value; }
        }

        private bool m_ChaoticNeutral;
        [CommandProperty(AccessLevel.GameMaster)]
        public bool ChaoticNeutral
        {
            get { return m_ChaoticNeutral; }
            set { m_ChaoticNeutral = value; }
        }

        private bool m_LawfulEvil;
        [CommandProperty(AccessLevel.GameMaster)]
        public bool LawfulEvil
        {
            get { return m_LawfulEvil; }
            set { m_LawfulEvil = value; }

        }

        private bool m_NeutralEvil;
        [CommandProperty(AccessLevel.GameMaster)]
        public bool NeutralEvil
        {
            get { return m_NeutralEvil; }
            set { m_NeutralEvil = value; }
        }

        private bool m_ChaoticEvil;
        [CommandProperty(AccessLevel.GameMaster)]
        public bool ChaoticEvil
        {
            get { return m_ChaoticEvil; }
            set { m_ChaoticEvil = value; }
        }
        #endregion

___________________________________________________________________________

In Playermobile.cs

Find:

 private static void OnLogin(LoginEventArgs e)
        {
            Mobile from = e.Mobile;

Add Below it:

  #region Alignment
            PlayerMobile player = e.Mobile as PlayerMobile;

            if (player.LawfulGood && AlignmentSystem.LawfulGood)
            {
                if (AlignmentSystem.ShowTitles)
                {
                    player.Title = "Lawful Good";
                }
            }
            if (player.NeutralGood && AlignmentSystem.NeutralGood)
            {
                if (AlignmentSystem.ShowTitles)
                {
                    player.Title = "Neutral Good";
                }
            }
            if (player.ChaoticGood && AlignmentSystem.ChaoticGood)
            {
                if(AlignmentSystem.ShowTitles)
                {
                    player.Title = "Chaotic Good";
                }
            }
            if (player.LawfulNeutral && AlignmentSystem.LawfulNeutral)
            {
                if (AlignmentSystem.ShowTitles)
                {
                    player.Title = "Lawful Neutral";
                }
            }
            if (player.TrueNeutral && AlignmentSystem.TrueNeutral)
            {
                if (AlignmentSystem.ShowTitles)
                {
                    player.Title = "True Neutral";
                }
            }
            if (player.ChaoticNeutral && AlignmentSystem.ChaoticNeutral)
            {
                if (AlignmentSystem.ShowTitles)
                {
                    player.Title = "Chaotic Neutral";
                }
            }
            if (player.LawfulEvil && AlignmentSystem.LawfulEvil)
            {
                if (AlignmentSystem.ShowTitles)
                {
                    player.Title = "Lawful Evil";
                }
            }
            if (player.NeutralEvil && AlignmentSystem.NeutralEvil)
            {
                if (AlignmentSystem.ShowTitles)
                {
                    player.Title = "Neutral Evil";
                }
            }
            if (player.ChaoticEvil && AlignmentSystem.ChaoticEvil)
            {
                if (AlignmentSystem.ShowTitles)
                {
                    player.Title = "Chaotic Evil";
                }
            }

            #endregion

______________________________________________________________
In Playermobile.cs

In Deserialize:

Add a new case number and add this:

 {
                        m_LawfulGood = reader.ReadBool();
                        m_NeutralGood = reader.ReadBool();
                        m_ChaoticGood = reader.ReadBool();
                        m_LawfulNeutral = reader.ReadBool();
                        m_TrueNeutral = reader.ReadBool();
                        m_ChaoticNeutral = reader.ReadBool();
                        m_LawfulEvil = reader.ReadBool();
                        m_NeutralEvil = reader.ReadBool();
                        m_ChaoticEvil = reader.ReadBool();

                        goto case ##;
                    }

Change ## to the following case number

______________________________________________________________
In Playermobile.cs

In Serialize, change:

 writer.Write((int)##); // version

Change the ## to the number case you just made

Add below:  writer.Write((int)##); // version

 //Alignment
            writer.Write((bool)m_LawfulGood);
            writer.Write((bool)m_NeutralGood);
            writer.Write((bool)m_ChaoticGood);
            writer.Write((bool)m_LawfulNeutral);
            writer.Write((bool)m_TrueNeutral);
            writer.Write((bool)m_ChaoticNeutral);
            writer.Write((bool)m_LawfulEvil);
            writer.Write((bool)m_NeutralEvil);
            writer.Write((bool)m_ChaoticEvil);
____________________________________________________________________

In Notoriety.cs

Find:
				BaseCreature bc = from as BaseCreature;

			if( !from.Player && !(bc != null && bc.GetMaster() != null && bc.GetMaster().AccessLevel == AccessLevel.Player ) )
			{
				if( !CheckAggressor( from.Aggressors, target ) && !CheckAggressed( from.Aggressed, target ) && target is PlayerMobile && ((PlayerMobile)target).CheckYoungProtection( from ) )
					return false;

				return true; // Uncontrolled NPCs are only restricted by the young system
            }

Add Below it:

         #region Alignment
            PlayerMobile player = from as PlayerMobile;
			PlayerMobile player2 = target as PlayerMobile;

            if (AlignmentSystem.Enemies)
            {
                #region Good Vs Evil
                if (from is PlayerMobile && target is PlayerMobile && player.LawfulGood && player2.LawfulEvil)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.LawfulGood && player2.NeutralEvil)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.LawfulGood && player2.ChaoticEvil)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.NeutralGood && player2.LawfulEvil)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.NeutralGood && player2.NeutralEvil)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.NeutralGood && player2.ChaoticEvil)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.ChaoticGood && player2.LawfulEvil)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.ChaoticGood && player2.NeutralEvil)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.ChaoticGood && player2.ChaoticEvil)
                {
                    return true;
                }
                #endregion
                #region Evil Vs Good
                if (from is PlayerMobile && target is PlayerMobile && player.LawfulEvil && player2.LawfulGood)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.LawfulEvil && player2.NeutralGood)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.LawfulEvil && player2.ChaoticGood)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.NeutralEvil && player2.LawfulGood)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.NeutralEvil && player2.NeutralGood)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.NeutralEvil && player2.ChaoticGood)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.ChaoticEvil && player2.LawfulGood)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.ChaoticEvil && player2.NeutralGood)
                {
                    return true;
                }
                if (from is PlayerMobile && target is PlayerMobile && player.ChaoticEvil && player2.ChaoticGood)
                {
                    return true;
                }
                #endregion
            }
            #endregion

