SlideShare a Scribd company logo
1 of 34
Coding with Minecraft 4:
Variables
The importance of variables
The different kinds of variables
To code a game in Minecraft with variables
Number variable – This holds numeric data.
Examples: a person’s age, a player’s score, the year
String variable – This holds a string of alphanumeric characters.
Examples: a person’s name, a password, the day of the week
Boolean variable – This has only two possible values: true or false.
Examples: Is it daytime? Is the game over?
Position variable in MakeCode – A special kind of variable that holds three
numbers that describe a specific location in three-dimensional space.
CHICKEN STORM
CHICKEN STORM
CHALLENGE 1 - MEANINGFUL
VARIABLE NAMES
• Let’s change the code so we are not using
“num1”
• The name num1 does not represent
anything meaningful and could be hard to
understand a big block of code.
• Instead, name your new variable
“ChickenNum” because the number you
store is the number of chickens.
CHALLENGE 2 - GIVING
FEEDBACK
• Let’s have the chicken rain machine
speak back to you.
• Right before you the chickens start
falling the response would be “5
Chickens! Coming right up!” Then 5
chickens will fall on your head!
CHALLENGE 2 - GIVING
FEEDBACK
To do this, you will need to…
1. Figure out how to “say” things in the
chat window
2. Use the join block to put together
ChickenNum + “ chickens! Coming
right up!”
3. Put this new block in the right location
in your code. If you put it in the wrong
spot, the chat window will respond
many times
CHALLENGE 2 - GIVING
FEEDBACK
REVIEW
• What did your variable determine in
the game?
• Why is it good coding practice to
give variables meaningful names?
To code variables in Minecraft to:
• Count things
• Keep score
• Create a report of your game’s activities
ARROW
COUNTER
ARROW
COUNTER
CHALLENGE 1 - 10
ARROWS ONLINE
CHALLENGE 2 -
PROVIDING A MESSAGE
EXTENSION 1- TARGET
PRACTICE
EXTENSION 2- HOW
MANY RABBITS?
FALLS IN THE AIR
FALLS IN THE AIR - STEP 1
FALLS IN THE AIR - STEP 2
HOW DOES THE VARIABLE
WORK?
EXTENSION 1 - TRACK SWIM
DISTANCE
To use variables in Minecraft to:
• Count things
• Keep score
• Create a report of your game’s activities
LESSON C :
COMBINING VARIABLES
Combining variables to create
messages in the sky
Check our learning progress with a quiz
Make your own unique
situations
Combine the variables to
create chains of words
Create a variable that stands
for a word
To create your own MakeCode projects
that use variables to activate different parts of
your program
INDEPENDENT
PROJECT
For this project, create an original
MakeCode project that uses multiple
variables of at least two different types,
to keep track of information in
Minecraft.
Also, find a way to use a chat
command with a parameter.
INDEPENDENT
PROJECT
Information you might store in
variables / project ideas:
• Store the number of something you spawn
• Store text for the animal you spawned
• Store your position
• Store words to put together to make
sentences.
MINECRAFT DIARY
ENTRY
• What type of information did you choose
to keep track of?
• What problems did you encounter?
How did you solve them?
• How did you use variables in your project, and
what were their types?
• What did you name your variables and why?
• What was something new that you learned for this
project? Describe how you figured
it out.
• Include at least one screenshot of your project.

More Related Content

What's hot

Virtual reality
Virtual realityVirtual reality
Virtual realitySTUDENT
 
Azure IoT Edge: a breakthrough platform and service running cloud intelligenc...
Azure IoT Edge: a breakthrough platform and service running cloud intelligenc...Azure IoT Edge: a breakthrough platform and service running cloud intelligenc...
Azure IoT Edge: a breakthrough platform and service running cloud intelligenc...Microsoft Tech Community
 
Keynote: Your Future With Cloud Computing - Dr. Werner Vogels - AWS Summit 2...
Keynote: Your Future With Cloud Computing - Dr. Werner Vogels  - AWS Summit 2...Keynote: Your Future With Cloud Computing - Dr. Werner Vogels  - AWS Summit 2...
Keynote: Your Future With Cloud Computing - Dr. Werner Vogels - AWS Summit 2...Amazon Web Services
 
ENOVIA 3Dcom Architecture
ENOVIA 3Dcom ArchitectureENOVIA 3Dcom Architecture
ENOVIA 3Dcom ArchitecturePalmV
 
Zabbix Smart problem detection - FISL 2015 workshop
Zabbix Smart problem detection - FISL 2015 workshopZabbix Smart problem detection - FISL 2015 workshop
Zabbix Smart problem detection - FISL 2015 workshopZabbix
 
