Debug map toggle configuration paramater added. Added in tiled and scaled versions of interface 9-patch patterning.
Co-authored-by: sigonasr2 <sigonasr2@gmail.com>
This commit is contained in:
@@ -16,12 +16,14 @@ class Menu{
|
||||
std::map<int/*Y*/,std::vector<MenuComponent*>>buttons; //Buttons are stored in rows followed by their column order.
|
||||
vi2d selection={-1,-1};
|
||||
vf2d size; //Size in tiles (24x24), every menu will be tile-based
|
||||
bool scaled=false; //Whether or not the patch border is supposed to be scaled or tiled.
|
||||
public:
|
||||
Menu();
|
||||
Menu(vf2d size);
|
||||
void AddComponent(MenuComponent*button);
|
||||
void Update(Crawler*game);
|
||||
void Draw(Crawler*game);
|
||||
void SetScaledPatchBorder(bool scaled);
|
||||
static void InitializeMenus();
|
||||
static void OpenMenu(MenuType menu);
|
||||
static std::vector<Menu*>stack;
|
||||
@@ -29,7 +31,11 @@ private:
|
||||
void MenuSelect(Crawler*game);
|
||||
static const Menu InitializeTestMenu();
|
||||
static const Menu InitializeTestSubMenu();
|
||||
//X (0-3), Y (0-2) for specific 9-patch tile (tiled version).
|
||||
static Renderable&GetPatchPart(int x,int y);
|
||||
|
||||
void KeyboardButtonNavigation(Crawler*game,vf2d menuPos);
|
||||
void DrawScaledWindow(Crawler*game,vf2d menuPos);
|
||||
void DrawTiledWindow(Crawler*game,vf2d menuPos);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user