Navigation

    CreatiCode Scratch Forum

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • CreatiCode

    3D - An Alien Dance Party (Difficulty: 1)

    Tutorials
    2
    2
    8458
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • info-creaticode
      CreatiCode last edited by admin

       

      Key Topics Covered

      • Initializing 3D scenes
      • Using avatars
      • Avatar animations
      • Camera configuration
      • Copying Objects
      • Playing drums
      • Updating object color

       
       

      Introduction

      In this tutorial, we’ll have some fun playing with dancing aliens:

      ada838b6-d69d-41b0-9144-6957c1e27d36.gif

       
       

      Step 1 - Initialize A “Grass Land” Scene with 3D Axes

      Please create a new project, and remove the dog sprite. In the “Empty1” sprite, add the green-flag block, the “initialize 3D scene” block, and the “add 3D axis” block. Note that you need to click the input box and choose the “Grass Land” scene. This is a lightweight scene with a large grassland and a blue sky.

      35e64a77-5128-4d98-9815-8751b283ad3c.gif

      As shown, the X-axis points to the right, the Y-axis points forward (into the screen), and the Z-axis points up. You can drag your mouse on the stage to rotate the camera around it:

       
       

      Step 2 - Add an alien avatar

      Avatars are human-like models that can perform various kinds of animations. Here is how to add an alien avatar:

      cac54a57-9d42-4e28-be0d-cef635c9fd73.gif

       
       

      Step 3 - Teach the alien to dance

      The alien avatar only knows how to “idle”. We need to “teach” it how to do some dancing animations by “adding animations” to it. Here is how to browse through the animations and add the “Breakdance Ready Dance” animation.

      e5a2bb60-ba31-470a-8836-0ef7b24c10be.gif

       
       

      Step 4 - Start the dance

      Now after adding the dance animation, we can start the animation at any time. By default, the animation will restart after it completes one round, so it will keep going repeatedly.

      a4ee9c6e-5d30-4f80-b92e-540d7ac602c5.gif

       
       

      Step 5 - Better position for the camera

      Since the alien is facing forward and it is quite small, we can move the camera to watch in front of the alien. We can set the distance and angle of the camera using this block:

      18ee9127-bb68-4954-bd82-8530f81651bc-image.png

       
       

      Step 6 - Copy and Move

      Next, let’s add another alien avatar. We can make a copy of it, and choose to share the data between these 2 avatars. This will make your program run faster, since all the avatars will reuse the same color and animation data.

      We also need to move the copied avatar to a different position, otherwise, it will overlap with the original avatar.

      Now we have 2 avatars that are dancing side by side:

      65250e2c-b4f0-431b-9af6-3396d344afc0.gif

       
       

      Step 7 - A Third Alien

      Next, can you try to add another alien like this?

      fc118329-0ce0-4392-9fa7-2c2e21f6cfb0.gif

      Here is one way to do it. We just need to set its X to -100 instead of 100.

       
       

      Step 8 - Dancing Beats

      Our dance party is still missing some dancing beats. We can add some drum beats to match the alien’s movement:

      7b96cb47-8abf-45fa-8adb-5b9ef209d49f-image.png

       
       

      Step 9 - Change Eye Colors

      Lastly, let’s make the aliens blink with red eyes:

      ada838b6-d69d-41b0-9144-6957c1e27d36.gif

      To make the eyes change color, you need to use the “update color” block, and select the “second” area, which represents the eyes of the avatars.

       
      In the forever loop, we can switch the eye color between black and red in between the drum beats:

      6f660556-8dbb-4164-ae83-a81583257f98-image.png

       
      Here is the final program for your reference.

       
       

      Creative Ideas

      There are many ways you can extend this project. Here are some ideas for your inspiration:

      1. Changing Body Colors: you can try to change the alien’s body color randomly on each step.

      2. More Aliens: you can try to add much more avatars, and move/rotate them to form an interesting formation.

      3. Make a New Scene: you can switch to a new scene and create something more interesting. For example, this scene looks like the 2 aliens are arguing about whether to eat pizza:

      alt text

      S 1 Reply Last reply Reply Quote 0
      • Pinned by  info-creaticode info-creaticode 
      • S
        Evan R. Sackett @info-creaticode last edited by

        @info-creaticode you should play ultrakill

        1 Reply Last reply Reply Quote 0
        • First post
          Last post