diff --git a/assets/gui_main_menu.json b/assets/gui_main_menu.json new file mode 100755 index 0000000..9861604 --- /dev/null +++ b/assets/gui_main_menu.json @@ -0,0 +1,23 @@ +{ + "widgets": [{ + "type": "FrameLayout", + "name": "menu_background", + "background": "#00000000", + "width": "match_parent", + "height": "match_parent", + "children": [{ + "type": "FrameLayout", + "name": "stars_plane", + "background": "#00000000", + "width": "wrap_content", + "height": "wrap_content", + "children": [{ + "type": "ImageView", + "name": "galaxy", + "background": "024863276-illustration-spiral-galaxy-vec.png", + "width": 700, + "height": 480 + }] + }] + }] +} \ No newline at end of file diff --git a/assets/ui/024863276-illustration-spiral-galaxy-vec.png b/assets/ui/024863276-illustration-spiral-galaxy-vec.png new file mode 100755 index 0000000..ed6b720 Binary files /dev/null and b/assets/ui/024863276-illustration-spiral-galaxy-vec.png differ diff --git a/game/main_code.cpp b/game/main_code.cpp index 1e30b15..4aee09c 100644 --- a/game/main_code.cpp +++ b/game/main_code.cpp @@ -116,7 +116,7 @@ void TMyApplication::InnerInit() ResourceManager->FontManager.AddFont("arial32", "arial32.png", "arial32.txt"); ResourceManager->FontManager.AddFont("lucon12", "lucon12.png", "lucon12.txt"); ResourceManager->FontManager.PushFont("lucon12"); - ResourceManager->newGuiManager.LoadFromConfig("gui_alex.json"); + ResourceManager->newGuiManager.LoadFromConfig("gui_main_menu.json"); SetButtonsAction(); // ------- UI ------- } @@ -154,12 +154,6 @@ void TMyApplication::InnerDeinit() } -void TMyApplication::InnerOnTapDown(Vector2f p) -{ - //-OnTapDownSignal(Vector2f(p.v[0], p.v[1])); - OnTapDownSignal(Vector2f(p(0), p(1))); -} - void TMyApplication::InnerOnTapUp(Vector2f p) { OnTapUpSignal(Vector2f(p(0), p(1))); diff --git a/game/main_code.h b/game/main_code.h index 89faaed..f0aa39f 100644 --- a/game/main_code.h +++ b/game/main_code.h @@ -161,7 +161,11 @@ public: void LoadResources(); - virtual void InnerOnTapDown(Vector2f p); + virtual void InnerOnTapDown(Vector2f p) + { + //-OnTapDownSignal(Vector2f(p.v[0], p.v[1])); + OnTapDownSignal(Vector2f(p(0), p(1))); + } virtual void InnerOnTapUp(Vector2f p); diff --git a/windows/DoubleHitBalls-win/DoubleHitBalls-win/DoubleHitBalls-win.vcxproj b/windows/DoubleHitBalls-win/DoubleHitBalls-win/DoubleHitBalls-win.vcxproj index 065dbb0..d6eba64 100755 --- a/windows/DoubleHitBalls-win/DoubleHitBalls-win/DoubleHitBalls-win.vcxproj +++ b/windows/DoubleHitBalls-win/DoubleHitBalls-win/DoubleHitBalls-win.vcxproj @@ -170,6 +170,8 @@ + + @@ -179,6 +181,8 @@ + + diff --git a/windows/DoubleHitBalls-win/DoubleHitBalls-win/DoubleHitBalls-win.vcxproj.filters b/windows/DoubleHitBalls-win/DoubleHitBalls-win/DoubleHitBalls-win.vcxproj.filters index b4ac7b9..5a33d79 100755 --- a/windows/DoubleHitBalls-win/DoubleHitBalls-win/DoubleHitBalls-win.vcxproj.filters +++ b/windows/DoubleHitBalls-win/DoubleHitBalls-win/DoubleHitBalls-win.vcxproj.filters @@ -33,6 +33,12 @@ Файлы исходного кода + + Файлы исходного кода + + + Файлы исходного кода + @@ -56,5 +62,11 @@ Заголовочные файлы + + Заголовочные файлы + + + Заголовочные файлы + \ No newline at end of file diff --git a/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy.cpp b/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy.cpp new file mode 100755 index 0000000..ba17e04 --- /dev/null +++ b/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy.cpp @@ -0,0 +1,2 @@ +#include "galaxy.h" + diff --git a/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy.h b/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy.h new file mode 100755 index 0000000..930f45d --- /dev/null +++ b/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy.h @@ -0,0 +1,38 @@ +#ifndef GALAXY_H +#define GALAXY_H + +#include "galaxy_objects.h" + +#include "include/Engine.h" +#include + + +class GalaxyMenu { +public: + + // ======== All objects ========= + std::vector Stars; + // ======== All objects ========= + + + // ======== Main Methods ======== + void InitGalaxy(); + void DrawGalaxy(); + void UpdateGalaxy(); + // ======== Main Methods ======== + + void InteractWithGalaxy(); // Prototype for mouse/tap events + + + // ::::::::::: + float GetGalaxyPosition(); + // ::::::::::: + +private: + + // Params + //Vector2f selfPosition; + +}; + +#endif diff --git a/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy_objects.cpp b/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy_objects.cpp new file mode 100755 index 0000000..e69de29 diff --git a/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy_objects.h b/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy_objects.h new file mode 100755 index 0000000..c5c0c59 --- /dev/null +++ b/windows/DoubleHitBalls-win/DoubleHitBalls-win/galaxy_objects.h @@ -0,0 +1,16 @@ +#ifndef GALAXY_OBJECTS_H +#define GALAXY_OBJECTS_H + +class StarObject { +public: + + + +private: + + + +}; + + +#endif \ No newline at end of file