作業|用 Swift 打造跳舞機器人 BoogieBot
Published in
2 min readApr 16, 2018
出處 : Intro to App Development Curriculum 07-BoogieBot.playground
目的:了解funcation的使用,設計跳舞機器人時尚的舞步.
07-BoogieBot.playground 彼得潘修正版
https://www.dropbox.com/s/h27w619aijsntdt/07_BoogieBot.playground.zip?dl=0
startBot()startRecording()setBotTitle(“Let’s Dancing”)setBotSubtitle(“BY KIMMY”)// Start the dance!func shake(){fabulize()shakeItLeft()shakeItRight()shakeItCenter()}func dacinghand(){fabulize()leftArmUp()rightArmUp()leftArmDown()rightArmDown()}func dancingleg(){fabulize()leftLegUp()leftLegDown()rightLegUp()rightLegDown()}func jamp(){fabulize()jumpUp()jumpDown()defabulize()}shake()shake()dacinghand()dancingleg()dacinghand()dancingleg()jamp()jamp()jamp()shake()fabulize()defabulize()fabulize()