Design, Deployment and Management of Unified WLAN
Design, Deployment and Management of Unified WLANDesign, Deployment and Management of Unified WLAN
Design, Deployment and Management of Unified WLANCisco Canada
 
AWS Tutorial | AWS Certified Solutions Architect | Amazon AWS | AWS Training ...
AWS Tutorial | AWS Certified Solutions Architect | Amazon AWS | AWS Training ...AWS Tutorial | AWS Certified Solutions Architect | Amazon AWS | AWS Training ...
AWS Tutorial | AWS Certified Solutions Architect | Amazon AWS | AWS Training ...Edureka!
 
How Nubank is building a customer-obsessed bank - FSV201 - New York AWS Summit
How Nubank is building a customer-obsessed bank - FSV201 - New York AWS SummitHow Nubank is building a customer-obsessed bank - FSV201 - New York AWS Summit
How Nubank is building a customer-obsessed bank - FSV201 - New York AWS SummitAmazon Web Services
 
GamingAnywhere: An Open Cloud Gaming System
GamingAnywhere: An Open Cloud Gaming SystemGamingAnywhere: An Open Cloud Gaming System
GamingAnywhere: An Open Cloud Gaming SystemAcademia Sinica
 
ROI for IP Address Management (IPAM) Solutions
ROI for IP Address Management (IPAM) SolutionsROI for IP Address Management (IPAM) Solutions
ROI for IP Address Management (IPAM) SolutionsSolarWinds
 
Power point oculus rift final
Power point oculus rift finalPower point oculus rift final
Power point oculus rift finallaurence allard
 
Securing your cloud perimeter with azure network security brk3185
Securing your cloud perimeter with azure network security brk3185Securing your cloud perimeter with azure network security brk3185
Securing your cloud perimeter with azure network security brk3185jtaylor707
 

What's hot (20)

Virtual reality
Virtual realityVirtual reality
Virtual reality
 
Azure IoT Edge: a breakthrough platform and service running cloud intelligenc...
Azure IoT Edge: a breakthrough platform and service running cloud intelligenc...Azure IoT Edge: a breakthrough platform and service running cloud intelligenc...
Azure IoT Edge: a breakthrough platform and service running cloud intelligenc...
 
Keynote: Your Future With Cloud Computing - Dr. Werner Vogels - AWS Summit 2...
Keynote: Your Future With Cloud Computing - Dr. Werner Vogels  - AWS Summit 2...Keynote: Your Future With Cloud Computing - Dr. Werner Vogels  - AWS Summit 2...
Keynote: Your Future With Cloud Computing - Dr. Werner Vogels - AWS Summit 2...
 
Introduction to Amazon EC2
Introduction to Amazon EC2Introduction to Amazon EC2
Introduction to Amazon EC2
 
ENOVIA 3Dcom Architecture
ENOVIA 3Dcom ArchitectureENOVIA 3Dcom Architecture
ENOVIA 3Dcom Architecture
 
Zabbix Smart problem detection - FISL 2015 workshop
Zabbix Smart problem detection - FISL 2015 workshopZabbix Smart problem detection - FISL 2015 workshop
Zabbix Smart problem detection - FISL 2015 workshop
 
Gaming Presentation
Gaming  PresentationGaming  Presentation
Gaming Presentation
 
Design, Deployment and Management of Unified WLAN
Design, Deployment and Management of Unified WLANDesign, Deployment and Management of Unified WLAN
Design, Deployment and Management of Unified WLAN
 
AWS Tutorial | AWS Certified Solutions Architect | Amazon AWS | AWS Training ...
AWS Tutorial | AWS Certified Solutions Architect | Amazon AWS | AWS Training ...AWS Tutorial | AWS Certified Solutions Architect | Amazon AWS | AWS Training ...
AWS Tutorial | AWS Certified Solutions Architect | Amazon AWS | AWS Training ...
 
How Nubank is building a customer-obsessed bank - FSV201 - New York AWS Summit
How Nubank is building a customer-obsessed bank - FSV201 - New York AWS SummitHow Nubank is building a customer-obsessed bank - FSV201 - New York AWS Summit
How Nubank is building a customer-obsessed bank - FSV201 - New York AWS Summit
 
Azure serverless computing
Azure serverless computingAzure serverless computing
Azure serverless computing
 
Cloud Gaming
Cloud GamingCloud Gaming
Cloud Gaming
 
AR VS VR.pptx
AR VS VR.pptxAR VS VR.pptx
AR VS VR.pptx
 
AR-VR Workshop
AR-VR WorkshopAR-VR Workshop
AR-VR Workshop
 
