public MenuButton(string id, Vector2 pos, StatusMenuButton status,bool abstractPos, SpriteFont font, Color normal, Color selected, Event onClick, bool normalSelect = true, PosOnScreen posOnScreen = PosOnScreen.TopLeft, bool isDrawable = true) : this(id, pos, status, abstractPos, () => GameEngine.LangCenter.GetString(id), (isSelect) => GameEngine.LangCenter.GetImage(id, !isSelect),() => GameEngine.Config.ResolutionWidth/1920f , font, normal, selected, onClick, normalSelect,posOnScreen,isDrawable) { }
internal MenuButton(string id, Vector2 pos, StatusMenuButton status, bool abstractPos, NameFunc text, TextureFunc image, RatioFunc ratioFunc, SpriteFont font, Color normal, Color selected, Event onClick, bool normalSelect = true, PosOnScreen posOnScreen = PosOnScreen.TopLeft, bool isDrawable = true) : base(new Rectangle((int)pos.X, (int)pos.Y, 0, 0),posOnScreen,isDrawable) { Id = id; MiddlePos = (abstractPos) ? Position : pos; Status = status; AbstractPos = abstractPos; Text = text; Image = image; Ratio = ratioFunc; Font = font; ColorNormal = normal; ColorSelected = selected; OnClick = onClick; NormalSelect = normalSelect; UpdateRectangles(); }