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

#1 2012-12-22 12:23:39

joefarebrother
Scratcher
Registered: 2011-04-08
Posts: 1000+

Mesh help

I'm working on a scratch project, and I want to add a feature that involves mesh. The thing is, the project has lots of broadcasts in it, and if it was connected to another instance of the project through mesh, they would call each other's broadcasts and mess up the structure of the project. Is there any way to avoid this by only sharing variables and only particular broadcasts using mesh?


My latest project is called http://tinyurl.com/d2m8hne! It has http://tinyurl.com/d395ygk views, http://tinyurl.com/cnasmt7 love-its, and http://tinyurl.com/bwjy8xs comments.
http://tinyurl.com/756anbk   http://tinyurl.com/iplaychess

Offline

 

#2 2012-12-22 12:53:11

GP1
Scratcher
Registered: 2009-07-06
Posts: 1000+

Re: Mesh help

I guess you could by editing the ScratchServer code in the browser, but that would be hard and not worth it for just one project.

Another solution is to have two different projects. One with the broadcasts the same, and one with the broadcasts changed (ex. "play" becomes "play2" except the broadcasts you want to go through mesh.


I am currently http://blocks.scratchr.org/API.php?user=GP1&action=onlineStatus&type=imagehttp://blocks.scratchr.org/API.php?user=GP1&action=onlineStatus&type=text and I finally got over 1000 posts.

Offline

 

#3 2012-12-24 04:58:33

joefarebrother
Scratcher
Registered: 2011-04-08
Posts: 1000+

Re: Mesh help

ok, but with a lot of broadcasts, it may take a while.

I was thinking I could have a third project, written in panther, that acts as a connector; when one project wants to send or receive some data, the connector project gets the data and puts it in a variable, the disconnects from one project and connects to the other, accessing the variable. This could work as panther can connect to mesh dynamically and can keep track of IP addresses.


My latest project is called http://tinyurl.com/d2m8hne! It has http://tinyurl.com/d395ygk views, http://tinyurl.com/cnasmt7 love-its, and http://tinyurl.com/bwjy8xs comments.
http://tinyurl.com/756anbk   http://tinyurl.com/iplaychess

Offline

 

#4 2012-12-24 12:01:06

GP1
Scratcher
Registered: 2009-07-06
Posts: 1000+

Re: Mesh help

joefarebrother wrote:

ok, but with a lot of broadcasts, it may take a while.

I was thinking I could have a third project, written in panther, that acts as a connector; when one project wants to send or receive some data, the connector project gets the data and puts it in a variable, the disconnects from one project and connects to the other, accessing the variable. This could work as panther can connect to mesh dynamically and can keep track of IP addresses.

Yeah, I guess that would work, too. It may be slower than regular mesh. And if you don't know which project should be the host, the Panther project should be joining mesh, and the other projects should be hosting mesh. Then, as you said before, the Panther project just connects back and forth between projects. There would be some issues, though but they can be fixed easily.


I am currently http://blocks.scratchr.org/API.php?user=GP1&action=onlineStatus&type=imagehttp://blocks.scratchr.org/API.php?user=GP1&action=onlineStatus&type=text and I finally got over 1000 posts.

Offline

 

Board footer