GamingAnywhere: An Open Cloud Gaming System
GamingAnywhere: An Open Cloud Gaming SystemGamingAnywhere: An Open Cloud Gaming System
GamingAnywhere: An Open Cloud Gaming System
 
AWS VPC Fundamentals- Webinar
AWS VPC Fundamentals- WebinarAWS VPC Fundamentals- Webinar
AWS VPC Fundamentals- Webinar
 
ROI for IP Address Management (IPAM) Solutions
ROI for IP Address Management (IPAM) SolutionsROI for IP Address Management (IPAM) Solutions
ROI for IP Address Management (IPAM) Solutions
 
Power point oculus rift final
Power point oculus rift finalPower point oculus rift final
Power point oculus rift final
 
Securing your cloud perimeter with azure network security brk3185
Securing your cloud perimeter with azure network security brk3185Securing your cloud perimeter with azure network security brk3185
Securing your cloud perimeter with azure network security brk3185
 
ICT Security.pdf
ICT Security.pdfICT Security.pdf
ICT Security.pdf
 

Similar to Lesson 3 - Coding with Minecraft - Variables.pptx

RBuilder and ByteSurgeon
RBuilder and ByteSurgeonRBuilder and ByteSurgeon
RBuilder and ByteSurgeonMarcus Denker
 
Intro to javascript (5:2)
Intro to javascript (5:2)Intro to javascript (5:2)
Intro to javascript (5:2)Thinkful
 
Intro to javascript (6:19)
Intro to javascript (6:19)Intro to javascript (6:19)
Intro to javascript (6:19)Thinkful
 
Visual basic intoduction
Visual basic intoductionVisual basic intoduction
Visual basic intoductionSpy Seat
 
Scratch for intermediates course
Scratch for intermediates courseScratch for intermediates course
Scratch for intermediates courseMatthew Parry
 
Intro to javascript (6:27)
Intro to javascript (6:27)Intro to javascript (6:27)
Intro to javascript (6:27)David Coulter
 
Python part two names and types
Python part two names and typesPython part two names and types
Python part two names and typesgrahamwell
 
Thinkful - Intro to JavaScript
Thinkful - Intro to JavaScriptThinkful - Intro to JavaScript
Thinkful - Intro to JavaScriptTJ Stalcup
 
Visual Basic Review - ICA
Visual Basic Review - ICAVisual Basic Review - ICA
Visual Basic Review - ICAemtrajano
 
Lecture 2: C# Programming for VR application in Unity
Lecture 2: C# Programming for VR application in UnityLecture 2: C# Programming for VR application in Unity
Lecture 2: C# Programming for VR application in UnityKobkrit Viriyayudhakorn
 
C# 101: Intro to Programming with C#
C# 101: Intro to Programming with C#C# 101: Intro to Programming with C#
C# 101: Intro to Programming with C#Hawkman Academy
 
Section1 compound data class
Section1 compound data classSection1 compound data class
Section1 compound data classDương Tùng
 
Intro to JavaScript - Thinkful LA, June 2017
Intro to JavaScript - Thinkful LA, June 2017Intro to JavaScript - Thinkful LA, June 2017
Intro to JavaScript - Thinkful LA, June 2017Thinkful
 

Similar to Lesson 3 - Coding with Minecraft - Variables.pptx (15)

RBuilder and ByteSurgeon
RBuilder and ByteSurgeonRBuilder and ByteSurgeon
RBuilder and ByteSurgeon
 
Intro to javascript (5:2)
Intro to javascript (5:2)Intro to javascript (5:2)
Intro to javascript (5:2)
 
Week 1
Week 1Week 1
Week 1
 
Intro to javascript (6:19)
Intro to javascript (6:19)Intro to javascript (6:19)
Intro to javascript (6:19)
 
Visual basic intoduction
Visual basic intoductionVisual basic intoduction
Visual basic intoduction
 
Scratch for intermediates course
Scratch for intermediates courseScratch for intermediates course
Scratch for intermediates course
 
Intro to javascript (6:27)
Intro to javascript (6:27)Intro to javascript (6:27)
Intro to javascript (6:27)
 
Python part two names and types
Python part two names and typesPython part two names and types
Python part two names and types
 
Variables
VariablesVariables
Variables
 
Thinkful - Intro to JavaScript
Thinkful - Intro to JavaScriptThinkful - Intro to JavaScript
Thinkful - Intro to JavaScript
 
Visual Basic Review - ICA
Visual Basic Review - ICAVisual Basic Review - ICA
Visual Basic Review - ICA
 
