Messages not always sent or received


#1

Hi all! Alessandro here from Italy! Some of you may remember me for an internship I did two years ago in the HighFidelity office, we built a prototype of VR shop, I’m missing you guys…
Btw I’m here to explain the issue I’m having, I’m trying to build some contents in a domain and basically once in a while happens that messages sent via Messages.sendMessage are not actually sent.
The sender script is running:

print(“sending message”);
Messages.sendMessage(“myChannel”,“myMessage”);

And the receiver script is running:

Messages.subscribe(“myChannel”);
Messages.messageReceived.connect(function (channel, message, senderID) {
print(“Message received - channel :” + channel + “, message:” + message + “, senderID:” + senderID);
});

But sometimes, even if the sender prints “sending message”, the receiver doesn’t print anything.

Is this a known issue of the message mixer? Am I doing something wrong? Any of you experienced the same problem?

Thanks you in advance :slight_smile:


#2

Hi Alessandro!

Without knowing more about what is sending and receiving, it looks like you are generally using the Messages right.

There are two scripts that might be interesting to see how many messages are being sent and received in a given period.

If you do try this, maybe take out the line of
if (sender === MyAvatar.sessionUUID) depending on what you are doing.