[MWForum]Microworld's EX a bug in reworked 'squish' game

Daniel Ajoy mwforum@lists.mathcats.com
Tue, 08 Feb 2005 13:25:59 -0500


On 8 Feb 2005 at 10:30, Gabrielle Doyle wrote:

> My son redeveloped the Microworlds EX sample game to look 
> like the one in the attachment this is the third such game 
> that he's made. With the first time there were no major 
> bugs but in the last two we keep getting an error message 
> in the command centre that says;
> I don't know how to homebase in raiselevel
> 
> I have tried to erase the raiselevel procedure since the 
> game 'works' with out it but the same messagge still 
> occurs. I have checked the turtles back back but I can't 
> see any differnce betwwn it and my son's first game that 
> works. I'ves tried to reset a homebase, and we've changed 
> the values in the speed slider. 
> 
> The error message appears in an error box in the webplyer 
> mode making the game unplayable.
> 
> I cannot see what is wrong, can anyone help me?

Hi Gabrielle,

There is a turtle named Fred that has a variable
named homebase it seems to be a coordinate pair.
Fred also has the following an OnColor rule:

setpos homebase setspeed speed + 1


If I disable the "setpos homebase" instruction
in the raiselevel procedure 
placing a ";" before it...

to raiselevel
;setpos homebase 
if speed > 39 [stop]
setspeed speed + 1
end


All I get is this kind of error:

setspeed does not like 11 as input in raiselevel

Why? Because The slider maximum value is set to 10.


> I have tried to erase the raiselevel procedure since the 
> game 'works' with out it but the same messagge still 
> occurs. 

Does this change help?

to raiselevel
fred, setpos homebase
if speed > 39 [stop]
setspeed speed + 1
end


Daniel
OpenWorld Learning
http://mia.openworldlearning.org