/// <summary>
 /// 
 /// </summary>
 internal void OnEnteredMap( WorldEntity worldEntity, BaseMap map )
 {
     EventHandler<WorldEntityEnteredMapEventArgs> tempAfterEventArgs = m_EventWorldEntityEnteredMap;
     if ( tempAfterEventArgs != null )
     {
         WorldEntityEnteredMapEventArgs eventArgs = new WorldEntityEnteredMapEventArgs( worldEntity, map );
         tempAfterEventArgs( this, eventArgs );
     }
 }
示例#2
0
        /// <summary>
        ///
        /// </summary>
        internal void OnEnteredMap(WorldEntity worldEntity, BaseMap map)
        {
            EventHandler <WorldEntityEnteredMapEventArgs> tempAfterEventArgs = m_EventWorldEntityEnteredMap;

            if (tempAfterEventArgs != null)
            {
                WorldEntityEnteredMapEventArgs eventArgs = new WorldEntityEnteredMapEventArgs(worldEntity, map);
                tempAfterEventArgs(this, eventArgs);
            }
        }
示例#3
0
        /// <summary>
        ///
        /// </summary>
        internal void OnLeavedMap(BaseItem item, BaseMap map)
        {
            EventHandler <ItemLeavedMapEventArgs> tempAfterEventArgs = m_EventItemLeavedMap;

            if (tempAfterEventArgs != null)
            {
                ItemLeavedMapEventArgs eventArgs = new ItemLeavedMapEventArgs(item, map);
                tempAfterEventArgs(this, eventArgs);
            }
        }
示例#4
0
        /// <summary>
        ///
        /// </summary>
        internal void OnLeavedMap(BaseCreature creature, BaseMap map)
        {
            EventHandler <CreatureLeavedMapEventArgs> tempAfterEventArgs = m_EventCreatureLeavedMap;

            if (tempAfterEventArgs != null)
            {
                CreatureLeavedMapEventArgs eventArgs = new CreatureLeavedMapEventArgs(creature, map);
                tempAfterEventArgs(this, eventArgs);
            }
        }
示例#5
0
        /// <summary>
        ///
        /// </summary>
        internal void OnLeavedMap(BaseCharacter character, BaseMap map)
        {
            EventHandler <CharacterLeavedMapEventArgs> tempAfterEventArgs = m_EventCharacterLeavedMap;

            if (tempAfterEventArgs != null)
            {
                CharacterLeavedMapEventArgs eventArgs = new CharacterLeavedMapEventArgs(character, map);
                tempAfterEventArgs(this, eventArgs);
            }
        }
示例#6
0
        /// <summary>
        ///
        /// </summary>
        internal void OnMoved(Point3D oldLocation, WorldEntity worldEntity, BaseMap map)
        {
            EventHandler <WorldEntityMovedInMapEventArgs> tempAfterEventArgs = m_EventWorldEntityMovedInMap;

            if (tempAfterEventArgs != null)
            {
                WorldEntityMovedInMapEventArgs eventArgs = new WorldEntityMovedInMapEventArgs(oldLocation, worldEntity, map);
                tempAfterEventArgs(this, eventArgs);
            }
        }
示例#7
0
        /// <summary>
        ///
        /// </summary>
        internal void OnMoved(Point3D oldLocation, BaseItem item, BaseMap map)
        {
            EventHandler <ItemMovedInMapEventArgs> tempAfterEventArgs = m_EventItemMovedInMap;

            if (tempAfterEventArgs != null)
            {
                ItemMovedInMapEventArgs eventArgs = new ItemMovedInMapEventArgs(oldLocation, item, map);
                tempAfterEventArgs(this, eventArgs);
            }
        }
示例#8
0
        /// <summary>
        ///
        /// </summary>
        internal void OnMoved(Point3D oldLocation, BaseCreature creature, BaseMap map)
        {
            EventHandler <CreaturedMoveInMapEventArgs> tempAfterEventArgs = m_EventCreatureMovedInMap;

            if (tempAfterEventArgs != null)
            {
                CreaturedMoveInMapEventArgs eventArgs = new CreaturedMoveInMapEventArgs(oldLocation, creature, map);
                tempAfterEventArgs(this, eventArgs);
            }
        }
