mirror of
https://github.com/cyberarm/w3d_hub_linux_launcher.git
synced 2025-12-16 17:22:35 +00:00
Handle user not having an avatar image
This commit is contained in:
@@ -104,7 +104,11 @@ class W3DHub
|
|||||||
def populate_account_info
|
def populate_account_info
|
||||||
@host.instance_variable_get(:"@account_container").clear do
|
@host.instance_variable_get(:"@account_container").clear do
|
||||||
flow(fill: true, height: 1.0) do
|
flow(fill: true, height: 1.0) do
|
||||||
avatar_image = get_image(Cache.path(Store.account.avatar_uri))
|
avatar_image = begin
|
||||||
|
get_image(Cache.path(Store.account.avatar_uri))
|
||||||
|
rescue
|
||||||
|
get_image("#{GAME_ROOT_PATH}/media/icons/default_icon.png")
|
||||||
|
end
|
||||||
mask_image = get_image("#{GAME_ROOT_PATH}/media/textures/circle_mask.png")
|
mask_image = get_image("#{GAME_ROOT_PATH}/media/textures/circle_mask.png")
|
||||||
|
|
||||||
composite_image = Gosu.render(256, 256) do
|
composite_image = Gosu.render(256, 256) do
|
||||||
|
|||||||
Reference in New Issue
Block a user