File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed
Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -17,17 +17,21 @@ module RP42
1717
1818 coa = JSON .parse(http_client.get(" /v2/users/#{ username } /coalitions" ).body).as_a.last[" name" ].to_s
1919 lvl = JSON .parse(http_client.get(" /v2/users/#{ username } " ).body)[" cursus_users" ][0 ][" level" ].to_s
20+ log = JSON .parse(http_client.get(" /v2/users/#{ username } /locations" ).body)[0 ]
2021
2122 rich_client = RichCrystal ::Client .new(531103976029028367 _u64 )
22- rich_client.login
23- rich_client.activity({
24- " details" => " Level: #{ lvl } " ,
25- " state" => " Location: #{ hostname[0 ] } " ,
23+ rich_client.login
24+ rich_client.activity({
25+ " details" => " Level: #{ lvl } " ,
26+ " state" => " Location: #{ hostname[0 ] } " ,
2627 " assets" => {
2728 " large_image" => " logo" ,
2829 " large_text" => username,
2930 " small_image" => coa.tr(" " , " -" ).downcase,
3031 " small_text" => coa,
32+ },
33+ " timestamps" => {
34+ " start" => Time .parse_iso8601(log[" begin_at" ].to_s).to_unix
3135 }
3236 })
3337
You can’t perform that action at this time.
0 commit comments