Microsoft MakeCode

Transcription

Microsoft MakeCodeWednesday May 20th, 20207:30–8:00am PTArcade Part 1—Blocks

Microsoft Code of ConductMicrosoft’s mission is to empower every person and every organization on the planet to achieve more. Thisincludes all Microsoft events and gatherings, including on digital platforms, where we seek to create arespectful, friendly, fun and inclusive experience for all participants.We expect all digital event participants to uphold the principles of this Code of Conduct, which covers themain digital event and all related activities. We do not tolerate disruptive or disrespectful behavior, messages,images, or interactions by any party participant, in any form, at any aspect of the program including businessand social activities, regardless of location.Microsoft will not tolerate harassment or discrimination based on age, ancestry, color, gender identity orexpression, national origin, physical or mental disability, religion, sexual orientation, or any othercharacteristic protected by applicable local laws, regulations, and ordinances.We encourage everyone to assist in creating a welcoming and safe environment. Please report any concerns,harassing behavior, suspicious, or disruptive activity to Business Conduct Hotline (1-877-320-MSFT orbuscond@microsoft.com). Microsoft reserves the right to refuse admittance to or remove any person fromMicrosoft Build at any time at its sole discretion.

MakeCode TeamPeli de Halleux@pelikhanJacqueline Russell@jaqsterJoey Wunderlich@joeywunderl

MakeCode Arcade home pageImport Projects(via a File, URL, Repo)Create a Newblank ProjectStep-by-stepTutorialsGame examplesOpen yourrecent Projects

Mod Eat the Fruit GameEat the Fruit—move your sprite around the screen and eat asmuch fruit as you can before the time runs out!

Create a new Project

Getting familiar with MakeCode x

Set the background From the Scene Toolbox drawer, drag a Set Background Coloronto the Workspace Drop into the On Start blockPick abackgroundcolor

Create a Player Sprite From the Sprites Toolbox drawer, drag a Set sprite block ontothe Workspace Drop into the On Start block after the Set Background block

Switch between Editor and Galleryof existing Sprite designsEraserPencil ct an areaand moveShortcutcolors16 ColorPaletteUndo/RedoCanvas SizeZoom

Control the movement of your Sprite From the Controller Toolbox drawer, drag a Move block ontothe Workspace Drop into the On Start block after the Set sprite block

Try it out in Simulator Click on the joystick buttons inthe Simulator to move yourSprite around the screen Or use the arrow keys on thekeyboard (make sure the mouseis hovered over the Simulator toactivate controls)

Keep Sprite in screen

Initialize Score and Start Countdown

Create a flying fruit Sprite From the Game Toolbox drawer, drag a On Game Update Everyblock onto the Workspace From the Sprites Toolbox drawer, drag a Set Projectile fromside block into the On Game Update Every block Set vx to 50 and vy to 0

Velocity speed and direction– vy– vx vx vy

Draw a Fruit Sprite(or pick one from the Gallery)

Set the fruit starting position From the Sprites Toolbox drawer, drag a Set Position block intothe On Game Update Every block Change mySprite variable to projectile

CoordinatesThe Arcade game screendimensions are 160 widthx 120 height(0, 0)x(160, 0)y(0, 120)(160, 120)

Set the fruit starting position From the Math Toolbox drawer, drag a Pick Random block, anddrop into the y field of the Set Position block In Pick Random block, change maximum value to 120

Add a point when you eat fruit From the Sprites Toolbox drawer, under the Overlaps category,drag an On Sprite Overlaps block onto the Workspace Change the second kind to Projectile

Add a point when you eat fruit From Info Toolbox drawer, add Change Score block

Destroy the Fruit From the Sprites Toolbox drawer, add Destroy mySprite block Drag the otherSprite local variable block into the Destroy block

Add effects and music In the Destroy block, click the plus ( ) icon Select an effect to play From the Music Toolbox drawer, drag a Play Sound block intothe On Sprite Overlaps block

Complete Program

Other mod options Change the Fruit or Junk food Sprites Add other types of Food for different points Change how often each type of food appears Change the speed of the food or player Change the direction of the food sprites

Share your game!Click the Share button in the top left of the screenName your GameTake a screenshotof your GameClick toPublishShare on Facebook, Twitter or Email URLPlay on your Phone!

Arcade hardwarearcade.makecode.com/hardware

Arcade cabinets

ResourcesOnline Learninghttps://makecode.com/online-learning

Microsoft student resources can be found at the GitHub repository forfurther learning opportunities.aka.ms/StudentsAtBuildMicrosoft Learn for Students is the place to develop practical skills throughfun, interactive modules and paths. Plus, educators can get access to Microsoftclassroom materials and curriculum. Find it all at: aka.ms/learnforstudentsWhat next?Azure for Students gives you 100 in credit on the Azure Cloud. Build yourskills in trending tech including data science, artificial intelligence (AI),machine learning, and other areas with access to professional developer tools.Start here: aka.ms/azureforstudentsImagine Cup is more than just a competition—you can work with friends (andmake new ones), network with professionals, gain new skills, make a differencein the world around you, and get the chance to win cash and cloud credits.To find out more: Higher education students: imaginecup.com/. Educators ofstudents ages 13–18 start with Imagine Cup Jr.Microsoft Student Learn Ambassadors are a global group of campus leaders whoare eager to help fellow students, lead in their local tech community, and developtechnical and career skills for the future.Learn more at: studentambassadors.microsoft.com/

LinksAbout MakeCode—aka.ms/makecodeOnline MakeCode editors—makecode.comBuy hardware—aka.ms/makecodestartArcade curriculum—arcade.makecode.com/coursesMakeCode Forum—forum.makecode.com

Thank you!

Copyright Microsoft Corporation. All rights reserved.

Microsoft Learn for Students is the place to develop practical skills through fun, interactive modules and paths. Plus, educators can get access to Microsoft classroom materials and curriculum. Find it all at: aka.ms/learnforstudents Azure for Students gives you 100 in credit on the Azure Cloud. Build your