[Intro to Python as a First Language] Functions, 'for', lists, & libraries; Pokemon gets AI!

Channel:
Subscribers:
851
Published on ● Video Link: https://www.youtube.com/watch?v=js3y5mlTqdQ



Duration: 2:31:17
57 views
3


In this episode, we're continuing our development of the 'Pokemon' example, where two creatures face off in a simple RPG reminiscent of the Game Boy classic.

First, we set off to simplify the code by way of functions -- and, while it doesn't work out exactly like I hoped, we still discuss, at length, how to define and use functions, including the importance of 'arguments' and 'return values'.

Next, we discuss a new data-type for our project: lists! Previously, we'd discussed integers, strings, and booleans, but lists are a powerful way to store, organize, and access information, and are useful for 'for' loops!

Finally, we briefly discuss how libraries are imported and used, and we bring in 'random' so that our former 'pokebot' can be upgraded to a fully-fledged Pokemon that fights back by choosing a random attack! This makes combat much more dangerous. T_T

If you're enjoying the series, come check us out live, and feel free to ask questions here in the comments or on the Discord server at http://vencabot.com ! Also check out this and other projects over at http://github.com/vencabot/intro_to_python .

Keep the good times rolling at https://www.patreon.com/vencabot
Watch the show live at https://www.twitch.tv/vencabot
Hang with us on Discord using https://discordapp.com/invite/Y2tETWA
Keep up-to-date at https://twitter.com/vencabot




Other Videos By Vencabot


2018-11-02[Demon's Souls] Ep. 5: "Armor Spider! Deeper Into the Mines, Senseless Killing Boogaloo!"
2018-11-01[3rd Strike] 06/28/18: DaRage vs Venca megathon! Triple threat action, 'Patch' my ass!
2018-10-31[God of War (2005)] Ep. 9: "Iron Man If Iron Man Were a Minotaur, Kissy-Kissy Lips Boogaloo!"
2018-10-30[3rd Strike] 06/27/18: FT10 - Crime_Alley vs Venca! Blank_Delay's Oro, Swirlyglass's Ryu!
2018-10-29[Intro to Python as a First Language] 'class' basics: attributes & methods, w/ Pokemon!
2018-10-28[3rd Strike] 06/26/18: FT1O - Shodokan vs Venca! Twins battle! Alex's Makoto trouble
2018-10-27[Gunbound] Apples, you BUNGER!! Dixx and Venca demonstrate high-level play
2018-10-26[3rd Strike] 06/26/18: Alex vs Ken vs Ibuki, 1xide's Yang arrives. Steam version is booboo.
2018-10-25[Demon's Souls] Ep. 4: "Look at this $%^&ing SWORD!! Stonefang Tunnel Boogaloo!"
2018-10-24[3rd Strike] 06/26/18: All Ranked, all episode! PinkGiSeanIsTopTier!
2018-10-23[Intro to Python as a First Language] Functions, 'for', lists, & libraries; Pokemon gets AI!
2018-10-21[3rd Strike] 06/25/18: Threevenge training, Pyteria cracking heads, styx_diver's Ibuki!
2018-10-20[God of War (2005)] Ep. 8: "Narrow Beam Balancing, Nearing Maximum Rage Boogaloo"
2018-10-19[3rd Strike] 06/21/18: Defensive Alex & KreichJr's sickening Ken. Awaken, Crime's Q!
2018-10-18[Sonic Spinball (GG)] G-$%^&ing-G! Legends never die... They go 8-bit!
2018-10-17[3rd Strike] 06/20/18: FT10: Venca / bm717252, Threevenge growin' skills, G-Type switches!
2018-10-16[Demon's Souls] Ep. 3: "This Dragon is 100% a Dick, Tower Knight Boogaloo!"
2018-10-15[3rd Strike] 06/20/18: bm717252 and Rock_mty: Two Dudleys clash! Ibumizu's Urien
2018-10-14[Intro to Python as a First Language] Pokemon example, the very basics. Code along! :D
2018-10-13[3rd Strike] 06/19/18: FT10: Venca / Rock_mty! DiddlyBukes, ggwprekt143, osirus bring it!
2018-10-12[Pizza & Cartoons] Ep. 2: Betty Boop is problematic. It's like that, Pudgy-Pudge?



Tags:
lets
twitch
learning to program
gaming
stream
creative
program
programming
long
lets play
engineering
dev
play
game
tutoring
learning
long play
letsplay
let's
python
educational
gameplay
development
coding
software
intro
commentary
longplay
game play
intro to python
tutor
let's play
vencabot
education