示例#9
0
        /// <summary>
        ///
        /// </summary>
        internal void OnMoved(Point3D oldLocation, BaseCharacter character, BaseMap map)
        {
            EventHandler <CharacterMovedInMapEventArgs> tempAfterEventArgs = m_EventCharacterMovedInMap;

            if (tempAfterEventArgs != null)
            {
                CharacterMovedInMapEventArgs eventArgs = new CharacterMovedInMapEventArgs(oldLocation, character, map);
                tempAfterEventArgs(this, eventArgs);
            }
        }
示例#10
0
        /// <summary>
        /// 
        /// </summary>
        internal bool OnEnteringMap( WorldEntity worldEntity, BaseMap map )
        {
            EventHandler<WorldEntityEnteringMapEventArgs> tempBeforeEventArgs = m_EventWorldEntityEnteringMap;
            if ( tempBeforeEventArgs != null )
            {
                WorldEntityEnteringMapEventArgs eventArgs = new WorldEntityEnteringMapEventArgs( worldEntity, map );
                tempBeforeEventArgs( this, eventArgs );

                return eventArgs.IsCancel;
            }

            return false;
        }
示例#11
0
        /// <summary>
        ///
        /// </summary>
        internal bool OnEnteringMap(WorldEntity worldEntity, BaseMap map)
        {
            EventHandler <WorldEntityEnteringMapEventArgs> tempBeforeEventArgs = m_EventWorldEntityEnteringMap;

            if (tempBeforeEventArgs != null)
            {
                WorldEntityEnteringMapEventArgs eventArgs = new WorldEntityEnteringMapEventArgs(worldEntity, map);
                tempBeforeEventArgs(this, eventArgs);

                return(eventArgs.IsCancel);
            }

            return(false);
        }
示例#12
0
        /// <summary>
        ///
        /// </summary>
        internal bool OnMoving(Point3D oldLocation, BaseCharacter character, BaseMap map)
        {
            EventHandler <CharacterMovingInMapEventArgs> tempBeforeEventArgs = m_EventCharacterMovingInMap;

            if (tempBeforeEventArgs != null)
            {
                CharacterMovingInMapEventArgs eventArgs = new CharacterMovingInMapEventArgs(oldLocation, character, map);
                tempBeforeEventArgs(this, eventArgs);

                return(eventArgs.IsCancel);
            }

            return(false);
        }
示例#13
0
        /// <summary>
        ///
        /// </summary>
        internal bool OnEnteringMap(BaseItem item, BaseMap map)
        {
            EventHandler <ItemEnteringMapEventArgs> tempBeforeEventArgs = m_EventItemEnteringMap;

            if (tempBeforeEventArgs != null)
            {
                ItemEnteringMapEventArgs eventArgs = new ItemEnteringMapEventArgs(item, map);
                tempBeforeEventArgs(this, eventArgs);

                return(eventArgs.IsCancel);
            }

            return(false);
        }
示例#14
0
        /// <summary>
        ///
        /// </summary>
        internal bool OnLeavingMap(BaseCharacter character, BaseMap map)
        {
            EventHandler <CharacterLeavingMapEventArgs> tempBeforeEventArgs = m_EventCharacterLeavingMap;

            if (tempBeforeEventArgs != null)
            {
                CharacterLeavingMapEventArgs eventArgs = new CharacterLeavingMapEventArgs(character, map);
                tempBeforeEventArgs(this, eventArgs);

                return(eventArgs.IsCancel);
            }

            return(false);
        }
示例#15
0
        /// <summary>
        ///
        /// </summary>
        internal bool OnLeavingMap(BaseCreature creature, BaseMap map)
        {
            EventHandler <CreatureLeavingMapEventArgs> tempBeforeEventArgs = m_EventCreatureLeavingMap;

            if (tempBeforeEventArgs != null)
            {
                CreatureLeavingMapEventArgs eventArgs = new CreatureLeavingMapEventArgs(creature, map);
                tempBeforeEventArgs(this, eventArgs);

                return(eventArgs.IsCancel);
            }

            return(false);
        }
示例#16
0
        /// <summary>
        ///
        /// </summary>
        internal bool OnMoving(Point3D oldLocation, WorldEntity worldEntity, BaseMap map)
        {
            EventHandler <WorldEntityMovingInMapEventArgs> tempBeforeEventArgs = m_EventWorldEntityMovingInMap;

            if (tempBeforeEventArgs != null)
            {
                WorldEntityMovingInMapEventArgs eventArgs = new WorldEntityMovingInMapEventArgs(oldLocation, worldEntity, map);
                tempBeforeEventArgs(this, eventArgs);

                return(eventArgs.IsCancel);
            }

            return(false);
        }
