[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: LOGO-L> questions about MSWLogo



Your code is not completely fixed, I'll let you clean up the rest.

But I did a couple things and have a few comments to get you going.

In MSWLogo you can independently control the "FILL" color with SETFC.
Second is that your not *inside* your triangle at the time
you fill (I ran it with 3 sides 3 levels). It's right on the very edge
which is unstable. How did I find this problem?
I turned on ST and added a PAUSE command right before the FILL.
So I can see exactly what's going on (STOP would of also worked).

I also reworked your code to use QUESTIONBOX instead of RW.

Regarding your other question about MESSAGEBOX being in the center.
You cannot control its position. But you can control the scrollers with
SCROLLX or SCROLLY. Or you can write your own "MESSAGEBOX" which you
can specify its placement. See "WINDOWS FUNCTIONS" in online help
it is a large subject. I have also placed a WAIT before a messagebox
so that the user can see the graphics before the box pops up.
MESSAGEBOX in the center is a common complaint.

to fil
pu rt :a fd :size*.6 pd
pause
fill pu bk :size*.6 lt :a pd 
setfc (list 20* :lev 0 0) 
;setpc :lev
end

to go 
make "n first questionbox [Input number of sides (3-6)] []
make "lev first questionbox [Input number of levels (3-5)] []
make "c 180/ :n make "a 90- :c st cs   
poly_star 200 :n :lev 
end

to poly_star :size :n :lev
if :lev =0 [stop]
repeat :n [
setfc (list 0 30* repcount 0)
;setpc repcount
fd :size/ 4 poly_star :size/3 :n :lev-1 fd :size/ 2 rt 360/ :n ]
fil 
end

MHELHEFNY@FRCU.EUN.EG wrote:
> 
> ;Hello George Mills
> ;I have two questions about MSWLogo. Since I am actually new to its
> ;use. As you may remember I told you that I downloaded it on september 11
> ;These questions are:-
> ;>First question:
> ;I ran the simple and elegant code that you proposed as demo named "all"
> ;to introduce 3-d to kidds. I agree with you that 3-d is important
> ;and nessecary especially for kidds. But when runing it I have found
> ;that the message box where I should click; had hided the square which
> ;I should see. I tried to drag the message box to another position
> ;but it jumbed back to its same position (0 0 0). My question is there
> ;any meens to place such message box at another position?
> ;>Second question:
> ;Beeing new to MSWLogo I have trouble with colour filling even if I
> ;did not turnon3d .
> ;The following code runs perfectly in UCBLogo.I made many trials to
> ;run it in MSWLogo. All my trials had failed; is there some thing that
> ;I have missed?
> ;Best Regards
> ;Mhelhefny
> ;-------------------------------------------------------------------
> to fil
> pu rt :a fd :size*.6 pd fill pu bk :size*.6 lt :a pd
> ;setpc (list 20* :lev 0 0)
> setpc :lev
> end
> 
> to go
> type [input number of side s(3- 6)  : ] type char 9 make "n rw
> type [input number of levels(3- 5)  : ] type char 9 make "lev rw
> make "c 180/ :n make "a 90- :c ht cs
> poly_star 200 :n :lev
> end
> 
> to poly_star :size :n :lev
> if :lev =0 [stop]
> repeat :n [
> ;setpc (list 0 30* repcount 0)
> setpc repcount
> fd :size/ 4 poly_star :size/3 :n :lev-1 fd :size/ 2 rt 360/ :n ]
> fil
> end
> ;------------------------------------------------------------
> ---------------------------------------------------------------
> Please post messages to the Logo forum to logo-l@gsn.org.  Mail
> questions about the list administration to logofdn@gsn.org.  To
> unsubscribe send    unsubscribe logo-l    to majordomo@gsn.org.

-- 
===============================================================
George Mills (mills@softronix.com)
http://www.softronix.com/
The www page contains some very powerful educational software.
Our single most important investment is our kids.





---------------------------------------------------------------
Please post messages to the Logo forum to logo-l@gsn.org.  Mail
questions about the list administration to logofdn@gsn.org.  To
unsubscribe send    unsubscribe logo-l    to majordomo@gsn.org.



Global SchoolNet Foundation - Linking Kids Around the World!
Copyright GSN - All Rights Reserved - Comments & Questions
Visit GSN's Global Schoolhouse for more exciting learning resources!
Search our Site - Home