haren724 / wallpaper-player-mac

A powerful open source live wallpaper app for mac
https://docc.haren724.top
GNU General Public License v3.0
383 stars 34 forks source link

使用 Steam CMD 安装 Wallpaper Engine 自动拉取壁纸 #11

Open starknt opened 1 year ago

starknt commented 1 year ago

您的功能请求是否与目前所存在的问题有关?请描述一下

使用 Steam CMD 安装 Wallpaper Engine 自动拉取创意工坊的壁纸列表

描述您想要的解决方案

等待 Steeam CMD 拉取完成后,可以自动扫描 ~/Library/Application Support/Steam/steamapps/content/431960 下的壁纸(默认),如果没有则可以由用户提供。

简单命令过程:

    mkdir ~/Steam && cd ~/Steam
    curl -sqL "https://steamcdn-a.akamaihd.net/client/installer/steamcmd_osx.tar.gz" | tar zxvf -
    ./steamcmd.sh
    # 登录
    login user pass
    # 必须设置平台为 Windows
    @sSteamCmdForcePlatformType windows
    # 下载安装 Wallpaper Engine
    app_update 431960

附加内容

拉取完成后, 可以看到在这个目录下有在创意工坊中收藏的所有壁纸

image

haren724 commented 1 year ago

Great idea! it's a very constructive suggestion. I' ll put it in the road map.

btw, I'll also keep this issue opened until the suggested feature comes out

FlyRenxing commented 1 year ago

您的功能请求是否与目前所存在的问题有关?请描述一下

使用 Steam CMD 安装 Wallpaper Engine 自动拉取创意工坊的壁纸列表

描述您想要的解决方案

等待 Steeam CMD 拉取完成后,可以自动扫描 ~/Library/Application Support/Steam/steamapps/content/431960 下的壁纸(默认),如果没有则可以由用户提供。

简单命令过程:

  mkdir ~/Steam && cd ~/Steam
  curl -sqL "https://steamcdn-a.akamaihd.net/client/installer/steamcmd_osx.tar.gz" | tar zxvf -
  ./steamcmd.sh
  # 登录
  login user pass
  # 必须设置平台为 Windows
  @sSteamCmdForcePlatformType windows
  # 下载安装 Wallpaper Engine
  app_update 431960

附加内容

拉取完成后, 可以看到在这个目录下有在创意工坊中收藏的所有壁纸

image

请问您用的是什么shell?zsh吗?啥主题呀真的很喜欢

starknt commented 1 year ago

您的功能请求是否与目前所存在的问题有关?请描述一下 使用 Steam CMD 安装 Wallpaper Engine 自动拉取创意工坊的壁纸列表 描述您想要的解决方案 等待 Steeam CMD 拉取完成后,可以自动扫描 ~/Library/Application Support/Steam/steamapps/content/431960 下的壁纸(默认),如果没有则可以由用户提供。 简单命令过程:

    mkdir ~/Steam && cd ~/Steam
    curl -sqL "https://steamcdn-a.akamaihd.net/client/installer/steamcmd_osx.tar.gz" | tar zxvf -
    ./steamcmd.sh
    # 登录
    login user pass
    # 必须设置平台为 Windows
    @sSteamCmdForcePlatformType windows
    # 下载安装 Wallpaper Engine
    app_update 431960

附加内容 拉取完成后, 可以看到在这个目录下有在创意工坊中收藏的所有壁纸 image

请问您用的是什么shell?zsh吗?啥主题呀真的很喜欢

baysonfox commented 1 year ago

补充一下,如果要手动下载一个壁纸,可以直接用workshop_download_item (AppID) (创意工坊里壁纸的 id) 来下载. e.g. workshop_download_item 431960 3004222851 431960为Wallpaper Engine的 AppID, 30004222851则为壁纸的id. ID可从创意工坊里壁纸的链接获取. 保存的位置在~/Library/Application Support/Steam/steamapps/workshop/content (以 https://steamcommunity.com/sharedfiles/filedetails/?id=3004222851 为例, ID 即 3004222851) (以这种方式可以直接下载单个壁纸,同时不需要登录,可以直接 login anonymous.) 更正:需要用 steam 账户登录.

image
starknt commented 1 year ago

使用 https://api.steampowered.com/IPublishedFileService/QueryFiles/v1?page=1&numperpage=4&appid=431960&key=? 能 获得 Wallpaper Engine 的创意工坊的壁纸 ID 列表,只需要在 https://steamcommunity.com/dev/apikey 申请一个 KEY 即可 还有几个可选的参数 return_metadata:1 或者 不填 search_text: 这个感觉应该是个用来过滤壁纸的

结合上 https://api.steampowered.com/ISteamRemoteStorage/GetPublishedFileDetails/v1 API, 我们或许能更进一步

baysonfox commented 1 year ago

使用 https://api.steampowered.com/IPublishedFileService/QueryFiles/v1?page=1&numperpage=4&appid=431960&key=? 能 获得 Wallpaper Engine 的创意工坊的壁纸 ID 列表,只需要在 https://steamcommunity.com/dev/apikey 申请一个 KEY 即可 还有几个可选的参数 return_metadata:1 或者 不填 search_text: 这个感觉应该是个用来过滤壁纸的

结合上 https://api.steampowered.com/ISteamRemoteStorage/GetPublishedFileDetails/v1 API, 我们或许能更进一步

补充下这俩的文档: https://partner.steamgames.com/doc/webapi/IPublishedFileService https://partner.steamgames.com/doc/webapi/ISteamRemoteStorage#GetPublishedFileDetails

baysonfox commented 1 year ago

https://partner.steamgames.com/doc/webapi/IPublishedFileService
https://partner.steamgames.com/doc/webapi/ISteamRemoteStorage#GetPublishedFileDetails

刚刚测试了下这俩 API, 可以正常请求得到结果, 但建议设置requiredtags来限定壁纸类型为 Video/Web (目前支持的两种壁纸类型),同时将return_metadata设置为true来避免请求ISteamRemoteStorage. 值得一提的是,返回的数据中url无值,大概率需要 SteamCMD 登录后再进行下载.

image image

starknt commented 1 year ago

https://partner.steamgames.com/doc/webapi/IPublishedFileService https://partner.steamgames.com/doc/webapi/ISteamRemoteStorage#GetPublishedFileDetails

刚刚测试了下这俩 API, 可以正常请求得到结果, 但建议设置requiredtags来限定壁纸类型为 Video/Web (目前支持的两种壁纸类型),同时将return_metadata设置为true来避免请求ISteamRemoteStorage. 值得一提的是,返回的数据中url无值,大概率需要 SteamCMD 登录后再进行下载.

image image

属于帮V社拓展mac系统业务了(乐)