From 01a8a2411f76078ce66caef8095fecc50d141ce9 Mon Sep 17 00:00:00 2001 From: Michael Moore <5983927+MichaelMakesGames@users.noreply.github.com> Date: Wed, 15 May 2024 10:48:39 -0500 Subject: [PATCH] Rewrite the mod to no longer use (now nonexistent) in-game browser (#150) Also add a link to wiki to the dashboard Some minor style tweaks to the dashboard --- .gitignore | 2 +- mod/stellaris_dashboard/descriptor.mod | 2 +- .../gfx/interface/icons/dashboard_icon.dds | Bin 0 -> 7472 bytes mod/stellaris_dashboard/interface/browser.gui | 148 ---- .../interface/main_bottom.gui | 774 ++++++++++++++++++ .../interface/stellaris_dashboard.gfx | 8 + .../interface/timeline_button.gfx | 63 -- .../stellaris_dashboard_l_braz_por.yml | 2 + .../stellaris_dashboard_l_english.yml | 2 + .../stellaris_dashboard_l_french.yml | 2 + .../stellaris_dashboard_l_german.yml | 2 + .../stellaris_dashboard_l_japanese.yml | 2 + .../stellaris_dashboard_l_korean.yml | 2 + .../stellaris_dashboard_l_polish.yml | 2 + .../stellaris_dashboard_l_russian.yml | 2 + .../stellaris_dashboard_l_simp_chinese.yml | 2 + .../stellaris_dashboard_l_spanish.yml | 2 + .../dashboard_app/assets/style.css | 8 +- .../dashboard_app/graph_ledger.py | 35 +- .../dashboard_app/templates/history_page.html | 5 +- .../dashboard_app/templates/layout.html | 2 + stellarisdashboard/dashboard_app/utils.py | 2 +- 22 files changed, 843 insertions(+), 226 deletions(-) create mode 100644 mod/stellaris_dashboard/gfx/interface/icons/dashboard_icon.dds delete mode 100644 mod/stellaris_dashboard/interface/browser.gui create mode 100644 mod/stellaris_dashboard/interface/main_bottom.gui create mode 100644 mod/stellaris_dashboard/interface/stellaris_dashboard.gfx delete mode 100644 mod/stellaris_dashboard/interface/timeline_button.gfx create mode 100644 mod/stellaris_dashboard/localisation/stellaris_dashboard_l_braz_por.yml create mode 100644 mod/stellaris_dashboard/localisation/stellaris_dashboard_l_english.yml create mode 100644 mod/stellaris_dashboard/localisation/stellaris_dashboard_l_french.yml create mode 100644 mod/stellaris_dashboard/localisation/stellaris_dashboard_l_german.yml create mode 100644 mod/stellaris_dashboard/localisation/stellaris_dashboard_l_japanese.yml create mode 100644 mod/stellaris_dashboard/localisation/stellaris_dashboard_l_korean.yml create mode 100644 mod/stellaris_dashboard/localisation/stellaris_dashboard_l_polish.yml create mode 100644 mod/stellaris_dashboard/localisation/stellaris_dashboard_l_russian.yml create mode 100644 mod/stellaris_dashboard/localisation/stellaris_dashboard_l_simp_chinese.yml create mode 100644 mod/stellaris_dashboard/localisation/stellaris_dashboard_l_spanish.yml diff --git a/.gitignore b/.gitignore index 882afe2..958b68f 100644 --- a/.gitignore +++ b/.gitignore @@ -8,7 +8,7 @@ data **/*.json **/.pytest* -*.yml +**/config.yml # Byte-compiled / optimized / DLL files __pycache__/ diff --git a/mod/stellaris_dashboard/descriptor.mod b/mod/stellaris_dashboard/descriptor.mod index e76389d..beba90c 100644 --- a/mod/stellaris_dashboard/descriptor.mod +++ b/mod/stellaris_dashboard/descriptor.mod @@ -1,5 +1,5 @@ name="Stellaris Dashboard" -version="v4.4" +version="v6.2" tags={ "Utilities" "Gameplay" diff --git a/mod/stellaris_dashboard/gfx/interface/icons/dashboard_icon.dds b/mod/stellaris_dashboard/gfx/interface/icons/dashboard_icon.dds new file mode 100644 index 0000000000000000000000000000000000000000..443496eb2031897ed781688438f373f821d6a7ba GIT binary patch literal 7472 zcmZ>930A0KU|`@EU|>)J(q=$>1BgL@5s2MAeFJn|T!LdbnZaWC2nC>|BUAy1&A{*< zh9DfE9q8cy|Nji5cr*+~)4*sN7)=ACX#igu$gD79AQNu~>ids`x8t*i-g0F62^1Ei z{u+Sx1Ge~rr5OTpLoU8X{WY}84W#(OnbwAQxq;y?q&$Zq2MdqEKqI*mTRn#1b|m!} za)ZG?FgGB%b42?KDLjT%d<`LgVT3zU+Qg6>_1D1mH-K@25htVZHK^Mgqwxhyv!mt4 bz?K`Z@E@f|<6$%njHZFnG%%V5=#>Tl!X~*6 literal 0 HcmV?d00001 diff --git a/mod/stellaris_dashboard/interface/browser.gui b/mod/stellaris_dashboard/interface/browser.gui deleted file mode 100644 index 33842b6..0000000 --- a/mod/stellaris_dashboard/interface/browser.gui +++ /dev/null @@ -1,148 +0,0 @@ -guiTypes = { - - containerWindowType = { - name = "browser_window" - position = { x=0 y=0 } - size = { width = 1220 height = 704 } - moveable = yes - orientation = center - origo = center - - background = { - name = "Background" - spriteType = "GFX_tile_large_bg" - } - - iconType = { - name = "hex_bg" - spriteType = "GFX_hex_bg" - position = { x = -10 y = -15 } - alwaysTransparent = yes - } - - iconType = { - name = "empire_header_line" - quadTextureSprite = "GFX_line_long" - position = { x = 6 y = 22 } - } - - instantTextBoxType={ - name = "header" - font = "malgun_goth_24" - text = "INTERNET_BROWSER" - position = { x = 19 y = 5 } - maxWidth = 800 - maxHeight = 40 - fixedSize = yes - format = left - alwaysTransparent = yes - } - - - browserType = { - name = "browser" - spriteType = "GFX_dummy_browser" - position = { x = 15 y = 90 } - size = { x = 1190 y = 600 } - } - - buttonType = - { - name = "back" - quadTextureSprite = "GFX_button_back" - position = { x = 10 y = 40 } - } - - buttonType = - { - name = "forward" - quadTextureSprite = "GFX_fleet_order_button_move" - position = { x = 45 y = 40 } - } - - buttonType = - { - name = "reload" - quadTextureSprite = "GFX_button_update" - position = { x = 80 y = 40 } - } - - buttonType = - { - name = "forum" - quadTextureSprite = "GFX_button_pdx" - position = { x = 150 y = 40 } - web_link="https://forum.paradoxplaza.com/forum/index.php?forums/stellaris.900/" - } - - buttonType = - { - name = "home" - quadTextureSprite = "GFX_fleet_order_button_return" - position = { x = 185 y = 40 } - } - - buttonType = - { - name = "dashboard_index" - quadTextureSprite = "GFX_button_timeline_index" - position = { x = -280 y = 26 } - Orientation = UPPER_RIGHT - web_link="http://127.0.0.1:28053/checkversion/v4.4" - shortcut = "J" - } - buttonType = - { - name = "dashboard_graphs" - quadTextureSprite = "GFX_button_timeline_graphs" - position = { x = -220 y = 17 } - Orientation = UPPER_RIGHT - web_link="http://127.0.0.1:28053/timeline" - shortcut = "K" - } - buttonType = - { - name = "dashboard_event_log" - quadTextureSprite = "GFX_button_event_history" - position = { x = -150 y = 21 } - Orientation = UPPER_RIGHT - web_link="http://127.0.0.1:28053/checkversion/v4.4/history" - shortcut = "L" - } - - containerWindowType = { - name = "setting_bg_box" - size = { width = 1206 height = 616 } - position = { x = 7 y = 82 } - clipping = no - - background = { - name = "setting_bg_frame" - spriteType = "GFX_clean_frame_area" - alwaystransparent = yes - } - } - - buttonType = - { - name = "close" - quadTextureSprite = "GFX_close" - position = { x = -45 y = 17 } - Orientation = UPPER_RIGHT - clicksound = back_click - shortcut = "ESCAPE" - } - containerWindowType = { - name = "setting_bg_box" - size = { width = 1206 height = 616 } - position = { x = 7 y = 82 } - clipping = no - - background = { - name = "setting_bg_frame" - spriteType = "GFX_clean_frame_area" - alwaystransparent = yes - } - } - } -} \ No newline at end of file diff --git a/mod/stellaris_dashboard/interface/main_bottom.gui b/mod/stellaris_dashboard/interface/main_bottom.gui new file mode 100644 index 0000000..eba27ff --- /dev/null +++ b/mod/stellaris_dashboard/interface/main_bottom.gui @@ -0,0 +1,774 @@ +guiTypes = { + + positionType = { + name = "control_groups_min_from_center" + position = { x = 246 y = 0 } + } + + #Adjusts offset for tooltips for all elements at the bottom of the screen + @tt_offset_y = 0 + + containerWindowType = { + name = "maingui_bottombar" + size = { width = 100% height = 100% } + + ## Control Groups + overlappingElementsBoxType = { + name = "control_groups" + position = { x = 4 y = -46 } + size = { x=700 y= 13 } + spacing = 2 + Orientation = "LOWER_LEFT" + format = left + } + + + ### LEAVE SYSTEM WINDOW + containerWindowType = { + name = "leave_system_window" + size = { width = 166 height = 114 } + hide_position = { x = 0 y = 0 } + show_position = { x = 0 y = -95 } + animation_type = decelerated + animation_time = 500.5 + orientation = center_down + origo = center_up + + ### BACKGROUND FOR AVOIDED SYSTEMS + iconType = { + name = "starsystem_panel_avoid_bg" + spriteType = "GFX_starsystem_panel_avoid" + position = { x = 0 y = 62 } + alwaysTransparent = yes + orientation = center_up + centerPosition = yes + } + + iconType = { + name = "starsystem_panel" + spriteType = "GFX_starsystem_panel" + position = { x = 0 y = 62 } + alwaysTransparent = yes + orientation = center_up + centerPosition = yes + } + + iconType = { + name = "paused_bar_bg" + spriteType = "GFX_paused_bar_glow" + position = { x = 0 y = 44 } + alwaysTransparent = yes + orientation = center_up + centerPosition = yes + } + + ### BACKGROUND FOR CLAIMS BUTTON VISIBLE WHEN ENABLED + iconType = { + name = "claims_button_bg" + spriteType = "GFX_starsystem_panel_left" + position = { x = -205 y = 38 } + } + + ### BACKGROUND FOR AVOID SYSTEM BUTTON VISIBLE WHEN ENABLED + iconType = { + name = "restricted_button_bg" + spriteType = "GFX_starsystem_panel_right" + position = { x = -112 y = 46 } + } + + buttonType = { + name = "flag_button" + quadTextureSprite = "GFX_empire_flag_64" + position = { x= -257 y = 27 } + orientation = center_up + clicksound = interface + oversound = no_sound + } + + iconType = { + name = "map_button_bg" + orientation = center_up + position = { x = 199 y = 38 } + spriteType = "GFX_bottombar_button_bg" + alwaystransparent = yes + } + + buttonType = { + name = "button" + quadTextureSprite = "GFX_open_galaxy_map" + orientation = center_up + position = { x = 194 y = 33 } + #pdx_tooltip = "" # Set in code + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + clicksound = ui_galaxy_map_open + oversound = mouse_over + } + + instantTextBoxType={ + name = "paused" + font = "large_title_font" + position = { x = -200 y = 1 } + text = "GAME_SPEED_0" + maxWidth = 400 + maxHeight = 50 + format = center + orientation = center_up + alwaystransparent = yes + text_color_code = "H" + } + + instantTextBoxType={ + name = "system_name" + font = "large_title_font_28" + position = { x = -195 y = 39 } + text = "Systemname" + maxWidth = 390 + maxHeight = 50 + format = center + orientation = center_up + alwaystransparent = yes + fixedsize = yes + #text_color_code = "E" + } + + instantTextBoxType={ + name = "system_type" + font = "cg_16b" + position = { x = -195 y = 66 } + text = "Mining System" + maxWidth = 390 + maxHeight = 50 + format = center + orientation = center_up + alwaystransparent = yes + fixedsize = yes + text_color_code = "E" + } + + buttonType = { + name = "system_rename_button" + spriteType = "GFX_invisible" + position = { x = -163 y = 40 } + size = { x = 330 y = 45 } + orientation = center_up + pdx_tooltip = "RENAME_SYSTEM_TOOLTIP" + oversound = no_sound + } + + iconType = { + name = "environmental_effects_icon" + spriteType = "GFX_system_hazards_icon" + position = { x = 252 y = 49 } + } + + buttonType = { + name = "claim_system_button" + quadTextureSprite = "GFX_claim_system_icon" + position = { x = -204 y = 43 } + } + + buttonType = { + name = "restricted_system_button" + quadTextureSprite = "GFX_restricted_system_icon" + position = { x = -112 y = 43 } + } + } + + ### LEAVE GALAXY WINDOW + containerWindowType = { + name = "leave_galaxy_window" + + size = { width = 166 height = 114 } + hide_position = { x = 0 y = 0 } + show_position = { x = 0 y = -95 } + animation_type = decelerated + animation_time = 500.5 + orientation = center_down + origo = center_up + + # iconType = { + # name = "system_button_panel" + # spriteType = "GFX_system_button_panel" + # position = { x = -130 y = 35 } + # alwaysTransparent = yes + # } + + iconType = { + name = "starsystem_panel" + spriteType = "GFX_starsystem_panel" + position = { x = 0 y = 62 } + alwaysTransparent = yes + orientation = center_up + centerPosition = yes + } + + iconType = { + name = "paused_bar_bg" + spriteType = "GFX_paused_bar_glow" + position = { x = 0 y = 44 } + alwaysTransparent = yes + orientation = center_up + centerPosition = yes + } + + buttonType = { + name = "flag_button_galaxy_view" + quadTextureSprite = "GFX_empire_flag_64" + position = { x= -257 y = 27 } + orientation = center_up + clicksound = interface + oversound = no_sound + } + + iconType = { + name = "map_button_bg" + orientation = center_up + position = { x = 199 y = 38 } + spriteType = "GFX_bottombar_button_bg" + alwaystransparent = yes + } + + buttonType = { + name = "change_camera_mode_button" + quadTextureSprite = "GFX_open_system_map" + position = { x= 194 y = 33 } + orientation = center_up + #text = "LEAVE_GALAXY" + buttonFont = "cg_16b" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + clicksound = ui_galaxy_map_close + oversound = mouse_over + } + + instantTextBoxType={ + name = "paused" + font = "large_title_font" + position = { x = -127 y = 1 } + text = "GAME_SPEED_0" + maxWidth = 400 + maxHeight = 50 + format = center + alwaystransparent = yes + text_color_code = "H" + } + + instantTextBoxType={ + name = "empire_name" + font = "large_title_font_28" + position = { x = -195 y = 39 } + maxWidth = 390 + maxHeight = 50 + format = center + orientation = center_up + alwaystransparent = yes + fixedsize = yes + } + + instantTextBoxType={ + name = "empire_type" + font = "cg_16b" + position = { x = -195 y = 66 } + maxWidth = 390 + maxHeight = 50 + format = center + orientation = center_up + alwaystransparent = yes + fixedsize = yes + text_color_code = "E" + } + + } + + ## Claims Management + containerWindowType = { + name = "claims_management" + + size = { width = 166 height = 114 } + position = { x = -83 y = 0 } + hide_position = { x = -83 y = 20 } + show_position = { x = -83 y = -97 } + animation_type = decelerated + animation_time = 500.5 + + orientation = center_down + + instantTextBoxType={ + name = "status" + font = "malgun_goth_24" + position = { x = -60 y = -10 } + maxWidth = 250 + maxHeight = 16 + alwaysTransparent = yes + format = center + text = "CLAIMS_MANAGEMENT_MODE" + } + + iconType = { + name = "system_button_panel" + spriteType = "GFX_system_button_panel" + position = { x = -130 y = 45 } + alwaysTransparent = yes + } + + buttonType = { + name = "close" + quadTextureSprite = "GFX_standard_button_142_34_button" + position = { x = -14 y = 42 } + text = "CLOSE" + buttonFont = "cg_16b" + pdx_tooltip = "TOOLTIP_CLOSE_CLAIMS_MANAGEMENT" + } + } + + ## Trade Routes Management + containerWindowType = { + name = "trade_routes_management" + size = { width = 166 height = 114 } + position = { x = -83 y = 0 } + hide_position = { x = -83 y = 20 } + show_position = { x = -83 y = -97 } + animation_type = decelerated + animation_time = 500.5 + + orientation = center_down + + instantTextBoxType={ + name = "status" + font = "malgun_goth_24" + position = { x = -60 y = -10 } + maxWidth = 250 + maxHeight = 16 + alwaysTransparent = yes + format = center + text = "TRADE_ROUTES_MANAGEMENT_MODE" + } + + iconType = { + name = "system_button_panel" + spriteType = "GFX_system_button_panel" + position = { x = -130 y = 45 } + alwaysTransparent = yes + } + + buttonType = { + name = "close" + quadTextureSprite = "GFX_standard_button_142_34_button" + position = { x = -14 y = 42 } + text = "CLOSE" + buttonFont = "cg_16b" + pdx_tooltip = "TOOLTIP_CLOSE_TRADE_ROUTES_MANAGEMENT_MODE" + } + } + + # Map Modes + containerWindowType = { + name = "mapmodes" + size = { width = 240 height = 100 } + position = { x = -277 y = -136 } + orientation = lower_right + #verticalScrollBar = "right_vertical_slider" + + #background = { + # name = "background" + # spriteType = "GFX_tiles_frame" + #} + + gridBoxType = { + name = "map_modes" + slotSize = { width = 34 height = 34 } + max_slots_horizontal = 12 + format = "LOWER_LEFT" + orientation = "LOWER_LEFT" + } + } + + # Lower right toolbar + containerWindowType = { + name = "toolbar" + position = { x = -379 y = -36 } + size = { width = 379 height = 36 } + orientation = lower_right + clipping = no + + background = { + name = "bg" + quadTextureSprite = "GFX_topbar_background" + position = { x = 0 y = 0 } + } + + iconType = { + name = "bottombar_details" + spriteType = "GFX_bottombar_details" + position = { x= 0 y = -5 } + } + + buttonType = { + name = "button_topbar_menu" + quadTextureSprite = "GFX_button_60_29" + position = { x= -89 y = -45 } + shortcut = "ESCAPE" + pdx_tooltip = "TOPBAR_MENU" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + orientation = lower_right + clicksound = confirm_click + } + + iconType = { + name ="main_menu_icon" + spriteType = "GFX_topbar_menu_button" + position = { x= -74 y = -33 } + orientation = lower_right + alwaystransparent = yes + } + + buttonType = { + name = "button_topbar_chat" + quadTextureSprite = "GFX_button_60_29" + position = { x = -221 y = -45 } + orientation = lower_right + shortcut = "l" + } + + iconType = { + name = "chat_icon" + spriteType = "GFX_chat_icon" + position = { x = -206 y = -35 } + orientation = lower_right + alwaystransparent = yes + } + + # STELLARIS DASHBOARD OVERWRITES + buttonType = { + name = "button_topbar_help" + quadTextureSprite = "GFX_button_60_29" + # position = { x = -155 y = -45 } + position = { x = -155 y = 100 } + orientation = lower_right + # shortcut="alt+b" + } + + buttonType = { + name = "button_topbar_help_menu" + quadTextureSprite = "GFX_button_60_29" + # position = { x = -155 y = -45 } + position = { x = -155 y = 100 } + orientation = lower_right + } + + iconType = { + name = "help_icon" + spriteType = "GFX_help_icon" + # position = { x = -140 y = -35 } + position = { x = -140 y = 100 } + orientation = lower_right + alwaystransparent = yes + } + + # STELLARIS DASHBOARD ADDITIONS + buttonType = { + name = "dashboard" + quadTextureSprite = "GFX_button_60_29" + position = { x = -155 y = -45 } + orientation = lower_right + pdx_tooltip = "STELLARIS_DASHBOARD_TOOLTIP" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + web_link="http://127.0.0.1:28053/checkversion/v6.2" + } + + iconType = { + name = "dashboard_icon" + spriteType = "GFX_dashboard_icon" + position = { x = -140 y = -35 } + orientation = lower_right + alwaystransparent = yes + } + # END STELLARIS DASHBOARD + + #containerWindowType = { + # name = "social_view_interface_window" + # position = { x= -221 y = -45 } + # size = { width=256 height=256 } + # orientation = lower_right + + # buttonType = { + # name = "toggle_button" + # quadTextureSprite = "GFX_button_60_29" + # position = { x= 0 y = 0 } + # pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + # pdx_tooltip_anchor_orientation = lower_left + # } + + # iconType = { + # name = "button_toggle_socialview_icon" + # spriteType = "GFX_socialview_icon" + # position = { x= 15 y = 10 } + # alwaystransparent = yes + # } + + # instantTextBoxType={ + # name = "friends_online" + # font = "cg_16b" + # position = { x= 36 y= 18 } + # text = "0" + # maxWidth = 30 + # maxHeight = 16 + # alwaysTransparent = yes + # format = center + # } + + # iconType = { + # name = "new_message" + # position = { x = 60 y = 8 } + # spriteType = "GFX_new_message_icon" + # pdx_tooltip = "SOCIAL_NEW_MESSAGE" + # } + # + # iconType = { + # name = "new_friend" + # position = { x = 60 y = 19 } + # spriteType = "GFX_new_friend_icon" + # pdx_tooltip = "SOCIAL_NEW_FRIEND" + # } + #} + + buttonType = { + name = "toggle_gotobox" + quadTextureSprite = "GFX_button_60_29" + position = { x= -287 y = -45 } + shortCut = "f" + pdx_tooltip = "GOTOBOX_HEADER" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + orientation = lower_right + clicksound = confirm_click + } + + iconType = { + name = "toggle_gotobox_icon" + spriteType = "GFX_search_icon" + position = { x= -271 y = -35 } + orientation = lower_right + alwaystransparent = yes + } + + buttonType = { + name = "home_button" + quadTextureSprite = "GFX_button_60_29" + position = { x= -353 y = -45 } + shortCut = "HOME" + pdx_tooltip = "GOTO_HOME" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + orientation = lower_right + shortCut = "BACKSPACE" + } + + iconType = { + name = "home_icon" + spriteType = "GFX_home_icon" + position = { x= -338 y = -33 } + orientation = lower_right + alwaystransparent = yes + } + + ## Filters + + iconType = { + name = "toggle_mapmode_icon_details" + spriteType = "GFX_mapmode" + frame = 9 + position = { x = -374 y = -33 } + orientation = "LOWER_RIGHT" + alwaystransparent = yes + } + + buttonType = { + name = "toggle_mapmode_details" + quadTextureSprite = "GFX_button_29_animated_survey" + position = { x= -386 y = -45 } + pdx_tooltip = "TOGGLE_MAPMODE_DETAILS_INFO" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + orientation = lower_right + } + + iconType = { + name = "toggle_mapmode_icon_sectors" + spriteType = "GFX_map_mode_sectors" + position = { x = -380 y = -70 } + orientation = "LOWER_RIGHT" + alwaystransparent = yes + } + + buttonType = { + name = "toggle_mapmode_sectors" + quadTextureSprite = "GFX_button_29_animated" + position = { x= -391 y = -82 } + pdx_tooltip = "TOGGLE_MAPMODE_SECTORS_INFO" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + orientation = lower_right + } + + iconType = { + name = "toggle_mapmode_icon_hyperlanes" + spriteType = "GFX_map_mode_hyperlanes" + position = { x = -346 y = -70 } + orientation = "LOWER_RIGHT" + alwaystransparent = yes + } + + buttonType = { + name = "toggle_mapmode_hyperlanes" + quadTextureSprite = "GFX_button_29_animated" + position = { x= -358 y = -82 } + pdx_tooltip = "TOGGLE_MAPMODE_HYPERLANES_INFO" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + orientation = lower_right + } + + iconType = { + name = "toggle_mapmode_icon_trade_routes" + spriteType = "GFX_map_mode_trade_routes" + position = { x = -346 y = -103 } + orientation = "LOWER_RIGHT" + alwaystransparent = yes + } + + buttonType = { + name = "toggle_mapmode_trade_routes" + quadTextureSprite = "GFX_button_29_animated" + position = { x= -358 y = -115 } + pdx_tooltip = "TOGGLE_MAPMODE_TRADE_ROUTES_INFO" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + orientation = lower_right + } + + iconType = { + name = "toggle_mapmode_icon_unions" + spriteType = "GFX_map_mode_unions" + position = { x = -313 y = -70 } + orientation = "LOWER_RIGHT" + alwaystransparent = yes + } + + buttonType = { + name = "toggle_mapmode_unions" + quadTextureSprite = "GFX_button_29_animated" + position = { x= -325 y = -82 } + pdx_tooltip = "TOGGLE_MAPMODE_UNIONS_INFO" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + orientation = lower_right + } + + iconType = { + name = "toggle_mapmode_icon_players" + spriteType = "GFX_map_mode_players" + position = { x = -379 y = -103 } + orientation = "LOWER_RIGHT" + alwaystransparent = yes + } + + buttonType = { + name = "toggle_mapmode_players" + quadTextureSprite = "GFX_button_29_animated" + position = { x = -391 y = -115 } + pdx_tooltip = "TOGGLE_MAPMODE_PLAYERS_INFO" + pdx_tooltip_anchor_offset = { x= 0 y = @tt_offset_y } + pdx_tooltip_anchor_orientation = lower_left + orientation = lower_right + } + + ## Error Log + + buttonType = { + name = "error_log_button" + quadTextureSprite = "GFX_error_log_button" + position = { x= -110 y = -68 } + text = "ERROR" + buttonFont = "cg_16b" + Orientation = "LOWER_RIGHT" + oversound = no_sound + } + } + } + + containerWindowType = { + name = "control_group_window" + size = { width=62 height=47 } + + buttonType = { + name ="background" + quadTextureSprite = "GFX_control_group_window_bg" + position = { x= 0 y = 10 } + clicksound = interface + } + + iconType = { + name ="progress" + spriteType = "GFX_control_group_progress" + position = { x= 0 y = 1 } + alwaysTransparent = yes + } + + iconType = { + name ="in_combat_flash" + spriteType = "GFX_control_group_in_combat_flash" + position = { x= -4 y = 3 } + alwaysTransparent = yes + } + + iconType = { + name ="icon" + spriteType = "GFX_control_group_strip" + position = { x= 22 y = 15 } + alwaysTransparent = yes + } + + instantTextBoxType={ + name = "info" + font = "cg_16b" + position = { x= 43 y= 25 } + maxWidth = 31 + maxHeight = 16 + alwaysTransparent = yes + format = left + } + + instantTextBoxType={ + name = "number" + font = "cg_16b" + position = { x= 02 y= 18 } + maxWidth = 19 + maxHeight = 16 + alwaysTransparent = yes + format = center + } + } +#map mode neighbours + containerWindowType = { + name = "main_gui_map_mode_entry" + position = { x= 0 y = 0 } + size = { width=32 height=32 } + + buttonType = + { + name = "button" + quadTextureSprite = "GFX_button_29_animated" + position = { x = -12 y = -12 } + clicksound = "ui_click_map_mode" + } + iconType = { + name = "icon" + spriteType = "GFX_map_mode_neighbours" + alwaysTransparent = yes + } + } +} diff --git a/mod/stellaris_dashboard/interface/stellaris_dashboard.gfx b/mod/stellaris_dashboard/interface/stellaris_dashboard.gfx new file mode 100644 index 0000000..5e733f5 --- /dev/null +++ b/mod/stellaris_dashboard/interface/stellaris_dashboard.gfx @@ -0,0 +1,8 @@ +spriteTypes = { + spriteType = { + name = "GFX_dashboard_icon" + texturefile = "gfx/interface/icons/dashboard_icon.dds" + } +} + + diff --git a/mod/stellaris_dashboard/interface/timeline_button.gfx b/mod/stellaris_dashboard/interface/timeline_button.gfx deleted file mode 100644 index 24bb17c..0000000 --- a/mod/stellaris_dashboard/interface/timeline_button.gfx +++ /dev/null @@ -1,63 +0,0 @@ -spriteTypes = { - spriteType = { - name = "GFX_button_timeline_index" - texturefile = "gfx/interface/buttons/open_galaxy_map.dds" - effectFile = "gfx/FX/buttonstate_onlydisable.lua" - noOfFrames = 3 - animation = { - animationmaskfile = "gfx/interface/fleet_view/standard_button_mask.dds" - animationtexturefile = "gfx/interface/fleet_view/standard_button_texture.dds" - animationrotation = 180.0 - animationlooping = yes - animationtime = 12.0 - animationdelay = 0.0 - animationblendmode = "overlay" #add, multiply, overlay - animationtype = "scrolling" #scrolling, rotating, pulsing - animationrotationoffset = { x = 0.0 y = 0.0 } - animationtexturescale = { x = 1.0 y = 1.0 } - animationframes = { 1 2 3 } - } - } - - spriteType = { - name = "GFX_button_timeline_graphs" - texturefile = "gfx/interface/buttons/button_drain_resources.dds" - effectFile = "gfx/FX/buttonstate_onlydisable.lua" - noOfFrames = 3 - animation = { - animationmaskfile = "gfx/interface/fleet_view/standard_button_mask.dds" - animationtexturefile = "gfx/interface/fleet_view/standard_button_texture.dds" - animationrotation = 180.0 - animationlooping = yes - animationtime = 12.0 - animationdelay = 0.0 - animationblendmode = "overlay" #add, multiply, overlay - animationtype = "scrolling" #scrolling, rotating, pulsing - animationrotationoffset = { x = 0.0 y = 0.0 } - animationtexturescale = { x = 1.0 y = 1.0 } - animationframes = { 1 2 3 } - } - } - - spriteType = { - name = "GFX_button_event_history" - texturefile = "gfx/interface/buttons/kick.dds" - effectFile = "gfx/FX/buttonstate_onlydisable.lua" - noOfFrames = 3 - animation = { - animationmaskfile = "gfx/interface/fleet_view/standard_button_mask.dds" - animationtexturefile = "gfx/interface/fleet_view/standard_button_texture.dds" - animationrotation = 180.0 - animationlooping = yes - animationtime = 12.0 - animationdelay = 0.0 - animationblendmode = "overlay" #add, multiply, overlay - animationtype = "scrolling" #scrolling, rotating, pulsing - animationrotationoffset = { x = 0.0 y = 0.0 } - animationtexturescale = { x = 1.0 y = 1.0 } - animationframes = { 1 2 3 } - } - } -} - - diff --git a/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_braz_por.yml b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_braz_por.yml new file mode 100644 index 0000000..5198bf0 --- /dev/null +++ b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_braz_por.yml @@ -0,0 +1,2 @@ +l_braz_por: + STELLARIS_DASHBOARD_TOOLTIP: "§HDashboard§!\nView graphs, maps, and an event ledger.\nAlso includes a link to the official Stellaris Wiki.\n§RYou must run the Stellaris Dashboard program in the background.§!" \ No newline at end of file diff --git a/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_english.yml b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_english.yml new file mode 100644 index 0000000..7a3863b --- /dev/null +++ b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_english.yml @@ -0,0 +1,2 @@ +l_english: + STELLARIS_DASHBOARD_TOOLTIP: "§HDashboard§!\nView graphs, maps, and an event ledger.\nAlso includes a link to the official Stellaris Wiki.\n§RYou must run the Stellaris Dashboard program in the background.§!" \ No newline at end of file diff --git a/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_french.yml b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_french.yml new file mode 100644 index 0000000..0b79ce6 --- /dev/null +++ b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_french.yml @@ -0,0 +1,2 @@ +l_french: + STELLARIS_DASHBOARD_TOOLTIP: "§HDashboard§!\nView graphs, maps, and an event ledger.\nAlso includes a link to the official Stellaris Wiki.\n§RYou must run the Stellaris Dashboard program in the background.§!" \ No newline at end of file diff --git a/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_german.yml b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_german.yml new file mode 100644 index 0000000..f26ad1a --- /dev/null +++ b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_german.yml @@ -0,0 +1,2 @@ +l_german: + STELLARIS_DASHBOARD_TOOLTIP: "§HDashboard§!\nView graphs, maps, and an event ledger.\nAlso includes a link to the official Stellaris Wiki.\n§RYou must run the Stellaris Dashboard program in the background.§!" \ No newline at end of file diff --git a/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_japanese.yml b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_japanese.yml new file mode 100644 index 0000000..af9a3bf --- /dev/null +++ b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_japanese.yml @@ -0,0 +1,2 @@ +l_japanese: + STELLARIS_DASHBOARD_TOOLTIP: "§HDashboard§!\nView graphs, maps, and an event ledger.\nAlso includes a link to the official Stellaris Wiki.\n§RYou must run the Stellaris Dashboard program in the background.§!" \ No newline at end of file diff --git a/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_korean.yml b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_korean.yml new file mode 100644 index 0000000..fcb100b --- /dev/null +++ b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_korean.yml @@ -0,0 +1,2 @@ +l_korean: + STELLARIS_DASHBOARD_TOOLTIP: "§HDashboard§!\nView graphs, maps, and an event ledger.\nAlso includes a link to the official Stellaris Wiki.\n§RYou must run the Stellaris Dashboard program in the background.§!" \ No newline at end of file diff --git a/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_polish.yml b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_polish.yml new file mode 100644 index 0000000..6cdc3f3 --- /dev/null +++ b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_polish.yml @@ -0,0 +1,2 @@ +l_polish: + STELLARIS_DASHBOARD_TOOLTIP: "§HDashboard§!\nView graphs, maps, and an event ledger.\nAlso includes a link to the official Stellaris Wiki.\n§RYou must run the Stellaris Dashboard program in the background.§!" \ No newline at end of file diff --git a/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_russian.yml b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_russian.yml new file mode 100644 index 0000000..0ae48e3 --- /dev/null +++ b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_russian.yml @@ -0,0 +1,2 @@ +l_russian: + STELLARIS_DASHBOARD_TOOLTIP: "§HDashboard§!\nView graphs, maps, and an event ledger.\nAlso includes a link to the official Stellaris Wiki.\n§RYou must run the Stellaris Dashboard program in the background.§!" \ No newline at end of file diff --git a/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_simp_chinese.yml b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_simp_chinese.yml new file mode 100644 index 0000000..b97c7eb --- /dev/null +++ b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_simp_chinese.yml @@ -0,0 +1,2 @@ +l_simp_chinese: + STELLARIS_DASHBOARD_TOOLTIP: "§HDashboard§!\nView graphs, maps, and an event ledger.\nAlso includes a link to the official Stellaris Wiki.\n§RYou must run the Stellaris Dashboard program in the background.§!" \ No newline at end of file diff --git a/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_spanish.yml b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_spanish.yml new file mode 100644 index 0000000..c2e4b6e --- /dev/null +++ b/mod/stellaris_dashboard/localisation/stellaris_dashboard_l_spanish.yml @@ -0,0 +1,2 @@ +l_spanish: + STELLARIS_DASHBOARD_TOOLTIP: "§HDashboard§!\nView graphs, maps, and an event ledger.\nAlso includes a link to the official Stellaris Wiki.\n§RYou must run the Stellaris Dashboard program in the background.§!" \ No newline at end of file diff --git a/stellarisdashboard/dashboard_app/assets/style.css b/stellarisdashboard/dashboard_app/assets/style.css index 40b8cc6..f3c61f2 100644 --- a/stellarisdashboard/dashboard_app/assets/style.css +++ b/stellarisdashboard/dashboard_app/assets/style.css @@ -49,7 +49,7 @@ a.button, input.button { font-size: 16px; background-color: rgba(43, 59, 52, 1); - display: inline; + display: inline-block; text-decoration: none; padding: 0.2cm; @@ -61,6 +61,12 @@ a.button.vis_toggle { font-size: 14px; } +a.button.wiki-link { + border: 1px solid transparent; + background: transparent; + float: right; +} + li.game { color: rgba(195, 133, 33, 1); list-style-type: none; diff --git a/stellarisdashboard/dashboard_app/graph_ledger.py b/stellarisdashboard/dashboard_app/graph_ledger.py index 5467110..6bbb406 100644 --- a/stellarisdashboard/dashboard_app/graph_ledger.py +++ b/stellarisdashboard/dashboard_app/graph_ledger.py @@ -23,6 +23,7 @@ BACKGROUND = "rgba(33,43,39,1)" GALAXY_BACKGROUND = "rgba(0,0,0,1)" BACKGROUND_DARK = "rgba(20,25,25,1)" +BACKGROUND_LIGHT = "rgba(43, 59, 52, 1)" TEXT_COLOR = "rgba(217,217,217,1)" TEXT_HIGHLIGHT_COLOR = "rgba(195, 133, 33, 1)" DEFAULT_PLOT_LAYOUT = dict( @@ -36,16 +37,20 @@ BUTTON_STYLE = { "color": TEXT_HIGHLIGHT_COLOR, "font-family": "verdana", - "font-size": "20px", + "font-size": "16px", "-webkit-appearance": "button", "-moz-appearance": "button", "appearance": "button", - "background-color": BACKGROUND, - "display": "inline", + "background-color": BACKGROUND_LIGHT, + "display": "inline-block", "text-decoration": "none", - "padding": "0.1cm", - "margin": "0.1cm", + "padding": "0.2cm", + "border": f"1px solid {TEXT_HIGHLIGHT_COLOR}" } +EXTERNAL_LINK_STYLE = dict(BUTTON_STYLE) +EXTERNAL_LINK_STYLE["border"] = "1px solid transparent" +EXTERNAL_LINK_STYLE["background"] = "transparent" +EXTERNAL_LINK_STYLE["float"] = "right" HEADER_STYLE = { "font-family": "verdana", "color": TEXT_COLOR, @@ -741,21 +746,31 @@ def get_layout(): top_navigation = html.Div( [ html.A( - html.Button("Game Selection", style=BUTTON_STYLE), + "Game Selection", + style=BUTTON_STYLE, id="index-link", href="/", ), + " ", html.A( - html.Button(f"Settings", style=BUTTON_STYLE), + "Settings", + style=BUTTON_STYLE, id="settings-link", href="/settings/", - style=BUTTON_STYLE, ), + " ", html.A( - html.Button(f"Event Ledger", style=BUTTON_STYLE), + "Event Ledger", + style=BUTTON_STYLE, id="ledger-link", href="/history", - style=BUTTON_STYLE, + ), + " ", + html.A( + "Stellaris Wiki 🔗", + style=EXTERNAL_LINK_STYLE, + id="wiki-link", + href="https://stellaris.paradoxwikis.com/Stellaris_Wiki", ), ] ) diff --git a/stellarisdashboard/dashboard_app/templates/history_page.html b/stellarisdashboard/dashboard_app/templates/history_page.html index d2d4456..cc9058e 100644 --- a/stellarisdashboard/dashboard_app/templates/history_page.html +++ b/stellarisdashboard/dashboard_app/templates/history_page.html @@ -1,10 +1,13 @@ {% extends "layout.html" %} -{% block body %} +{% block nav %} Graph Dashboard {% if is_filtered_page %} Global event ledger {% endif %} +{% endblock %} + +{% block body %} {% if not is_filtered_page %}
{% if wars %} diff --git a/stellarisdashboard/dashboard_app/templates/layout.html b/stellarisdashboard/dashboard_app/templates/layout.html index dfdc9c7..9309bb4 100644 --- a/stellarisdashboard/dashboard_app/templates/layout.html +++ b/stellarisdashboard/dashboard_app/templates/layout.html @@ -6,6 +6,8 @@ Game Selection Settings + {% block nav %}{% endblock %} + Stellaris Wiki 🔗 {%if show_old_version_notice%}

You may be using an old version of the stellaris dashboard program. You are using version {{ version }}, and the requested version was {{ update_version_id }}. diff --git a/stellarisdashboard/dashboard_app/utils.py b/stellarisdashboard/dashboard_app/utils.py index 671cced..ec026a5 100644 --- a/stellarisdashboard/dashboard_app/utils.py +++ b/stellarisdashboard/dashboard_app/utils.py @@ -7,7 +7,7 @@ logger = logging.getLogger(__name__) -VERSION = "v5.2" +VERSION = "v6.2" def parse_version(version: str):