{"id":73079,"student_id":3647,"content":"setBackdrop('bg.jpg');\nvar platform = createSprite(\"platform.png\");\nvar rocket = createSprite([\"rocket.png\", \"bomb.png\"]);\nvar fuel = 1000;\nplatform.x = 550;\nplatform.y = 450;\nrocket.x = 105;\nrocket.y = 92;\nvar vy = 0;\nvar xx = 0;\nvar vx = 0;\nrocket.direction = 0;\nforever(function()'{'\n if (fuel \u003e 0)\n rocket.y += vy;\n vy += 0.015;\n if (key.up) {\n vy -= 0.05;\n fuel -= 1;\n }\n if (key.down) {\n vy += 0.05;\n fuel -= 1;\n }\n rocket.x += xx;\n if (key.right) {\n xx += 0.06;\n vx += 0.1;\n rocket.direction = vx*10;\n fuel -= 1;\n }\n if (key.left) {\n xx -= 0.06;\n vx -= 0.1;\n rocket.direction = vx*10;\n fuel -= 1;\n\n\n if (rocket.touched(platform));\n if (vy \u003e 1.2) {\n rocket.costumeId = 1;\n }\n if (vx \u003e 6 || vx \u003c 6) {\n rocket.costumeId = 1;\n\n }stop;\n }\n print(\"fuel: \"+ fuel, 10, 10, \"red\", 20);\n if (vy \u003c 1.2) {\n print(\"降落速度\"+ vy+ \"安全\", 10, 30, \"green\");\n }\n if (vy \u003e 1.2) {\n print(\"降落速度\"+ vy+ \"危險\", 10, 30, \"red\");\n }\n });","created_at":"2019-06-15T18:44:41.612+08:00","updated_at":"2019-06-17T20:49:05.344+08:00","name":"火箭降落 副本","language":"javascript","screenshot":{"url":"https://cdn7.koding.school/uploads/project/screenshot/73079/89edcce60b8890776f43b51e69f48ea4.jpg"},"parent_id":10697,"plugin":"var fire = createSprite(\"fire.png\");\nfire.scale = 0.7;\nforever(function() {\n if(window.rocket \u0026\u0026 window.platform) {\n fire.x = rocket.x;\n fire.y = rocket.y;\n fire.direction = rocket.direction - 180;\n fire.stepForward(65);\n fire.direction = rocket.direction;\n if(window.rocket \u0026\u0026 (key.up || key.left || key.right) \u0026\u0026 window.fuel\u003e0) {\n fire.hidden = false;\n } else {\n fire.hidden = true;\n }\n if(rocket.touched(platform)) {\n // fire.hidden = true;\n }\n }\n});","description":"上、左、右推進火箭\n在料用盡前成功火箭降落在平台上。","note":null,"status":"public","like_student_ids":[],"is_featured":false,"views":148,"hashid":"5j3s5qwg","is_content_changed":false,"review_status":"unsubmitted","submitted_at":null,"reviewed_at":null,"advise":null,"is_deleted":false}
[{"id":1276070,"file_name":"bg.jpg","project_id":73079,"asset_id":19411,"created_at":"2019-06-15T18:44:41.617+08:00","updated_at":"2019-06-15T18:44:41.617+08:00"},{"id":1276071,"file_name":"bomb.png","project_id":73079,"asset_id":19412,"created_at":"2019-06-15T18:44:41.619+08:00","updated_at":"2019-06-15T18:44:41.619+08:00"},{"id":1276072,"file_name":"rocket.png","project_id":73079,"asset_id":19413,"created_at":"2019-06-15T18:44:41.620+08:00","updated_at":"2019-06-15T18:44:41.620+08:00"},{"id":1276073,"file_name":"fire.png","project_id":73079,"asset_id":19414,"created_at":"2019-06-15T18:44:41.621+08:00","updated_at":"2019-06-15T18:44:41.621+08:00"},{"id":1276074,"file_name":"platform.png","project_id":73079,"asset_id":19415,"created_at":"2019-06-15T18:44:41.621+08:00","updated_at":"2019-06-15T18:44:41.621+08:00"}]
橘蘋學習平台
我的作品
檢視專案頁
匯出
複製
匯入
刪除
下載 Android APP (APK)
截圖
繁中
简中
English
日本語
1:1:1
1:1
全寬
用手機掃描下方 QRCode 進行安裝
或您也可以
下載 APK
到這台電腦
用手機掃描下方 QRCode 進行安裝
或您也可以
下載 APK
到這台電腦