class RSGuitarTech::Steam

Constants

ROCKSMITH2014_APP_ID

Public Instance Methods

crd() click to toggle source

Uplay junk

# File lib/rsgt/steam.rb, line 19
def crd
  "#{base_path}crd"
end
local_profiles() click to toggle source
# File lib/rsgt/steam.rb, line 14
def local_profiles
  "#{base_path}LocalProfiles.json"
end
save_file() click to toggle source
# File lib/rsgt/steam.rb, line 6
def save_file
  "#{base_path}#{save_filename}"
end
save_filename() click to toggle source
# File lib/rsgt/steam.rb, line 10
def save_filename
  "#{unique_id}_PRFLDB"
end
unique_id() click to toggle source
# File lib/rsgt/steam.rb, line 23
def unique_id
  @unique_id ||= begin
    file = File.open local_profiles
    data = RSGuitarTech::EncryptedSteamFile.read(file)
    data.uncompressed_json['Profiles'].first['UniqueID']
  end
end

Private Instance Methods

base_path() click to toggle source
# File lib/rsgt/steam.rb, line 33
def base_path
  "#{steam_path}#{steam_id}/#{ROCKSMITH2014_APP_ID}/remote/"
end
steam_id() click to toggle source
# File lib/rsgt/steam.rb, line 41
def steam_id
  Dir["#{steam_path}/*"].first.match(/\/(\d+)$/)[1]
end
steam_path() click to toggle source
# File lib/rsgt/steam.rb, line 37
def steam_path
  "/Users/#{`whoami`.strip}/Library/Application\ Support/Steam/userdata/"
end