{"id":1056309,"student_id":1488,"content":"import game\nimport random\n\n\ngame.set_backdrop('bg.png')\np1 = game.create_sprite('pipes.png')\np2 = game.create_sprite('pipes.png')\np3 = game.create_sprite('pipes.png')\ngd = game.create_sprite('ground.png')\nbird = game.create_sprite('bird_0.png', 'bird_1.png')\nhint = game.create_sprite('hint.png')\nend = game.create_sprite('gameover.png')\n\nhint.hidden = True\nend.hidden = True\n\nspeed = 0\nscore = 0\nstart = False\n\np1.x = 0\np2.x = 500\np3.x = 1000\n\n\ndef loop():\n move_ground()\n move_pipes(p1)\n move_pipes(p2)\n move_pipes(p3)\n move_bird()\n \n game.draw_text(score,10,10,'white',60)\n\n\ndef move_ground():\n gd.x = gd.x - 6\n\n if gd.x \u003c 0:\n gd.x = gd.x + 1200\n\n\ndef move_pipes(pipe):\n global score\n\n pipe.x = pipe.x - 6\n \n if pipe.x \u003c -100:\n pipe.x = pipe.x + 1500\n if start == True:\n pipe.y = random.randrange(150,650)\n score = score + 1\n\ndef move_bird():\n global speed\n \n if start == True:\n speed = speed + 0.6\n bird.y = bird.y + speed\n\n\ndef jump():\n global speed, start\n \n speed = -12\n start = True\n game.create_sound('jump.mp3')\n\n\ndef game_over(t):\n game.stop()\n game.create_sound('gg.mp3')\n\n\ngame.forever(loop)\ngame.on('keydown', jump)\nbird.on('touch', [p1, p2, p3, gd], game_over)\n\ngame.create_sound('bgm.mp3',True)","created_at":"2025-07-10T13:14:54.841+08:00","updated_at":"2025-11-17T16:24:46.476+08:00","name":"Jumpy Bird 副本","language":"python","screenshot":{"url":"https://cdn5.koding.school/uploads/project/screenshot/1056309/a6f5bc4c1fb40af5f89414a99a44bfec.jpg"},"parent_id":1055007,"plugin":"","description":null,"note":null,"status":"public","like_student_ids":[],"is_featured":false,"views":37,"hashid":"zpes3gj3g","is_content_changed":false,"review_status":"unsubmitted","submitted_at":null,"reviewed_at":null,"advise":null,"is_deleted":false}
[{"id":39565466,"file_name":"gameover.png","project_id":1056309,"asset_id":189062,"created_at":"2025-07-10T13:14:54.846+08:00","updated_at":"2025-07-10T13:14:54.846+08:00"},{"id":39565467,"file_name":"ground.png","project_id":1056309,"asset_id":189063,"created_at":"2025-07-10T13:14:54.847+08:00","updated_at":"2025-07-10T13:14:54.847+08:00"},{"id":39565468,"file_name":"bird_1.png","project_id":1056309,"asset_id":189060,"created_at":"2025-07-10T13:14:54.849+08:00","updated_at":"2025-07-10T13:14:54.849+08:00"},{"id":39565469,"file_name":"bird_0.png","project_id":1056309,"asset_id":189061,"created_at":"2025-07-10T13:14:54.850+08:00","updated_at":"2025-07-10T13:14:54.850+08:00"},{"id":39565470,"file_name":"bgm.mp3","project_id":1056309,"asset_id":172841,"created_at":"2025-07-10T13:14:54.851+08:00","updated_at":"2025-07-10T13:14:54.851+08:00"},{"id":39565471,"file_name":"jump.mp3","project_id":1056309,"asset_id":201868,"created_at":"2025-07-10T13:14:54.852+08:00","updated_at":"2025-07-10T13:14:54.852+08:00"},{"id":39565472,"file_name":"gg.mp3","project_id":1056309,"asset_id":202597,"created_at":"2025-07-10T13:14:54.853+08:00","updated_at":"2025-07-10T13:14:54.853+08:00"},{"id":39565473,"file_name":"bg.png","project_id":1056309,"asset_id":189059,"created_at":"2025-07-10T13:14:54.854+08:00","updated_at":"2025-07-10T13:14:54.854+08:00"},{"id":39565474,"file_name":"pipes.png","project_id":1056309,"asset_id":202594,"created_at":"2025-07-10T13:14:54.855+08:00","updated_at":"2025-07-10T13:14:54.855+08:00"},{"id":39565475,"file_name":"hint.png","project_id":1056309,"asset_id":832350,"created_at":"2025-07-10T13:14:54.856+08:00","updated_at":"2025-07-10T13:14:54.856+08:00"}]
橘蘋學習平台
我的作品
檢視專案頁
匯出
複製
匯入
刪除
截圖
繁中
简中
English
日本語
用手機掃描下方 QRCode 進行安裝
或您也可以
下載 APK
到這台電腦