{"id":503552,"student_id":26492,"content":"setBackdrop('bg.png', 0, 0, 640, 480);\n\nvar p1 = createSprite([\"right_0.png\", \"right_1.png\", \"right_2.png\", \"right_3.png\"]);\n\n\nvar p2 = createSprite([\"left_0.png\", \"left_1.png\", \"left_2.png\", \"left_3.png\"]);\n\n\nvar step = 0\nvar score1 = 0;\nvar score2 = 0;\nstart();\nforever(function() {\n move();\n\n fire();\n if (p1.costumeId == 3 || p2.costumeId == 3) {\n if (key.p) {\n start();\n }\n }\n\n\n\n});\nfunction move() {\n if (step \u003e 0) {\n p1.x += 1;\n p2.x -= 1;\n step -= 1;\n }\n if (step == 0 \u0026\u0026 p1.costumeId == 0) {\n p1.costumeId = 1;\n p2.costumeId = 1;\n }\n}\nfunction fire() {\n if (key.enter \u0026\u0026 p1.costumeId == 1) {\n p1.costumeId = 2;\n p2.costumeId = 3;\n sound.play('shot.wav');\n }\n if (key.space \u0026\u0026 p1.costumeId == 1) {\n p1.costumeId = 3;\n p2.costumeId = 2;\n sound.play('shot.wav');\n }\n}\nfunction start() {\n p1.x = 340;\n p1.y = 400;\n p2.x = 340;\n p2.y = 400;\n p1.costumeId = 0;\n p2.costumeId = 0;\n step = Math.round(Math.random()*200 + 50);\n}\n\n\n\n","created_at":"2023-03-07T19:01:30.384+08:00","updated_at":"2023-03-07T20:12:30.324+08:00","name":"牛仔大對決 副本","language":"javascript","screenshot":{"url":"https://cdn3.koding.school/uploads/project/screenshot/503552/9e0210bd5b652bae1f4596acbe252ca7.jpg"},"parent_id":218649,"plugin":"","description":null,"note":null,"status":"public","like_student_ids":[],"is_featured":false,"views":8,"hashid":"gk4sprmd3","is_content_changed":false,"review_status":"unsubmitted","submitted_at":null,"reviewed_at":null,"advise":null,"is_deleted":false}
[{"id":11442763,"file_name":"left_3.png","project_id":503552,"asset_id":305139,"created_at":"2023-03-07T19:01:30.392+08:00","updated_at":"2023-03-07T19:01:30.392+08:00"},{"id":11442764,"file_name":"right_0.png","project_id":503552,"asset_id":305140,"created_at":"2023-03-07T19:01:30.395+08:00","updated_at":"2023-03-07T19:01:30.395+08:00"},{"id":11442765,"file_name":"right_1.png","project_id":503552,"asset_id":305141,"created_at":"2023-03-07T19:01:30.397+08:00","updated_at":"2023-03-07T19:01:30.397+08:00"},{"id":11442766,"file_name":"right_2.png","project_id":503552,"asset_id":305142,"created_at":"2023-03-07T19:01:30.399+08:00","updated_at":"2023-03-07T19:01:30.399+08:00"},{"id":11442767,"file_name":"right_3.png","project_id":503552,"asset_id":305143,"created_at":"2023-03-07T19:01:30.401+08:00","updated_at":"2023-03-07T19:01:30.401+08:00"},{"id":11442768,"file_name":"left_1.png","project_id":503552,"asset_id":305136,"created_at":"2023-03-07T19:01:30.402+08:00","updated_at":"2023-03-07T19:01:30.402+08:00"},{"id":11442769,"file_name":"left_0.png","project_id":503552,"asset_id":305137,"created_at":"2023-03-07T19:01:30.404+08:00","updated_at":"2023-03-07T19:01:30.404+08:00"},{"id":11442770,"file_name":"left_2.png","project_id":503552,"asset_id":305138,"created_at":"2023-03-07T19:01:30.406+08:00","updated_at":"2023-03-07T19:01:30.406+08:00"},{"id":11442771,"file_name":"bg.png","project_id":503552,"asset_id":305126,"created_at":"2023-03-07T19:01:30.408+08:00","updated_at":"2023-03-07T19:01:30.408+08:00"},{"id":11442772,"file_name":"shot.wav","project_id":503552,"asset_id":305127,"created_at":"2023-03-07T19:01:30.410+08:00","updated_at":"2023-03-07T19:01:30.410+08:00"}]
橘蘋學習平台
橘蘋學習平台
我的作品
檢視專案頁
匯出
複製
匯入
刪除
下載 Android APP (APK)
截圖
1:1:1
1:1
full
幫助
用手機掃描下方 QRCode 進行安裝
或您也可以
下載 APK
到這台電腦
用手機掃描下方 QRCode 進行安裝
或您也可以
下載 APK
到這台電腦