Skip to content

Commit

Permalink
[Community] [WithThreeJs] Supports GDevelop v5.3.180 (#1076)
Browse files Browse the repository at this point in the history
Supports GDevelop v5.3.180
  • Loading branch information
PANDAKO-GitHub authored Nov 6, 2023
1 parent f6cd782 commit 3af3ece
Showing 1 changed file with 57 additions and 12 deletions.
69 changes: 57 additions & 12 deletions extensions/community/WithThreeJS.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"name": "WithThreeJS",
"previewIconUrl": "https://resources.gdevelop-app.com/assets/Icons/rotate-3d.svg",
"shortDescription": "Create a simple 3D scene.",
"version": "1.0.1",
"version": "1.0.2",
"description": [
"Extension for GDevelop to create simple 3D scenes. ",
"This extension is intended for easy and simple 3D rendering. It does not currently aim for realistic 3D rendering. ",
Expand Down Expand Up @@ -1233,7 +1233,7 @@
"textG": 0,
"textR": 0
},
"comment": "Commented out to always use built-in 3D. (GDevelop v5.2.173 and PixiJS v7.3.0 or later)"
"comment": "This is the magic comment out that always enables built-in 3D. (GDevelop v5.2.173 - v5.2.176 (?) and PixiJS v7.3.0 or later)"
},
{
"disabled": true,
Expand Down Expand Up @@ -1405,9 +1405,23 @@
"} else {",
" // v5.2.173 対応した v1.0.1 以降は使用されないはず",
" console.log(\"[WithThreeJS] Built-in 3D is disabled. (LEGACY MODE)\");",
" // GDの背景を黒くした上で透明にする",
" runtimeScene.setBackgroundColor(0,0,0);",
" runtimeScene.getRenderer().getPIXIRenderer().backgroundAlpha = 0;// For PixiJS 6",
" // GDの背景を黒くした上で透明にする(v1.0.2 で廃止)",
" // runtimeScene.setBackgroundColor(0,0,0);",
" // runtimeScene.getRenderer().getPIXIRenderer().backgroundAlpha = 0;// For PixiJS 6",
" // 警告表示",
" let AlertElement = document.createElement('div');",
" AlertElement.innerHTML = `<strong>Warning from WithThreeJS</strong><br>",
" Please add an \"Enable WithThreeJS\" object to a scene.<br>",
" For more information, <a href=\"https://pandako.itch.io/with-threejs-extension-for-gdevelop/devlog/631434/about-the-warning-please-add-an-enable-withthreejs-object-to-a-scene\" target=\"_blank\" style=\"color:yellow\">please click here</a>.`;",
" AlertElement.style.position = \"absolute\";",
" AlertElement.style.zIndex = 999;",
" AlertElement.style.top = 0;",
" AlertElement.style.left = 0;",
" AlertElement.style.backgroundColor = \"red\";",
" AlertElement.style.color = \"white\";",
" AlertElement.style.padding = \"0.5em\";",
" document.body.appendChild(AlertElement);",
" return;",
"}",
"//",
"const ProjectionScale = eventsFunctionContext.getArgument(\"ProjectionScale\") || 1;",
Expand Down Expand Up @@ -12725,6 +12739,7 @@
"defaultName": "My3DBox",
"description": "This 3D Box can have different textures on 6 faces.\n⚠️ This object is high load.",
"fullName": "3D Box (Experimental)",
"is3D": true,
"name": "Box3D",
"eventsFunctions": [
{
Expand Down Expand Up @@ -13422,7 +13437,6 @@
"assetStoreId": "",
"height": 32,
"name": "Top",
"tags": "",
"texture": "",
"type": "TiledSpriteObject::TiledSprite",
"width": 32,
Expand All @@ -13434,7 +13448,6 @@
"assetStoreId": "",
"height": 32,
"name": "Bottom",
"tags": "",
"texture": "",
"type": "TiledSpriteObject::TiledSprite",
"width": 32,
Expand All @@ -13446,7 +13459,6 @@
"assetStoreId": "",
"height": 32,
"name": "Front",
"tags": "",
"texture": "",
"type": "TiledSpriteObject::TiledSprite",
"width": 32,
Expand All @@ -13458,7 +13470,6 @@
"assetStoreId": "",
"height": 32,
"name": "Back",
"tags": "",
"texture": "",
"type": "TiledSpriteObject::TiledSprite",
"width": 32,
Expand All @@ -13470,7 +13481,6 @@
"assetStoreId": "",
"height": 32,
"name": "Left",
"tags": "",
"texture": "",
"type": "TiledSpriteObject::TiledSprite",
"width": 32,
Expand All @@ -13482,15 +13492,50 @@
"assetStoreId": "",
"height": 32,
"name": "Right",
"tags": "",
"texture": "",
"type": "TiledSpriteObject::TiledSprite",
"width": 32,
"variables": [],
"effects": [],
"behaviors": []
}
]
],
"objectsFolderStructure": {
"folderName": "__ROOT",
"children": [
{
"objectName": "Top"
},
{
"objectName": "Bottom"
},
{
"objectName": "Front"
},
{
"objectName": "Back"
},
{
"objectName": "Left"
},
{
"objectName": "Right"
}
]
}
},
{
"defaultName": "Enable_WithThreeJS",
"description": "Adding this object to your project will enable WithThreeJS in all scenes.\nThere is no need to place this in the scene.",
"fullName": "Enable WithThreeJS",
"is3D": true,
"name": "EnableWithThreeJS",
"eventsFunctions": [],
"propertyDescriptors": [],
"objects": [],
"objectsFolderStructure": {
"folderName": "__ROOT"
}
}
]
}

0 comments on commit 3af3ece

Please sign in to comment.