{"id":138304,"student_id":10,"content":"setBackdrop(\"border.jpg\")\nend = createSprite(\"e.png\")\nroad = createSprite(\"road.png\")\ncar1 = createSprite(\"car_red.png\")\ncar2 = createSprite(\"car_blue.png\")\n\nend.direction = 0\nend.y = 40\nend.x = 450\ncar1.direction = 270\ncar1.y = 20\ncar1.x = 340\ncar2.direction = 270\ncar2.y = 50\ncar2.x = 340\n\ndef loop ():\n if key.right:\n car1.direction += 4\n \n if key.left:\n car1.direction -= 4\n \n if car1.touched(road):\n car1.stepForward(0.3)\n else:\n car1.stepForward(2.5)\n \n if key.d:\n car2.direction += 4\n \n if key.a:\n car2.direction -= 4\n \n if car2.touched(road):\n car2.stepForward(.3)\n else:\n car2.stepForward(2.5)\n \n if car2.touched(end) and car1.touched(end):\n stop()\n \nforever(loop)","created_at":"2020-04-01T10:44:05.389+08:00","updated_at":"2024-08-28T12:16:32.467+08:00","name":"迷你賽車Python","language":"python","screenshot":{"url":"https://cdn5.koding.school/uploads/project/screenshot/138304/66f373020e916a54b36e68dc2ac6fcdb.jpg"},"parent_id":4,"plugin":"game.set({'width': 640, 'height': 480})","description":null,"note":null,"status":"public","like_student_ids":[],"is_featured":false,"views":277,"hashid":"5j3swkpk","is_content_changed":false,"review_status":"unsubmitted","submitted_at":null,"reviewed_at":null,"advise":null,"is_deleted":false}
[{"id":2382386,"file_name":"car_black.png","project_id":138304,"asset_id":24107,"created_at":"2020-04-01T10:44:26.093+08:00","updated_at":"2020-04-01T10:44:26.093+08:00"},{"id":2382385,"file_name":"border.jpg","project_id":138304,"asset_id":24106,"created_at":"2020-04-01T10:44:26.090+08:00","updated_at":"2020-04-01T10:46:50.213+08:00"},{"id":2382389,"file_name":"car_yellow.png","project_id":138304,"asset_id":24109,"created_at":"2020-04-01T10:44:26.700+08:00","updated_at":"2020-04-01T10:44:26.700+08:00"},{"id":2382390,"file_name":"road.png","project_id":138304,"asset_id":23940,"created_at":"2020-04-01T10:44:26.702+08:00","updated_at":"2020-04-01T10:44:26.702+08:00"},{"id":2382396,"file_name":"e.png","project_id":138304,"asset_id":24111,"created_at":"2020-04-01T10:47:30.796+08:00","updated_at":"2020-04-01T10:47:41.274+08:00"},{"id":2382387,"file_name":"car_blue.png","project_id":138304,"asset_id":24110,"created_at":"2020-04-01T10:44:26.367+08:00","updated_at":"2020-04-01T10:44:26.367+08:00"},{"id":2382388,"file_name":"car_red.png","project_id":138304,"asset_id":24108,"created_at":"2020-04-01T10:44:26.369+08:00","updated_at":"2020-04-01T10:44:26.369+08:00"}]
橘蘋學習平台
橘蘋學習平台
我的作品
檢視專案頁
匯出
複製
匯入
刪除
截圖
幫助
用手機掃描下方 QRCode 進行安裝
或您也可以
下載 APK
到這台電腦