Ejemplo n.º 1
0
 protected MapElement(IRes myRes, Map map, ElementMovements movements,
                      EventHandler @event, bool isBackgroundElement = false) : base(myRes)
 {
     Movements      = movements;
     MovementWorker = @event;
     Map            = map;
     FFramable      =
         Movements == ElementMovements.NoMovements;
     IsBackgroundElement = isBackgroundElement;
     InitializeComponent();
 }
Ejemplo n.º 2
0
 //---------------------------------------------
 #region Constructors Region
 /// <summary>
 /// create a new instance of the <see cref="ChatBackgroundLabel"/>,
 /// which will provide you the chat frame, chat icon
 /// and chat flash.
 /// </summary>
 /// <param name="myRes"></param>
 /// <param name="client"></param>
 public ChatBackgroundLabel(IRes myRes, GameClient client, ChatLabelControl backLabel) :
     base(myRes, LabelControlSpecies.ChatBackGroundLabel)
 {
     GameClient = client;
     BackLabel  = backLabel;
     // set the default showing channel to the cross,
     // so when the user opens his chat channel, he should see the
     // cross channel's chats.
     CurrentShowingChannel = ChatChannels.Cross_Chat;
     Movements             = ElementMovements.VerticalMovements;
     InitializeComponent();
 }
Ejemplo n.º 3
0
        public static MapElement GetMapElement(IRes res, GameIcon elementIcon, Map theMap,
                                               bool clickedImage, ElementMovements movements,
                                               EventHandler @event, bool isBackground = false)
        {
            MapElement element = new MapElement(res, theMap, elementIcon, movements, @event, isBackground)
            {
                DontUseClickedImage = !clickedImage,
            };

            element.SetPictureName(element.ElementInMapType.ToString());
            element.SetPicture();
            element.SetSrcRectangle();
            return(element);
        }
Ejemplo n.º 4
0
 public FlatElement(IRes myRes, ElementMovements movements, bool isBarren = false) :
     base(myRes, isBarren)
 {
     Movements = movements;
     InitializeComponent();
 }