Lecture 2: C# Programming for VR application in Unity
Lecture 2: C# Programming for VR application in UnityLecture 2: C# Programming for VR application in Unity
Lecture 2: C# Programming for VR application in Unity
 
C# 101: Intro to Programming with C#
C# 101: Intro to Programming with C#C# 101: Intro to Programming with C#
C# 101: Intro to Programming with C#
 
Section1 compound data class
Section1 compound data classSection1 compound data class
Section1 compound data class
 
Intro to JavaScript - Thinkful LA, June 2017
Intro to JavaScript - Thinkful LA, June 2017Intro to JavaScript - Thinkful LA, June 2017
Intro to JavaScript - Thinkful LA, June 2017
 

More from missstevenson01

Lesson 2 - Coding with Minecraft - Events.pptx
Lesson 2 - Coding with Minecraft - Events.pptxLesson 2 - Coding with Minecraft - Events.pptx
Lesson 2 - Coding with Minecraft - Events.pptxmissstevenson01
 
Lesson 1 - Coding with Minecraft -Introduction.pptx
Lesson 1 - Coding with Minecraft -Introduction.pptxLesson 1 - Coding with Minecraft -Introduction.pptx
Lesson 1 - Coding with Minecraft -Introduction.pptxmissstevenson01
 
Lesson2 - Coding with Minecraft - Events.pptx
Lesson2 - Coding with Minecraft - Events.pptxLesson2 - Coding with Minecraft - Events.pptx
Lesson2 - Coding with Minecraft - Events.pptxmissstevenson01
 
Ethical hacking trojans, worms and spyware
Ethical hacking    trojans, worms and spywareEthical hacking    trojans, worms and spyware
Ethical hacking trojans, worms and spywaremissstevenson01
 
Ethical hacking anti virus
Ethical hacking   anti virusEthical hacking   anti virus
Ethical hacking anti virusmissstevenson01
 
Ethical hacking introduction to ethical hacking
Ethical hacking   introduction to ethical hackingEthical hacking   introduction to ethical hacking
Ethical hacking introduction to ethical hackingmissstevenson01
 
S1 internet safety-chattingonline
S1 internet safety-chattingonlineS1 internet safety-chattingonline
S1 internet safety-chattingonlinemissstevenson01
 
Video Games and Copyright laws
Video Games and Copyright lawsVideo Games and Copyright laws
Video Games and Copyright lawsmissstevenson01
 

More from missstevenson01 (20)

S3 environment
S3 environmentS3 environment
S3 environment
 
The Processor.pptx
The Processor.pptxThe Processor.pptx
The Processor.pptx
 
How Computers Work
How Computers WorkHow Computers Work
How Computers Work
 
Lesson 2 - Coding with Minecraft - Events.pptx
Lesson 2 - Coding with Minecraft - Events.pptxLesson 2 - Coding with Minecraft - Events.pptx
Lesson 2 - Coding with Minecraft - Events.pptx
 
Lesson 1 - Coding with Minecraft -Introduction.pptx
Lesson 1 - Coding with Minecraft -Introduction.pptxLesson 1 - Coding with Minecraft -Introduction.pptx
Lesson 1 - Coding with Minecraft -Introduction.pptx
 
Lesson2 - Coding with Minecraft - Events.pptx
Lesson2 - Coding with Minecraft - Events.pptxLesson2 - Coding with Minecraft - Events.pptx
Lesson2 - Coding with Minecraft - Events.pptx
 
Ethical hacking trojans, worms and spyware
Ethical hacking    trojans, worms and spywareEthical hacking    trojans, worms and spyware
Ethical hacking trojans, worms and spyware
 
Ethical hacking anti virus
Ethical hacking   anti virusEthical hacking   anti virus
Ethical hacking anti virus
 
Ethical hacking introduction to ethical hacking
Ethical hacking   introduction to ethical hackingEthical hacking   introduction to ethical hacking
Ethical hacking introduction to ethical hacking
 
S1 internet safety-chattingonline
S1 internet safety-chattingonlineS1 internet safety-chattingonline
S1 internet safety-chattingonline
 
S3 wireframe diagrams
S3 wireframe diagramsS3 wireframe diagrams
S3 wireframe diagrams
 
Sql
SqlSql
Sql
 
Alien database
Alien databaseAlien database
Alien database
 
Video Games and Copyright laws
Video Games and Copyright lawsVideo Games and Copyright laws
Video Games and Copyright laws
 
Games Design Document
Games Design DocumentGames Design Document
Games Design Document
 
Video game proposal
Video game proposalVideo game proposal
Video game proposal
 
Evaluation
EvaluationEvaluation
Evaluation
 
