diff options
author | Wboerenkamps <wrj.boerenkamps@student.avans.nl> | 2025-01-11 11:50:18 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-01-11 11:50:18 +0100 |
commit | b4f5c3aed5c72dfb9ba9352c573691622b31d858 (patch) | |
tree | 7229298f9a377d6b56a1fcb497f3f32095b06b6e /game/menus/shop | |
parent | ba0db2e49ff1b5c3e952c00bbc3f31176397f6b6 (diff) | |
parent | a57aa66f95c85e427b7ae51cadad4e4388d1a802 (diff) |
Merge pull request #132 from lonkaars/max/game2
Bug fixes
Diffstat (limited to 'game/menus/shop')
-rw-r--r-- | game/menus/shop/ShopMenuScene.cpp | 116 |
1 files changed, 113 insertions, 3 deletions
diff --git a/game/menus/shop/ShopMenuScene.cpp b/game/menus/shop/ShopMenuScene.cpp index 641352c..4975a95 100644 --- a/game/menus/shop/ShopMenuScene.cpp +++ b/game/menus/shop/ShopMenuScene.cpp @@ -54,7 +54,8 @@ void ShopMenuScene::load_scene() { .position = {-400, -350}, .script_type = ButtonSubScene::ScriptSelect::MAINMENU, .button_type = ButtonSubScene::ButtonSelect::BACK, - .scale = 0.8 + .scale = 0.8, + .sorting_layer_offset = 1, } ); @@ -67,10 +68,47 @@ void ShopMenuScene::load_scene() { Asset("asset/other_effects/effect_rocketmgshell_TVOS.png"), Sprite::Data { .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, - .size = {0, 100}, + .size = {0, 20}, + .angle_offset = 30, .position_offset = {0, 0}, } ); + shop_item_bullet.add_component<Sprite>( + Asset("asset/other_effects/effect_rocketmgshell_TVOS.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 20}, + .angle_offset = 10, + .position_offset = {-10, -30}, + } + ); + shop_item_bullet.add_component<Sprite>( + Asset("asset/other_effects/effect_rocketmgshell_TVOS.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 20}, + .angle_offset = -10, + .position_offset = {-40, 30}, + } + ); + shop_item_bullet.add_component<Sprite>( + Asset("asset/other_effects/effect_rocketmgshell_TVOS.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 20}, + .angle_offset = 0, + .position_offset = {10, 15}, + } + ); + shop_item_bullet.add_component<Sprite>( + Asset("asset/other_effects/effect_rocketmgshell_TVOS.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 20}, + .angle_offset = -5, + .position_offset = {45, -5}, + } + ); const string BULLETS_STRING = "BULLETS"; size @@ -112,10 +150,82 @@ void ShopMenuScene::load_scene() { Asset("asset/background/aquarium/bubble.png"), Sprite::Data { .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, - .size = {0, 100}, + .size = {0, 10}, .position_offset = {0, 0}, } ); + shop_item_bubble.add_component<Sprite>( + Asset("asset/background/aquarium/bubble.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 10}, + .position_offset = {-50, -20}, + } + ); + shop_item_bubble.add_component<Sprite>( + Asset("asset/background/aquarium/bubble.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 20}, + .position_offset = {45, -40}, + } + ); + shop_item_bubble.add_component<Sprite>( + Asset("asset/background/aquarium/bubble.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 20}, + .position_offset = {-20, 40}, + } + ); + shop_item_bubble.add_component<Sprite>( + Asset("asset/background/aquarium/bubble.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 15}, + .position_offset = {15, -25}, + } + ); + shop_item_bubble.add_component<Sprite>( + Asset("asset/background/aquarium/bubble.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 10}, + .position_offset = {10, 5}, + } + ); + shop_item_bubble.add_component<Sprite>( + Asset("asset/background/aquarium/bubble.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 10}, + .position_offset = {-5, -20}, + } + ); + shop_item_bubble.add_component<Sprite>( + Asset("asset/background/aquarium/bubble.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 20}, + .position_offset = {15, -40}, + } + ); + shop_item_bubble.add_component<Sprite>( + Asset("asset/background/aquarium/bubble.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 20}, + .position_offset = {-20, 10}, + } + ); + shop_item_bubble.add_component<Sprite>( + Asset("asset/background/aquarium/bubble.png"), + Sprite::Data { + .sorting_in_layer = STARTING_SORTING_IN_LAYER + 1, + .size = {0, 15}, + .position_offset = {30, -25}, + } + ); const string BUBBLE_STRING = "BUBBLE"; size |