rektbot Posted March 5, 2017 Report Posted March 5, 2017 (edited) Hi There, I understand what ID events do, emitting the event with a suffix eg #steamid. My main question is what's the purpose of this? Second question is how would you listen for it? (given that it would be impractical to hardcode a steamid) Thanks in advance Edited March 5, 2017 by rektbot Quote
Dr. McKay Posted March 6, 2017 Report Posted March 6, 2017 Please post in the correct board next time. I've moved your topic. An ID event is a special kind of event specific to steam-user where both the base event and the event suffixed with the SteamID of the relevant account are emitted. For example, if I sent you a chat message, both friendMessage and friendMessage#76561198006409530 would be emitted. Listening for the latter event is mostly useful for when you only care about one specific user. For example, you might hardcode a listener for friendMessage#yoursteamid to listen for admin commands (or perhaps something like on('friendMessage#' + config.adminSteamID)). Quote
rektbot Posted March 6, 2017 Author Report Posted March 6, 2017 Thanks Doc. That makes sense. I didn't realise you could add a variable to a listen event. Thanks again Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.