H evaluation
H evaluationH evaluation
H evaluation
 
H testing and debugging
H testing and debuggingH testing and debugging
H testing and debugging
 
H file handling
H file handlingH file handling
H file handling
 

Recently uploaded

MENTAL STATUS EXAMINATION format.docx
MENTAL     STATUS EXAMINATION format.docxMENTAL     STATUS EXAMINATION format.docx
MENTAL STATUS EXAMINATION format.docxPoojaSen20
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppCeline George
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxOH TEIK BIN
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...M56BOOKSTORE PRODUCT/SERVICE
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting DataJhengPantaleon
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsanshu789521
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13Steve Thomason
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxRoyAbrique
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionSafetyChain Software
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Science 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsScience 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsKarinaGenton
 

Recently uploaded (20)

TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
MENTAL STATUS EXAMINATION format.docx
MENTAL     STATUS EXAMINATION format.docxMENTAL     STATUS EXAMINATION format.docx
MENTAL STATUS EXAMINATION format.docx
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website App
 
Staff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSDStaff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSD
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptx
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha elections
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13
 
9953330565 Low Rate Call Girls In Rohini Delhi NCR
9953330565 Low Rate Call Girls In Rohini  Delhi NCR9953330565 Low Rate Call Girls In Rohini  Delhi NCR
9953330565 Low Rate Call Girls In Rohini Delhi NCR
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
 
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
Science 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsScience 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its Characteristics
 

Lesson 3 - Coding with Minecraft - Variables.pptx

  • 1. Coding with Minecraft 4: Variables
  • 2.
  • 3. The importance of variables The different kinds of variables To code a game in Minecraft with variables
  • 4. Number variable – This holds numeric data. Examples: a person’s age, a player’s score, the year String variable – This holds a string of alphanumeric characters. Examples: a person’s name, a password, the day of the week Boolean variable – This has only two possible values: true or false. Examples: Is it daytime? Is the game over? Position variable in MakeCode – A special kind of variable that holds three numbers that describe a specific location in three-dimensional space.
  • 7. CHALLENGE 1 - MEANINGFUL VARIABLE NAMES • Let’s change the code so we are not using “num1” • The name num1 does not represent anything meaningful and could be hard to understand a big block of code. • Instead, name your new variable “ChickenNum” because the number you store is the number of chickens.
  • 8. CHALLENGE 2 - GIVING FEEDBACK • Let’s have the chicken rain machine speak back to you. • Right before you the chickens start falling the response would be “5 Chickens! Coming right up!” Then 5 chickens will fall on your head!
  • 9. CHALLENGE 2 - GIVING FEEDBACK To do this, you will need to… 1. Figure out how to “say” things in the chat window 2. Use the join block to put together ChickenNum + “ chickens! Coming right up!” 3. Put this new block in the right location in your code. If you put it in the wrong spot, the chat window will respond many times
  • 10. CHALLENGE 2 - GIVING FEEDBACK
  • 11. REVIEW • What did your variable determine in the game? • Why is it good coding practice to give variables meaningful names?
  • 12.
  • 13. To code variables in Minecraft to: • Count things • Keep score • Create a report of your game’s activities
  • 16. CHALLENGE 1 - 10 ARROWS ONLINE
  • 21. FALLS IN THE AIR - STEP 1
  • 22. FALLS IN THE AIR - STEP 2
  • 23. HOW DOES THE VARIABLE WORK?
  • 24. EXTENSION 1 - TRACK SWIM DISTANCE
  • 25. To use variables in Minecraft to: • Count things • Keep score • Create a report of your game’s activities
  • 26. LESSON C : COMBINING VARIABLES
  • 27. Combining variables to create messages in the sky Check our learning progress with a quiz
  • 28. Make your own unique situations Combine the variables to create chains of words Create a variable that stands for a word
  • 29.
  • 30.
  • 31. To create your own MakeCode projects that use variables to activate different parts of your program
  • 32. INDEPENDENT PROJECT For this project, create an original MakeCode project that uses multiple variables of at least two different types, to keep track of information in Minecraft. Also, find a way to use a chat command with a parameter.
  • 33. INDEPENDENT PROJECT Information you might store in variables / project ideas: • Store the number of something you spawn • Store text for the animal you spawned • Store your position • Store words to put together to make sentences.
  • 34. MINECRAFT DIARY ENTRY • What type of information did you choose to keep track of? • What problems did you encounter? How did you solve them? • How did you use variables in your project, and what were their types? • What did you name your variables and why? • What was something new that you learned for this project? Describe how you figured it out. • Include at least one screenshot of your project.