예제 #1
0
        // public override bool OnDroppedInto(Mobile from, Container target, Point3D p)
        public override bool OnDroppedInto(Mobile from, Container target, Point3D p, byte gridloc)

        {
            if (target == from.Backpack)
            {
                Item item = from.Backpack.FindItemByType(typeof(GoldLedger));

                if (item != null)
                {
                    from.SendMessage(2125, "You can only carry one gold ledger!");
                    return(false);
                }
            }

            else if (target.IsChildOf(from.Backpack))
            {
                Item item = from.Backpack.FindItemByType(typeof(GoldLedger));

                if (item != null)
                {
                    from.SendMessage(2125, "You can only carry one gold ledger!");
                    return(false);
                }
            }

            return(target.OnDragDropInto(from, this, p, gridloc));
        }
예제 #2
0
        public virtual bool OnDroppedInto( Mobile from, Container target, Point3D p )
        {
            if ( !from.OnDroppedItemInto( this, target, p ) )
                return false;

            return target.OnDragDropInto( from, this, p );
        }
예제 #3
0
파일: Item.cs 프로젝트: Ravenwolfe/xrunuo
        public virtual bool OnDroppedInto( Mobile from, Container target, Point3D p, byte gridloc )
        {
            if ( IsUnderYourFeet( from, target ) )
            {
                from.SendMessage( "No puedes mover eso, ¡estás pisando la bolsa!" );
                return false;
            }
            else if ( !from.OnDroppedItemInto( this, target, p ) )
            {
                return false;
            }
            else if ( NonTransferable && from.IsPlayer && target != from.Backpack && from.AccessLevel <= AccessLevel.GameMaster )
            {
                HandleInvalidTransfer( from );
                return false;
            }

            return target.OnDragDropInto( from, this, p, gridloc );
        }
예제 #4
0
       // public override bool OnDroppedInto(Mobile from, Container target, Point3D p)
        public override bool OnDroppedInto(Mobile from, Container target, Point3D p, byte gridloc)
        
        {
            if (target == from.Backpack)
            {
                Item item = from.Backpack.FindItemByType(typeof(GoldLedger));

                if (item != null)
                {
                    from.SendMessage(2125, "You can only carry one gold ledger!");
                    return false;
                }
            }

            else if (target.IsChildOf(from.Backpack))
            {
                Item item = from.Backpack.FindItemByType(typeof(GoldLedger));

                if (item != null)
                {
                    from.SendMessage(2125, "You can only carry one gold ledger!");
                    return false;
                }
            }

            return target.OnDragDropInto(from, this, p, gridloc);
        }