示例#17
0
        /// <summary>
        ///
        /// </summary>
        internal bool OnMoving(Point3D oldLocation, BaseItem item, BaseMap map)
        {
            EventHandler <ItemMovingInMapEventArgs> tempBeforeEventArgs = m_EventItemMovingInMap;

            if (tempBeforeEventArgs != null)
            {
                ItemMovingInMapEventArgs eventArgs = new ItemMovingInMapEventArgs(oldLocation, item, map);
                tempBeforeEventArgs(this, eventArgs);

                return(eventArgs.IsCancel);
            }

            return(false);
        }
示例#18
0
        /// <summary>
        /// 
        /// </summary>
        internal bool OnLeavingMap( BaseCreature creature, BaseMap map )
        {
            EventHandler<CreatureLeavingMapEventArgs> tempBeforeEventArgs = m_EventCreatureLeavingMap;
            if ( tempBeforeEventArgs != null )
            {
                CreatureLeavingMapEventArgs eventArgs = new CreatureLeavingMapEventArgs( creature, map );
                tempBeforeEventArgs( this, eventArgs );

                return eventArgs.IsCancel;
            }

            return false;
        }
示例#19
0
 /// <summary>
 /// 
 /// </summary>
 internal void OnLeavedMap( BaseCreature creature, BaseMap map )
 {
     EventHandler<CreatureLeavedMapEventArgs> tempAfterEventArgs = m_EventCreatureLeavedMap;
     if ( tempAfterEventArgs != null )
     {
         CreatureLeavedMapEventArgs eventArgs = new CreatureLeavedMapEventArgs( creature, map );
         tempAfterEventArgs( this, eventArgs );
     }
 }
示例#20
0
 /// <summary>
 /// 
 /// </summary>
 internal void OnMoved( Point3D oldLocation, BaseCreature creature, BaseMap map )
 {
     EventHandler<CreaturedMoveInMapEventArgs> tempAfterEventArgs = m_EventCreatureMovedInMap;
     if ( tempAfterEventArgs != null )
     {
         CreaturedMoveInMapEventArgs eventArgs = new CreaturedMoveInMapEventArgs( oldLocation, creature, map );
         tempAfterEventArgs( this, eventArgs );
     }
 }
示例#21
0
 /// <summary>
 /// 初始化构造
 /// </summary>
 /// <param name="baseCreature"></param>
 public MovedToWorldEventArgs( Point3D oldLocation, BaseMap oldMap, WorldEntity gameEntity ) :
     base( gameEntity )
 {
     m_OldLocation = oldLocation;
     m_OldMap = oldMap;
 }
示例#22
0
 /// <summary>
 /// 
 /// </summary>
 /// <param name="owner"></param>
 public MapSpaceNode( BaseMap owner )
 {
 }
 /// <summary>
 /// 
 /// </summary>
 /// <param name="mobile"></param>
 /// <param name="newLocation"></param>
 public MoveToWorldEventArgs( Point3D newLocation, BaseMap newMap, WorldEntity entity )
 {
     m_Entity = entity;
     m_NewMap = newMap;
     m_NewLocation = newLocation;
 }
示例#24
0
 /// <summary>
 /// 
 /// </summary>
 internal void OnLeavedMap( BaseCharacter character, BaseMap map )
 {
     EventHandler<CharacterLeavedMapEventArgs> tempAfterEventArgs = m_EventCharacterLeavedMap;
     if ( tempAfterEventArgs != null )
     {
         CharacterLeavedMapEventArgs eventArgs = new CharacterLeavedMapEventArgs( character, map );
         tempAfterEventArgs( this, eventArgs );
     }
 }
示例#25
0
        /// <summary>
        /// 
        /// </summary>
        internal bool OnMoving( Point3D oldLocation, WorldEntity worldEntity, BaseMap map )
        {
            EventHandler<WorldEntityMovingInMapEventArgs> tempBeforeEventArgs = m_EventWorldEntityMovingInMap;
            if ( tempBeforeEventArgs != null )
            {
                WorldEntityMovingInMapEventArgs eventArgs = new WorldEntityMovingInMapEventArgs( oldLocation, worldEntity, map );
                tempBeforeEventArgs( this, eventArgs );

                return eventArgs.IsCancel;
            }

            return false;
        }
