00:26 < bridge> https://i.imgur.com/M5OcDqs.png 00:37 < bridge> that's how you use the variable 00:42 < bridge> your actual code would probably look something like this 00:42 < bridge> ```cpp 00:42 < bridge> // in CDiscord 00:42 < bridge> IGameClient m_pGameClient = nullptr; 00:42 < bridge> ... 00:42 < bridge> // in SetGameInfo 00:42 < bridge> if(!m_pGameClient) m_pGameClient = Kernel()->RequestInterface(); 00:42 < bridge> m_pActivityManager->update_activity(m_pActivityManager, &Activity, 0, 0); 00:42 < bridge> if(pGameClient && pGameClient->m_Snap.m_LocalClientID >= 0 && pGameClient->m_aClients[pGameClient->m_Snap.m_LocalClientID]->m_Afk) { 00:42 < bridge> str_copy(Activity.assets.small_image, "idle", sizeof(Activity.assets.small_image)); 00:42 < bridge> str_copy(Activity.assets.small_text, "Idling", sizeof(Activity.assets.small_text)); 00:42 < bridge> } else { 00:42 < bridge> str_copy(Activity.assets.small_image, "greenline", sizeof(Activity.assets.small_image)); 00:42 < bridge> str_copy(Activity.assets.small_text, "In Game", sizeof(Activity.assets.small_text)); 00:42 < bridge> } 00:42 < bridge> ``` 00:42 < bridge> your actual code would probably look something like this 00:42 < bridge> ```cpp 00:42 < bridge> // in CDiscord 00:42 < bridge> IGameClient *m_pGameClient = nullptr; 00:42 < bridge> ... 00:42 < bridge> // in SetGameInfo 00:42 < bridge> if(!m_pGameClient) m_pGameClient = Kernel()->RequestInterface(); 00:43 < bridge> m_pActivityManager->update_activity(m_pActivityManager, &Activity, 0, 0); 00:43 < bridge> if(pGameClient && pGameClient->m_Snap.m_LocalClientID >= 0 && pGameClient->m_aClients[pGameClient->m_Snap.m_LocalClientID]->m_Afk) { 00:43 < bridge> str_copy(Activity.assets.small_image, "idle", sizeof(Activity.assets.small_image)); 00:43 < bridge> str_copy(Activity.assets.small_text, "Idling", sizeof(Activity.assets.small_text)); 00:43 < bridge> } else { 00:43 < bridge> str_copy(Activity.assets.small_image, "greenline", sizeof(Activity.assets.small_image)); 00:43 < bridge> str_copy(Activity.assets.small_text, "In Game", sizeof(Activity.assets.small_text)); 00:43 < bridge> } 00:43 < bridge> ``` 00:46 < bridge> your actual code would probably look something like this 00:46 < bridge> ```cpp 00:46 < bridge> // in CDiscord 00:46 < bridge> IGameClient *m_pGameClient = nullptr; 00:46 < bridge> ... 00:46 < bridge> // in SetGameInfo 00:46 < bridge> if(!m_pGameClient) m_pGameClient = Kernel()->RequestInterface(); 00:46 < bridge> m_pActivityManager->update_activity(m_pActivityManager, &Activity, 0, 0); 00:46 < bridge> 00:46 < bridge> if(pGameClient && pGameClient->m_Snap.m_LocalClientID >= 0 && pGameClient->m_aClients[pGameClient->m_Snap.m_LocalClientID]->m_Afk) { 00:46 < bridge> str_copy(Activity.assets.small_image, "idle", sizeof(Activity.assets.small_image)); 00:46 < bridge> str_copy(Activity.assets.small_text, "Idling", sizeof(Activity.assets.small_text)); 00:46 < bridge> } else { 00:46 < bridge> str_copy(Activity.assets.small_image, "greenline", sizeof(Activity.assets.small_image)); 00:46 < bridge> str_copy(Activity.assets.small_text, "In Game", sizeof(Activity.assets.small_text)); 00:46 < bridge> } 00:46 < bridge> ``` 00:46 < bridge> sorry chiller 00:46 < bridge> why with dots? xD 00:46 < bridge> because they go in different places 00:46 < bridge> fair enough 00:47 < bridge> ok why are wo using pGameClient here? 00:47 < bridge> ok why are we using pGameClient here? 00:48 < bridge> because your player's afk value is stored in a CClientInfo object stored in an array in the game client 00:49 < bridge> Alr then, 2nd question is wtheck this wont workhttps://i.imgur.com/ERiJqWT.png 00:50 < bridge> oh mb 00:50 < bridge> your actual code would probably look something like this 00:50 < bridge> ```cpp 00:50 < bridge> // in CDiscord 00:50 < bridge> IGameClient *m_pGameClient = nullptr; 00:50 < bridge> ... 00:50 < bridge> // in SetGameInfo 00:50 < bridge> if(!m_pGameClient) m_pGameClient = Kernel()->RequestInterface(); 00:50 < bridge> m_pActivityManager->update_activity(m_pActivityManager, &Activity, 0, 0); 00:50 < bridge> 00:50 < bridge> if(m_pGameClient && m_pGameClient->m_Snap.m_LocalClientID >= 0 && m_pGameClient->m_aClients[pGameClient->m_Snap.m_LocalClientID]->m_Afk) { 00:50 < bridge> str_copy(Activity.assets.small_image, "idle", sizeof(Activity.assets.small_image)); 00:51 < bridge> str_copy(Activity.assets.small_text, "Idling", sizeof(Activity.assets.small_text)); 00:51 < bridge> } else { 00:51 < bridge> str_copy(Activity.assets.small_image, "greenline", sizeof(Activity.assets.small_image)); 00:51 < bridge> str_copy(Activity.assets.small_text, "In Game", sizeof(Activity.assets.small_text)); 00:51 < bridge> } 00:51 < bridge> ``` 00:51 < bridge> updated 00:51 < bridge> i mean, is might looks dumb from my side 00:51 < bridge> https://cdn.discordapp.com/attachments/293493549758939136/1171235530810339338/image.png?ex=655bf117&is=65497c17&hm=66a44f147b39b4f0027d79100ef298c204f71e0c8be1485bc25a595852dea6fc& 00:52 < bridge> missed another 00:52 < bridge> but it should be fairly obvious 00:52 < bridge> m_pGameClient instead of pGameClient 00:52 < bridge> since it's a member 00:53 < bridge> now m_Snap `No member named 'm_Snap' in 'IGameClient'` 00:54 < bridge> hell, the most hard staff i made for today, was cracking discord 00:54 < bridge> i have no idea why it isn't in the IGameClient interface 00:55 < bridge> this is against all OOP wisdom but i don't think there's any other class inheriting from IGameClient so you should just be able to cast your IGameClient pointer into a CGameClient pointer 00:56 < bridge> so in CDiscord class def do this instead 00:56 < bridge> `CGameClient *m_pGameClient = nullptr;` 00:56 < bridge> 00:56 < bridge> then in SetGameInfo, do this instead 00:56 < bridge> `m_pGameClient = static_cast(Kernel()->RequestInterface());` 00:59 < bridge> now i can say that discord made me braindamaged 01:00 < bridge> 1st day of making own client 01:00 < bridge> https://i.imgur.com/N5sSzMH.png 01:00 < bridge> 4th day of learning c++ without chatGPT 01:00 < bridge> xd 01:00 < bridge> 😃 01:01 < bridge> and some discord rpc https://i.imgur.com/p3eb2Jf.png 01:02 < bridge> idk looks cool as for relatively 1st day 01:02 < bridge> nice 01:02 < bridge> did u test if it works yet 01:02 < bridge> what exactly? 01:02 < bridge> the afk 01:02 < bridge> its not 01:03 < bridge> i give up for today 01:03 < bridge> rip 01:03 < bridge> its 2:am 01:03 < bridge> oh wow 01:04 < bridge> noticed that if im logged in f2, in any way my name will be = sc_player_own_color 01:05 < bridge> well i need to see the code 01:05 < bridge> to know what the issue is 01:05 < bridge> 😃 01:26 < bridge> I wouldn't consider that an error tbh, it's a bit weird that you have to special case the empty case 01:29 < bridge> perhaps try looking at it in wireshark 01:32 < bridge> yea, temperature scales are kinda arbitrary 01:33 < bridge> a friend of mine hasn't recovered from covid and still can't do any straining things or work 01:34 < bridge> but "long covid" doesn't really mean anything AFAIK, it's just "long-term consequences of covid", nothing precise 01:34 < bridge> i have a hunch that there was an infrastructure change somewhere which introduced some sort of variability in the latency 01:34 < bridge> AFAIK avocado is lengths better than meat 01:35 < bridge> because now when i'm not lagging i get 8-10 fewer ms in latency. but obviously i have the micro lags 01:35 < bridge> thing is i never traced the route before i had this issue so idk 01:37 < bridge> let me sleeep 01:37 < bridge> is this the EU mandated CA thing? 01:38 < bridge> @mpftimagine awake and see 100500 bug report xd 01:38 < bridge> https://i.imgur.com/JhISxCd.png 01:40 < bridge> oh, we're doing accounts discussion 😄 01:40 < bridge> <_voxeldoesart> i can already see heinrich walking out the door LOL 01:40 < bridge> btw 01:40 < bridge> hmm 01:41 < bridge> <_voxeldoesart> whyd you screenshot your entire client 01:42 < bridge> do you want me to? 01:42 < bridge> <_voxeldoesart> what 01:42 < bridge> banning versions sounds futile. once ddnet starts doing it, they'll change the version number 01:43 < bridge> nvm, to sleepy for understand english 01:43 < bridge> gn 01:43 < bridge> <_voxeldoesart> goodnight 01:43 < bridge> no mentioning bot client names 01:45 < bridge> I know but a kog mod already did that so 01:45 < bridge> :owo: 01:45 < bridge> <_voxeldoesart> that just makes Them in the wrong 01:47 < bridge> +1 At least is already known to be a malicious client 01:53 < bridge> I know but a kog mod already did that so... *I won't do it again* 02:19 < bridge> <_voxeldoesart> grahh im trying to find good shader tutorials but all im getting is javascript or unity 02:21 < bridge> <_voxeldoesart> also wait wtf vulkan and opengl are owned by the same group? LOL 02:32 < bridge> yeah 03:56 < bridge> <_voxeldoesart> LOL 04:57 < bridge> Put the ``OwnPlayer`` check before the ``AuthedPlayer`` check, and do ``else if`` 04:59 < bridge> Although, in this case ``AuthedPlayer`` will not work, it is easier to just add to the check for ``AuthedPlayer`` also check for ``OwnPlayer`` 08:07 < bridge> https://tenor.com/view/thomas-thomas-wiltherford-rainbow-rgb-flashing-gif-21788197 08:13 < bridge> Point was more supposed to be that there is give or take in the production of moat everything 08:13 < bridge> Most* 09:39 < bridge> morning to all rust users 09:39 < bridge> go back to bed 09:41 < bridge> im at gym 09:41 < bridge> :troll: 10:44 < bridge> https://gwern.net/holy-war 11:01 < bridge> stalking the chat 11:08 < bridge> lmfao 11:09 < bridge> https://cdn.discordapp.com/attachments/293493549758939136/1171390837238804621/IMG_3990.png?ex=655c81ba&is=654a0cba&hm=8123abd240bb35482ecec8c975899b9e5bef4bdfc61abd63ba5d2167cbe3dba1& 12:26 < bridge> https://tenor.com/view/mean-people-rude-ignorant-spiteful-hurtful-gif-19113534 12:27 < bridge> Apple sucks ass 12:29 < bridge> what 13:01 < ws-client1> a 13:01 < ws-client1> https://tenor.com/view/mean-people-rude-ignorant-spiteful-hurtful-gif-19113534 13:01 < ws-client1> https://tenor.com/view/mean-people-rude-ignorant-spiteful-hurtful-gif-19113534 13:02 < ws-client1> 13:12 < ChillerDragon> ops my bad i thought im in my dev environment 15:31 < bridge> chillerdragon: It seems like https://schildi.chat/ is a functioning matrix client on mobile for android (dont remember rn whether you are on android or ios) 15:31 < bridge> even the custom reactions are working 15:35 < ws-client> im on ios :( 15:38 < bridge> Yo, ive got a question. I have 2 projects. They both have the same folder. Can i somehow yoink a folder from one repo and use in another or the only way is to create a separate repo with those files and use as submodule in those projects? 15:42 < bridge> Wat? 15:43 < bridge> You can copy them if you just need a snapshot. Otherwise use a submodule 16:42 < bridge> ChillerDragon: u could try https://fluffychat.im/ I remember it being a good client, it probably works better than element on mobile (element is definitely shitty in combination with the discord bridge) 16:48 < bridge> Yeah this client seems nicer!!! Thanks zwelf uwu 17:16 < bridge> @ryozuki did you know @milkeeycat is a fellow gentoo enjoyer? 17:17 < bridge> Ryozuki is the own who guided him through iirc xD 17:18 < bridge> <_voxeldoesart> explains the way they act too 17:22 < bridge> its gentoo thing not ryo 17:32 < bridge> <_voxeldoesart> sadge 17:40 < bridge> xd 18:44 < bridge> someone deleting my shit 18:44 < bridge> https://cdn.discordapp.com/attachments/293493549758939136/1171505445903548508/IMG_3992.png?ex=655cec77&is=654a7777&hm=07ac16d201e19aaa9eb142228cf66d50eac7f418249f72778aef78fbc95a2d21& 18:47 < bridge> It's heinrich and ur on a watchlist now 18:49 < bridge> @learath2 https://doc.rust-lang.org/stable/std/sync/struct.Barrier.html 18:49 < bridge> did u know about this 18:49 < bridge> What is this??? Magic?????? 18:49 < bridge> I looked at this chat for a second. You hilite me 18:49 < bridge> xd 18:49 < bridge> its coincidence rly 18:49 < bridge> Yes I did know. Why? 18:50 < bridge> C++20 has barriers too btw 18:51 < bridge> what do you use it for? 18:52 < bridge> i didnt know, iguess i never had to use it 18:52 < bridge> When you need the workers to start working at the same time 18:53 < bridge> why would u need that 18:53 < bridge> benchmarking cores? xd 18:54 < bridge> @learath2 rust has had them since 1.0 18:54 < bridge> do u think c++20 added them cuz rust influence? 18:57 < bridge> can you give an example for this? 19:03 < bridge> https://without.boats/blog/a-four-year-plan/ 19:03 < bridge> A four year plan for async Rust 19:07 < bridge> > I’ve never seen the project’s relationship with its community be in a worse state. But that community contains invaluable expertise; closing yourselves off is not the solution. I want to see the relationships of mutual trust and respect rebuilt between project members and community members, instead of the present situation of hostility and dissatisfaction. To this, I want to thank those from the project who have reached out and engaged w 19:07 < bridge> triggered that the page isn't centered 19:07 < bridge> make your browser smaller I guess ^^ 19:07 < bridge> I :zoozer: 19:08 < bridge> Hm, idk, it might be useful when you have strict timing requirements 20:07 < bridge> agreed with the dude from the screenshot 21:36 < bridge> https://www.eff.org/deeplinks/2023/11/article-45-will-roll-back-web-security-12-years 21:37 < bridge> more on this shit @ryozuki 😦 21:37 < bridge> yeah 21:49 < bridge> something great is coming 21:51 < bridge> I'm hoping it won't pass