Page 74 - IT_V5.0_Class7
P. 74

Block                                Explanation
                                                        Reports the y position of the mouse pointer.



                                                        Sets the drag mode of the  sprite to draggable or  not
                                                        draggable.

                                                        Reports the loudness of the sound input.



                                                        Reports the value of the timer.



                                                        Resets the timer to zero.



                                                        Reports the number of the current backdrop of the Stage.



                                                        Reports the current  year,  month, date,  day of the week,
                                                        hour, minute, or second.

                                                        Reports the number of days since January 1, 2000.



                                                        Reports the username of the person using the project.



                  Example 10: When the Green Flag is clicked, the sprite asks, ‘What’s your name?’ and waits for
                  a response. Once the name is entered, the sprite becomes draggable, allowing users to move it
                  around the stage. The entered name is displayed when the Enter key is pressed.

                  Follow the given steps:
                  Step 1:  Drag and drop the when clicked block to the script area.

                  Step 2:   Drag the ask and wait block from the Sensing blocks category and drop it below the
                            when clicked block.
                  Step 3:  Drag the set drag mode block and drop it below the ask and wait block.

                  Step 4:   Drag the say block from the Looks category and drop it below the set drag mode
                            block.
                  Step 5:  Drag the answer block from the Sensing category and drop it inside the say block.

                  Step 6:  Click on the Green Flag button.

                  Step 7:   Type your name and click on the tick or press the Enter key. The entered name appears
                            in the speech bubble.








                    72    Information Technology (V5.0)-VII
   69   70   71   72   73   74   75   76   77   78   79