示例#26
0
 /// <summary>
 /// 
 /// </summary>
 internal void OnMoved( Point3D oldLocation, BaseCharacter character, BaseMap map )
 {
     EventHandler<CharacterMovedInMapEventArgs> tempAfterEventArgs = m_EventCharacterMovedInMap;
     if ( tempAfterEventArgs != null )
     {
         CharacterMovedInMapEventArgs eventArgs = new CharacterMovedInMapEventArgs( oldLocation, character, map );
         tempAfterEventArgs( this, eventArgs );
     }
 }
示例#27
0
        /// <summary>
        /// 
        /// </summary>
        internal bool OnMoving( Point3D oldLocation, BaseCharacter character, BaseMap map )
        {
            EventHandler<CharacterMovingInMapEventArgs> tempBeforeEventArgs = m_EventCharacterMovingInMap;
            if ( tempBeforeEventArgs != null )
            {
                CharacterMovingInMapEventArgs eventArgs = new CharacterMovingInMapEventArgs( oldLocation, character, map );
                tempBeforeEventArgs( this, eventArgs );

                return eventArgs.IsCancel;
            }

            return false;
        }
示例#28
0
 /// <summary>
 /// 初始化构造
 /// </summary>
 /// <param name="baseCreature"></param>
 public UpdatedMapEventArgs( BaseMap baseMap, WorldEntity gameEntity ) :
     base( gameEntity )
 {
     m_OldMap = baseMap;
 }
示例#29
0
 /// <summary>
 /// 
 /// </summary>
 internal void OnLeavedMap( BaseItem item, BaseMap map )
 {
     EventHandler<ItemLeavedMapEventArgs> tempAfterEventArgs = m_EventItemLeavedMap;
     if ( tempAfterEventArgs != null )
     {
         ItemLeavedMapEventArgs eventArgs = new ItemLeavedMapEventArgs( item, map );
         tempAfterEventArgs( this, eventArgs );
     }
 }
示例#30
0
 /// <summary>
 /// 初始化构造
 /// </summary>
 /// <param name="baseCreature"></param>
 public MovingToWorldEventArgs( Point3D location, BaseMap newMap, WorldEntity gameEntity ) :
     base( gameEntity )
 {
     m_NewLocation = location;
     m_NewMap = newMap;
 }
        /// <summary>
        /// 
        /// </summary>
        /// <param name="iGridCellPointX"></param>
        /// <param name="iGridCellPointY"></param>
        /// <param name="map"></param>
        /// <returns></returns>
        private MapSpaceNode GetSubSpaceNode( int iPointXOfGridCell, int iPointYOfGridCell, BaseMap map )
        {
            Debug.Assert( map != null, "PartitionSpaceStrategy.GetSubSpaceNode(...) - map == null error!" );

            if ( iPointXOfGridCell < 0 || iPointYOfGridCell < 0 )
                return null;

            int iGridPointX = (int)( iPointXOfGridCell / MAX_NUMBER_OF_CELLS );
            int iGridPointY = (int)( iPointYOfGridCell / MAX_NUMBER_OF_CELLS );

            if ( iGridPointX >= MAX_NUMBER_OF_GRIDS || iGridPointY >= MAX_NUMBER_OF_GRIDS )
                return null;

            int iCellPointX = (int)( iPointXOfGridCell % MAX_NUMBER_OF_CELLS );
            int iCellPointY = (int)( iPointYOfGridCell % MAX_NUMBER_OF_CELLS );

            return map.SpaceNodes[iGridPointX, iGridPointY, 0].SpaceNodes[iCellPointX, iCellPointY, 0];
        }
示例#32
0
        /// <summary>
        /// 
        /// </summary>
        internal bool OnMoving( Point3D oldLocation, BaseItem item, BaseMap map )
        {
            EventHandler<ItemMovingInMapEventArgs> tempBeforeEventArgs = m_EventItemMovingInMap;
            if ( tempBeforeEventArgs != null )
            {
                ItemMovingInMapEventArgs eventArgs = new ItemMovingInMapEventArgs( oldLocation, item, map );
                tempBeforeEventArgs( this, eventArgs );

                return eventArgs.IsCancel;
            }

            return false;
        }
 /// <summary>
 /// 
 /// </summary>
 internal void OnMovedToWorld( Point3D oldLocation, BaseMap oldMap, WorldEntity gameEntity )
 {
     EventHandler<MovedToWorldEventArgs> tempAfterEventArgs = m_EventMovedToWorld;
     if ( tempAfterEventArgs != null )
     {
         MovedToWorldEventArgs eventArgs = new MovedToWorldEventArgs( oldLocation, oldMap, gameEntity );
         tempAfterEventArgs( this, eventArgs );
     }
 }
