This is my attempt to make a Space Invaders type game in the browser with JavaScript and the p5.js library Code: thecodingtrain.com/challenges...
🕹️ p5.js Web Editor Sketch: editor.p5js.org/codingtrain/s...
🎥 Previous video: • Coding Challenge #4: P...
🎥 Next video: • Coding Challenge #6: M...
🎥 All videos: • Coding Challenges
Videos:
🚂 Classes in JavaScript: • 6.2: Classes in JavaSc...
🔴 Coding Train Live 33: • Coding Train Live 33: ...
Related Coding Challenges:
🚂 #46 Asteroids: • Coding Challenge #46.1...
🚂 #72 Frogger: • Coding Challenge #72: ...
Timestamps:
00:00 Welcome to the challenge!
00:46 Setup the sketch canvas
01:22 Planning the game
02:00 Create a Ship constructor
04:20 Add keyboard interaction to move the ship
07:35 Create a Flower constructor
09:37 Create an array of Flowers
12:35 Create a Water Drop constructor
16:00 Create an array of drops
16:55 Create a drop object on key press
18:02 Start the drop at the ship's location
19:40 Check for intersection of water drop and flower
25:00 Grow the flower and remove the drop
30:40 Some improvements
31:20 Move the flowers
37:12 Improve keyboard interaction
40:00 Thanks for watching!
Editing by Mathieu Blanchette
Animations by Jason Heglund
Music from Epidemic Sound
🚂 Website: thecodingtrain.com/
👾 Share Your Creation! thecodingtrain.com/guides/pas...
🚩 Suggest Topics: github.com/CodingTrain/Sugges...
💡 GitHub: github.com/CodingTrain
💬 Discord: / discord
💖 Membership: kzitem.infojoin
🛒 Store: standard.tv/codingtrain
🖋️ Twitter: / thecodingtrain
📸 Instagram: / the.coding.train
🎥 Coding Challenges: • Coding Challenges
🎥 Intro to Programming: • Start learning here!
🔗 p5.js: p5js.org
🔗 p5.js Web Editor: editor.p5js.org/
🔗 Processing: processing.org
📄 Code of Conduct: github.com/CodingTrain/Code-o...
This description was auto-generated. If you see a problem, please open an issue: github.com/CodingTrain/thecod...
#spaceinvaders #game #p5js
Негізгі бет Coding Challenge #5: Space Invaders in JavaScript with p5.js
Пікірлер: 760