예제 #1
0
            private bool CheckTravel(Point3D p)
            {
                if (!User.InRange(Moonstone.GetWorldLocation(), 2) || User.Map != Moonstone.Map)
                {
                    User.SendLocalizedMessage(500295); // You are too far away to do that.
                }
                else if (User.Murderer)
                {
                    User.SendLocalizedMessage(1019004); // You are not allowed to travel there.
                }
                else if (User.Criminal)
                {
                    User.SendLocalizedMessage(1005561, "", 0x22); // Thou'rt a criminal and cannot escape so easily.
                }
                else if (Spells.SpellHelper.CheckCombat(User))
                {
                    User.SendLocalizedMessage(1005564, "", 0x22); // Wouldst thou flee during the heat of battle??
                }
                else if (User.Spell != null)
                {
                    User.SendLocalizedMessage(1049616); // You are too busy to do that at the moment.
                }
                else if (User.Map == Map.TerMur && User.InRange(p, 1))
                {
                    User.SendLocalizedMessage(1019003); // You are already there.
                }
                else
                {
                    return(true);
                }

                return(false);
            }
예제 #2
0
파일: Rewards.cs 프로젝트: pallop/Servuo
            private bool CheckTravel(Point3D p)
            {
                if (!User.InRange(Moonstone.GetWorldLocation(), 1) || User.Map != Moonstone.Map)
                {
                    User.SendLocalizedMessage(1019002);                       // You are too far away to use the gate.
                }

                /* CEO - 02/20/06 - Removed to allow Reds access to other lands
                 * else if ( User.Murderer )
                 * {
                 *      User.SendLocalizedMessage( 1019004 ); // You are not allowed to travel there.
                 * }
                 */
                else if (Server.Factions.Sigil.ExistsOn(User))
                {
                    User.SendLocalizedMessage(1019004);                       // You are not allowed to travel there.
                }
                else if (User.Criminal)
                {
                    User.SendLocalizedMessage(1005561, "", 0x22);                       // Thou'rt a criminal and cannot escape so easily.
                }
                else if (Server.Spells.SpellHelper.CheckCombat(User))
                {
                    User.SendLocalizedMessage(1005564, "", 0x22);                       // Wouldst thou flee during the heat of battle??
                }
                else if (User.Spell != null)
                {
                    User.SendLocalizedMessage(1049616);                       // You are too busy to do that at the moment.
                }
                else if (User.Map == Map.TerMur && User.InRange(p, 1))
                {
                    User.SendLocalizedMessage(1019003);                       // You are already there.
                }
                else
                {
                    return(true);
                }

                return(false);
            }