示例#34
0
 /// <summary>
 /// 
 /// </summary>
 internal void OnMoved( Point3D oldLocation, BaseItem item, BaseMap map )
 {
     EventHandler<ItemMovedInMapEventArgs> tempAfterEventArgs = m_EventItemMovedInMap;
     if ( tempAfterEventArgs != null )
     {
         ItemMovedInMapEventArgs eventArgs = new ItemMovedInMapEventArgs( oldLocation, item, map );
         tempAfterEventArgs( this, eventArgs );
     }
 }
示例#35
0
        /// <summary>
        /// 
        /// </summary>
        internal bool OnLeavingMap( BaseCharacter character, BaseMap map )
        {
            EventHandler<CharacterLeavingMapEventArgs> tempBeforeEventArgs = m_EventCharacterLeavingMap;
            if ( tempBeforeEventArgs != null )
            {
                CharacterLeavingMapEventArgs eventArgs = new CharacterLeavingMapEventArgs( character, map );
                tempBeforeEventArgs( this, eventArgs );

                return eventArgs.IsCancel;
            }

            return false;
        }
示例#36
0
 /// <summary>
 /// 
 /// </summary>
 internal void OnMoved( Point3D oldLocation, WorldEntity worldEntity, BaseMap map )
 {
     EventHandler<WorldEntityMovedInMapEventArgs> tempAfterEventArgs = m_EventWorldEntityMovedInMap;
     if ( tempAfterEventArgs != null )
     {
         WorldEntityMovedInMapEventArgs eventArgs = new WorldEntityMovedInMapEventArgs( oldLocation, worldEntity, map );
         tempAfterEventArgs( this, eventArgs );
     }
 }
示例#37
0
        /// <summary>
        /// 
        /// </summary>
        internal bool OnEnteringMap( BaseItem item, BaseMap map )
        {
            EventHandler<ItemEnteringMapEventArgs> tempBeforeEventArgs = m_EventItemEnteringMap;
            if ( tempBeforeEventArgs != null )
            {
                ItemEnteringMapEventArgs eventArgs = new ItemEnteringMapEventArgs( item, map );
                tempBeforeEventArgs( this, eventArgs );

                return eventArgs.IsCancel;
            }

            return false;
        }
 /// <summary>
 /// 
 /// </summary>
 internal void OnUpdatedMap( BaseMap map, WorldEntity gameEntity )
 {
     EventHandler<UpdatedMapEventArgs> tempAfterEventArgs = m_EventUpdatedMap;
     if ( tempAfterEventArgs != null )
     {
         UpdatedMapEventArgs eventArgs = new UpdatedMapEventArgs( map, gameEntity );
         tempAfterEventArgs( this, eventArgs );
     }
 }
示例#39
0
            /// <summary>
            /// 
            /// </summary>
            /// <param name="eventArgs"></param>
            internal static MoveToWorldEventArgs InvokeMoveToWorld( Point3D newLocation, BaseMap newMap, WorldEntity entity )
            {
                EventHandler<MoveToWorldEventArgs> tempMoveToWorld = m_MoveToWorld;
                if ( tempMoveToWorld != null )
                {
                    MoveToWorldEventArgs moveToWorldEventArgs = new MoveToWorldEventArgs( newLocation, newMap, entity );
                    if ( moveToWorldEventArgs == null )
                        return null;

                    tempMoveToWorld( entity, moveToWorldEventArgs );

                    return moveToWorldEventArgs;
                }

                return null;
            }
        /// <summary>
        /// 
        /// </summary>
        internal bool OnMovingToWorld( Point3D newLocation, BaseMap newMap, WorldEntity gameEntity )
        {
            EventHandler<MovingToWorldEventArgs> tempBeforeEventArgs = m_EventMovingToWorld;
            if ( tempBeforeEventArgs != null )
            {
                MovingToWorldEventArgs eventArgs = new MovingToWorldEventArgs( newLocation, newMap, gameEntity );
                tempBeforeEventArgs( this, eventArgs );

                return eventArgs.IsCancel;
            }

            return false;
        }
示例#41
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="owner"></param>
 public MapSpaceNode(BaseMap owner)
 {
 }
示例#42
0
 /// <summary>
 /// 初始化构造
 /// </summary>
 /// <param name="baseCreature"></param>
 public UpdatingMapEventArgs( BaseMap baseMap, WorldEntity gameEntity ) :
     base( gameEntity )
 {
     m_NewMap = baseMap;
 }