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

#1 2011-02-07 16:59:53

Billybob-Mario
Scratcher
Registered: 2008-01-05
Posts: 500+

"Mind Control" Block- Sprites Making Other Sprites Do Stuff

I'm back.

I'm making a new block to send blocks to another sprite and have it run them, but it's not working.

Here is my code:

Code:

make: t1 do: t2

^ Compiler evaluate: t2 for: t1 logged: false

When I do it, it says that there is a syntax error for the CSlotMorph that the blocks go into (remember, Slash is based on BYOB). For some reason, it is reporting itself instead of the blocks. Can anyone help? Once this is solved, I can release Slash 1.2, with a customizable color scheme!

Offline

 

#2 2011-02-07 20:19:00

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

Billybob-Mario wrote:

I'm back.

I'm making a new block to send blocks to another sprite and have it run them, but it's not working.

Here is my code:

Code:

make: t1 do: t2

^ Compiler evaluate: t2 for: t1 logged: false

When I do it, it says that there is a syntax error for the CSlotMorph that the blocks go into (remember, Slash is based on BYOB). For some reason, it is reporting itself instead of the blocks. Can anyone help? Once this is solved, I can release Slash 1.2, with a customizable color scheme!

I have been working on that for a LOOOOOOONG time. You may have solved my problem lemme check.


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#3 2011-02-08 19:06:49

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

Pecola1 wrote:

Billybob-Mario wrote:

I'm back.

I'm making a new block to send blocks to another sprite and have it run them, but it's not working.

Here is my code:

Code:

make: t1 do: t2

^ Compiler evaluate: t2 for: t1 logged: false

When I do it, it says that there is a syntax error for the CSlotMorph that the blocks go into (remember, Slash is based on BYOB). For some reason, it is reporting itself instead of the blocks. Can anyone help? Once this is solved, I can release Slash 1.2, with a customizable color scheme!

I have been working on that for a LOOOOOOONG time. You may have solved my problem lemme check.

Nope. Didn't work. Is it a c block? If so, you cannot make it a variable in the method. You could make BYOB's lambada C-block. I don't know how but its possible.


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#4 2011-02-09 08:09:58

Billybob-Mario
Scratcher
Registered: 2008-01-05
Posts: 500+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

Pecola1 wrote:

Pecola1 wrote:

Billybob-Mario wrote:

I'm back.

I'm making a new block to send blocks to another sprite and have it run them, but it's not working.

Here is my code:

Code:

make: t1 do: t2

^ Compiler evaluate: t2 for: t1 logged: false

When I do it, it says that there is a syntax error for the CSlotMorph that the blocks go into (remember, Slash is based on BYOB). For some reason, it is reporting itself instead of the blocks. Can anyone help? Once this is solved, I can release Slash 1.2, with a customizable color scheme!

I have been working on that for a LOOOOOOONG time. You may have solved my problem lemme check.

Nope. Didn't work. Is it a c block? If so, you cannot make it a variable in the method. You could make BYOB's lambada C-block. I don't know how but its possible.

I tried the special BYOB C-block and also the slot that looks like a block outline, but neither worked.

Offline

 

#5 2011-02-09 16:01:15

bbbeb
Scratcher
Registered: 2009-06-11
Posts: 1000+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

Make it a C block and it requires execution engine edits.

I.E. Making a class in the actual class with the C shapes.
And another thing: You need the popStackFrame and pushStackFrame methods in there somewhere.  tongue  Or else they dont run.


Back in my day.... there were no laws that censored the internet... now, there are.... nah.

Offline

 

#6 2011-02-09 16:40:51

LS97
Scratcher
Registered: 2009-06-14
Posts: 1000+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

That code is for executing Squeak commands on a sprite, such as 'self isHidden: true'
not for running Scratch blocks.

Offline

 

#7 2011-02-09 18:05:55

Billybob-Mario
Scratcher
Registered: 2008-01-05
Posts: 500+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

Is there a way to convert the blocks into Squeak commands?

Offline

 

#8 2011-02-12 10:25:09

Billybob-Mario
Scratcher
Registered: 2008-01-05
Posts: 500+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

bump

Offline

 

#9 2011-02-13 16:44:04

Billybob-Mario
Scratcher
Registered: 2008-01-05
Posts: 500+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

Rebump.

Offline

 

#10 2011-02-15 17:54:58

Billybob-Mario
Scratcher
Registered: 2008-01-05
Posts: 500+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

Can anyone help me? (more)

Offline

 

#11 2011-08-30 09:11:48

bobbybee
Scratcher
Registered: 2009-10-18
Posts: 1000+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

LS97 said that that is how you execute Squeak commands. Make an array of all of the blocks code, and then just fetch out which commands to run. (can't show you how to do it, don't know squeak)


I support the Free Software Foundation. Protect our digital rights!

Offline

 

#12 2011-08-30 09:13:22

jslomba
Scratcher
Registered: 2009-09-25
Posts: 1000+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

I have it in MegaMod  tongue


the the the the the

Offline

 

#13 2011-08-30 16:21:52

owetre18
Scratcher
Registered: 2009-07-01
Posts: 1000+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

Try this:

http://scratch.mit.edu/forums/viewtopic.php?id=61203

Works in BYOB (with some hacking, just so you know. you said your mod is based on BYON anyways, so...)

Offline

 

#14 2011-08-31 19:17:04

Billybob-Mario
Scratcher
Registered: 2008-01-05
Posts: 500+

Re: "Mind Control" Block- Sprites Making Other Sprites Do Stuff

I did it, it's already in SlasH

Offline

 

Board footer