This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2012-05-28 17:21:12

t-boy
Scratcher
Registered: 2008-05-15
Posts: 21

Panther Mesh Chat

hi all,
I'm having a lot of trouble with my chatting engine I'm making called mesh chat. I'm making it in Panther which is a fabulous mod made by a bunch of scratchers. It supports mesh features through blocks such as blocks for "join mesh [ ]" "host mesh" "leave mesh" and "IP [ ] hosting mesh?" as well as others. the problem i cant work around is that i have no way to sense if my friend has connected to my session yet. I thought if the remote username is not blank then that means someone has connected, but i learned if no one is actually there, the block gives an error and stops the whole script. Using brodcasts doesnt help much more becuase both local and remote users recieve them, so there's no way to tell if youre recieving a brodcast from yourself or your friend. if you have any ideas how i can fix this problem please say so, or if you know how to make the code for any of the following blocks:
<IP [ ] has joined session?>
<IP is in session?>
thanks!

Offline

 

#2 2012-05-28 21:05:37

Magnie
Scratcher
Registered: 2007-12-12
Posts: 1000+

Re: Panther Mesh Chat

Mesh does not natively support the "detection" of connections. You'll have to either create the Mesh server in another language or modify Scratch to detect them.

Offline

 

#3 2012-06-09 13:05:15

Asraelite
Scratcher
Registered: 2012-04-09
Posts: 100+

Re: Panther Mesh Chat

How about whenever the person joins the mesh, they send a message saying "[username] has joined the chatroom" and they add it to the chat room list. Then, whenever that message is received, you know someone has joined.


I hate the new vector graphics  sad

Offline

 

#4 2012-06-09 15:04:46

777w
Scratcher
Registered: 2009-02-10
Posts: 1000+

Re: Panther Mesh Chat

i think there are blocks in the block library for mesh detection
if they dont have the specific blocks youre looking for then you can request them be made

Offline

 

#5 2012-06-27 17:18:06

KPX
Scratcher
Registered: 2011-10-03
Posts: 13

Re: Panther Mesh Chat

in panther make something like
When Green Flag Clicked
(Broadcast [joining] )

When I receive [joining]
(Add (join [<mesh IP address>] [ : Just joined])]) to list [readout])


[this message is censored by SOPA]

Offline

 

Board footer