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

#1 2013-04-05 10:38:45

liam48D
Scratcher
Registered: 2013-02-18
Posts: 33

define more specific

define should allow you to make operators. Like

define (invisible?)
if<[ghost v] > 100>
 true
else
 false
end
That should be helpful to add.

Offline

 

#2 2013-04-05 11:05:53

northmeister
Scratcher
Registered: 2011-07-12
Posts: 1000+

Re: define more specific

Variables aren't just "true" or "false". Just do:

if <(ghost) > [100]> //Have another script changing "ghost" whenever the effect changes.
  set [invisible v] to (1)
else
  set [invisible v] to (0)
in that case


http://i48.tinypic.com/5a25g5.png

Offline

 

#3 2013-04-05 18:51:29

veggieman001
Scratcher
Registered: 2010-02-20
Posts: 1000+

Re: define more specific

northmeister wrote:

Variables aren't just "true" or "false". Just do:

if <(ghost) > [100]> //Have another script changing "ghost" whenever the effect changes.
  set [invisible v] to (1)
else
  set [invisible v] to (0)
in that case

he's talking about custom booleans
the scratch team have actually stated several times that custom reporters and booleans (as opposed to just stack blocks) will be in a future version of scratch (most likely 2.1)


Posts: 20000 - Show all posts

Offline

 

Board footer