Game Hungry shark bagian 1 | Tutorial Scratch
Summary
TLDRIn this engaging tutorial, the instructor walks viewers through creating a simple 'shark eating small fish' game in Scratch. The video covers how to design the shark and fish sprites, animate the shark to follow the mouse pointer, and make the fish disappear and reappear at random positions. The instructor explains each step with clear instructions, helping beginners learn game mechanics like sprite manipulation, animation, and event handling. The tutorial concludes by encouraging viewers to add their own features, such as a score counter and obstacles, to enhance the gameplay experience.
Takeaways
- 😀 Start by deleting the default sprite (T-shirt Red) and add a shark sprite for the game.
- 😀 Adjust the shark sprite's name and position to set it up correctly in the game environment.
- 😀 Use basic motion blocks like 'Move 10 steps' and 'Point towards mouse pointer' to make the shark follow the mouse.
- 😀 Implement the 'Forever' block to keep the shark moving continuously as long as the green flag is clicked.
- 😀 Introduce an 'if' statement to control the shark’s movement, ensuring it only moves when touching the mouse pointer.
- 😀 Create an animation for the shark eating the small fish by using different costumes (e.g., mouth opening).
- 😀 Program the small fish to disappear when touched by the shark using the 'Hide' block.
- 😀 Make the small fish reappear in a random position on the screen using the 'Go to random position' block.
- 😀 Add a brief delay (e.g., 0.3 seconds) to avoid the fish reappearing too quickly after being eaten.
- 😀 Change the appearance of the fish by using 'Next costume' to create variety and enhance the game experience.
- 😀 Encourage students to customize the game further by adding additional features like score tracking or obstacles for more challenge.
Q & A
What is the purpose of the 'point toward' block in this game?
-The 'point toward' block makes the shark sprite follow the mouse pointer. This ensures the shark always moves in the direction of the mouse, simulating the behavior of the shark chasing the pointer.
Why does the shark stop moving when it touches the mouse pointer?
-The shark stops moving when it touches the mouse pointer due to the 'if' condition in the script, which checks if the shark is not touching the pointer. If it is, the shark halts its movement, giving the effect of the shark 'pausing' when it reaches the mouse.
How can we make the shark move when not touching the mouse pointer?
-To make the shark move when not touching the mouse pointer, an 'if' condition is used with a 'not touching mouse pointer' check. This allows the shark to continue moving freely unless it is touching the pointer.
What is the purpose of the 'forever' loop in the script?
-The 'forever' loop ensures that the shark's movement and other actions continue running indefinitely. It repeats the movement and check conditions continuously throughout the game, making the behavior seamless during gameplay.
Why is there a need to change the fish's costume when it is eaten?
-Changing the fish's costume when it is eaten helps to animate the action, giving the player feedback that the shark has successfully consumed the fish. It also enhances the visual appeal by simulating the opening and closing of the shark's mouth.
What is the 'go to random position' block used for in the game?
-The 'go to random position' block is used to make the fish reappear at a different location on the screen after being eaten by the shark. This adds randomness to the game and makes it more challenging as the player must catch the fish in various locations.
How can we control the speed of the fish disappearing and reappearing?
-The speed of the fish disappearing and reappearing is controlled by using the 'wait' block after the 'hide' and 'go to random position' blocks. This adds a delay between the fish hiding and showing up in a new location, preventing it from happening too quickly.
What additional features could be added to this game in the future?
-Future features could include adding a score counter to track the number of fish eaten, health points or lives for the shark, and obstacles like other fish or objects to avoid. The game could also be made more difficult by increasing the shark's speed or introducing new fish with different behaviors.
How do you add sound effects to the game?
-Sound effects can be added by using the 'Sound' blocks in Scratch. These blocks allow you to play specific sounds when certain actions occur, such as when the shark eats a fish or moves. Sounds help improve the game experience and make it more interactive.
Why is it important to use the 'not' operator in the shark's movement script?
-The 'not' operator is used to invert the condition, meaning the shark will move freely only when it is not touching the mouse pointer. Without this, the shark would stop moving as soon as it reached the mouse, making the gameplay feel unnatural and static.
Outlines
此内容仅限付费用户访问。 请升级后访问。
立即升级Mindmap
此内容仅限付费用户访问。 请升级后访问。
立即升级Keywords
此内容仅限付费用户访问。 请升级后访问。
立即升级Highlights
此内容仅限付费用户访问。 请升级后访问。
立即升级Transcripts
此内容仅限付费用户访问。 请升级后访问。
立即升级浏览更多相关视频
JUMP GAME DI SCRATCH | JUMPING GAME SCRATCH | MAPEL INFORMATIKA
Membuat Game Arcade 2D dengan Pygame (Part 1) || Python
Balloon Shooting Game with Python
Game hungry shark Bagian 4|Tutorial Scratch
Lecture: 14 | WATER BOAT GAME IN SCRATCH | GAME DEVELOPMENT | SCRATCH TUTORIAL
3D ENDLESS RUNNER IN UNITY - COINS (Pt 4)
5.0 / 5 (0 votes)