diff --git a/examples/platformer-3d-wipeout/Base 1 Arrow White Blue.glb b/examples/platformer-3d-wipeout/Base 1 Arrow White Blue.glb new file mode 100644 index 000000000..1d15a0ead Binary files /dev/null and b/examples/platformer-3d-wipeout/Base 1 Arrow White Blue.glb differ diff --git a/examples/platformer-3d-wipeout/Base 1 Triangle Small White Blue.glb b/examples/platformer-3d-wipeout/Base 1 Triangle Small White Blue.glb new file mode 100644 index 000000000..0ded449a6 Binary files /dev/null and b/examples/platformer-3d-wipeout/Base 1 Triangle Small White Blue.glb differ diff --git a/examples/platformer-3d-wipeout/README.md b/examples/platformer-3d-wipeout/README.md new file mode 100644 index 000000000..7abe20082 --- /dev/null +++ b/examples/platformer-3d-wipeout/README.md @@ -0,0 +1,4 @@ +# 3D Wipeout Platformer + +A 3D third person example game where the player can jump. +It has a groud composed on big platforms. Some balls can be pushed by the player. \ No newline at end of file diff --git a/examples/platformer-3d-wipeout/Untitled.glb b/examples/platformer-3d-wipeout/Untitled.glb new file mode 100644 index 000000000..d41a27cea Binary files /dev/null and b/examples/platformer-3d-wipeout/Untitled.glb differ diff --git a/examples/platformer-3d-wipeout/assets/Base 1 Low White Blue.glb b/examples/platformer-3d-wipeout/assets/Base 1 Low White Blue.glb new file mode 100644 index 000000000..0eba56024 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/Base 1 Low White Blue.glb differ diff --git a/examples/platformer-3d-wipeout/assets/Base 1 Low White Cyan.glb b/examples/platformer-3d-wipeout/assets/Base 1 Low White Cyan.glb new file mode 100644 index 000000000..593f0af62 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/Base 1 Low White Cyan.glb differ diff --git a/examples/platformer-3d-wipeout/assets/Base 1 Low White Orange.glb b/examples/platformer-3d-wipeout/assets/Base 1 Low White Orange.glb new file mode 100644 index 000000000..d8ddf2c19 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/Base 1 Low White Orange.glb differ diff --git a/examples/platformer-3d-wipeout/assets/Base 1 Triangle White Blue.glb b/examples/platformer-3d-wipeout/assets/Base 1 Triangle White Blue.glb new file mode 100644 index 000000000..cf566022a Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/Base 1 Triangle White Blue.glb differ diff --git a/examples/platformer-3d-wipeout/assets/Pad Bumper Red White Red.glb b/examples/platformer-3d-wipeout/assets/Pad Bumper Red White Red.glb new file mode 100644 index 000000000..6ab5e4bb5 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/Pad Bumper Red White Red.glb differ diff --git a/examples/platformer-3d-wipeout/assets/Small Plastic Green Round Switch_Off.png b/examples/platformer-3d-wipeout/assets/Small Plastic Green Round Switch_Off.png new file mode 100644 index 000000000..482728394 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/Small Plastic Green Round Switch_Off.png differ diff --git a/examples/platformer-3d-wipeout/assets/Small Plastic Green Round Switch_On.png b/examples/platformer-3d-wipeout/assets/Small Plastic Green Round Switch_On.png new file mode 100644 index 000000000..18cd180c6 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/Small Plastic Green Round Switch_On.png differ diff --git a/examples/platformer-3d-wipeout/assets/models/Arrow Side.glb b/examples/platformer-3d-wipeout/assets/models/Arrow Side.glb new file mode 100644 index 000000000..08038a264 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Arrow Side.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Base_1x1_Low_White_Blue.glb b/examples/platformer-3d-wipeout/assets/models/Base_1x1_Low_White_Blue.glb new file mode 100644 index 000000000..f4a2058f9 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Base_1x1_Low_White_Blue.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Base_1x1_Ramp_Low_To_Mid_White_Blue.glb b/examples/platformer-3d-wipeout/assets/models/Base_1x1_Ramp_Low_To_Mid_White_Blue.glb new file mode 100644 index 000000000..4376b5ce2 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Base_1x1_Ramp_Low_To_Mid_White_Blue.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Base_1x1_Ramp_Low_To_Tall_White_Blue.glb b/examples/platformer-3d-wipeout/assets/models/Base_1x1_Ramp_Low_To_Tall_White_Blue.glb new file mode 100644 index 000000000..8a3355d95 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Base_1x1_Ramp_Low_To_Tall_White_Blue.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Base_1x1_Tall_White_Blue.glb b/examples/platformer-3d-wipeout/assets/models/Base_1x1_Tall_White_Blue.glb new file mode 100644 index 000000000..a19aa1e83 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Base_1x1_Tall_White_Blue.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Bumper_Red_Giant_Metal_Red.glb b/examples/platformer-3d-wipeout/assets/models/Bumper_Red_Giant_Metal_Red.glb new file mode 100644 index 000000000..4ef7798f6 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Bumper_Red_Giant_Metal_Red.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Chest Gold.glb b/examples/platformer-3d-wipeout/assets/models/Chest Gold.glb new file mode 100644 index 000000000..ad970f5ad Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Chest Gold.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Crate_1x1.glb b/examples/platformer-3d-wipeout/assets/models/Crate_1x1.glb new file mode 100644 index 000000000..339ae1937 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Crate_1x1.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Cube Grass Single.glb b/examples/platformer-3d-wipeout/assets/models/Cube Grass Single.glb new file mode 100644 index 000000000..8c23a8fb6 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Cube Grass Single.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Pad_Bumper_Red_White_Red.glb b/examples/platformer-3d-wipeout/assets/models/Pad_Bumper_Red_White_Red.glb new file mode 100644 index 000000000..498ebb315 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Pad_Bumper_Red_White_Red.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Palm Tree 3.glb b/examples/platformer-3d-wipeout/assets/models/Palm Tree 3.glb new file mode 100644 index 000000000..9430a4c3a Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Palm Tree 3.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Pipe.glb b/examples/platformer-3d-wipeout/assets/models/Pipe.glb new file mode 100644 index 000000000..845a3df41 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Pipe.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Planet 8.glb b/examples/platformer-3d-wipeout/assets/models/Planet 8.glb new file mode 100644 index 000000000..a9efbb8f9 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Planet 8.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Player_Capsule_for_scale.glb b/examples/platformer-3d-wipeout/assets/models/Player_Capsule_for_scale.glb new file mode 100644 index 000000000..05b61a9cf Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Player_Capsule_for_scale.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Safety_Nets_Low_Blue.glb b/examples/platformer-3d-wipeout/assets/models/Safety_Nets_Low_Blue.glb new file mode 100644 index 000000000..94fc3f13e Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Safety_Nets_Low_Blue.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Safety_Nets_Tall_Blue.glb b/examples/platformer-3d-wipeout/assets/models/Safety_Nets_Tall_Blue.glb new file mode 100644 index 000000000..7be6cdc71 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Safety_Nets_Tall_Blue.glb differ diff --git a/examples/platformer-3d-wipeout/assets/models/Spiky Ball.glb b/examples/platformer-3d-wipeout/assets/models/Spiky Ball.glb new file mode 100644 index 000000000..944bbd40e Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/models/Spiky Ball.glb differ diff --git a/examples/platformer-3d-wipeout/assets/textures/Flat dark joystick border.png b/examples/platformer-3d-wipeout/assets/textures/Flat dark joystick border.png new file mode 100644 index 000000000..606bf85b2 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/Flat dark joystick border.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/Flat dark joystick thumb.png b/examples/platformer-3d-wipeout/assets/textures/Flat dark joystick thumb.png new file mode 100644 index 000000000..acd005cc0 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/Flat dark joystick thumb.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/LightGlow.png b/examples/platformer-3d-wipeout/assets/textures/LightGlow.png new file mode 100644 index 000000000..871c194cc Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/LightGlow.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/NewSprite.png b/examples/platformer-3d-wipeout/assets/textures/NewSprite.png new file mode 100644 index 000000000..5294a0793 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/NewSprite.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/StartingBackground.png b/examples/platformer-3d-wipeout/assets/textures/StartingBackground.png new file mode 100644 index 000000000..83470d7ee Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/StartingBackground.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/StartingCheckeredPattern.png b/examples/platformer-3d-wipeout/assets/textures/StartingCheckeredPattern.png new file mode 100644 index 000000000..e46d32e20 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/StartingCheckeredPattern.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/StartingGround.png b/examples/platformer-3d-wipeout/assets/textures/StartingGround.png new file mode 100644 index 000000000..e3e68a63c Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/StartingGround.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/Target round button.png b/examples/platformer-3d-wipeout/assets/textures/Target round button.png new file mode 100644 index 000000000..ac62c6af2 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/Target round button.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/nx.png b/examples/platformer-3d-wipeout/assets/textures/nx.png new file mode 100644 index 000000000..773b33997 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/nx.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/ny.png b/examples/platformer-3d-wipeout/assets/textures/ny.png new file mode 100644 index 000000000..20ba50bb1 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/ny.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/nz.png b/examples/platformer-3d-wipeout/assets/textures/nz.png new file mode 100644 index 000000000..c25812579 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/nz.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/px.png b/examples/platformer-3d-wipeout/assets/textures/px.png new file mode 100644 index 000000000..ee0d61440 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/px.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/py.png b/examples/platformer-3d-wipeout/assets/textures/py.png new file mode 100644 index 000000000..604bc3371 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/py.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/pz.png b/examples/platformer-3d-wipeout/assets/textures/pz.png new file mode 100644 index 000000000..48489a9a2 Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/pz.png differ diff --git a/examples/platformer-3d-wipeout/assets/textures/water.png b/examples/platformer-3d-wipeout/assets/textures/water.png new file mode 100644 index 000000000..5c43de45f Binary files /dev/null and b/examples/platformer-3d-wipeout/assets/textures/water.png differ diff --git a/examples/platformer-3d-wipeout/platformer-3d-wipeout.json b/examples/platformer-3d-wipeout/platformer-3d-wipeout.json new file mode 100644 index 000000000..6d45708c8 --- /dev/null +++ b/examples/platformer-3d-wipeout/platformer-3d-wipeout.json @@ -0,0 +1,18240 @@ +{ + "firstLayout": "Game Scene", + "gdVersion": { + "build": 245, + "major": 5, + "minor": 5, + "revision": 0 + }, + "properties": { + "adaptGameResolutionAtRuntime": true, + "antialiasingMode": "MSAA", + "antialisingEnabledOnMobile": false, + "folderProject": false, + "orientation": "landscape", + "packageName": "com.example.gamename", + "pixelsRounding": false, + "projectUuid": "c33661e9-c185-419f-97c2-fde32585bead", + "scaleMode": "linear", + "sizeOnStartupMode": "", + "templateSlug": "starting-3d-tank", + "version": "1.0.0", + "name": "platformer-3d-wipeout", + "description": "", + "author": "", + "windowWidth": 1980, + "windowHeight": 1080, + "latestCompilationDirectory": "", + "maxFPS": 60, + "minFPS": 20, + "verticalSync": false, + "platformSpecificAssets": { + "android-icon-144": "", + "android-icon-192": "", + "android-icon-36": "", + "android-icon-48": "", + "android-icon-72": "", + "android-icon-96": "", + "android-windowSplashScreenAnimatedIcon": "", + "desktop-icon-512": "", + "ios-icon-100": "", + "ios-icon-1024": "", + "ios-icon-114": "", + "ios-icon-120": "", + "ios-icon-144": "", + "ios-icon-152": "", + "ios-icon-167": "", + "ios-icon-180": "", + "ios-icon-20": "", + "ios-icon-29": "", + "ios-icon-40": "", + "ios-icon-50": "", + "ios-icon-57": "", + "ios-icon-58": "", + "ios-icon-60": "", + "ios-icon-72": "", + "ios-icon-76": "", + "ios-icon-80": "", + "ios-icon-87": "" + }, + "loadingScreen": { + "backgroundColor": 0, + "backgroundFadeInDuration": 0.2, + "backgroundImageResourceName": "", + "gdevelopLogoStyle": "light", + "logoAndProgressFadeInDuration": 0.2, + "logoAndProgressLogoFadeInDelay": 0, + "minDuration": 1.5, + "progressBarColor": 16777215, + "progressBarHeight": 20, + "progressBarMaxWidth": 200, + "progressBarMinWidth": 40, + "progressBarWidthPercent": 30, + "showGDevelopSplash": true, + "showProgressBar": true + }, + "watermark": { + "placement": "bottom-left", + "showWatermark": true + }, + "authorIds": [], + "authorUsernames": [], + "categories": [], + "playableDevices": [ + "mobile", + "mobile" + ], + "extensionProperties": [], + "platforms": [ + { + "name": "GDevelop JS platform" + } + ], + "currentPlatform": "GDevelop JS platform" + }, + "resources": { + "resources": [ + { + "file": "assets/textures/py.png", + "kind": "image", + "metadata": "", + "name": "assets/textures/py.png", + "smoothed": true, + "userAdded": false + }, + { + "file": "assets/textures/ny.png", + "kind": "image", + "metadata": "", + "name": "assets/textures/ny.png", + "smoothed": true, + "userAdded": false + }, + { + "file": "assets/textures/nx.png", + "kind": "image", + "metadata": "", + "name": "assets/textures/nx.png", + "smoothed": true, + "userAdded": false + }, + { + "file": "assets/textures/nz.png", + "kind": "image", + "metadata": "", + "name": "assets/textures/nz.png", + "smoothed": true, + "userAdded": false + }, + { + "file": "assets/textures/px.png", + "kind": "image", + "metadata": "", + "name": "assets/textures/px.png", + "smoothed": true, + "userAdded": false + }, + { + "file": "assets/textures/pz.png", + "kind": "image", + "metadata": "", + "name": "assets/textures/pz.png", + "smoothed": true, + "userAdded": false + }, + { + "file": "assets/models/Safety_Nets_Tall_Blue.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Safety_Nets_Tall_Blue.glb", + "userAdded": false + }, + { + "file": "assets/models/Crate_1x1.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Crate_1x1.glb", + "userAdded": false + }, + { + "file": "assets/models/Player_Capsule_for_scale.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Player_Capsule_for_scale.glb", + "userAdded": false + }, + { + "file": "assets/models/Chest Gold.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Chest Gold.glb", + "userAdded": false + }, + { + "file": "assets/textures/water.png", + "kind": "image", + "metadata": "", + "name": "assets\\textures\\water.png", + "smoothed": true, + "userAdded": false + }, + { + "file": "assets/models/Pipe.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Pipe.glb", + "userAdded": false + }, + { + "file": "assets/textures/StartingGround.png", + "kind": "image", + "metadata": "", + "name": "assets\\textures\\StartingGround.png", + "smoothed": true, + "userAdded": false + }, + { + "file": "assets/models/Palm Tree 3.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Palm Tree 3.glb", + "userAdded": false + }, + { + "file": "assets/models/Arrow Side.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Arrow Side.glb", + "userAdded": false + }, + { + "file": "assets/models/Planet 8.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Planet 8.glb", + "userAdded": false + }, + { + "file": "assets/models/Spiky Ball.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Spiky Ball.glb", + "userAdded": false + }, + { + "file": "assets/models/Pad_Bumper_Red_White_Red.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Pad_Bumper_Red_White_Red.glb", + "userAdded": false + }, + { + "file": "assets/models/Bumper_Red_Giant_Metal_Red.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Bumper_Red_Giant_Metal_Red.glb", + "userAdded": false + }, + { + "file": "assets/models/Base_1x1_Low_White_Blue.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Base_1x1_Low_White_Blue.glb", + "userAdded": false + }, + { + "file": "assets/models/Base_1x1_Ramp_Low_To_Mid_White_Blue.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Base_1x1_Ramp_Low_To_Mid_White_Blue.glb", + "userAdded": false + }, + { + "file": "assets/models/Base_1x1_Tall_White_Blue.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Base_1x1_Tall_White_Blue.glb", + "userAdded": false + }, + { + "file": "assets/models/Base_1x1_Ramp_Low_To_Tall_White_Blue.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Base_1x1_Ramp_Low_To_Tall_White_Blue.glb", + "userAdded": false + }, + { + "file": "assets/models/Safety_Nets_Low_Blue.glb", + "kind": "model3D", + "metadata": "", + "name": "assets\\models\\Safety_Nets_Low_Blue.glb", + "userAdded": false + }, + { + "file": "assets/Base 1 Low White Orange.glb", + "kind": "model3D", + "metadata": "", + "name": "Base 1 Low White Orange.glb", + "userAdded": false, + "origin": { + "identifier": "https://private-assets.gdevelop.io/1c810c43-55e4-4c88-984f-ba91a005bf62/resources/assets/Platform/Base/Orange/Base 1 Low White Orange.glb", + "name": "gdevelop-private-asset-storage" + } + }, + { + "file": "Base 1 Triangle Small White Blue.glb", + "kind": "model3D", + "metadata": "", + "name": "Base 1 Triangle Small White Blue.glb", + "userAdded": false + }, + { + "file": "assets/Base 1 Low White Cyan.glb", + "kind": "model3D", + "metadata": "", + "name": "Base 1 Low White Cyan.glb", + "userAdded": false, + "origin": { + "identifier": "https://private-assets.gdevelop.io/1c810c43-55e4-4c88-984f-ba91a005bf62/resources/assets/Platform/Base/Cyan/Base 1 Low White Cyan.glb", + "name": "gdevelop-private-asset-storage" + } + }, + { + "file": "assets/Pad Bumper Red White Red.glb", + "kind": "model3D", + "metadata": "", + "name": "Pad Bumper Red White Red.glb", + "userAdded": false, + "origin": { + "identifier": "https://private-assets.gdevelop.io/1c810c43-55e4-4c88-984f-ba91a005bf62/resources/assets/Obstacles/Pad Bumper Red White Red.glb", + "name": "gdevelop-private-asset-storage" + } + }, + { + "file": "assets/Small Plastic Green Round Switch_Off.png", + "kind": "image", + "metadata": "{\"localFilePath\":\"assets/Small Plastic Green Round Switch_Off.png\",\"extension\":\".png\"}", + "name": "Small Plastic Green Round Switch_Off.png", + "smoothed": true, + "userAdded": false, + "origin": { + "identifier": "https://asset-resources.gdevelop.io/public-resources/Settings UI/Toggle Switch/80b157db1711ebc0166b1e42ff29bbf8837b5c9a0b1d62494e8eb5ca06837a31_Small Plastic Green Round Switch_Off.png", + "name": "Small Plastic Green Round Switch_Off.png" + } + }, + { + "file": "assets/Small Plastic Green Round Switch_On.png", + "kind": "image", + "metadata": "{\"localFilePath\":\"assets/Small Plastic Green Round Switch_On.png\",\"extension\":\".png\"}", + "name": "Small Plastic Green Round Switch_On.png", + "smoothed": true, + "userAdded": false, + "origin": { + "identifier": "https://asset-resources.gdevelop.io/public-resources/Settings UI/Toggle Switch/0af9e04c0c382482aeeaa36bc713a626249d6f6df3280bbccc6a042973ad555c_Small Plastic Green Round Switch_On.png", + "name": "Small Plastic Green Round Switch_On.png" + } + } + ] + }, + "objects": [], + "objectsFolderStructure": { + "folderName": "__ROOT" + }, + "objectsGroups": [], + "variables": [ + { + "name": "Settings", + "type": "structure", + "children": [ + { + "name": "Controls", + "type": "structure", + "children": [ + { + "name": "Backward", + "type": "string", + "value": "s" + }, + { + "name": "Forward", + "type": "string", + "value": "w" + }, + { + "name": "Jump", + "type": "string", + "value": "Space" + }, + { + "name": "Left", + "type": "string", + "value": "a" + }, + { + "name": "Right", + "type": "string", + "value": "d" + }, + { + "name": "Toggle", + "type": "boolean", + "value": false + } + ] + } + ] + }, + { + "name": "IsCameraLocked", + "type": "boolean", + "value": false + }, + { + "name": "Camera", + "type": "structure", + "children": [ + { + "name": "RaycastTouch", + "type": "structure", + "children": [] + } + ] + } + ], + "layouts": [ + { + "b": 91, + "disableInputWhenNotFocused": true, + "mangledName": "Game_32Scene", + "name": "Game Scene", + "r": 255, + "standardSortMethod": true, + "stopSoundsOnStartup": true, + "title": "", + "v": 199, + "uiSettings": { + "grid": false, + "gridType": "rectangular", + "gridWidth": 64, + "gridHeight": 64, + "gridDepth": 32, + "gridOffsetX": 0, + "gridOffsetY": 0, + "gridOffsetZ": 0, + "gridColor": 10401023, + "gridAlpha": 0.8, + "snap": false, + "zoomFactor": 0.8141881203710374, + "windowMask": false, + "selectedLayer": "Base meshes" + }, + "objectsGroups": [ + { + "name": "CollisionsForCamera", + "objects": [ + { + "name": "GrassCube" + }, + { + "name": "Base_1x1_White_Blue" + }, + { + "name": "Base_1_Tall_White_Blue" + }, + { + "name": "Base_1_Ramp_Base_to_Tall_White_Blue" + }, + { + "name": "Pipe" + }, + { + "name": "Bumper_Red_Giant_Metal_Red" + }, + { + "name": "Pad_Bumper_Red_White_Red" + } + ] + }, + { + "name": "UI", + "objects": [ + { + "name": "ToggleKeyboard" + }, + { + "name": "KeyboardMode" + } + ] + } + ], + "variables": [ + { + "name": "IsFullscreen", + "type": "boolean", + "value": false + }, + { + "name": "Camera", + "type": "structure", + "children": [ + { + "name": "DesiredCameraDistance", + "type": "number", + "value": 500 + }, + { + "name": "RaycastTouch", + "type": "structure", + "children": [ + { + "name": "X", + "type": "number", + "value": 0 + }, + { + "name": "Y", + "type": "number", + "value": 0 + }, + { + "name": "Z", + "type": "number", + "value": 0 + } + ] + }, + { + "name": "TargetCameraDistance", + "type": "number", + "value": 500 + } + ] + } + ], + "instances": [ + { + "angle": 0, + "customSize": false, + "height": 255.30368850413362, + "layer": "", + "name": "Base_1x1_White_Blue", + "persistentUuid": "0efa8acd-124a-4e13-aedc-c99fc1d26aae", + "width": 255.44317626953125, + "x": -1068, + "y": 2240, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 303.17313009865865, + "layer": "", + "name": "Base_1x1_White_Blue", + "persistentUuid": "77728ee6-0493-468f-a13a-08adff6176f7", + "width": 303.33877182006836, + "x": -64, + "y": 2240, + "z": -11, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.129610630167, + "layer": "", + "name": "Base_1x1_White_Blue", + "persistentUuid": "a2d30618-6cae-4c2b-830e-4bf54a4acc1a", + "width": 319.30397033691406, + "x": -1708, + "y": 2240, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.1296428345515, + "layer": "", + "name": "Base_1_Ramp_Base_to_Tall_White_Blue", + "persistentUuid": "aaa76bdf-212f-4953-a8b2-fba70b0441c3", + "width": 319.30397033691406, + "x": 1536, + "y": 3200, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 158.32139772472385, + "layer": "", + "name": "Pad_Bumper_Red_White_Red", + "persistentUuid": "5817c285-839b-4e77-844e-db93cec8d20c", + "width": 158.3213710784912, + "x": -577, + "y": 2240, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 158.32139772472385, + "layer": "", + "name": "Bumper_Red_Giant_Metal_Red", + "persistentUuid": "8dbb61c0-fe68-4281-8552-2c9d12abed70", + "width": 158.3213710784912, + "x": 1368, + "y": 2225, + "z": -69, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "6be00088-719c-4fa3-bf8d-1d9fce7373b9", + "width": 319.30397033691406, + "x": 887, + "y": 2240, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "452ed55c-3d11-49d4-a8e7-633562d0923f", + "width": 319.30397033691406, + "x": 1856, + "y": 2240, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "a670f172-c449-4430-9539-0da476870700", + "width": 319.30397033691406, + "x": 1856, + "y": 3200, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 90, + "customSize": false, + "height": 317.91637794992346, + "layer": "", + "name": "Safety_Nets_Small_Blue", + "persistentUuid": "9f170bb6-3f8e-452c-8ede-bdd6868e0906", + "width": 730.8359527587891, + "x": 1240, + "y": 3021, + "z": 64, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 270, + "customSize": false, + "height": 317.9163779499231, + "layer": "", + "name": "Safety_Nets_Small_Blue", + "persistentUuid": "35c57e35-b9bb-45a8-9d2e-e4423fd3ddb5", + "width": 67.48077392578125, + "x": 1243, + "y": 3378, + "z": 63, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 270, + "customSize": false, + "height": 317.9163779499231, + "layer": "", + "name": "Safety_Nets_Small_Blue", + "persistentUuid": "ae66c7e7-ac53-479b-8f07-a9dcef45a4d5", + "width": 67.48077392578125, + "x": -1039, + "y": 2419, + "z": 63, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 90, + "customSize": false, + "height": 317.91637794992346, + "layer": "", + "name": "Safety_Nets_Small_Blue", + "persistentUuid": "64a1dd52-78c3-4ae6-afbd-3419743862f5", + "width": 730.8359527587891, + "x": -1042, + "y": 2059, + "z": 64, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 317.9163779499231, + "layer": "", + "name": "Safety_Nets_Tall_Blue", + "persistentUuid": "47bbff7f-0937-4da8-a29b-fe939910e35a", + "width": 67.48077392578125, + "x": 2008, + "y": 2560, + "z": 263, + "zOrder": 16, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 180, + "customSize": false, + "height": 317.916389947963, + "layer": "", + "name": "Safety_Nets_Tall_Blue", + "persistentUuid": "5c6be5e1-a49e-4b82-9971-d8d7183aadfe", + "width": 100.73684096336365, + "x": 1615, + "y": 2560, + "z": 263, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 180, + "customSize": false, + "height": 317.916389947963, + "layer": "", + "name": "Safety_Nets_Tall_Blue", + "persistentUuid": "6c2ebee7-46a4-4334-bacf-6807994ad4c7", + "width": 100.73684096336365, + "x": 1615, + "y": 2882, + "z": 263, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 317.916389947963, + "layer": "", + "name": "Safety_Nets_Tall_Blue", + "persistentUuid": "d001e885-0230-4ae0-93d1-39d53fc4f6fd", + "width": 100.73684096336365, + "x": 2008, + "y": 2882, + "z": 263, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.129610630167, + "layer": "", + "name": "Crate_1x1", + "persistentUuid": "911fbeff-9698-4547-948d-79e2d04ce1f3", + "width": 319.30397033691406, + "x": 676, + "y": 2297, + "z": 192, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 33, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "4950c1b4-f651-4ab0-9ddf-1626365b76bd", + "rotationX": 16, + "rotationY": 344, + "width": 740, + "x": 3258, + "y": 3790, + "z": -67, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 528, + "height": 528, + "layer": "", + "name": "GrassCube", + "persistentUuid": "9c279af9-daa9-4948-8415-54075c5e34d7", + "rotationY": 343, + "width": 528, + "x": 3239, + "y": 3218, + "z": 14, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "2145bdc1-1494-4a82-8883-bb6b37455f5f", + "width": 740, + "x": 2987, + "y": 1690, + "z": -109, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 342, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "17c2c95f-a5f7-4add-8c8e-fb404e9f2da9", + "rotationX": 352, + "rotationY": 341, + "width": 740, + "x": 2682, + "y": 2103, + "z": -266, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 20, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "5a979000-a919-4e1f-b8a4-d5e054bb8590", + "rotationX": 8, + "rotationY": 1, + "width": 740, + "x": 3118, + "y": 2645, + "z": 14, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 53, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "9b917a26-2c89-4d38-8b21-605c2078b4d3", + "rotationX": 4, + "rotationY": 340, + "width": 740, + "x": 2996, + "y": 1054, + "z": -27, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 28, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "915eead7-0f54-46eb-ab6f-216c663c260e", + "rotationX": 356, + "rotationY": 347, + "width": 740, + "x": -46, + "y": 609, + "z": -660, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "eb29ca86-3e88-4661-80b0-7660454a160c", + "width": 740, + "x": 1848, + "y": 451, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "d3b17d2e-c6d6-47af-b54b-39aa8e38bee7", + "width": 740, + "x": 2619, + "y": 4075, + "z": -247, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "16ca415b-5ead-4efb-964f-9832c8456582", + "width": 740, + "x": 1509, + "y": 5323, + "z": -133, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "f70e529f-d58d-445f-8770-626737b927fc", + "width": 319.30397033691406, + "x": 1856, + "y": 2560, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "201d4d20-9e66-4a58-ac98-3675864494db", + "width": 319.30397033691406, + "x": 1856, + "y": 2880, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 158.32139772472385, + "layer": "", + "name": "Pad_Bumper_Red_White_Red", + "persistentUuid": "9280121f-5d61-4e46-8aab-c671243323ad", + "width": 158.3213710784912, + "x": 683, + "y": 3200, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 303.17313009865865, + "layer": "", + "name": "Base_1x1_White_Blue", + "persistentUuid": "c40b4f0d-c776-4271-a42c-3f96759cd69e", + "width": 303.33877182006836, + "x": 148, + "y": 3200, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 90, + "customSize": false, + "height": 317.91637794992346, + "layer": "", + "name": "Safety_Nets_Small_Blue", + "persistentUuid": "5d36dc06-2a47-493d-b089-2a069b956e47", + "width": 730.8359527587891, + "x": 176, + "y": 3019, + "z": 64, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 270, + "customSize": false, + "height": 317.9163779499231, + "layer": "", + "name": "Safety_Nets_Small_Blue", + "persistentUuid": "7a0ea453-acf5-4d70-9eb8-e50e886e172a", + "width": 67.48077392578125, + "x": 179, + "y": 3378, + "z": 63, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 90, + "customSize": false, + "height": 317.91637794992346, + "layer": "", + "name": "Safety_Nets_Small_Blue", + "persistentUuid": "6ab15459-5e2a-4156-8658-1f2c3bd9ec6c", + "width": 730.8359527587891, + "x": -144, + "y": 3019, + "z": 64, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 270, + "customSize": false, + "height": 317.9163779499231, + "layer": "", + "name": "Safety_Nets_Small_Blue", + "persistentUuid": "462bea4e-62e8-4b4c-bdc4-7551a4c597eb", + "width": 67.48077392578125, + "x": -141, + "y": 3378, + "z": 63, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 303.17313009865865, + "layer": "", + "name": "Base_1x1_White_Blue", + "persistentUuid": "4514ee31-42c2-44a1-87f3-fa414a070705", + "width": 303.33877182006836, + "x": -172, + "y": 3200, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 303.17313009865865, + "layer": "", + "name": "Base_1x1_White_Blue", + "persistentUuid": "dc71dc38-a0cc-44d2-99eb-60b2cc6498f6", + "width": 303.33877182006836, + "x": -492, + "y": 3200, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "88b29674-4e61-4f84-abdf-f9924562a10a", + "width": 319.30397033691406, + "x": -492, + "y": 2880, + "z": -208, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "7c1207b6-7670-4041-9fd2-fb2d94c8a923", + "width": 319.30397033691406, + "x": -492, + "y": 3520, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "6a3bb5ac-a0e9-421a-b9c9-116e8ba74a2a", + "width": 319.30397033691406, + "x": -812, + "y": 3520, + "z": -81, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "a236c00f-ebe2-4eea-9c26-071ed57ec0c0", + "width": 319.30397033691406, + "x": -812, + "y": 2880, + "z": -97, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "b3b64d50-a5d9-4e12-9d5d-a1327971d9fb", + "width": 319.30397033691406, + "x": -1132, + "y": 3520, + "z": -176, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "5d0ad2e8-e967-4eff-abfa-f2a411b5ebf3", + "width": 319.30397033691406, + "x": -1132, + "y": 2877, + "z": -17, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 303.17313009865865, + "layer": "", + "name": "Base_1x1_White_Blue", + "persistentUuid": "7b1158c1-2b83-479e-a2aa-9a817f9520f1", + "width": 303.33877182006836, + "x": -1132, + "y": 3200, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "087994f8-e162-4eb9-8240-b99e1557a6b3", + "width": 28, + "x": -663, + "y": 3329, + "z": 45, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "ab9f3852-aa04-4f45-9306-92f14b81a698", + "width": 28, + "x": -661, + "y": 3291, + "z": 45, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "eea91bd9-d87e-4ffe-857a-45a62d507ab3", + "width": 28, + "x": -666, + "y": 3253, + "z": 45, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "6b7f6faa-de61-471d-b91b-4e38a9fbf579", + "width": 28, + "x": -665, + "y": 3215, + "z": 45, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "af25d79e-c9bd-44be-8d87-334d74bc23dc", + "width": 28, + "x": -665, + "y": 3172, + "z": 45, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "bf456320-9856-4627-9d96-3328fd6f153d", + "width": 28, + "x": -665, + "y": 3139, + "z": 45, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "929e2458-bbda-46e1-bdf2-0babd990511b", + "width": 28, + "x": -665, + "y": 3091, + "z": 45, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "d502d7d9-17de-471a-9ed1-feafa6a120d4", + "width": 28, + "x": -663, + "y": 3054, + "z": 45, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "fa90ab71-42d4-41a4-bceb-2edcbeaf1eca", + "width": 28, + "x": -925, + "y": 3329, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "b1ad6e92-4183-4a81-9b67-d0ec6b86cb33", + "width": 28, + "x": -923, + "y": 3291, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "ef8535c1-6e1e-4b6a-9a19-69b7445bba70", + "width": 28, + "x": -928, + "y": 3253, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "2b9d9e4a-389e-4084-8c3c-81d8ea49ae53", + "width": 28, + "x": -927, + "y": 3215, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "7235080e-dc14-4fc4-a3ba-be01b2f3754e", + "width": 28, + "x": -927, + "y": 3172, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "305d1d65-7554-4a6e-86d2-4d1059f8c806", + "width": 28, + "x": -927, + "y": 3139, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "e74c86df-db52-4987-b9c4-ac7c50cac258", + "width": 28, + "x": -927, + "y": 3091, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "beedfb81-98ea-416a-b888-075d6c071f90", + "width": 28, + "x": -925, + "y": 3054, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "1b0f3b2e-7511-4a49-a079-e7d6e30ece2f", + "width": 28, + "x": -898, + "y": 3329, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "d6a486d3-5842-49ac-a528-4af3ee120d21", + "width": 28, + "x": -896, + "y": 3291, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "7857d797-eca1-454b-bd61-c20770f58e6d", + "width": 28, + "x": -901, + "y": 3253, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "06c8b70a-6565-48e1-ad25-363954f4aacc", + "width": 28, + "x": -900, + "y": 3215, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "3fdb0856-7057-4dae-a96a-91d2c22e531c", + "width": 28, + "x": -900, + "y": 3172, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "8a6dd16a-025a-4e46-82b0-fd85b0fa7853", + "width": 28, + "x": -900, + "y": 3139, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "65b1ab0a-69be-4e78-ab79-ec8ed049db1c", + "width": 28, + "x": -900, + "y": 3091, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "fdf2543e-e6d6-47e4-bf0f-07ac5e24d53e", + "width": 28, + "x": -898, + "y": 3054, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "5cd1267d-8306-472e-a826-6076c1fd12d3", + "width": 28, + "x": -863, + "y": 3329, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "a677e3c5-a6bb-4d16-acb5-d17d748b5516", + "width": 28, + "x": -865, + "y": 3215, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "52e05eae-3bb9-496b-a6fe-bd633e55f45b", + "width": 28, + "x": -865, + "y": 3139, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "e320d723-c544-4c66-94f5-3e03572d6def", + "width": 28, + "x": -865, + "y": 3091, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "681fff2d-59e5-415e-8bf8-c7901ef1d08d", + "width": 28, + "x": -863, + "y": 3054, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "47d27919-3e15-4256-a515-5183242205ce", + "width": 28, + "x": -823, + "y": 3329, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "1d526de1-c616-4351-93eb-8f2724467764", + "width": 28, + "x": -825, + "y": 3091, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "b56d0643-9984-4dba-88b2-d4e8c73e6f88", + "width": 28, + "x": -823, + "y": 3054, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "50dd1cd7-6443-4560-90a7-79edad4621f8", + "width": 28, + "x": -802, + "y": 3329, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "65851820-6970-4f4a-9ebf-611db63cc769", + "width": 28, + "x": -802, + "y": 3054, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "97e3b3ea-59f0-4cee-8d75-9e81276cb262", + "width": 28, + "x": -761, + "y": 3054, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "b6588c12-30e8-4d0c-b5f4-65faf6d7a10e", + "width": 28, + "x": -716, + "y": 3329, + "z": 46, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "c3695e34-2761-4314-a814-76fbe2ae88dc", + "width": 28, + "x": -671, + "y": 3329, + "z": 71, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "cc0b9ccf-b993-4d99-bfb1-47ce2701ee5b", + "width": 28, + "x": -669, + "y": 3291, + "z": 71, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "bb18c600-f31d-4394-b214-a9a3efb9c2f9", + "width": 28, + "x": -674, + "y": 3253, + "z": 71, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "17b97acb-f9e6-40b8-a6ae-1d391d8f7a2c", + "width": 28, + "x": -673, + "y": 3215, + "z": 71, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "67781a2d-8436-478d-a843-0f280fec2c54", + "width": 28, + "x": -673, + "y": 3172, + "z": 71, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "1ae52ceb-f632-48b7-ba0b-b7979259047e", + "width": 28, + "x": -673, + "y": 3139, + "z": 71, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "a74e0177-f66a-4874-8ed5-de2667ed16f3", + "width": 28, + "x": -673, + "y": 3091, + "z": 71, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "6e1b2ed3-fbf4-41f3-978f-21a78cd44a71", + "width": 28, + "x": -671, + "y": 3054, + "z": 71, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "1a2d38a5-9dd2-4b03-96cb-00f46c892dbc", + "width": 28, + "x": -687, + "y": 3253, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "4add11f0-6451-47cb-98ad-890085acb79c", + "width": 28, + "x": -686, + "y": 3172, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "eb161d99-af08-47bb-ac89-d4f9ba96f35d", + "width": 28, + "x": -686, + "y": 3139, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "8d656c61-87a5-4751-9b79-5390edb8077d", + "width": 28, + "x": -686, + "y": 3091, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "9cd168b8-dacb-4b06-919a-0a66ffbd2e4a", + "width": 28, + "x": -684, + "y": 3054, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "42a6608c-710b-4aea-b72d-8ceeb26f0617", + "width": 28, + "x": -727, + "y": 3329, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "a38df3da-faf2-46ef-ab81-6e441eb613d8", + "width": 28, + "x": -727, + "y": 3054, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "2f784770-c2c7-4dcf-a235-a87e2205201f", + "width": 28, + "x": -775, + "y": 3054, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "b9ea595c-af24-44b1-b9cd-8e056a3dc50f", + "width": 28, + "x": -816, + "y": 3091, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "3c1323da-fe3b-4d4c-be41-3fdd349e14b5", + "width": 28, + "x": -814, + "y": 3054, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "97ccad4a-93ec-4b74-af35-65071a8010a6", + "width": 28, + "x": -854, + "y": 3329, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "2f70d509-a4e9-4554-814d-a48d96fdf5aa", + "width": 28, + "x": -894, + "y": 3215, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "26fe2c07-93bc-4670-af87-c3578b9c079d", + "width": 28, + "x": -894, + "y": 3139, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "43b4625a-140b-472b-bc79-9b22b20cde0e", + "width": 28, + "x": -894, + "y": 3091, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "e2d3d2c7-58c6-46d5-87ba-5a0b82bdef87", + "width": 28, + "x": -892, + "y": 3054, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "f930d799-759a-45b9-8081-8e87368a55d4", + "width": 28, + "x": -934, + "y": 3329, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "839af1a5-f750-4852-8b33-fa01235662de", + "width": 28, + "x": -932, + "y": 3291, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "ca83f018-d0b9-4aa3-97a7-8080f7aa54d8", + "width": 28, + "x": -937, + "y": 3253, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "41cba37c-b962-416e-8014-88e541192639", + "width": 28, + "x": -936, + "y": 3215, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "d6ec0941-f7d7-4294-a13b-85de0e89bc6f", + "width": 28, + "x": -936, + "y": 3172, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "9bc3f4cb-80c7-48a9-876c-f1a0a2518997", + "width": 28, + "x": -936, + "y": 3139, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "f1127a64-41c2-4994-9286-4fcec17fd2da", + "width": 28, + "x": -936, + "y": 3091, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "6bbadf86-0163-4570-9c2e-9d53b2b96c65", + "width": 28, + "x": -934, + "y": 3054, + "z": 104, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 167, + "customSize": false, + "height": 56.193901176473304, + "layer": "", + "name": "Arrow_Side", + "persistentUuid": "bdbb64a3-133f-4f06-a4f3-182ce96090a1", + "width": 10.972593617115521, + "x": 1988, + "y": 2223, + "z": 320, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 144, + "customSize": false, + "height": 56.193901176473304, + "layer": "", + "name": "Arrow_Side", + "persistentUuid": "b16be4f4-6e28-4067-9e06-329a8e18fbbd", + "rotationX": 6, + "rotationY": 5, + "width": 10.972593617115521, + "x": 1951, + "y": 2122, + "z": 320, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 280, + "customSize": false, + "height": 56.193901176473304, + "layer": "", + "name": "Arrow_Side", + "persistentUuid": "4bbbfc88-658c-4967-8e40-44566c9d054c", + "rotationX": 1, + "rotationY": 270, + "width": 10.972593617115521, + "x": 254, + "y": 3271, + "z": 82, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 250.5335954073236, + "height": 270, + "keepRatio": true, + "layer": "", + "name": "Pipe", + "persistentUuid": "96996c5a-d026-441a-a03c-b98c354524e1", + "rotationX": 270, + "width": 250.2184715349983, + "x": 2879, + "y": 4310, + "z": 493, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 250.5335954073236, + "height": 270, + "keepRatio": true, + "layer": "", + "name": "Pipe", + "persistentUuid": "d0491fba-b476-4bcf-ac70-28bd69228f85", + "rotationX": 270, + "width": 250.2184715349983, + "x": 3495, + "y": 1989, + "z": 631, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 250.5335954073236, + "height": 270, + "keepRatio": true, + "layer": "", + "name": "Pipe", + "persistentUuid": "7a736f44-fb39-4678-a252-8f0e09a6acbc", + "rotationX": 270, + "width": 250.2184715349983, + "x": 2108, + "y": 931, + "z": 740, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 250.5335954073236, + "height": 270, + "keepRatio": true, + "layer": "", + "name": "Pipe", + "persistentUuid": "ac41702d-ba15-45e4-a463-d9af6a9748f1", + "rotationX": 270, + "rotationY": 270, + "width": 250.2184715349983, + "x": 1848, + "y": 760, + "z": 407, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 304, + "customSize": true, + "depth": 770, + "height": 830, + "keepRatio": true, + "layer": "", + "name": "Pipe", + "persistentUuid": "e45cb42c-33e2-4ee6-be5d-f14dc548f8d6", + "rotationY": 270, + "width": 769, + "x": 2923, + "y": 5394, + "z": 72, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 35, + "customSize": true, + "depth": 552, + "height": 1523, + "layer": "", + "name": "GrassCube", + "persistentUuid": "20b07cf8-4a3c-4150-9a82-155c52cf8dce", + "width": 1809, + "x": 2280, + "y": 4953, + "z": 343, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 36, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "b180a3be-8891-4731-b7de-0ed638f5ed15", + "width": 740, + "x": 2016, + "y": 5460, + "z": -133, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 36, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "7978e3b8-badf-4210-83c2-41233af0002d", + "width": 740, + "x": 2721, + "y": 4375, + "z": -133, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 11, + "customSize": true, + "depth": 395.86927257212426, + "height": 421, + "keepRatio": true, + "layer": "", + "name": "Palm_Tree_3", + "persistentUuid": "13c56ca5-a6bd-42fb-99e7-ec51e4ba9144", + "rotationX": 9, + "rotationY": 351, + "width": 404.92023896197526, + "x": 3549, + "y": 3923, + "z": 601, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 307, + "customSize": true, + "depth": 395.86927257212426, + "height": 421, + "keepRatio": true, + "layer": "", + "name": "Palm_Tree_3", + "persistentUuid": "c2444403-2edf-4fcf-a623-6155a5777540", + "rotationX": 1, + "rotationY": 12, + "width": 404.92023896197526, + "x": 1459, + "y": 5229, + "z": -42, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 350, + "customSize": true, + "depth": 395.86927257212426, + "height": 421, + "keepRatio": true, + "layer": "", + "name": "Palm_Tree_3", + "persistentUuid": "9aa51c30-a905-4dd7-976a-145c1a1b6171", + "rotationX": 7, + "rotationY": 350, + "width": 404.92023896197526, + "x": 1677, + "y": 5493, + "z": 607, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 346, + "customSize": true, + "depth": 395.86927257212426, + "height": 421, + "layer": "", + "name": "Palm_Tree_3", + "persistentUuid": "59076d85-e96c-45bf-a024-a14f3c2786ba", + "rotationX": 347, + "rotationY": 350, + "width": 404.92023896197526, + "x": -2015, + "y": 1183, + "z": 45, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 15, + "customSize": true, + "depth": 395.86927257212426, + "height": 421, + "layer": "", + "name": "Palm_Tree_3", + "persistentUuid": "dd9e4f7d-7709-4777-ba6a-35c15504106e", + "rotationX": 12, + "rotationY": 15, + "width": 404.92023896197526, + "x": 364, + "y": 944, + "z": 3, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 55, + "customSize": true, + "depth": 395.86927257212426, + "height": 421, + "layer": "", + "name": "Palm_Tree_3", + "persistentUuid": "163d82b4-33a7-422d-abac-ab6e5bb73af1", + "width": 404.92023896197526, + "x": -21, + "y": 1051, + "z": -15, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 82, + "customSize": true, + "depth": 339, + "height": 512, + "layer": "", + "name": "GrassCube", + "persistentUuid": "11693f34-b8e4-48fb-a4bf-f3df4b802b75", + "rotationX": 92, + "rotationY": 6, + "width": 307, + "x": -2183, + "y": 929, + "z": -369, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 21, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "01966d22-fcbd-48ee-8073-d363804b0782", + "rotationX": 14, + "rotationY": 358, + "width": 740, + "x": 1223, + "y": 5323, + "z": -687, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 372, + "height": 542, + "layer": "", + "name": "GrassCube", + "persistentUuid": "456be41a-69b0-4a27-acca-39989766aaf0", + "width": 625, + "x": -1146, + "y": 2974, + "z": -362, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 372, + "height": 336, + "layer": "", + "name": "GrassCube", + "persistentUuid": "a5cf6774-f7da-416a-bafa-d74ad54d4868", + "width": 969, + "x": -1877, + "y": 2068, + "z": -378, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 372, + "height": 336, + "layer": "", + "name": "GrassCube", + "persistentUuid": "3bab6960-def9-483d-9bd4-611d6909804e", + "width": 1615, + "x": -223, + "y": 2068, + "z": -378, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 372, + "height": 1295, + "layer": "", + "name": "GrassCube", + "persistentUuid": "f80c4dab-db47-407b-ad07-b0d000694734", + "width": 391, + "x": 1635, + "y": 2068, + "z": -378, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 372, + "height": 327, + "layer": "", + "name": "GrassCube", + "persistentUuid": "e4b3c154-1b7d-433a-aee7-bea1d1586352", + "width": 702, + "x": -388, + "y": 3037, + "z": -378, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 372, + "height": 327, + "layer": "", + "name": "GrassCube", + "persistentUuid": "4bd532b4-1ed1-4747-af05-bb837faf05e1", + "width": 702, + "x": 1049, + "y": 3037, + "z": -378, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 85, + "height": 120, + "layer": "", + "name": "Chest_Gold", + "persistentUuid": "b3c9c313-89fb-4ff0-bfd8-20a52d6a6938", + "width": 105, + "x": -1219, + "y": 3216, + "z": 80, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "005eadee-d5a2-4681-8e30-498a633ed7b5", + "width": 28, + "x": -1038, + "y": 2201, + "z": 169, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 28, + "height": 26, + "layer": "", + "name": "Planet_8", + "persistentUuid": "d30fdb31-2195-4b22-81e0-77cc18a5f436", + "width": 28, + "x": -752, + "y": 2226, + "z": 233, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 268, + "customSize": false, + "height": 56.193901176473304, + "layer": "", + "name": "Arrow_Side", + "persistentUuid": "988e0dee-7ac5-48bd-8536-84ca35964c17", + "rotationX": 4, + "width": 10.972593617115521, + "x": 1874, + "y": 3301, + "z": 320, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 86, + "layer": "", + "name": "Player_Capsule", + "persistentUuid": "11b9092a-34d0-4af7-bcdb-8f5b55bc0921", + "width": 96, + "x": -1783, + "y": 2240, + "z": 82, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 306, + "customSize": false, + "height": 80.00002149741704, + "layer": "", + "name": "Crate_1x1", + "persistentUuid": "077ada8a-fe79-4b81-b92d-f0767e1b346d", + "width": 80, + "x": 650, + "y": 2188, + "z": 193, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 306, + "customSize": false, + "height": 80.00002149741704, + "layer": "", + "name": "Crate_1x1", + "persistentUuid": "c791fcc5-df69-42be-9a5a-e1f437baf330", + "width": 80, + "x": 520, + "y": 2269, + "z": 201, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 306, + "customSize": false, + "height": 80.00002149741704, + "layer": "", + "name": "Crate_1x1", + "persistentUuid": "a5c3946a-ce78-4479-97a6-e6d395422eb3", + "width": 80, + "x": -412, + "y": 3403, + "z": 320, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 35.65327897368253, + "layer": "", + "name": "Spiky_Ball", + "persistentUuid": "27835723-939a-40f0-a324-a1088ddfd986", + "width": 35.65327897368254, + "x": -1133, + "y": 2230, + "z": 130, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 65, + "height": 12225, + "layer": "", + "name": "GrassCube", + "persistentUuid": "c5a2fd46-3b3b-4473-bf89-e71f01484ac0", + "width": 14039, + "x": -5194, + "y": -1536, + "z": -641, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 6, + "customSize": true, + "depth": 740, + "height": 740, + "layer": "", + "name": "GrassCube", + "persistentUuid": "5f5b3c61-c118-495a-85d5-4e5194f073ca", + "rotationX": 345, + "rotationY": 340, + "width": 740, + "x": 2430, + "y": 666, + "z": -171, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 35.65327897368253, + "layer": "", + "name": "Spiky_Ball", + "persistentUuid": "ee1cb50e-54c2-4d35-9b91-6945d8475b3e", + "width": 35.65327897368254, + "x": -453, + "y": 2927, + "z": 112, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 8, + "height": 318, + "layer": "", + "name": "Box_Collider", + "persistentUuid": "ed5515d9-d409-41e6-a8d5-6a63b2416217", + "rotationY": 338, + "width": 316, + "x": 104, + "y": 2079, + "z": 122, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 8, + "height": 318, + "layer": "", + "name": "Box_Collider", + "persistentUuid": "c2e72ff2-60f7-4109-a3dd-eb90da9916e0", + "rotationY": 322, + "width": 388, + "x": 1342, + "y": 3041, + "z": 188, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 8, + "height": 646, + "layer": "", + "name": "Box_Collider", + "persistentUuid": "1cb0048e-6758-4ddc-8b43-c74726b3a897", + "rotationY": 313, + "width": 109, + "x": 2006, + "y": 2398, + "z": 363, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 8, + "height": 646, + "layer": "", + "name": "Box_Collider", + "persistentUuid": "ec24dacf-8544-4361-80c3-d8f0fa23e111", + "rotationY": 47, + "width": 109, + "x": 1597, + "y": 2398, + "z": 363, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 845, + "height": 6715, + "layer": "", + "name": "GrassCube", + "persistentUuid": "1f96a885-effe-4acc-81a7-e3bd4e847403", + "width": 391, + "x": 1635, + "y": -782, + "z": -891, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 90, + "customSize": true, + "depth": 845, + "height": 6715, + "layer": "", + "name": "GrassCube", + "persistentUuid": "717bf2c8-d2ef-4a5e-a34c-41358d15c40f", + "width": 391, + "x": 1635, + "y": 2736, + "z": -851, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 90, + "customSize": true, + "depth": 845, + "height": 6715, + "layer": "", + "name": "GrassCube", + "persistentUuid": "39a06f5e-d620-4958-a955-880b8b041e3b", + "width": 391, + "x": 1635, + "y": -4081, + "z": -891, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 845, + "height": 6715, + "layer": "", + "name": "GrassCube", + "persistentUuid": "9c9d2dbe-e98f-409f-a72e-fd6c551d247c", + "width": 391, + "x": -3947, + "y": -782, + "z": -891, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 90, + "customSize": true, + "depth": 845, + "height": 6715, + "layer": "", + "name": "GrassCube", + "persistentUuid": "5362aaaa-8e8c-4c81-a291-9d3c82d5d19a", + "width": 391, + "x": -850, + "y": 2736, + "z": -851, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 90, + "customSize": true, + "depth": 845, + "height": 6715, + "layer": "", + "name": "GrassCube", + "persistentUuid": "04f47bfa-cf33-4766-a8b7-e102cacf919d", + "width": 391, + "x": -850, + "y": -4081, + "z": -891, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.129610630167, + "layer": "", + "name": "Base_1x1_White_Blue", + "persistentUuid": "00eb8dfa-83e9-4218-98bb-5bfcec1ed765", + "width": 319.30397033691406, + "x": -1388, + "y": 2240, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.12961063016957, + "layer": "", + "name": "Base_1_Tall_White_Blue", + "persistentUuid": "85c63560-dd45-4424-af8f-a7e73e1c3b60", + "width": 319.30397033691406, + "x": 571, + "y": 2240, + "z": -128, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 303.17313009865865, + "layer": "", + "name": "Base_1x1_White_Blue", + "persistentUuid": "405f18fe-1e59-4a2a-b1b9-c87e7321b6ae", + "width": 303.33877182006836, + "x": 1216, + "y": 3200, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 319.1296428345515, + "keepRatio": true, + "layer": "", + "name": "Base_1x1_Ramp_Base_To_Mid_White_Blue", + "persistentUuid": "ff312e3b-21c4-4cd6-89b3-536d05f09571", + "width": 319.30397033691406, + "x": 257, + "y": 2240, + "z": -9, + "zOrder": 17, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 274, + "customSize": false, + "height": 80.00002149741704, + "layer": "", + "name": "Crate_1x1", + "persistentUuid": "f767a87d-ee10-4663-b036-61b0ce489627", + "width": 80, + "x": -593, + "y": 2848, + "z": 112, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 35.65327897368253, + "layer": "", + "name": "Spiky_Ball", + "persistentUuid": "2224f232-bce4-4556-9ae8-873305d5fd8a", + "width": 35.65327897368254, + "x": 386, + "y": 2254, + "z": 213, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 35.65327897368253, + "layer": "", + "name": "Spiky_Ball", + "persistentUuid": "b9188e32-9e17-49c8-bf2d-e300f240b156", + "width": 35.65327897368254, + "x": 53, + "y": 2171, + "z": 91, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 35.65327897368253, + "layer": "", + "name": "Spiky_Ball", + "persistentUuid": "1ed40064-0552-44ec-8dbb-966497bf4922", + "width": 35.65327897368254, + "x": 705, + "y": 3235, + "z": 108, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 35.65327897368253, + "layer": "", + "name": "Spiky_Ball", + "persistentUuid": "ea85b079-4fde-44c4-938d-995e245bfa16", + "width": 35.65327897368254, + "x": -829, + "y": 3070, + "z": 190, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 21, + "height": 21, + "layer": "", + "name": "StartPoint", + "persistentUuid": "8fcf6b21-4153-4ad0-979a-aeeedff0b5cf", + "width": 21, + "x": -1855, + "y": 2192, + "z": 228, + "zOrder": 0, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": true, + "depth": 849, + "height": 849, + "keepRatio": true, + "layer": "", + "name": "WaterPlane", + "persistentUuid": "d5c91f80-6800-403b-af3a-ba3bba363e96", + "width": 849, + "x": -1343, + "y": 2360, + "z": 3, + "zOrder": 18, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 0, + "keepRatio": true, + "layer": "UI", + "name": "ToggleKeyboard", + "persistentUuid": "f660a7ad-6a83-4c39-b8f8-d9717031fa07", + "width": 0, + "x": 1725, + "y": 58, + "zOrder": 19, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + }, + { + "angle": 0, + "customSize": false, + "height": 0, + "keepRatio": true, + "layer": "UI", + "name": "KeyboardMode", + "persistentUuid": "7e44368a-81ee-4f39-aef9-0b9247ec4c19", + "width": 0, + "x": 1642, + "y": 15, + "zOrder": 20, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + } + ], + "objects": [ + { + "assetStoreId": "", + "name": "GrassCube", + "type": "Scene3D::Cube3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Static", + "bullet": false, + "fixedRotation": false, + "shape": "Box", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "density": 1, + "friction": 5, + "restitution": 0.1, + "linearDamping": 0.1, + "angularDamping": 0.1, + "gravityScale": 1, + "layers": 17, + "masks": 17, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 0 + } + ], + "content": { + "width": 128, + "height": 128, + "depth": 128, + "enableTextureTransparency": false, + "facesOrientation": "Y", + "frontFaceResourceName": "assets\\textures\\StartingGround.png", + "backFaceResourceName": "assets\\textures\\StartingGround.png", + "backFaceUpThroughWhichAxisRotation": "X", + "leftFaceResourceName": "assets\\textures\\StartingGround.png", + "rightFaceResourceName": "assets\\textures\\StartingGround.png", + "topFaceResourceName": "assets\\textures\\StartingGround.png", + "bottomFaceResourceName": "assets\\textures\\StartingGround.png", + "frontFaceVisible": true, + "backFaceVisible": true, + "leftFaceVisible": true, + "rightFaceVisible": true, + "topFaceVisible": true, + "bottomFaceVisible": true, + "frontFaceResourceRepeat": true, + "backFaceResourceRepeat": true, + "leftFaceResourceRepeat": true, + "rightFaceResourceRepeat": true, + "topFaceResourceRepeat": true, + "bottomFaceResourceRepeat": true, + "materialType": "StandardWithoutMetalness", + "tint": "255;255;255", + "isCastingShadow": true, + "isReceivingShadow": true + } + }, + { + "assetStoreId": "", + "name": "Player_Capsule", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Static", + "bullet": true, + "fixedRotation": true, + "shape": "Capsule", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 4, + "density": 50, + "friction": 0.3, + "restitution": 0.1, + "linearDamping": 0.1, + "angularDamping": 0.1, + "gravityScale": 1, + "layers": 17, + "masks": 17 + }, + { + "name": "PhysicsCharacter3D", + "type": "Physics3D::PhysicsCharacter3D", + "physics3D": "Physics3D", + "jumpHeight": 100, + "jumpSustainTime": 0.2, + "gravity": 1000, + "fallingSpeedMax": 700, + "forwardAcceleration": 1200, + "forwardDeceleration": 1200, + "forwardSpeedMax": 600, + "sidewaysAcceleration": 800, + "sidewaysDeceleration": 800, + "sidewaysSpeedMax": 400, + "slopeMaxAngle": 50, + "stairHeightMax": 20, + "shouldBindObjectAndForwardAngle": true, + "canBePushed": true + }, + { + "name": "ThirdPersonCamera", + "type": "ThirdPersonCamera::ThirdPersonCamera", + "Object3D": "Object3D", + "RotationHalfwayDuration": 0.2, + "ElevationHalfwayDuration": 0.2, + "TranslationZHalfwayDuration": 0.1, + "Distance": 600, + "OffsetX": 0, + "OffsetY": 0, + "OffsetZ": 60, + "RotationAngleOffset": 0.1, + "ElevationAngleOffset": 15, + "FollowFreeAreaZMax": 0.1, + "FollowFreeAreaZMin": 0.1, + "RotationLogSpeed": 2.0247e-320, + "ElevationLogSpeed": 2.0247e-320, + "TranslationZLogSpeed": 2.0247e-320, + "IsCalledManually": false, + "CameraZ": 0, + "HasJustBeenCreated": true, + "IsRotatingWithObject": true, + "IsElevatingWithObject": false, + "RotationMode": "Z", + "TargetedRotationAngle": 0, + "TargetedElevationAngle": 0, + "ForwardX": 0, + "ForwardY": 0, + "ForwardZ": 0 + } + ], + "content": { + "centerLocation": "ModelOrigin", + "crossfadeDuration": 0.10000000149011612, + "depth": 99.99914480471189, + "height": 49.897440618510785, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": true, + "materialType": "StandardWithoutMetalness", + "modelResourceName": "assets\\models\\Player_Capsule_for_scale.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 59.87690816438199, + "animations": [] + } + }, + { + "assetStoreId": "", + "name": "Base_1x1_White_Blue", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Static", + "bullet": false, + "fixedRotation": false, + "shape": "Box", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 0, + "density": 1, + "friction": 0.3, + "restitution": 0.1, + "linearDamping": 0.1, + "angularDamping": 0.1, + "gravityScale": 1, + "layers": 17, + "masks": 17 + } + ], + "content": { + "centerLocation": "ObjectCenter", + "crossfadeDuration": 0.1, + "depth": 80.00005252652025, + "height": 319.129610630167, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": false, + "materialType": "KeepOriginal", + "modelResourceName": "assets\\models\\Base_1x1_Low_White_Blue.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 319.30397033691406, + "animations": [] + } + }, + { + "assetStoreId": "", + "name": "Base_1_Tall_White_Blue", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Static", + "bullet": false, + "fixedRotation": false, + "shape": "Box", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 0, + "density": 1, + "friction": 0.3, + "restitution": 0.1, + "linearDamping": 0.1, + "angularDamping": 0.1, + "gravityScale": 1, + "layers": 17, + "masks": 17 + } + ], + "content": { + "centerLocation": "ObjectCenter", + "crossfadeDuration": 0.10000000149011612, + "depth": 319.7347343951955, + "height": 319.12961063016957, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": true, + "materialType": "KeepOriginal", + "modelResourceName": "assets\\models\\Base_1x1_Tall_White_Blue.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 319.30397033691406, + "animations": [] + } + }, + { + "assetStoreId": "", + "name": "Base_1_Ramp_Base_to_Tall_White_Blue", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [], + "content": { + "centerLocation": "ObjectCenter", + "crossfadeDuration": 0.1, + "depth": 319.68941578559094, + "height": 319.1296428345515, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": false, + "materialType": "KeepOriginal", + "modelResourceName": "assets\\models\\Base_1x1_Ramp_Low_To_Tall_White_Blue.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 319.30397033691406, + "animations": [] + } + }, + { + "assetStoreId": "", + "name": "Pad_Bumper_Red_White_Red", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Kinematic", + "bullet": false, + "fixedRotation": false, + "shape": "Box", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 0, + "density": 1, + "friction": 0.3, + "restitution": 0.8, + "linearDamping": 0.1, + "angularDamping": 0.1, + "gravityScale": 1, + "layers": 17, + "masks": 17 + } + ], + "content": { + "centerLocation": "ObjectCenter", + "crossfadeDuration": 0.1, + "depth": 80.00003094983532, + "height": 158.32139772472385, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": false, + "materialType": "KeepOriginal", + "modelResourceName": "assets\\models\\Pad_Bumper_Red_White_Red.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 158.3213710784912, + "animations": [] + } + }, + { + "assetStoreId": "", + "name": "Bumper_Red_Giant_Metal_Red", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Static", + "bullet": false, + "fixedRotation": false, + "shape": "Capsule", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 0, + "density": 1, + "friction": 0.3, + "restitution": 10, + "linearDamping": 1, + "angularDamping": 1, + "gravityScale": 1, + "layers": 17, + "masks": 17 + } + ], + "content": { + "centerLocation": "ObjectCenter", + "crossfadeDuration": 0.1, + "depth": 454.6157835211146, + "height": 214.46458365065604, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": false, + "materialType": "KeepOriginal", + "modelResourceName": "assets\\models\\Bumper_Red_Giant_Metal_Red.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 214.46455001831055, + "animations": [] + } + }, + { + "assetStoreId": "", + "name": "Safety_Nets_Small_Blue", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Static", + "bullet": false, + "fixedRotation": false, + "shape": "Box", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 0, + "density": 1, + "friction": 0.3, + "restitution": 0.1, + "linearDamping": 0.1, + "angularDamping": 0.1, + "gravityScale": 1, + "layers": 17, + "masks": 17 + } + ], + "content": { + "centerLocation": "ObjectCenter", + "crossfadeDuration": 0.1, + "depth": 64.84298126718389, + "height": 317.9163779499231, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": false, + "materialType": "KeepOriginal", + "modelResourceName": "assets\\models\\Safety_Nets_Low_Blue.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 67.48077392578125, + "animations": [] + } + }, + { + "assetStoreId": "", + "name": "Safety_Nets_Tall_Blue", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [], + "content": { + "centerLocation": "ObjectCenter", + "crossfadeDuration": 0.1, + "depth": 154.14145970923923, + "height": 317.916389947963, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": false, + "materialType": "KeepOriginal", + "modelResourceName": "assets\\models\\Safety_Nets_Tall_Blue.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 100.73684096336365, + "animations": [] + } + }, + { + "assetStoreId": "", + "name": "StartPoint", + "type": "Scene3D::Cube3DObject", + "variables": [], + "effects": [], + "behaviors": [], + "content": { + "width": 100, + "height": 100, + "depth": 100, + "enableTextureTransparency": false, + "facesOrientation": "Y", + "frontFaceResourceName": "", + "backFaceResourceName": "", + "backFaceUpThroughWhichAxisRotation": "X", + "leftFaceResourceName": "", + "rightFaceResourceName": "", + "topFaceResourceName": "", + "bottomFaceResourceName": "", + "frontFaceVisible": true, + "backFaceVisible": true, + "leftFaceVisible": true, + "rightFaceVisible": true, + "topFaceVisible": true, + "bottomFaceVisible": true, + "frontFaceResourceRepeat": false, + "backFaceResourceRepeat": false, + "leftFaceResourceRepeat": false, + "rightFaceResourceRepeat": false, + "topFaceResourceRepeat": false, + "bottomFaceResourceRepeat": false, + "materialType": "StandardWithoutMetalness", + "tint": "255;255;255", + "isCastingShadow": true, + "isReceivingShadow": true + } + }, + { + "assetStoreId": "", + "name": "Crate_1x1", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Dynamic", + "bullet": false, + "fixedRotation": false, + "shape": "Box", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 0, + "density": 50, + "friction": 1, + "restitution": 0, + "linearDamping": 0, + "angularDamping": 0.1, + "gravityScale": 1, + "layers": 17, + "masks": 17 + } + ], + "content": { + "centerLocation": "ObjectCenter", + "crossfadeDuration": 0.1, + "depth": 81.23106677979833, + "height": 80.00002149741704, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": false, + "materialType": "KeepOriginal", + "modelResourceName": "assets\\models\\Crate_1x1.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 80, + "animations": [] + } + }, + { + "assetStoreId": "4c5bd23ecc5e91d667300cc442f6cf19bfb8ebfca24200e6881348a3c0f1d33e", + "name": "Palm_Tree_3", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [], + "content": { + "centerLocation": "ModelOrigin", + "crossfadeDuration": 0.10000000149011612, + "depth": 86, + "height": 86, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": true, + "materialType": "StandardWithoutMetalness", + "modelResourceName": "assets\\models\\Palm Tree 3.glb", + "originLocation": "ModelOrigin", + "rotationX": 90, + "rotationY": 0, + "rotationZ": 90, + "width": 86, + "animations": [] + } + }, + { + "assetStoreId": "bf2b891c29443313ee31b718f26a9543762e822aa23e32f712d1cd8aaf4c83f1", + "name": "Pipe", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [], + "content": { + "centerLocation": "ModelOrigin", + "crossfadeDuration": 0.10000000149011612, + "depth": 79, + "height": 79, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": true, + "materialType": "StandardWithoutMetalness", + "modelResourceName": "assets\\models\\Pipe.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 79, + "animations": [] + } + }, + { + "assetStoreId": "eecdb503f345155dc87ce34b7d3ac162e29d7495284efb2a1f4ce1e79ed96187", + "name": "Arrow_Side", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [], + "content": { + "centerLocation": "ModelOrigin", + "crossfadeDuration": 0.10000000149011612, + "depth": 62, + "height": 62, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": true, + "materialType": "StandardWithoutMetalness", + "modelResourceName": "assets\\models\\Arrow Side.glb", + "originLocation": "ModelOrigin", + "rotationX": 90, + "rotationY": 0, + "rotationZ": 90, + "width": 62, + "animations": [] + } + }, + { + "assetStoreId": "2a32220b97261b7d25bfac750227a933a6b98dbf244803baba29c09bfb260144", + "name": "Spiky_Ball", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Dynamic", + "bullet": true, + "fixedRotation": false, + "shape": "Sphere", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 0, + "density": 20, + "friction": 2, + "restitution": 0, + "linearDamping": 0, + "angularDamping": 0.1, + "gravityScale": 1, + "layers": 17, + "masks": 17 + } + ], + "content": { + "centerLocation": "ModelOrigin", + "crossfadeDuration": 0.10000000149011612, + "depth": 36, + "height": 36, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": true, + "materialType": "StandardWithoutMetalness", + "modelResourceName": "assets\\models\\Spiky Ball.glb", + "originLocation": "ModelOrigin", + "rotationX": 90, + "rotationY": 0, + "rotationZ": 90, + "width": 36, + "animations": [] + } + }, + { + "assetStoreId": "ef1e0acbeff96c2a750b169344ecb6d952d743dd82a07805fb2ea3a6427fa000", + "name": "Planet_8", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Dynamic", + "bullet": true, + "fixedRotation": false, + "shape": "Sphere", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 0, + "density": 10, + "friction": 2, + "restitution": 0.1, + "linearDamping": 1, + "angularDamping": 1, + "gravityScale": 1, + "layers": 17, + "masks": 17 + } + ], + "content": { + "centerLocation": "ModelOrigin", + "crossfadeDuration": 0.10000000149011612, + "depth": 113, + "height": 113, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": true, + "materialType": "StandardWithoutMetalness", + "modelResourceName": "assets\\models\\Planet 8.glb", + "originLocation": "ModelOrigin", + "rotationX": 90, + "rotationY": 0, + "rotationZ": 90, + "width": 113, + "animations": [] + } + }, + { + "assetStoreId": "277361ed1c1e2deae8e6accd943d0e57f11ae69685dca2d29476300bb343723d", + "name": "Chest_Gold", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [], + "content": { + "centerLocation": "ModelOrigin", + "crossfadeDuration": 0.10000000149011612, + "depth": 55, + "height": 55, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": true, + "materialType": "StandardWithoutMetalness", + "modelResourceName": "assets\\models\\Chest Gold.glb", + "originLocation": "ModelOrigin", + "rotationX": 90, + "rotationY": 0, + "rotationZ": 90, + "width": 55, + "animations": [] + } + }, + { + "assetStoreId": "", + "name": "Box_Collider", + "type": "Scene3D::Cube3DObject", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "object3D": "Object3D", + "bodyType": "Static", + "bullet": false, + "fixedRotation": false, + "shape": "Box", + "shapeOrientation": "Z", + "shapeDimensionA": 0, + "shapeDimensionB": 0, + "shapeDimensionC": 0, + "shapeOffsetX": 0, + "shapeOffsetY": 0, + "shapeOffsetZ": 0, + "massCenterOffsetX": 0, + "massCenterOffsetY": 0, + "massCenterOffsetZ": 0, + "massOverride": 0, + "density": 1, + "friction": 0.3, + "restitution": 0.1, + "linearDamping": 0.1, + "angularDamping": 0.1, + "gravityScale": 1, + "layers": 17, + "masks": 17 + } + ], + "content": { + "width": 100, + "height": 100, + "depth": 100, + "enableTextureTransparency": false, + "facesOrientation": "Y", + "frontFaceResourceName": "", + "backFaceResourceName": "", + "backFaceUpThroughWhichAxisRotation": "X", + "leftFaceResourceName": "", + "rightFaceResourceName": "", + "topFaceResourceName": "", + "bottomFaceResourceName": "", + "frontFaceVisible": true, + "backFaceVisible": true, + "leftFaceVisible": true, + "rightFaceVisible": true, + "topFaceVisible": true, + "bottomFaceVisible": true, + "frontFaceResourceRepeat": false, + "backFaceResourceRepeat": false, + "leftFaceResourceRepeat": false, + "rightFaceResourceRepeat": false, + "topFaceResourceRepeat": false, + "bottomFaceResourceRepeat": false, + "materialType": "StandardWithoutMetalness", + "tint": "255;255;255", + "isCastingShadow": true, + "isReceivingShadow": true + } + }, + { + "assetStoreId": "", + "name": "Base_1x1_Ramp_Base_To_Mid_White_Blue", + "type": "Scene3D::Model3DObject", + "variables": [], + "effects": [], + "behaviors": [], + "content": { + "centerLocation": "ObjectCenter", + "crossfadeDuration": 0.1, + "depth": 199.18555437998833, + "height": 319.1296266437926, + "isCastingShadow": true, + "isReceivingShadow": true, + "keepAspectRatio": false, + "materialType": "KeepOriginal", + "modelResourceName": "assets\\models\\Base_1x1_Ramp_Low_To_Mid_White_Blue.glb", + "originLocation": "ModelOrigin", + "rotationX": 0, + "rotationY": 0, + "rotationZ": 0, + "width": 319.30397033691406, + "animations": [] + } + }, + { + "assetStoreId": "", + "name": "WaterPlane", + "type": "WaterShader::WaterPlane", + "variant": "", + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "WaterShader", + "type": "WaterShader::WaterShader" + } + ], + "content": {}, + "childrenContent": { + "New3DBox": { + "content": { + "width": 100, + "height": 100, + "depth": 100, + "enableTextureTransparency": false, + "facesOrientation": "Y", + "frontFaceResourceName": "", + "backFaceResourceName": "", + "backFaceUpThroughWhichAxisRotation": "X", + "leftFaceResourceName": "", + "rightFaceResourceName": "", + "topFaceResourceName": "", + "bottomFaceResourceName": "", + "frontFaceVisible": true, + "backFaceVisible": true, + "leftFaceVisible": true, + "rightFaceVisible": true, + "topFaceVisible": true, + "bottomFaceVisible": true, + "frontFaceResourceRepeat": false, + "backFaceResourceRepeat": false, + "leftFaceResourceRepeat": false, + "rightFaceResourceRepeat": false, + "topFaceResourceRepeat": false, + "bottomFaceResourceRepeat": false, + "materialType": "StandardWithoutMetalness", + "tint": "255;255;255", + "isCastingShadow": true, + "isReceivingShadow": true + } + } + } + }, + { + "assetStoreId": "99f912de1cf5033ae934a8453c2f98a712955bcdb5ea1b1fda2fe2aa616de4a9", + "name": "ToggleKeyboard", + "persistentUuid": "3d8e2b2a-a787-4a38-beb5-3f33ddb99b5b", + "type": "SpriteToggleSwitch::SpriteToggleSwitch", + "variant": "Small Green Plastic Round Switch2", + "variables": [], + "effects": [], + "behaviors": [], + "content": {} + }, + { + "assetStoreId": "", + "bold": true, + "italic": false, + "name": "KeyboardMode", + "smoothed": true, + "type": "TextObject::Text", + "underlined": false, + "variables": [], + "effects": [], + "behaviors": [], + "string": "AZERTY | QWERTY", + "font": "", + "textAlignment": "left", + "characterSize": 35, + "color": { + "b": 255, + "g": 255, + "r": 255 + }, + "content": { + "bold": true, + "isOutlineEnabled": false, + "isShadowEnabled": false, + "italic": false, + "outlineColor": "255;255;255", + "outlineThickness": 2, + "shadowAngle": 90, + "shadowBlurRadius": 2, + "shadowColor": "0;0;0", + "shadowDistance": 4, + "shadowOpacity": 127, + "smoothed": true, + "underlined": false, + "text": "AZERTY | QWERTY", + "font": "", + "textAlignment": "left", + "verticalTextAlignment": "top", + "characterSize": 35, + "lineHeight": 0, + "color": "255;255;255" + } + } + ], + "objectsFolderStructure": { + "folderName": "__ROOT", + "children": [ + { + "folderName": "Terrain", + "children": [ + { + "objectName": "Box_Collider" + }, + { + "objectName": "WaterPlane" + }, + { + "objectName": "GrassCube" + }, + { + "objectName": "Palm_Tree_3" + }, + { + "objectName": "Arrow_Side" + }, + { + "objectName": "Chest_Gold" + }, + { + "objectName": "Pipe" + } + ] + }, + { + "folderName": "Gameplay", + "children": [ + { + "objectName": "Player_Capsule" + }, + { + "objectName": "StartPoint" + }, + { + "objectName": "Planet_8" + }, + { + "objectName": "Spiky_Ball" + } + ] + }, + { + "folderName": "Wipeout base pack", + "children": [ + { + "objectName": "Bumper_Red_Giant_Metal_Red" + }, + { + "objectName": "Pad_Bumper_Red_White_Red" + }, + { + "objectName": "Safety_Nets_Tall_Blue" + }, + { + "objectName": "Base_1_Ramp_Base_to_Tall_White_Blue" + }, + { + "objectName": "Base_1x1_Ramp_Base_To_Mid_White_Blue" + }, + { + "objectName": "Base_1_Tall_White_Blue" + }, + { + "objectName": "Safety_Nets_Small_Blue" + }, + { + "objectName": "Base_1x1_White_Blue" + }, + { + "objectName": "Crate_1x1" + } + ] + }, + { + "objectName": "ToggleKeyboard" + }, + { + "objectName": "KeyboardMode" + } + ] + }, + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "DepartScene" + }, + "parameters": [ + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "Cache" + }, + "parameters": [ + "Box_Collider" + ] + } + ] + }, + { + "disabled": true, + "type": "BuiltinCommonInstructions::Link", + "include": { + "includeConfig": 0 + }, + "target": "SettingsToggle" + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "MousePointerLock::isPointerLocked" + }, + "parameters": [ + "", + "" + ] + }, + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "value": "MouseButtonFromTextPressed" + }, + "parameters": [ + "", + "\"Left\"" + ] + }, + { + "type": { + "value": "MouseButtonFromTextPressed" + }, + "parameters": [ + "", + "\"Right\"" + ] + } + ] + }, + { + "type": { + "inverted": true, + "value": "SourisSurObjet" + }, + "parameters": [ + "UI", + "", + "", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "MousePointerLock::RequestPointerLock" + }, + "parameters": [ + "", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetAngle" + }, + "parameters": [ + "Player_Capsule", + "+", + "90 * MousePointerLock::MovementX() / SceneWindowWidth()" + ] + }, + { + "type": { + "value": "Scene3D::Base3DBehavior::SetRotationY" + }, + "parameters": [ + "Player_Capsule", + "Object3D", + "=", + "clamp(Player_Capsule.RotationY(), -90, 90)" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::SetElevationAngleOffset" + }, + "parameters": [ + "Player_Capsule", + "ThirdPersonCamera", + "=", + "clamp(Player_Capsule.ThirdPersonCamera::ElevationAngleOffset(), -90, 90)", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "MousePointerLock::isPointerLocked" + }, + "parameters": [ + "", + "" + ] + }, + { + "type": { + "value": "MousePointerLock::IsMoving" + }, + "parameters": [ + "", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::SetCameraRotation" + }, + "parameters": [ + "Player_Capsule", + "ThirdPersonCamera", + "=", + "90 * MousePointerLock::MovementX() / SceneWindowWidth()", + "" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::SetElevationAngleOffset" + }, + "parameters": [ + "Player_Capsule", + "ThirdPersonCamera", + "+", + "90 * MousePointerLock::MovementY() / SceneWindowHeight()", + "" + ] + }, + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "IsCameraLocked", + "True", + "" + ] + } + ] + }, + { + "aiGeneratedEventId": "01K95W0SHQDPQC68RBYM5FXCDS", + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::JumpToTargetedRotation" + }, + "parameters": [ + "Player_Capsule", + "ThirdPersonCamera", + "=" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "KeyFromTextPressed" + }, + "parameters": [ + "", + "Settings.Controls.Forward" + ] + } + ], + "actions": [ + { + "type": { + "value": "Physics3D::PhysicsCharacter3D::SimulateForwardKey" + }, + "parameters": [ + "Player_Capsule", + "PhysicsCharacter3D" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "KeyFromTextPressed" + }, + "parameters": [ + "", + "Settings.Controls.Backward" + ] + } + ], + "actions": [ + { + "type": { + "value": "Physics3D::PhysicsCharacter3D::SimulateBackwardKey" + }, + "parameters": [ + "Player_Capsule", + "PhysicsCharacter3D" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "KeyFromTextPressed" + }, + "parameters": [ + "", + "Settings.Controls.Left" + ] + } + ], + "actions": [ + { + "type": { + "value": "Physics3D::PhysicsCharacter3D::SimulateLeftKey" + }, + "parameters": [ + "Player_Capsule", + "PhysicsCharacter3D" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "KeyFromTextPressed" + }, + "parameters": [ + "", + "Settings.Controls.Right" + ] + } + ], + "actions": [ + { + "type": { + "value": "Physics3D::PhysicsCharacter3D::SimulateRightKey" + }, + "parameters": [ + "Player_Capsule", + "PhysicsCharacter3D" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "KeyFromTextPressed" + }, + "parameters": [ + "", + "Settings.Controls.Jump" + ] + } + ], + "actions": [ + { + "type": { + "value": "Physics3D::PhysicsCharacter3D::SimulateJumpKey" + }, + "parameters": [ + "Player_Capsule", + "PhysicsCharacter3D" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsCameraLocked", + "", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::SetRotationHalfwayDuration" + }, + "parameters": [ + "Player_Capsule", + "ThirdPersonCamera", + "=", + "2", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsCameraLocked", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::SetRotationHalfwayDuration" + }, + "parameters": [ + "Player_Capsule", + "ThirdPersonCamera", + "=", + "10000000", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BuiltinCommonInstructions::CompareNumbers" + }, + "parameters": [ + "abs(AngleDifference(Player_Capsule.ThirdPersonCamera::TargetedRotationAngle() + 90, CameraAngle()))", + ">", + "90" + ] + } + ], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::SetRotationHalfwayDuration" + }, + "parameters": [ + "Player_Capsule", + "ThirdPersonCamera", + "=", + "10000000", + "" + ] + } + ] + }, + { + "aiGeneratedEventId": "01K98KR6Q8YKJ1DRF2GSAP3QRD", + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "Camera distance with wall" + }, + { + "aiGeneratedEventId": "01K98KR6Q8YKJ1DRF2GSAP3QRD", + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "Raycaster3D::RaycastBetweenPosition" + }, + "parameters": [ + "", + "CollisionsForCamera", + "Player_Capsule.BoundingBoxCenterX()", + "Player_Capsule.BoundingBoxCenterY()", + "Player_Capsule.Object3D::CenterZ()+(Player_Capsule.Height()/2)", + "CameraCenterX()", + "CameraCenterY()", + "Scene3D::CameraZ()", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "Camera.TargetCameraDistance", + "=", + "Raycaster3D::Distance() - 50" + ] + } + ] + }, + { + "aiGeneratedEventId": "01K98KR6Q8YKJ1DRF2GSAP3QRD", + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "Always" + }, + { + "aiGeneratedEventId": "01K98KR6Q8YKJ1DRF2GSAP3QRD", + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "Physics3D::PhysicsCharacter3D::IsMovingEvenALittle" + }, + "parameters": [ + "Player_Capsule", + "PhysicsCharacter3D" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "Camera.TargetCameraDistance", + "+", + "50" + ] + } + ] + }, + { + "aiGeneratedEventId": "01K98KR6Q8YKJ1DRF2GSAP3QRD", + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "Camera.DesiredCameraDistance", + "=", + "Camera.DesiredCameraDistance + (Camera.TargetCameraDistance - Camera.DesiredCameraDistance) * 1" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::SetDistance" + }, + "parameters": [ + "Player_Capsule", + "ThirdPersonCamera", + "=", + "clamp(Camera.DesiredCameraDistance,10,500)", + "" + ] + } + ] + }, + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Fall in the void", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "Scene3D::Base3DBehavior::Z" + }, + "parameters": [ + "Player_Capsule", + "Object3D", + "<", + "-450" + ] + }, + { + "type": { + "value": "BuiltinCommonInstructions::Once" + }, + "parameters": [] + } + ], + "actions": [ + { + "type": { + "value": "SetCenter" + }, + "parameters": [ + "Player_Capsule", + "=", + "StartPoint.CenterX()", + "=", + "StartPoint.CenterY()" + ] + }, + { + "type": { + "value": "Scene3D::Base3DBehavior::SetCenterZ" + }, + "parameters": [ + "Player_Capsule", + "Object3D", + "=", + "StartPoint.Object3D::CenterZ()" + ] + } + ] + } + ], + "parameters": [] + }, + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Fullscreen toggle", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "KeyFromTextJustPressed" + }, + "parameters": [ + "", + "\"Escape\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "MousePointerLock::ExitPointerLock" + }, + "parameters": [ + "", + "" + ] + } + ] + }, + { + "aiGeneratedEventId": "01K9R1SQRDFAJDZ35DYM3GG7T0", + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "KeyFromTextJustPressed" + }, + "parameters": [ + "", + "\"f\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "IsFullscreen", + "Toggle", + "False" + ] + } + ], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsFullscreen", + "true", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetFullScreen" + }, + "parameters": [ + "", + "no", + "yes" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsFullscreen", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetFullScreen" + }, + "parameters": [ + "", + "yes", + "yes" + ] + } + ] + } + ] + } + ], + "parameters": [] + }, + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "AZERTY / QWERTY", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SpriteToggleSwitch::HasJustBeenToggled" + }, + "parameters": [ + "ToggleKeyboard", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "Settings.Controls.Toggle", + "Toggle", + "" + ] + } + ], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "Settings.Controls.Toggle", + "False", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Forward", + "=", + "\"w\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Left", + "=", + "\"a\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Backward", + "=", + "\"s\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Right", + "=", + "\"d\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Jump", + "=", + "\"Space\"" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "Settings.Controls.Toggle", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Forward", + "=", + "\"z\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Left", + "=", + "\"q\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Backward", + "=", + "\"s\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Right", + "=", + "\"d\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Jump", + "=", + "\"Space\"" + ] + } + ] + } + ] + } + ], + "parameters": [] + } + ], + "layers": [ + { + "ambientLightColorB": 200, + "ambientLightColorG": 200, + "ambientLightColorR": 200, + "camera2DPlaneMaxDrawingDistance": 5000, + "camera3DFarPlaneDistance": 10000, + "camera3DFieldOfView": 45, + "camera3DNearPlaneDistance": 3, + "cameraType": "", + "followBaseLayerCamera": false, + "isLightingLayer": false, + "isLocked": false, + "name": "Background", + "renderingType": "", + "visibility": true, + "cameras": [], + "effects": [] + }, + { + "ambientLightColorB": 200, + "ambientLightColorG": 200, + "ambientLightColorR": 200, + "camera2DPlaneMaxDrawingDistance": 5000, + "camera3DFarPlaneDistance": 10000, + "camera3DFieldOfView": 45, + "camera3DNearPlaneDistance": 3, + "cameraType": "", + "followBaseLayerCamera": false, + "isLightingLayer": false, + "isLocked": false, + "name": "", + "renderingType": "", + "visibility": true, + "cameras": [ + { + "defaultSize": true, + "defaultViewport": true, + "height": 0, + "viewportBottom": 1, + "viewportLeft": 0, + "viewportRight": 1, + "viewportTop": 0, + "width": 0 + } + ], + "effects": [ + { + "effectType": "Scene3D::DirectionalLight", + "name": "DirlightShadow", + "doubleParameters": { + "distanceFromCamera": 6000, + "elevation": 45, + "frustumSize": 6000, + "intensity": 0.75, + "minimumShadowBias": 0.0008, + "rotation": 8 + }, + "stringParameters": { + "color": "255;255;255", + "shadowQuality": "high", + "top": "Z+" + }, + "booleanParameters": { + "isCastingShadow": true + } + }, + { + "effectType": "Scene3D::ExponentialFog", + "name": "Effect2", + "doubleParameters": { + "density": 0.0002 + }, + "stringParameters": { + "color": "172;212;167" + }, + "booleanParameters": {} + }, + { + "effectType": "Scene3D::AmbientLight", + "name": "3D Light", + "doubleParameters": { + "intensity": 0.15 + }, + "stringParameters": { + "color": "255;255;255" + }, + "booleanParameters": {} + }, + { + "effectType": "Scene3D::Skybox", + "name": "Effects", + "doubleParameters": {}, + "stringParameters": { + "backFaceResourceName": "assets/textures/ny.png", + "bottomFaceResourceName": "assets/textures/pz.png", + "frontFaceResourceName": "assets/textures/py.png", + "leftFaceResourceName": "assets/textures/px.png", + "rightFaceResourceName": "assets/textures/nx.png", + "topFaceResourceName": "assets/textures/nz.png" + }, + "booleanParameters": {} + } + ] + }, + { + "ambientLightColorB": 200, + "ambientLightColorG": 200, + "ambientLightColorR": 200, + "camera2DPlaneMaxDrawingDistance": 5000, + "camera3DFarPlaneDistance": 10000, + "camera3DFieldOfView": 45, + "camera3DNearPlaneDistance": 3, + "cameraType": "", + "followBaseLayerCamera": false, + "isLightingLayer": false, + "isLocked": false, + "name": "MobileControls", + "renderingType": "", + "visibility": true, + "cameras": [], + "effects": [] + }, + { + "ambientLightColorB": 200, + "ambientLightColorG": 200, + "ambientLightColorR": 200, + "camera2DPlaneMaxDrawingDistance": 5000, + "camera3DFarPlaneDistance": 10000, + "camera3DFieldOfView": 45, + "camera3DNearPlaneDistance": 3, + "cameraType": "", + "followBaseLayerCamera": false, + "isLightingLayer": false, + "isLocked": false, + "name": "Base meshes", + "renderingType": "", + "visibility": true, + "cameras": [], + "effects": [] + }, + { + "ambientLightColorB": 200, + "ambientLightColorG": 200, + "ambientLightColorR": 200, + "camera2DPlaneMaxDrawingDistance": 5000, + "camera3DFarPlaneDistance": 10000, + "camera3DFieldOfView": 45, + "camera3DNearPlaneDistance": 3, + "cameraType": "", + "followBaseLayerCamera": false, + "isLightingLayer": false, + "isLocked": false, + "name": "UI", + "renderingType": "", + "visibility": true, + "cameras": [], + "effects": [ + { + "effectType": "Scene3D::HemisphereLight", + "name": "3D Ambient Hemisphere Light", + "doubleParameters": { + "elevation": 40, + "intensity": 0.33, + "rotation": 300 + }, + "stringParameters": { + "groundColor": "127;127;127", + "skyColor": "255;255;255", + "top": "Z+" + }, + "booleanParameters": {} + }, + { + "effectType": "Scene3D::DirectionalLight", + "name": "3D Sun Light", + "doubleParameters": { + "distanceFromCamera": 1500, + "elevation": 40, + "frustumSize": 4000, + "intensity": 0.75, + "minimumShadowBias": 0, + "rotation": 300 + }, + "stringParameters": { + "color": "255;255;255", + "shadowQuality": "medium", + "top": "Z+" + }, + "booleanParameters": { + "isCastingShadow": true + } + } + ] + } + ], + "behaviorsSharedData": [ + { + "name": "Animation", + "type": "AnimatableCapability::AnimatableBehavior" + }, + { + "name": "Effect", + "type": "EffectCapability::EffectBehavior" + }, + { + "name": "Flippable", + "type": "FlippableCapability::FlippableBehavior" + }, + { + "name": "Object3D", + "type": "Scene3D::Base3DBehavior" + }, + { + "name": "Opacity", + "type": "OpacityCapability::OpacityBehavior" + }, + { + "name": "Physics3D", + "type": "Physics3D::Physics3DBehavior", + "gravityX": 0, + "gravityY": 0, + "gravityZ": -9.8, + "worldScale": 100 + }, + { + "name": "PhysicsCharacter3D", + "type": "Physics3D::PhysicsCharacter3D" + }, + { + "name": "Resizable", + "type": "ResizableCapability::ResizableBehavior" + }, + { + "name": "Scale", + "type": "ScalableCapability::ScalableBehavior" + }, + { + "name": "Text", + "type": "TextContainerCapability::TextContainerBehavior" + }, + { + "name": "ThirdPersonCamera", + "type": "ThirdPersonCamera::ThirdPersonCamera" + }, + { + "name": "WaterShader", + "type": "WaterShader::WaterShader" + } + ] + } + ], + "externalEvents": [ + { + "associatedLayout": "Game Scene", + "name": "SettingsToggle", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "Control switching, toggle between QWERTY keyboard and AZERTY keyboard" + }, + { + "disabled": true, + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "KeyFromTextJustPressed" + }, + "parameters": [ + "", + "\"t\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "Settings.Controls.Toggle", + "Toggle", + "" + ] + } + ], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "Settings.Controls.Toggle", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Forward", + "=", + "\"z\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Left", + "=", + "\"q\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Backward", + "=", + "\"s\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Right", + "=", + "\"d\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Jump", + "=", + "\"Space\"" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "Settings.Controls.Toggle", + "False", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Forward", + "=", + "\"w\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Left", + "=", + "\"a\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Backward", + "=", + "\"s\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Right", + "=", + "\"d\"" + ] + }, + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "Settings.Controls.Jump", + "=", + "\"Space\"" + ] + } + ] + } + ] + } + ] + } + ], + "eventsFunctionsExtensions": [ + { + "author": "", + "category": "Camera", + "extensionNamespace": "", + "fullName": "Third person camera", + "gdevelopVersion": ">=5.5.222", + "helpPath": "", + "iconUrl": "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4NCjwhLS0gR2VuZXJhdG9yOiBBZG9iZSBJbGx1c3RyYXRvciAyMy4wLjMsIFNWRyBFeHBvcnQgUGx1Zy1JbiAuIFNWRyBWZXJzaW9uOiA2LjAwIEJ1aWxkIDApICAtLT4NCjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iSWNvbnMiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4Ig0KCSB2aWV3Qm94PSIwIDAgMzIgMzIiIHN0eWxlPSJlbmFibGUtYmFja2dyb3VuZDpuZXcgMCAwIDMyIDMyOyIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+DQo8c3R5bGUgdHlwZT0idGV4dC9jc3MiPg0KCS5zdDB7ZmlsbDpub25lO3N0cm9rZTojMDAwMDAwO3N0cm9rZS13aWR0aDoyO3N0cm9rZS1saW5lY2FwOnJvdW5kO3N0cm9rZS1saW5lam9pbjpyb3VuZDtzdHJva2UtbWl0ZXJsaW1pdDoxMDt9DQo8L3N0eWxlPg0KPHBvbHlnb24gY2xhc3M9InN0MCIgcG9pbnRzPSI3LDEwIDEsMTMgNywxNiAxMywxMyAiLz4NCjxwb2x5bGluZSBjbGFzcz0ic3QwIiBwb2ludHM9IjEsMTMgMSwyMCA3LDIzIDEzLDIwIDEzLDEzICIvPg0KPGxpbmUgY2xhc3M9InN0MCIgeDE9IjciIHkxPSIxNiIgeDI9IjciIHkyPSIyMyIvPg0KPGxpbmUgY2xhc3M9InN0MCIgeDE9IjMxIiB5MT0iMTYiIHgyPSIyMSIgeTI9IjgiLz4NCjxsaW5lIGNsYXNzPSJzdDAiIHgxPSIyMSIgeTE9IjI0IiB4Mj0iMzEiIHkyPSIxNiIvPg0KPHBhdGggY2xhc3M9InN0MCIgZD0iTTIyLjcsMjIuNkMyMCwyMS43LDE4LDE5LjEsMTgsMTZjMC0zLjEsMi01LjcsNC43LTYuNiIvPg0KPHBhdGggY2xhc3M9InN0MCIgZD0iTTE5LjgsMTEuM2MxLjQsMS4xLDIuMiwyLjgsMi4yLDQuN2MwLDEuOS0wLjksMy42LTIuMiw0LjciLz4NCjwvc3ZnPg0K", + "name": "ThirdPersonCamera", + "previewIconUrl": "https://asset-resources.gdevelop.io/public-resources/Icons/Line Hero Pack/Master/SVG/Virtual Reality/94e95d2c318e1f3dc7151a351024e13c574e1e44669c6696aa107d60230073f6_Virtual Reality_3d_vision_eye_vr.svg", + "shortDescription": "Move the camera to look at an object from a given distance.", + "version": "1.8.0", + "description": [ + "Move the camera to look at an object from a given distance with a rotation and an elevation angles.", + "", + "It can be useful for:", + "- 3D platformer games ([open the project online](https://editor.gdevelop.io/?project=example://3d-platformer))", + "- 3D racing games ([open the project online](https://editor.gdevelop.io/?project=example://3d-car-coin-hunt))", + "- Orbit camera controls ([open the project online](https://editor.gdevelop.io/?project=example://3d-tile-based-city-builder))", + "- Isometric-like point of view ([open the project online](https://editor.gdevelop.io/?project=example://3d-road-crosser))" + ], + "origin": { + "identifier": "ThirdPersonCamera", + "name": "gdevelop-extension-store" + }, + "tags": [ + "3d", + "camera" + ], + "authorIds": [ + "IWykYNRvhCZBN3vEgKEbBPOR3Oc2" + ], + "dependencies": [], + "globalVariables": [], + "sceneVariables": [], + "eventsFunctions": [ + { + "description": "Define helper classes JavaScript code.", + "fullName": "Define helper classes", + "functionType": "Action", + "name": "DefineHelperClasses", + "private": true, + "sentence": "Define helper classes JavaScript code", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "if (gdjs.__thirdPersonCameraExtension) {", + " return;", + "}", + "", + "class CameraLocalBasis {", + " /** @type {gdjs.RuntimeObject} */", + " object;", + " rotationMatrix = new THREE.Matrix4();", + " forward = new THREE.Vector3();", + "", + " /**", + " * @param object {gdjs.RuntimeObject}", + " */", + " constructor(object) {", + " this.object = object;", + " }", + "", + " update() {", + " const layer = this.object.getInstanceContainer().getLayer(this.object.getLayer());", + " const threeCamera = layer.getRenderer().getThreeCamera();", + " this.rotationMatrix.makeRotationFromEuler(threeCamera.rotation);", + " const elements = this.rotationMatrix.elements;", + "", + " this.forward.set(-elements[8], elements[9], -elements[10]);", + " // Normalize them, just in case (they should generally be unit vectors).", + " this.forward.normalize();", + " }", + "}", + "", + "class ObjectLocalBasis {", + " /** @type {gdjs.RuntimeObject} */", + " object;", + " rotationMatrix = new THREE.Matrix4();", + " forward = new THREE.Vector3();", + " up = new THREE.Vector3();", + " right = new THREE.Vector3();", + "", + " /**", + " * @param object {gdjs.RuntimeObject}", + " */", + " constructor(object) {", + " this.object = object;", + " }", + "", + " update() {", + " const threeObject = this.object.get3DRendererObject();", + " this.rotationMatrix.makeRotationFromEuler(threeObject.rotation);", + " const elements = this.rotationMatrix.elements;", + "", + " this.up.set(elements[8], elements[9], elements[10]);", + " this.forward.set(elements[0], elements[1], elements[2]);", + " this.right.crossVectors(this.forward, this.up);", + "", + " // Normalize them, just in case (they should generally be unit vectors).", + " this.right.normalize();", + " this.up.normalize();", + " this.forward.normalize();", + " }", + "}", + "", + "/**", + " * It can be built the follow:", + " * ", + " * `objectDefaultRotation.setFromAxisAngle(new THREE.Vector3(0, 0, 1), -Math.PI/2);`", + " * ", + " * `objectDefaultRotation.multiply(new THREE.Quaternion().setFromAxisAngle(new THREE.Vector3(1, 0, 0), Math.PI/2));`", + " * ", + " */", + "const objectDefaultRotation = new THREE.Quaternion(0.5, -0.5, -0.5, 0.5);", + "const targetQuaternion = new THREE.Quaternion();", + "const yAxis = new THREE.Vector3(0, 1, 0);", + "const zAxis = new THREE.Vector3(0, 0, 1);", + "const quaternion = new THREE.Quaternion();", + "const objectRotation = new THREE.Euler();", + "", + "/**", + " * @param object {gdjs.RuntimeObject}", + " * @param ratio {number}", + " * @param elevationAngleOffset {number}", + " */", + "function slerpCamera(object, ratio, rotationAngleOffset, elevationAngleOffset) {", + " const layer = object.getInstanceContainer().getLayer(object.getLayer());", + " const threeCamera = layer.getRenderer().getThreeCamera();", + " const threeObject = object.get3DRendererObject();", + "", + " objectRotation.copy(threeObject.rotation);", + " objectRotation.z = -objectRotation.z;", + " objectRotation.x = -objectRotation.x;", + " targetQuaternion.setFromEuler(objectRotation);", + " targetQuaternion.multiply(quaternion.setFromAxisAngle(zAxis, -gdjs.toRad(rotationAngleOffset)));", + " targetQuaternion.multiply(quaternion.setFromAxisAngle(yAxis, gdjs.toRad(elevationAngleOffset)));", + " targetQuaternion.multiply(objectDefaultRotation);", + "", + " threeCamera.quaternion.slerp(targetQuaternion, ratio);", + "", + " // The layer angle takes over the 3D camera Z rotation.", + " layer.setCameraRotation(gdjs.toDegrees(-threeCamera.rotation.z));", + "}", + "", + "gdjs.__thirdPersonCameraExtension = {", + " CameraLocalBasis,", + " ObjectLocalBasis,", + " slerpCamera,", + "};", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "Move the camera to look at a position from a distance.", + "fullName": "Look at a position from a distance (deprecated)", + "functionType": "Action", + "name": "LookFromDistanceAtPosition", + "private": true, + "sentence": "Move the camera of _PARAM6_ to look at _PARAM1_; _PARAM2_ from _PARAM3_ pixels with a rotation of _PARAM4_° and an elevation of _PARAM5_°", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetCameraCenterX" + }, + "parameters": [ + "", + "=", + "PositionX + Distance * cos(ToRad(RotationAngle + 90)) * cos(ToRad(ElevationAngle))", + "Layer", + "" + ] + }, + { + "type": { + "value": "SetCameraCenterY" + }, + "parameters": [ + "", + "=", + "PositionY + Distance * sin(ToRad(RotationAngle + 90)) * cos(ToRad(ElevationAngle))", + "Layer", + "" + ] + }, + { + "type": { + "value": "Scene3D::SetCameraZ" + }, + "parameters": [ + "", + "=", + "Distance * sin(ToRad(ElevationAngle))", + "Layer", + "" + ] + }, + { + "type": { + "value": "Scene3D::TurnCameraTowardPosition" + }, + "parameters": [ + "", + "PositionX", + "PositionY", + "0", + "Layer", + "", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Position on X axis", + "name": "PositionX", + "type": "expression" + }, + { + "description": "Position on Y axis", + "name": "PositionY", + "type": "expression" + }, + { + "description": "Distance", + "name": "Distance", + "type": "expression" + }, + { + "description": "Rotation angle (around Z axis)", + "name": "RotationAngle", + "type": "expression" + }, + { + "description": "Elevation angle (around Y axis)", + "name": "ElevationAngle", + "type": "expression" + }, + { + "description": "Layer", + "name": "Layer", + "type": "layer" + } + ], + "objectGroups": [] + }, + { + "description": "Move the camera to look at an object from a distance.", + "fullName": "Look at an object from a distance (deprecated)", + "functionType": "Action", + "name": "LookFromDistanceAtObject", + "private": true, + "sentence": "Move the camera of _PARAM5_ to look at _PARAM1_ from _PARAM2_ pixels with a rotation of _PARAM3_° and an elevation of _PARAM4_°", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::LookFromDistanceAtPosition" + }, + "parameters": [ + "", + "Object.CenterX()", + "Object.CenterY()", + "Distance", + "RotationAngle", + "ElevationAngle", + "Layer", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "objectList" + }, + { + "description": "Distance", + "name": "Distance", + "type": "expression" + }, + { + "description": "Rotation angle (around Z axis)", + "name": "RotationAngle", + "type": "expression" + }, + { + "description": "Elevation angle (around Y axis)", + "name": "ElevationAngle", + "type": "expression" + }, + { + "description": "Layer", + "name": "Layer", + "type": "layer" + } + ], + "objectGroups": [] + }, + { + "description": "Move the camera to look at a position from a distance.", + "fullName": "Look at a position from a distance", + "functionType": "Action", + "name": "LookFromDistanceAtPosition3D", + "sentence": "Move the camera of _PARAM7_ to look at _PARAM1_; _PARAM2_; _PARAM3_ from _PARAM4_ pixels with a rotation of _PARAM5_° and an elevation of _PARAM6_°", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetCameraCenterX" + }, + "parameters": [ + "", + "=", + "PositionX + Distance * cos(ToRad(RotationAngle + 90)) * cos(ToRad(ElevationAngle))", + "Layer", + "" + ] + }, + { + "type": { + "value": "SetCameraCenterY" + }, + "parameters": [ + "", + "=", + "PositionY + Distance * sin(ToRad(RotationAngle + 90)) * cos(ToRad(ElevationAngle))", + "Layer", + "" + ] + }, + { + "type": { + "value": "Scene3D::SetCameraZ" + }, + "parameters": [ + "", + "=", + "PositionZ + Distance * sin(ToRad(ElevationAngle))", + "Layer", + "" + ] + }, + { + "type": { + "value": "Scene3D::SetCameraRotationX" + }, + "parameters": [ + "", + "=", + "90 - ElevationAngle", + "Layer", + "" + ] + }, + { + "type": { + "value": "Scene3D::SetCameraRotationY" + }, + "parameters": [ + "", + "=", + "0", + "Layer", + "" + ] + }, + { + "type": { + "value": "SetCameraAngle" + }, + "parameters": [ + "", + "=", + "RotationAngle", + "Layer", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Position on X axis", + "name": "PositionX", + "type": "expression" + }, + { + "description": "Position on Y axis", + "name": "PositionY", + "type": "expression" + }, + { + "description": "Position on Z axis", + "name": "PositionZ", + "type": "expression" + }, + { + "description": "Distance", + "name": "Distance", + "type": "expression" + }, + { + "description": "Rotation angle (around Z axis)", + "name": "RotationAngle", + "type": "expression" + }, + { + "description": "Elevation angle (around Y axis)", + "name": "ElevationAngle", + "type": "expression" + }, + { + "description": "Layer", + "name": "Layer", + "type": "layer" + } + ], + "objectGroups": [] + }, + { + "description": "Move the camera to look at an object from a distance.", + "fullName": "Look at an object from a distance", + "functionType": "Action", + "group": "Layers and cameras", + "name": "LookFromDistanceAtObject3D", + "sentence": "Move the camera of _PARAM6_ to look at _PARAM1_ from _PARAM3_ pixels with a rotation of _PARAM4_° and an elevation of _PARAM5_°", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::LookFromDistanceAtPosition3D" + }, + "parameters": [ + "", + "Object.CenterX()", + "Object.CenterY()", + "Object.Object3D::CenterZ()", + "Distance", + "RotationAngle", + "ElevationAngle", + "Layer", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "objectList" + }, + { + "description": "3D capability", + "name": "Object3D", + "supplementaryInformation": "Scene3D::Base3DBehavior", + "type": "behavior" + }, + { + "description": "Distance", + "name": "Distance", + "type": "expression" + }, + { + "description": "Rotation angle (around Z axis)", + "name": "RotationAngle", + "type": "expression" + }, + { + "description": "Elevation angle (around Y axis)", + "name": "ElevationAngle", + "type": "expression" + }, + { + "description": "Layer", + "name": "Layer", + "type": "layer" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "Expression", + "name": "RotatedX", + "private": true, + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "Cos", + "=", + "cos(ToRad(RotationAngle))" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "Sin", + "=", + "sin(ToRad(RotationAngle))" + ] + }, + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "Cos * X - Sin * Y" + ] + } + ], + "variables": [ + { + "folded": true, + "name": "Cos", + "type": "number", + "value": 0 + }, + { + "folded": true, + "name": "Sin", + "type": "number", + "value": 0 + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Rotation angle", + "name": "RotationAngle", + "supplementaryInformation": "Tank::Tank", + "type": "expression" + }, + { + "description": "", + "name": "X", + "type": "expression" + }, + { + "description": "", + "name": "Y", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "Expression", + "name": "RotatedY", + "private": true, + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "Cos", + "=", + "cos(ToRad(RotationAngle))" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "Sin", + "=", + "sin(ToRad(RotationAngle))" + ] + }, + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "Sin * X + Cos * Y" + ] + } + ], + "variables": [ + { + "folded": true, + "name": "Cos", + "type": "number", + "value": 0 + }, + { + "folded": true, + "name": "Sin", + "type": "number", + "value": 0 + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Rotation angle", + "name": "RotationAngle", + "supplementaryInformation": "Tank::Tank", + "type": "expression" + }, + { + "description": "", + "name": "X", + "type": "expression" + }, + { + "description": "", + "name": "Y", + "type": "expression" + } + ], + "objectGroups": [] + } + ], + "eventsBasedBehaviors": [ + { + "description": "Smoothly follow an object at a distance.", + "fullName": "Third person camera", + "name": "ThirdPersonCamera", + "objectType": "", + "quickCustomizationVisibility": "hidden", + "eventsFunctions": [ + { + "fullName": "", + "functionType": "Action", + "name": "onCreated", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::DefineHelperClasses" + }, + "parameters": [ + "", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const { CameraLocalBasis, ObjectLocalBasis } = gdjs.__thirdPersonCameraExtension;\r", + "const object = objects[0];\r", + "const behavior = object.getBehavior(eventsFunctionContext.getBehaviorName(\"Behavior\"));\r", + "behavior.__thirdPersonCameraExtension = {\r", + " cameraLocalBasis: new CameraLocalBasis(object),\r", + " objectlocalBasis: new ObjectLocalBasis(object)\r", + "};" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": false + }, + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "Update private properties through setters to check their values and initialize state." + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::SetRotationHalfwayDuration" + }, + "parameters": [ + "Object", + "Behavior", + "=", + "RotationHalfwayDuration", + "" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::SetElevationHalfwayDuration" + }, + "parameters": [ + "Object", + "Behavior", + "=", + "ElevationHalfwayDuration", + "" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::SetTranslationZHalfwayDuration" + }, + "parameters": [ + "Object", + "Behavior", + "=", + "TranslationZHalfwayDuration", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "Action", + "name": "doStepPreEvents", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasJustBeenCreated", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasJustBeenCreated", + "False", + "" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CameraZ", + "=", + "Object.Object3D::CenterZ()" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::JumpToTargetedRotation" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "IsCalledManually", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::DoMoveCameraCloser" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Move the camera closer to the object. This action must be called after the object has moved for the frame.", + "fullName": "Move the camera closer", + "functionType": "Action", + "name": "MoveCameraCloser", + "sentence": "Move the camera closer to _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "The camera following is called with an action, the call from doStepPreEvents must be disabled to avoid to do it twice." + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BehaviorActivated" + }, + "parameters": [ + "Object", + "Behavior" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "IsCalledManually", + "False", + "" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::DoMoveCameraCloser" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Move the camera closer to the object.", + "fullName": "Do move the camera closer", + "functionType": "Action", + "name": "DoMoveCameraCloser", + "private": true, + "sentence": "Do move the camera closer _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "At each frame, the camera must catchup the target by a given ratio (speed)\ncameraX(t) - targetX = (cameraX(t - 1) - targetX) * (1 - speed)\n\nThe frame rate must not impact on the catch-up speed, we don't want a speed in ratio per frame but a speed ratio per second, like this:\ncameraX(t) - targetX = (cameraX(t - 1s) - targetX) * (1 - speed)\n\nOk, but we still need to process each frame, we can use a exponent for this:\ncameraX(t) - targetX = (cameraX(t - timeDelta) - targetX) * (1 - speed)^timeDelta\ncameraX(t) = targetX + (cameraX(t - timeDelta) - targetX) * exp(timeDelta * ln((1 - speed)))\n\npow is probably more efficient than precalculated log if the speed is changed continuously but this might be rare enough." + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "RotationMode", + "=", + "\"ZYX\"" + ] + }, + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsRotatingWithObject", + "False", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::Slerp" + }, + "parameters": [ + "Object", + "Behavior", + "1 - exp(TimeDelta() * RotationLogSpeed)", + "RotationAngleOffset", + "ElevationAngleOffset", + "" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::UpdateLocalBasis" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::ThirdPersonCamera::MoveToObject" + }, + "parameters": [ + "Object", + "Behavior", + "OffsetX", + "OffsetY", + "OffsetZ", + "" + ] + }, + { + "type": { + "value": "SetCameraCenterX" + }, + "parameters": [ + "", + "-", + "Distance * ForwardX", + "Object.Layer()", + "" + ] + }, + { + "type": { + "value": "SetCameraCenterY" + }, + "parameters": [ + "", + "-", + "Distance * ForwardY", + "Object.Layer()", + "" + ] + }, + { + "type": { + "value": "Scene3D::SetCameraZ" + }, + "parameters": [ + "", + "-", + "Distance * ForwardZ", + "Object.Layer()", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "RotationMode", + "!=", + "\"ZYX\"" + ] + }, + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsRotatingWithObject", + "True", + "" + ] + } + ] + } + ], + "actions": [], + "events": [ + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Z translation", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "CameraZ", + "<", + "Object.Behavior::FreeAreaZMin()" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CameraZ", + "=", + "Object.Behavior::FreeAreaZMin() + (CameraZ - Object.Behavior::FreeAreaZMin()) * exp(TimeDelta() * TranslationZLogSpeed)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "CameraZ", + ">", + "Object.Behavior::FreeAreaZMax()" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CameraZ", + "=", + "Object.Behavior::FreeAreaZMax() + (CameraZ - Object.Behavior::FreeAreaZMax()) * exp(TimeDelta() * TranslationZLogSpeed)" + ] + } + ] + } + ], + "parameters": [] + }, + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Z rotation", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsRotatingWithObject", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedRotationAngle", + "=", + "Object.Angle()" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "RotationMode", + "!=", + "\"Z\"" + ] + }, + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsElevatingWithObject", + "True", + "" + ] + } + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedElevationAngle", + "=", + "Object.Object3D::RotationY()" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CameraRotationAngle", + "=", + "TargetedRotationAngle + 90 + RotationAngleOffset + AngleDifference(CameraAngle(Object.Layer()), TargetedRotationAngle + 90 + RotationAngleOffset) * exp(TimeDelta() * RotationLogSpeed)" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CameraElevationAngle", + "=", + "TargetedElevationAngle + ElevationAngleOffset + AngleDifference(90 - Scene3D::CameraRotationX(Object.Layer()), TargetedElevationAngle + ElevationAngleOffset) * exp(TimeDelta() * ElevationLogSpeed)" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::LookFromDistanceAtPosition3D" + }, + "parameters": [ + "", + "Object.CenterX() + ThirdPersonCamera::RotatedX(CameraRotationAngle, OffsetX, -OffsetY)", + "Object.CenterY() + ThirdPersonCamera::RotatedY(CameraRotationAngle, OffsetX, -OffsetY)", + "CameraZ + OffsetZ", + "Distance", + "CameraRotationAngle", + "CameraElevationAngle", + "Object.Layer()", + "" + ] + } + ], + "variables": [ + { + "folded": true, + "name": "CameraRotationAngle", + "type": "number", + "value": 0 + }, + { + "name": "CameraElevationAngle", + "type": "number", + "value": 0 + } + ] + } + ], + "parameters": [] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "Lerp camera", + "functionType": "Action", + "name": "Slerp", + "private": true, + "sentence": "Lerp the camera rotation to _PARAM0_ with a ratio of _PARAM2_ with rotation offset _PARAM3_° and elevation offset _PARAM4_°", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "/** @type {gdjs.RuntimeObject3D} */", + "const object = objects[0];", + "const ratio = eventsFunctionContext.getArgument(\"Ratio\");", + "const rotationAngleOffset = eventsFunctionContext.getArgument(\"NewRotationAngleOffset\");", + "const elevationAngleOffset = eventsFunctionContext.getArgument(\"NewElevationAngleOffset\");", + "", + "gdjs.__thirdPersonCameraExtension.slerpCamera(object, ratio, rotationAngleOffset, elevationAngleOffset);", + "" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + }, + { + "description": "Ratio", + "name": "Ratio", + "type": "expression" + }, + { + "description": "Rotation angle offset", + "name": "NewRotationAngleOffset", + "type": "expression" + }, + { + "description": "Elevation angle offset", + "name": "NewElevationAngleOffset", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "fullName": "Move to object", + "functionType": "Action", + "name": "MoveToObject", + "private": true, + "sentence": "Change the camera position to _PARAM0_ with offset _PARAM2_, _PARAM3_, _PARAM4_ ", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "/** @type {gdjs.RuntimeObject3D} */", + "const object = objects[0];", + "const behavior = object.getBehavior(eventsFunctionContext.getBehaviorName(\"Behavior\"));", + "const localOffsetX = eventsFunctionContext.getArgument(\"LocalOffsetX\");", + "const localOffsetY = eventsFunctionContext.getArgument(\"LocalOffsetY\");", + "const localOffsetZ = eventsFunctionContext.getArgument(\"LocalOffsetZ\");", + "", + "const layer = object.getInstanceContainer().getLayer(object.getLayer());", + "", + "const { objectlocalBasis } = behavior.__thirdPersonCameraExtension;", + "/** @type {{forward: THREE.Vector3, up: THREE.Vector3, right: THREE.Vector3 }} */", + "const { forward, up, right } = objectlocalBasis;", + "", + "layer.setCameraX(object.getCenterXInScene() + localOffsetX * right.x + localOffsetY * forward.x + localOffsetZ * up.x);", + "layer.setCameraY(object.getCenterYInScene() + localOffsetX * right.y + localOffsetY * forward.y + localOffsetZ * up.y);", + "layer.setCameraZ(object.getCenterZInScene() + localOffsetX * right.z + localOffsetY * forward.z + localOffsetZ * up.z);", + "" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + }, + { + "description": "X offset", + "name": "LocalOffsetX", + "type": "expression" + }, + { + "description": "Y offset", + "name": "LocalOffsetY", + "type": "expression" + }, + { + "description": "Z offset", + "name": "LocalOffsetZ", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "fullName": "Update local basis", + "functionType": "Action", + "name": "UpdateLocalBasis", + "private": true, + "sentence": "Update local basis of _PARAM0_ and the camera", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const object = objects[0];", + "const behavior = object.getBehavior(eventsFunctionContext.getBehaviorName(\"Behavior\"));", + "const { cameraLocalBasis, objectlocalBasis } = behavior.__thirdPersonCameraExtension;", + "cameraLocalBasis.update();", + "objectlocalBasis.update();", + "behavior._setForwardX(cameraLocalBasis.forward.x);", + "behavior._setForwardY(cameraLocalBasis.forward.y);", + "behavior._setForwardZ(cameraLocalBasis.forward.z);", + "" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Rotate the camera all the way to the targeted angle.", + "fullName": "Rotate the camera all the way", + "functionType": "Action", + "name": "JumpToTargetedRotation", + "sentence": "Rotate the camera all the way to the targeted angle of _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsRotatingWithObject", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedRotationAngle", + "=", + "Object.Angle()" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsElevatingWithObject", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedElevationAngle", + "=", + "Object.Object3D::RotationY()" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CameraAngle", + "=", + "TargetedRotationAngle + 90 + RotationAngleOffset" + ] + }, + { + "type": { + "value": "ThirdPersonCamera::LookFromDistanceAtPosition3D" + }, + "parameters": [ + "", + "Object.CenterX() + ThirdPersonCamera::RotatedX(CameraAngle, OffsetX, -OffsetY)", + "Object.CenterY() + ThirdPersonCamera::RotatedY(CameraAngle, OffsetX, -OffsetY)", + "CameraZ + OffsetZ", + "Distance", + "CameraAngle", + "Object.Object3D::RotationY() + ElevationAngleOffset", + "", + "" + ] + } + ], + "variables": [ + { + "folded": true, + "name": "CameraAngle", + "type": "number", + "value": 0 + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the camera rotation.", + "fullName": "Camera rotation", + "functionType": "ExpressionAndCondition", + "name": "RotationAngle", + "private": true, + "sentence": "the camera rotation", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "CameraAngle(Object.Layer())" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Rotate the camera all the way to the targeted angle.", + "fullName": "Rotate the camera all the way", + "functionType": "ActionWithOperator", + "getterName": "RotationAngle", + "name": "SetCameraRotation", + "sentence": "Rotate the camera all the way to the targeted angle of _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "ThirdPersonCamera::LookFromDistanceAtPosition3D" + }, + "parameters": [ + "", + "Object.CenterX() + ThirdPersonCamera::RotatedX(Value, OffsetX, -OffsetY)", + "Object.CenterY() + ThirdPersonCamera::RotatedY(Value, OffsetX, -OffsetY)", + "CameraZ + OffsetZ", + "Distance", + "Value", + "Object.Object3D::RotationY() + ElevationAngleOffset", + "", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the halfway time for rotation of the object.", + "fullName": "Halfway time for rotation", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "RotationHalfwayDuration", + "sentence": "the halfway time for rotation", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "RotationHalfwayDuration" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "RotationHalfwayDuration", + "name": "SetRotationHalfwayDuration", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "ln((1 - speed)) = ln(1 / 2) / halfwatTime" + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "RotationHalfwayDuration", + "=", + "Value" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "RotationLogSpeed", + "=", + "log(0.5) / Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the halfway time for elevation rotation of the object.", + "fullName": "Halfway time for elevation rotation", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "ElevationHalfwayDuration", + "sentence": "the halfway time for elevation rotation", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "ElevationHalfwayDuration" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "ElevationHalfwayDuration", + "name": "SetElevationHalfwayDuration", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "ln((1 - speed)) = ln(1 / 2) / halfwatTime" + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "ElevationHalfwayDuration", + "=", + "Value" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "ElevationLogSpeed", + "=", + "log(0.5) / Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the halfway time on Z axis of the object.", + "fullName": "Halfway time on Z axis", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "TranslationZHalfwayDuration", + "sentence": "the halfway time on Z axis", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "TranslationZHalfwayDuration" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "TranslationZHalfwayDuration", + "name": "SetTranslationZHalfwayDuration", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "ln((1 - speed)) = ln(1 / 2) / halfwatTime" + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TranslationZHalfwayDuration", + "=", + "Value" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TranslationZLogSpeed", + "=", + "log(0.5) / Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Return follow free area bottom border Z.", + "fullName": "Free area Z min", + "functionType": "Expression", + "group": "Private", + "name": "FreeAreaZMin", + "private": true, + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "Object.Object3D::CenterZ() + OffsetZ - FollowFreeAreaZMin" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Return follow free area top border Z.", + "fullName": "Free area Z max", + "functionType": "Expression", + "group": "Private", + "name": "FreeAreaZMax", + "private": true, + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "Object.Object3D::CenterZ() + OffsetZ + FollowFreeAreaZMax" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the follow free area top border on Z axis of the object.", + "fullName": "Follow free area top border on Z axis", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "FollowFreeAreaZMax", + "sentence": "the follow free area top border on Z axis", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "FollowFreeAreaZMax" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "FollowFreeAreaZMax", + "name": "SetFollowFreeAreaZMax", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "FollowFreeAreaZMax", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the follow free area bottom border on Z axis of the object.", + "fullName": "Follow free area bottom border on Z axis", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "FollowFreeAreaZMin", + "sentence": "the follow free area bottom border on Z axis", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "FollowFreeAreaZMin" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "FollowFreeAreaZMin", + "name": "SetFollowFreeAreaZMin", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "FollowFreeAreaZMin", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the camera distance of the object.", + "fullName": "Camera distance", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "Distance", + "sentence": "the camera distance", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "Distance" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "Distance", + "name": "SetDistance", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "Distance", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the lateral distance offset of the object.", + "fullName": "Lateral distance offset", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "OffsetX", + "sentence": "the lateral distance offset", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "OffsetX" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "OffsetX", + "name": "SetOffsetX", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "OffsetX", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the ahead distance offset of the object.", + "fullName": "Ahead distance offset", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "OffsetY", + "sentence": "the ahead distance offset", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "OffsetY" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "OffsetY", + "name": "SetOffsetY", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "OffsetY", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the z offset of the object.", + "fullName": "Z offset", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "OffsetZ", + "sentence": "the z offset", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "OffsetZ" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "OffsetZ", + "name": "SetOffsetZ", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "OffsetZ", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the rotation angle offset of the object.", + "fullName": "Rotation angle offset", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "RotationAngleOffset", + "sentence": "the rotation angle offset", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "RotationAngleOffset" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "RotationAngleOffset", + "name": "SetRotationAngleOffset", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "RotationAngleOffset", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the elevation angle offset of the object.", + "fullName": "Elevation angle offset", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "ElevationAngleOffset", + "sentence": "the elevation angle offset", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "ElevationAngleOffset" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "ElevationAngleOffset", + "name": "SetElevationAngleOffset", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "ElevationAngleOffset", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the targeted camera rotation angle of the object. When this angle is set, the camera follow this value instead of the object angle.", + "fullName": "Targeted rotation angle", + "functionType": "ExpressionAndCondition", + "group": "Third person camera configuration", + "name": "TargetedRotationAngle", + "sentence": "the targeted camera rotation angle", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "TargetedRotationAngle" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "TargetedRotationAngle", + "name": "SetTargetedRotationAngle", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedRotationAngle", + "=", + "Value" + ] + }, + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "IsRotatingWithObject", + "False", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "ThirdPersonCamera::ThirdPersonCamera", + "type": "behavior" + } + ], + "objectGroups": [] + } + ], + "propertyDescriptors": [ + { + "value": "", + "type": "Behavior", + "label": "3D capability", + "extraInformation": [ + "Scene3D::Base3DBehavior" + ], + "choices": [], + "name": "Object3D" + }, + { + "value": "0.125", + "type": "Number", + "unit": "Second", + "label": "Halfway time for rotation", + "group": "Catch-up speed", + "quickCustomizationVisibility": "hidden", + "name": "RotationHalfwayDuration" + }, + { + "value": "0", + "type": "Number", + "unit": "Second", + "label": "Halfway time for elevation rotation", + "description": "Only used by Z and ZY rotation modes", + "group": "Catch-up speed", + "quickCustomizationVisibility": "hidden", + "name": "ElevationHalfwayDuration" + }, + { + "value": "0.125", + "type": "Number", + "unit": "Second", + "label": "Halfway time on Z axis", + "description": "Only used by Z and ZY rotation modes", + "group": "Catch-up speed", + "quickCustomizationVisibility": "hidden", + "name": "TranslationZHalfwayDuration" + }, + { + "value": "500", + "type": "Number", + "unit": "Pixel", + "label": "Camera distance", + "group": "Position", + "name": "Distance" + }, + { + "value": "0", + "type": "Number", + "unit": "Pixel", + "label": "Lateral distance offset", + "group": "Position", + "name": "OffsetX" + }, + { + "value": "0", + "type": "Number", + "unit": "Pixel", + "label": "Ahead distance offset", + "group": "Position", + "name": "OffsetY" + }, + { + "value": "0", + "type": "Number", + "unit": "Pixel", + "label": "Z offset", + "group": "Position", + "name": "OffsetZ" + }, + { + "value": "0", + "type": "Number", + "unit": "DegreeAngle", + "label": "Rotation angle offset", + "group": "Position", + "advanced": true, + "name": "RotationAngleOffset" + }, + { + "value": "20", + "type": "Number", + "unit": "DegreeAngle", + "label": "Elevation angle offset", + "group": "Position", + "name": "ElevationAngleOffset" + }, + { + "value": "0", + "type": "Number", + "unit": "Pixel", + "label": "Follow free area top border on Z axis", + "group": "Position", + "advanced": true, + "quickCustomizationVisibility": "hidden", + "name": "FollowFreeAreaZMax" + }, + { + "value": "0", + "type": "Number", + "unit": "Pixel", + "label": "Follow free area bottom border on Z axis", + "group": "Position", + "advanced": true, + "quickCustomizationVisibility": "hidden", + "name": "FollowFreeAreaZMin" + }, + { + "value": "", + "type": "Number", + "label": "", + "hidden": true, + "name": "RotationLogSpeed" + }, + { + "value": "", + "type": "Number", + "label": "", + "hidden": true, + "name": "ElevationLogSpeed" + }, + { + "value": "", + "type": "Number", + "label": "", + "hidden": true, + "name": "TranslationZLogSpeed" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "IsCalledManually" + }, + { + "value": "0", + "type": "Number", + "unit": "Pixel", + "label": "", + "hidden": true, + "name": "CameraZ" + }, + { + "value": "true", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HasJustBeenCreated" + }, + { + "value": "true", + "type": "Boolean", + "label": "Automatically rotate the camera with the object", + "quickCustomizationVisibility": "hidden", + "name": "IsRotatingWithObject" + }, + { + "value": "false", + "type": "Boolean", + "label": "Automatically rotate the camera with the object (elevation)", + "description": "Best left unchecked, use the rotation mode instead", + "deprecated": true, + "quickCustomizationVisibility": "hidden", + "name": "IsElevatingWithObject" + }, + { + "value": "Z", + "type": "Choice", + "label": "Rotation mode", + "choices": [ + { + "label": "Horizontal rotation (good for characters)", + "value": "Z" + }, + { + "label": "Vertical and horizontal rotations (good for cars)", + "value": "ZY" + }, + { + "label": "All rotations (good for spaceships)", + "value": "ZYX" + } + ], + "name": "RotationMode" + }, + { + "value": "0", + "type": "Number", + "unit": "DegreeAngle", + "label": "Targeted camera rotation angle", + "hidden": true, + "name": "TargetedRotationAngle" + }, + { + "value": "0", + "type": "Number", + "unit": "DegreeAngle", + "label": "Targeted camera rotation angle", + "hidden": true, + "name": "TargetedElevationAngle" + }, + { + "value": "0", + "type": "Number", + "unit": "Pixel", + "label": "Forward X", + "hidden": true, + "name": "ForwardX" + }, + { + "value": "0", + "type": "Number", + "unit": "Pixel", + "label": "Forward Y", + "hidden": true, + "name": "ForwardY" + }, + { + "value": "0", + "type": "Number", + "unit": "Pixel", + "label": "Forward Z", + "hidden": true, + "name": "ForwardZ" + } + ], + "sharedPropertyDescriptors": [] + } + ], + "eventsBasedObjects": [] + }, + { + "author": "", + "category": "Movement", + "extensionNamespace": "", + "fullName": "Top-down walk", + "gdevelopVersion": ">=5.5.222", + "helpPath": "", + "iconUrl": "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmVyc2lvbj0iMS4xIiBpZD0ibWRpLXdhbGsiIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTQuMTIsMTBIMTlWOC4ySDE1LjM4TDEzLjM4LDQuODdDMTMuMDgsNC4zNyAxMi41NCw0LjAzIDExLjkyLDQuMDNDMTEuNzQsNC4wMyAxMS41OCw0LjA2IDExLjQyLDQuMTFMNiw1LjhWMTFINy44VjcuMzNMOS45MSw2LjY3TDYsMjJINy44TDEwLjY3LDEzLjg5TDEzLDE3VjIySDE0LjhWMTUuNTlMMTIuMzEsMTEuMDVMMTMuMDQsOC4xOE0xNCwzLjhDMTUsMy44IDE1LjgsMyAxNS44LDJDMTUuOCwxIDE1LDAuMiAxNCwwLjJDMTMsMC4yIDEyLjIsMSAxMi4yLDJDMTIuMiwzIDEzLDMuOCAxNCwzLjhaIiAvPjwvc3ZnPg==", + "name": "Walk3D", + "previewIconUrl": "https://asset-resources.gdevelop.io/public-resources/Icons/941323cf01b837b2eb512ecbf0a95add8a195b3696eb6f5865dc090e526dc9b3_walk.svg", + "shortDescription": "Turn and move objects forward and sideways.", + "version": "0.2.1", + "description": "Move objects forward and sideways according to the direction they're facing.", + "origin": { + "identifier": "Walk3D", + "name": "gdevelop-extension-store" + }, + "tags": [ + "" + ], + "authorIds": [ + "IWykYNRvhCZBN3vEgKEbBPOR3Oc2", + "oc974hW1zSYZfAnRbpKoXizqc1D3", + "3qThSVKAPdP03MXTWNpe2QaNxpv1" + ], + "dependencies": [], + "globalVariables": [], + "sceneVariables": [], + "eventsFunctions": [], + "eventsBasedBehaviors": [ + { + "description": "Turn and move objects forward and sideways.", + "fullName": "Top-down walk", + "name": "Walk3D", + "objectType": "", + "eventsFunctions": [ + { + "fullName": "", + "functionType": "Action", + "name": "doStepPreEvents", + "sentence": "", + "events": [ + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Rotation", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "PreviousRotationSpeed", + "=", + "CurrentRotationSpeed" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedTurnLeft", + "True", + "" + ] + }, + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedTurnRight", + "True", + "" + ] + }, + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedTurnLeftLast", + "True", + "" + ] + } + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedRotationSpeed", + "=", + "-RotationSpeedMax" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedTurnRight", + "True", + "" + ] + }, + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedTurnLeft", + "True", + "" + ] + }, + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedTurnLeftLast", + "True", + "" + ] + } + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedRotationSpeed", + "=", + "RotationSpeedMax" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TargetedRotationSpeed", + "<", + "0" + ] + } + ], + "actions": [], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousRotationSpeed", + "<=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentRotationSpeed", + "=", + "max(CurrentRotationSpeed - RotationAcceleration * TimeDelta(), TargetedRotationSpeed)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousRotationSpeed", + ">", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentRotationSpeed", + "=", + "max(CurrentRotationSpeed - (RotationAcceleration + RotationDeceleration) * TimeDelta(), TargetedRotationSpeed)" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TargetedRotationSpeed", + ">", + "0" + ] + } + ], + "actions": [], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousRotationSpeed", + ">=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentRotationSpeed", + "=", + "min(CurrentRotationSpeed + RotationAcceleration * TimeDelta(), TargetedRotationSpeed)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousRotationSpeed", + "<", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentRotationSpeed", + "=", + "min(CurrentRotationSpeed + (RotationAcceleration + RotationDeceleration) * TimeDelta(), TargetedRotationSpeed)" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TargetedRotationSpeed", + "=", + "0" + ] + } + ], + "actions": [], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousRotationSpeed", + ">=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentRotationSpeed", + "=", + "max(CurrentRotationSpeed - RotationDeceleration * TimeDelta(), 0)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousRotationSpeed", + "<", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentRotationSpeed", + "=", + "min(CurrentRotationSpeed + RotationDeceleration * TimeDelta(), 0)" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetAngle" + }, + "parameters": [ + "Object", + "+", + "(PreviousRotationSpeed + CurrentRotationSpeed) / 2 * TimeDelta()" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedTurnLeft", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedTurnLeft", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedTurnLeft", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedTurnLeft", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedTurnRight", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedTurnRight", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedTurnRight", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedTurnRight", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedTurnLeft", + "False", + "" + ] + }, + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedTurnRight", + "False", + "" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedRotationSpeed", + "=", + "0" + ] + } + ] + } + ], + "parameters": [] + }, + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Translation", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Forward", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "PreviousForwardSpeed", + "=", + "CurrentForwardSpeed" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveBackward", + "True", + "" + ] + }, + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveForward", + "True", + "" + ] + }, + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveBackwardLast", + "True", + "" + ] + } + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedForwardSpeed", + "=", + "-TranslationSpeedMax" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveForward", + "True", + "" + ] + }, + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveBackward", + "True", + "" + ] + }, + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveBackwardLast", + "True", + "" + ] + } + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedForwardSpeed", + "=", + "TranslationSpeedMax" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TargetedForwardSpeed", + "<", + "0" + ] + } + ], + "actions": [], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousForwardSpeed", + "<=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentForwardSpeed", + "=", + "max(CurrentForwardSpeed - TranslationAcceleration * TimeDelta(), TargetedForwardSpeed)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousForwardSpeed", + ">", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentForwardSpeed", + "=", + "max(CurrentForwardSpeed - (TranslationAcceleration + TranslationDeceleration) * TimeDelta(), TargetedForwardSpeed)" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TargetedForwardSpeed", + ">", + "0" + ] + } + ], + "actions": [], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousForwardSpeed", + ">=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentForwardSpeed", + "=", + "min(CurrentForwardSpeed + TranslationAcceleration * TimeDelta(), TargetedForwardSpeed)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousForwardSpeed", + "<", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentForwardSpeed", + "=", + "min(CurrentForwardSpeed + (TranslationAcceleration + TranslationDeceleration) * TimeDelta(), TargetedForwardSpeed)" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TargetedForwardSpeed", + "=", + "0" + ] + } + ], + "actions": [], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousForwardSpeed", + ">=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentForwardSpeed", + "=", + "max(CurrentForwardSpeed - TranslationDeceleration * TimeDelta(), 0)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousForwardSpeed", + "<", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentForwardSpeed", + "=", + "min(CurrentForwardSpeed + TranslationDeceleration * TimeDelta(), 0)" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HadPressedMoveBackward", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedMoveBackward", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HadPressedMoveBackward", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedMoveBackward", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveForward", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedMoveForward", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveForward", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedMoveForward", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveBackward", + "False", + "" + ] + }, + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveForward", + "False", + "" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedForwardSpeed", + "=", + "0" + ] + } + ] + } + ], + "parameters": [] + }, + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Sideways", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "PreviousSidewaysSpeed", + "=", + "CurrentSidewaysSpeed" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveLeft", + "True", + "" + ] + }, + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveRight", + "True", + "" + ] + }, + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveLeftLast", + "True", + "" + ] + } + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedSidewaysSpeed", + "=", + "-TranslationSpeedMax" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveRight", + "True", + "" + ] + }, + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveLeft", + "True", + "" + ] + }, + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveLeftLast", + "True", + "" + ] + } + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedSidewaysSpeed", + "=", + "TranslationSpeedMax" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TargetedSidewaysSpeed", + "<", + "0" + ] + } + ], + "actions": [], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousSidewaysSpeed", + "<=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentSidewaysSpeed", + "=", + "max(CurrentSidewaysSpeed - TranslationAcceleration * TimeDelta(), TargetedSidewaysSpeed)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousSidewaysSpeed", + ">", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentSidewaysSpeed", + "=", + "max(CurrentSidewaysSpeed - (TranslationAcceleration + TranslationDeceleration) * TimeDelta(), TargetedSidewaysSpeed)" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TargetedSidewaysSpeed", + ">", + "0" + ] + } + ], + "actions": [], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousSidewaysSpeed", + ">=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentSidewaysSpeed", + "=", + "min(CurrentSidewaysSpeed + TranslationAcceleration * TimeDelta(), TargetedSidewaysSpeed)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousSidewaysSpeed", + "<", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentSidewaysSpeed", + "=", + "min(CurrentSidewaysSpeed + (TranslationAcceleration + TranslationDeceleration) * TimeDelta(), TargetedSidewaysSpeed)" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TargetedSidewaysSpeed", + "=", + "0" + ] + } + ], + "actions": [], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousSidewaysSpeed", + ">=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentSidewaysSpeed", + "=", + "max(CurrentSidewaysSpeed - TranslationDeceleration * TimeDelta(), 0)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "PreviousSidewaysSpeed", + "<", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentSidewaysSpeed", + "=", + "min(CurrentSidewaysSpeed + TranslationDeceleration * TimeDelta(), 0)" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HadPressedMoveLeft", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedMoveLeft", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HadPressedMoveLeft", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedMoveLeft", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveRight", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedMoveRight", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HasPressedMoveRight", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HadPressedMoveRight", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveLeft", + "False", + "" + ] + }, + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveRight", + "False", + "" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedSidewaysSpeed", + "=", + "0" + ] + } + ] + } + ], + "parameters": [] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "MettreAutour" + }, + "parameters": [ + "Object", + "Object", + "(PreviousForwardSpeed + CurrentForwardSpeed) / 2 * TimeDelta()", + "Object.Angle()" + ] + }, + { + "type": { + "value": "MettreAutour" + }, + "parameters": [ + "Object", + "Object", + "(PreviousSidewaysSpeed + CurrentSidewaysSpeed) / 2 * TimeDelta()", + "Object.Angle() + 90" + ] + } + ] + } + ], + "parameters": [] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Simulate a press of the turn left key.", + "fullName": "Simulate turn left key press", + "functionType": "Action", + "group": "Top-down walk state", + "name": "SimulateTurnLeftKey", + "sentence": "Simulate pressing turn left key for _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HadPressedTurnLeft", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedTurnLeftLast", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedTurnLeft", + "True", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Simulate a press of the turn right key.", + "fullName": "Simulate turn right key press", + "functionType": "Action", + "group": "Top-down walk state", + "name": "SimulateTurnRightKey", + "sentence": "Simulate pressing turn right key for _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HadPressedTurnRight", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedTurnLeftLast", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedTurnRight", + "True", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Simulate a press of the move backward key.", + "fullName": "Simulate move backward key press", + "functionType": "Action", + "group": "Top-down walk state", + "name": "SimulateMoveBackwardKey", + "sentence": "Simulate pressing move backward key for _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HadPressedMoveBackward", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveBackwardLast", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveBackward", + "True", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Simulate a press of the move forward key.", + "fullName": "Simulate move forward key press", + "functionType": "Action", + "group": "Top-down walk state", + "name": "SimulateMoveForwardKey", + "sentence": "Simulate pressing move forward key for _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HadPressedMoveForward", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveBackwardLast", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveForward", + "True", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Simulate a press of the move left key.", + "fullName": "Simulate move left key press", + "functionType": "Action", + "group": "Top-down walk state", + "name": "SimulateMoveLeftKey", + "sentence": "Simulate pressing move left key for _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HadPressedMoveLeft", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveLeftLast", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveLeft", + "True", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Simulate a press of the move right key.", + "fullName": "Simulate move right key press", + "functionType": "Action", + "group": "Top-down walk state", + "name": "SimulateMoveRightKey", + "sentence": "Simulate pressing move right key for _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "HadPressedMoveRight", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveLeftLast", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "HasPressedMoveRight", + "True", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Simulate a stick control.", + "fullName": "Simulate stick control", + "functionType": "Action", + "group": "Top-down walk state", + "name": "SimulateMoveStick", + "sentence": "Simulate a stick control for _PARAM0_ with a _PARAM2_ angle and a _PARAM3_ force", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "Denormilize the targeted speed.\nIt projects the circle on a square with sides length of the circle diameter." + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "Walk3D::Walk3D::SetSharedPropertyCos" + }, + "parameters": [ + "Object", + "Behavior", + "=", + "cos(ToRad(-Angle))" + ] + }, + { + "type": { + "value": "Walk3D::Walk3D::SetSharedPropertySin" + }, + "parameters": [ + "Object", + "Behavior", + "=", + "sin(ToRad(-Angle))" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BuiltinCommonInstructions::CompareNumbers" + }, + "parameters": [ + "abs(Cos)", + ">=", + "abs(Sin)" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedSidewaysSpeed", + "=", + "Force * TranslationSpeedMax * sign(Cos)" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedForwardSpeed", + "=", + "Force * TranslationSpeedMax * Sin / abs(Cos)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BuiltinCommonInstructions::CompareNumbers" + }, + "parameters": [ + "abs(Cos)", + "<=", + "abs(Sin)" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedSidewaysSpeed", + "=", + "Force * TranslationSpeedMax * Cos / abs(Sin)" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedForwardSpeed", + "=", + "Force * TranslationSpeedMax * sign(Sin)" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + }, + { + "description": "Stick angle (in degrees)", + "name": "Angle", + "type": "expression" + }, + { + "description": "Stick force (between 0 and 1)", + "name": "Force", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": "Simulate a stick control for rotation.", + "fullName": "Simulate stick control for rotation", + "functionType": "Action", + "group": "Top-down walk state", + "name": "SimulateRotationStick", + "sentence": "Simulate a stick control for rotation of _PARAM0_ with an axis value of _PARAM2_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TargetedRotationSpeed", + "=", + "Value * RotationSpeedMax" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + }, + { + "description": "Axis value (between -1 and 1)", + "name": "Value", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": "the current rotation speed of the object.", + "fullName": "Current rotation speed", + "functionType": "ExpressionAndCondition", + "group": "Top-down walk state", + "name": "CurrentRotationSpeed", + "sentence": "the current rotation speed", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "CurrentRotationSpeed" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "CurrentRotationSpeed", + "name": "SetCurrentRotationSpeed", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentRotationSpeed", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the current forward speed of the object.", + "fullName": "Current forward speed", + "functionType": "ExpressionAndCondition", + "group": "Top-down walk state", + "name": "CurrentForwardSpeed", + "sentence": "the current forward speed", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "CurrentForwardSpeed" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "CurrentForwardSpeed", + "name": "SetCurrentForwardSpeed", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentForwardSpeed", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the current sideways speed of the object.", + "fullName": "Current sideways speed", + "functionType": "ExpressionAndCondition", + "group": "Top-down walk state", + "name": "CurrentSidewaysSpeed", + "sentence": "the current sideways speed", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "CurrentSidewaysSpeed" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "CurrentSidewaysSpeed", + "name": "SetCurrentSidewaysSpeed", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "CurrentSidewaysSpeed", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the maximum rotation speed of the object.", + "fullName": "Maximum rotation speed", + "functionType": "ExpressionAndCondition", + "group": "Top-down walk configuration", + "name": "RotationSpeedMax", + "sentence": "the maximum rotation speed", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "RotationSpeedMax" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "RotationSpeedMax", + "name": "SetRotationSpeedMax", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "RotationSpeedMax", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the rotation acceleration of the object.", + "fullName": "Rotation acceleration", + "functionType": "ExpressionAndCondition", + "group": "Top-down walk configuration", + "name": "RotationAcceleration", + "sentence": "the rotation acceleration", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "RotationAcceleration" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "RotationAcceleration", + "name": "SetRotationAcceleration", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "RotationAcceleration", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the rotation deceleration of the object.", + "fullName": "Rotation deceleration", + "functionType": "ExpressionAndCondition", + "group": "Top-down walk configuration", + "name": "RotationDeceleration", + "sentence": "the rotation deceleration", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "RotationDeceleration" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "RotationDeceleration", + "name": "SetRotationDeceleration", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "RotationDeceleration", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the maximum speed of the object.", + "fullName": "Maximum speed", + "functionType": "ExpressionAndCondition", + "group": "Top-down walk configuration", + "name": "TranslationSpeedMax", + "sentence": "the maximum speed", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "TranslationSpeedMax" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "TranslationSpeedMax", + "name": "SetTranslationSpeedMax", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TranslationSpeedMax", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the acceleration of the object.", + "fullName": "Acceleration", + "functionType": "ExpressionAndCondition", + "group": "Top-down walk configuration", + "name": "TranslationAcceleration", + "sentence": "the acceleration", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "TranslationAcceleration" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "TranslationAcceleration", + "name": "SetTranslationAcceleration", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TranslationAcceleration", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the deceleration of the object.", + "fullName": "Deceleration", + "functionType": "ExpressionAndCondition", + "group": "Top-down walk configuration", + "name": "TranslationDeceleration", + "sentence": "the deceleration", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "TranslationDeceleration" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "TranslationDeceleration", + "name": "SetTranslationDeceleration", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TranslationDeceleration", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "Walk3D::Walk3D", + "type": "behavior" + } + ], + "objectGroups": [] + } + ], + "propertyDescriptors": [ + { + "value": "180", + "type": "Number", + "unit": "AngularSpeed", + "label": "Maximum rotation speed", + "group": "Rotation", + "name": "RotationSpeedMax" + }, + { + "value": "720", + "type": "Number", + "label": "Rotation acceleration", + "group": "Rotation", + "name": "RotationAcceleration" + }, + { + "value": "720", + "type": "Number", + "label": "Rotation deceleration", + "group": "Rotation", + "name": "RotationDeceleration" + }, + { + "value": "400", + "type": "Number", + "unit": "PixelSpeed", + "label": "Maximum speed", + "name": "TranslationSpeedMax" + }, + { + "value": "1600", + "type": "Number", + "unit": "PixelAcceleration", + "label": "Acceleration", + "name": "TranslationAcceleration" + }, + { + "value": "1600", + "type": "Number", + "unit": "PixelAcceleration", + "label": "Deceleration", + "name": "TranslationDeceleration" + }, + { + "value": "0", + "type": "Number", + "unit": "AngularSpeed", + "label": "Current rotation speed", + "hidden": true, + "name": "CurrentRotationSpeed" + }, + { + "value": "0", + "type": "Number", + "label": "", + "hidden": true, + "name": "PreviousRotationSpeed" + }, + { + "value": "0", + "type": "Number", + "unit": "PixelSpeed", + "label": "Current forward speed", + "hidden": true, + "name": "CurrentForwardSpeed" + }, + { + "value": "0", + "type": "Number", + "unit": "PixelSpeed", + "label": "Current sideways speed", + "hidden": true, + "name": "CurrentSidewaysSpeed" + }, + { + "value": "0", + "type": "Number", + "label": "", + "hidden": true, + "name": "PreviousForwardSpeed" + }, + { + "value": "0", + "type": "Number", + "label": "", + "hidden": true, + "name": "PreviousSidewaysSpeed" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HasPressedTurnLeft" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HasPressedTurnRight" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HasPressedTurnLeftLast" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HadPressedTurnLeft" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HadPressedTurnRight" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HasPressedMoveForward" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HasPressedMoveBackward" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HadPressedMoveForward" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HadPressedMoveBackward" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HasPressedMoveBackwardLast" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HasPressedMoveLeft" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HasPressedMoveRight" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HadPressedMoveLeft" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HadPressedMoveRight" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "HasPressedMoveLeftLast" + }, + { + "value": "0", + "type": "Number", + "label": "", + "hidden": true, + "name": "TargetedForwardSpeed" + }, + { + "value": "0", + "type": "Number", + "label": "", + "hidden": true, + "name": "TargetedSidewaysSpeed" + }, + { + "value": "0", + "type": "Number", + "label": "", + "hidden": true, + "name": "TargetedRotationSpeed" + } + ], + "sharedPropertyDescriptors": [ + { + "value": "0", + "type": "Number", + "label": "", + "hidden": true, + "name": "Cos" + }, + { + "value": "0", + "type": "Number", + "label": "", + "name": "Sin" + } + ] + } + ], + "eventsBasedObjects": [] + }, + { + "author": "PANDAKO-GitHub", + "category": "Input", + "extensionNamespace": "", + "fullName": "Mouse Pointer Lock", + "gdevelopVersion": ">=5.5.222", + "helpPath": "", + "iconUrl": "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4NCjwhLS0gR2VuZXJhdG9yOiBBZG9iZSBJbGx1c3RyYXRvciAyMy4wLjMsIFNWRyBFeHBvcnQgUGx1Zy1JbiAuIFNWRyBWZXJzaW9uOiA2LjAwIEJ1aWxkIDApICAtLT4NCjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iSWNvbnMiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4Ig0KCSB2aWV3Qm94PSIwIDAgMzIgMzIiIHN0eWxlPSJlbmFibGUtYmFja2dyb3VuZDpuZXcgMCAwIDMyIDMyOyIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+DQo8c3R5bGUgdHlwZT0idGV4dC9jc3MiPg0KCS5zdDB7ZmlsbDpub25lO3N0cm9rZTojMDAwMDAwO3N0cm9rZS13aWR0aDoyO3N0cm9rZS1saW5lY2FwOnJvdW5kO3N0cm9rZS1saW5lam9pbjpyb3VuZDtzdHJva2UtbWl0ZXJsaW1pdDoxMDt9DQo8L3N0eWxlPg0KPHBvbHlsaW5lIGNsYXNzPSJzdDAiIHBvaW50cz0iMTksMTkgMjQsMTkgMjQsMjQgIi8+DQo8cG9seWxpbmUgY2xhc3M9InN0MCIgcG9pbnRzPSI2LDIzIDExLDIzIDExLDE4ICIvPg0KPHBhdGggY2xhc3M9InN0MCIgZD0iTTI0LDE5LjRjLTAuNywwLjgtMS40LDEuNi0yLjIsMi40Yy03LDctMTUuMywxMC4yLTE4LjUsN3MtMC4xLTExLjUsNy0xOC41czE1LjMtMTAuMiwxOC41LTcNCgljMS40LDEuNCwxLjYsMy42LDAuOCw2LjMiLz4NCjxwYXRoIGNsYXNzPSJzdDAiIGQ9Ik0xMSwyMi41Yy0wLjMtMC4yLTAuNS0wLjUtMC44LTAuOGMtNy03LTEwLjItMTUuMy03LTE4LjVzMTEuNS0wLjEsMTguNSw3czEwLjIsMTUuMyw3LDE4LjUNCgljLTEuNywxLjctNC44LDEuNi04LjQsMC4xIi8+DQo8L3N2Zz4NCg==", + "name": "MousePointerLock", + "previewIconUrl": "https://resources.gdevelop-app.com/assets/Icons/Line Hero Pack/Master/SVG/Virtual Reality/Virtual Reality_360_rotate_vr_movement.svg", + "shortDescription": "This behavior removes the limit on the distance the mouse can move and hides the cursor.", + "version": "0.3.0", + "description": [ + "This behavior removes the limit on the distance the mouse can move and hides the cursor.", + "", + "For example, a user can rotate or continue to manipulate an object by moving the mouse endlessly ([open the project online](https://editor.gdevelop.io/?project=example://mouse-pointer-lock)).", + "Without the pointer lock, the rotation or operation will stop the moment the pointer reaches the edge of the browser or screen.", + "", + "Game players don't have to worry about leaving the gameplay area or accidentally clicking on another application that moves the mouse focus away from the game.", + "", + "Locking the pointer locks `CursorX()` and `CursorY()` expressions.", + "Use `MovementX()` and `MovementY()` instead.", + "" + ], + "origin": { + "identifier": "MousePointerLock", + "name": "gdevelop-extension-store" + }, + "tags": [ + "mouse", + "lock", + "cursor", + "pointer" + ], + "authorIds": [ + "Zu55H5hcb9YmZTltIVOTAFDJQyB2", + "IWykYNRvhCZBN3vEgKEbBPOR3Oc2" + ], + "dependencies": [], + "globalVariables": [], + "sceneVariables": [ + { + "name": "TouchId", + "type": "number", + "value": -1 + }, + { + "name": "OldX", + "type": "number", + "value": 0 + }, + { + "name": "OldY", + "type": "number", + "value": 0 + }, + { + "name": "TouchSpeedFactor", + "type": "number", + "value": 4 + } + ], + "eventsFunctions": [ + { + "fullName": "", + "functionType": "Action", + "name": "onFirstSceneLoaded", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "class PointerLockHandler {", + " movementX = 0;", + " movementY = 0;", + " retried = false;", + " /**", + " * @type {gdjs.RuntimeGame}", + " */", + " game;", + "", + " /**", + " * @param {gdjs.RuntimeGame} game", + " */", + " constructor(game) {", + " this.game = game;", + " const canvas = game.getRenderer().getCanvas();", + "", + " canvas.addEventListener(\"pointermove\", event => {", + " if (!!document.pointerLockElement) {", + " this.movementX += event.movementX || 0;", + " this.movementY += event.movementY || 0;", + " }", + " }, false);", + "", + " document.addEventListener(\"pointerlockerror\", event => {", + " if (!this.retried) {", + " canvas.requestPointerLock();", + " this.retried = true;", + " }", + " });", + " }", + "", + " requestPointerLock() {", + " const canvas = this.game.getRenderer().getCanvas();", + " if (canvas.requestPointerLock && !document.pointerLockElement) {", + " this.retried = false;", + " canvas.requestPointerLock({ unadjustedMovement: true });", + " }", + " }", + "", + " exitPointerLock() {", + " if (document.exitPointerLock) {", + " document.exitPointerLock();", + " }", + " }", + "", + " isPointerLocked() {", + " return !!document.pointerLockElement;", + " }", + "", + " resetMovement() {", + " this.movementX = 0;", + " this.movementY = 0;", + " }", + "};", + "", + "gdjs._MousePointerLockExtension = { handler: new PointerLockHandler(runtimeScene.getGame()) };", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "Action", + "name": "onScenePostEvents", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const { handler } = gdjs._MousePointerLockExtension;\r", + "\r", + "handler.resetMovement();\r", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "MousePointerLock::isEmulatingPointerLock" + }, + "parameters": [ + "", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "MousePointerLock::SetMovementX" + }, + "parameters": [ + "", + "=", + "(MousePointerLock::TouchX(TouchId) - OldX) * TouchSpeedFactor", + "" + ] + }, + { + "type": { + "value": "MousePointerLock::SetMovementY" + }, + "parameters": [ + "", + "=", + "(MousePointerLock::TouchY(TouchId) - OldY) * TouchSpeedFactor", + "" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "OldX", + "=", + "MousePointerLock::TouchX(TouchId)" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "OldY", + "=", + "MousePointerLock::TouchY(TouchId)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "HasTouchEnded" + }, + "parameters": [ + "", + "TouchId" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TouchId", + "=", + "-1" + ] + } + ] + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "Lock the mouse pointer to hide it.", + "fullName": "Request Pointer Lock", + "functionType": "Action", + "name": "RequestPointerLock", + "sentence": "Request Pointer Lock", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "HasAnyTouchOrMouseStarted" + }, + "parameters": [ + "" + ] + }, + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TouchId", + "=", + "-1" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TouchId", + "=", + "StartedTouchOrMouseId(0)" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "OldX", + "=", + "MousePointerLock::TouchX(TouchId)" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "OldY", + "=", + "MousePointerLock::TouchY(TouchId)" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const { handler } = gdjs._MousePointerLockExtension;\r", + "\r", + "handler.requestPointerLock();\r", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "Unlocks the mouse pointer and show it.", + "fullName": "Exit pointer lock", + "functionType": "Action", + "name": "ExitPointerLock", + "sentence": "Exit pointer lock", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TouchId", + "=", + "-1" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "\r", + "const { handler } = gdjs._MousePointerLockExtension;\r", + "\r", + "handler.exitPointerLock();\r", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "Check if the mouse pointer is locked.", + "fullName": "Pointer is locked", + "functionType": "Condition", + "name": "isPointerLocked", + "sentence": "The mouse pointer is locked", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TouchId", + ">=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TouchId", + "<", + "0" + ] + }, + { + "type": { + "value": "MousePointerLock::isPointerActuallyLocked" + }, + "parameters": [ + "", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "Check if the mouse pointer is actually locked.", + "fullName": "Pointer is actually locked", + "functionType": "Condition", + "name": "isPointerActuallyLocked", + "private": true, + "sentence": "The mouse pointer actually is locked", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "\r", + "const { handler } = gdjs._MousePointerLockExtension;\r", + "\r", + "eventsFunctionContext.returnValue = handler.isPointerLocked();\r", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "Check if the mouse pointer lock is emulated.", + "fullName": "Pointer lock is emulated", + "functionType": "Condition", + "name": "isEmulatingPointerLock", + "private": true, + "sentence": "The mouse pointer is lock is emulated", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "MousePointerLock::isPointerActuallyLocked" + }, + "parameters": [ + "", + "" + ] + }, + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TouchId", + ">=", + "0" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "Check if the locked pointer is moving.", + "fullName": "Locked pointer is moving", + "functionType": "Condition", + "name": "IsMoving", + "sentence": "Locked pointer is moving", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "value": "MousePointerLock::MovementX" + }, + "parameters": [ + "", + "!=", + "0", + "" + ] + }, + { + "type": { + "value": "MousePointerLock::MovementY" + }, + "parameters": [ + "", + "!=", + "0", + "" + ] + } + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "the movement of the locked pointer on the X axis.", + "fullName": "Pointer X movement", + "functionType": "ExpressionAndCondition", + "name": "MovementX", + "sentence": "the movement of the locked pointer on the X axis", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "\r", + "eventsFunctionContext.returnValue = gdjs._MousePointerLockExtension.handler.movementX || 0;\r", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + }, + { + "description": "the movement of the locked pointer on the X axis.", + "fullName": "Pointer X movement", + "functionType": "ActionWithOperator", + "getterName": "MovementX", + "name": "SetMovementX", + "private": true, + "sentence": "the movement of the locked pointer on the X axis", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "\r", + "const value = eventsFunctionContext.getArgument(\"Value\");\r", + "gdjs._MousePointerLockExtension.handler.movementX = value;\r", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "the movement of the pointer on the Y axis.", + "fullName": "Pointer Y movement", + "functionType": "ExpressionAndCondition", + "name": "MovementY", + "sentence": "the movement of the pointer on the Y axis", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "\r", + "eventsFunctionContext.returnValue = gdjs._MousePointerLockExtension.handler.movementY || 0;\r", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + }, + { + "description": "the movement of the locked pointer on the X axis.", + "fullName": "Pointer X movement", + "functionType": "ActionWithOperator", + "getterName": "MovementY", + "name": "SetMovementY", + "private": true, + "sentence": "the movement of the locked pointer on the X axis", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "\r", + "const value = eventsFunctionContext.getArgument(\"Value\");\r", + "gdjs._MousePointerLockExtension.handler.movementY = value;\r", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "Return the X position of a specific touch", + "fullName": "Touch X position", + "functionType": "Expression", + "name": "TouchX", + "private": true, + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const touchId = eventsFunctionContext.getArgument(\"NewTouchId\");", + "eventsFunctionContext.returnValue = runtimeScene.getGame().getInputManager().getTouchX(touchId);", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Touch identifier", + "name": "NewTouchId", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": "Return the Y position of a specific touch", + "fullName": "Touch Y position", + "functionType": "Expression", + "name": "TouchY", + "private": true, + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const touchId = eventsFunctionContext.getArgument(\"NewTouchId\");", + "eventsFunctionContext.returnValue = runtimeScene.getGame().getInputManager().getTouchY(touchId);", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Touch identifier", + "name": "NewTouchId", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": "the speed factor for touch movement.", + "fullName": "Speed factor for touch movement", + "functionType": "ExpressionAndCondition", + "name": "TouchSpeedFactor", + "sentence": "the speed factor for touch movement", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "TouchSpeedFactor" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "TouchSpeedFactor", + "name": "SetTouchSpeedFactor", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TouchSpeedFactor", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [], + "objectGroups": [] + } + ], + "eventsBasedBehaviors": [ + { + "description": "Control camera rotations with a mouse.", + "fullName": "First person camera mouse mapper", + "name": "FirstPersonPointerMapper", + "objectType": "", + "eventsFunctions": [ + { + "fullName": "", + "functionType": "Action", + "name": "doStepPreEvents", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "TODO It's probably a bad idea to rotate the object around Y." + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "MousePointerLock::isPointerLocked" + }, + "parameters": [ + "", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetAngle" + }, + "parameters": [ + "Object", + "+", + "MousePointerLock::MovementX() * HorizontalSpeed / SceneWindowWidth()" + ] + }, + { + "type": { + "value": "Scene3D::Base3DBehavior::SetRotationY" + }, + "parameters": [ + "Object", + "Object3D", + "+", + "MousePointerLock::MovementY() * VerticalSpeed / SceneWindowHeight()" + ] + }, + { + "type": { + "value": "Scene3D::Base3DBehavior::SetRotationY" + }, + "parameters": [ + "Object", + "Object3D", + "=", + "clamp(Object.Object3D::RotationY(), VerticalAngleMin, VerticalAngleMax)" + ] + }, + { + "type": { + "value": "MousePointerLock::FirstPersonPointerMapper::LookFromObjectEyes" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "MouseButtonReleased" + }, + "parameters": [ + "", + "Left" + ] + }, + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "ShouldLock", + "True", + "" + ] + }, + { + "type": { + "inverted": true, + "value": "MousePointerLock::isPointerLocked" + }, + "parameters": [ + "", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "MousePointerLock::RequestPointerLock" + }, + "parameters": [ + "", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Move the camera to look though _PARAM1_ eyes. The object must look to the right when all its angles are 0 and the top of its head be toward Z+.", + "fullName": "Look through object eyes", + "functionType": "Action", + "group": "Layers and cameras", + "name": "LookFromObjectEyes", + "private": true, + "sentence": "Move the camera to look though _PARAM0_ eyes", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "CentreCamera" + }, + "parameters": [ + "", + "Object", + "", + "Object.Layer()", + "" + ] + }, + { + "type": { + "value": "Scene3D::SetCameraZ" + }, + "parameters": [ + "", + "=", + "Object.Object3D::Z() + Object.Object3D::Depth() + OffsetZ", + "", + "" + ] + }, + { + "type": { + "value": "Scene3D::SetCameraRotationX" + }, + "parameters": [ + "", + "=", + "- Object.Object3D::RotationY() + 90", + "GetArgumentAsString(\"Layer\")", + "" + ] + }, + { + "type": { + "value": "Scene3D::SetCameraRotationY" + }, + "parameters": [ + "", + "=", + "Object.Object3D::RotationX()", + "GetArgumentAsString(\"Layer\")", + "" + ] + }, + { + "type": { + "value": "SetCameraAngle" + }, + "parameters": [ + "", + "=", + "Object.Angle() + 90", + "Object.Layer()", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the horizontal rotation speed factor of the object.", + "fullName": "Horizontal rotation speed factor", + "functionType": "ExpressionAndCondition", + "group": "First person camera mouse mapper configuration", + "name": "HorizontalSpeed", + "sentence": "the horizontal rotation speed factor", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "HorizontalSpeed" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "HorizontalSpeed", + "name": "SetHorizontalSpeed", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "HorizontalSpeed", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the vertical rotation speed factor of the object.", + "fullName": "Vertical rotation speed factor", + "functionType": "ExpressionAndCondition", + "group": "First person camera mouse mapper configuration", + "name": "VerticalSpeed", + "sentence": "the vertical rotation speed factor", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "VerticalSpeed" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "VerticalSpeed", + "name": "SetVerticalSpeed", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "VerticalSpeed", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the minimum vertical camera angle of the object.", + "fullName": "Minimum vertical camera angle", + "functionType": "ExpressionAndCondition", + "group": "First person camera mouse mapper configuration", + "name": "VerticalAngleMin", + "sentence": "the minimum vertical camera angle", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "VerticalAngleMin" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "VerticalAngleMin", + "name": "SetVerticalAngleMin", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "VerticalAngleMin", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the maximum vertical camera angle of the object.", + "fullName": "Maximum vertical camera angle", + "functionType": "ExpressionAndCondition", + "group": "First person camera mouse mapper configuration", + "name": "VerticalAngleMax", + "sentence": "the maximum vertical camera angle", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "VerticalAngleMax" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "VerticalAngleMax", + "name": "SetVerticalAngleMax", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "VerticalAngleMax", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the z position offset of the object.", + "fullName": "Z position offset", + "functionType": "ExpressionAndCondition", + "group": "First person camera mouse mapper configuration", + "name": "OffsetZ", + "sentence": "the z position offset", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "OffsetZ" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "ActionWithOperator", + "getterName": "OffsetZ", + "name": "SetOffsetZ", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "OffsetZ", + "=", + "Value" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "MousePointerLock::FirstPersonPointerMapper", + "type": "behavior" + } + ], + "objectGroups": [] + } + ], + "propertyDescriptors": [ + { + "value": "", + "type": "Behavior", + "label": "3D capability", + "extraInformation": [ + "Scene3D::Base3DBehavior" + ], + "choices": [], + "name": "Object3D" + }, + { + "value": "200", + "type": "Number", + "unit": "Dimensionless", + "label": "Horizontal rotation speed factor", + "name": "HorizontalSpeed" + }, + { + "value": "100", + "type": "Number", + "unit": "Dimensionless", + "label": "Vertical rotation speed factor", + "name": "VerticalSpeed" + }, + { + "value": "-90", + "type": "Number", + "unit": "DegreeAngle", + "label": "Minimum vertical camera angle", + "name": "VerticalAngleMin" + }, + { + "value": "90", + "type": "Number", + "unit": "DegreeAngle", + "label": "Maximum vertical camera angle", + "name": "VerticalAngleMax" + }, + { + "value": "0", + "type": "Number", + "unit": "Pixel", + "label": "Z position offset", + "name": "OffsetZ" + }, + { + "value": "true", + "type": "Boolean", + "label": "Lock the pointer on click", + "name": "ShouldLock" + } + ], + "sharedPropertyDescriptors": [] + } + ], + "eventsBasedObjects": [] + }, + { + "author": "", + "category": "General", + "extensionNamespace": "", + "fullName": "3D raycast", + "gdevelopVersion": ">=5.5.222", + "helpPath": "", + "iconUrl": "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmVyc2lvbj0iMS4xIiBpZD0ibWRpLXJheS1zdGFydC1hcnJvdyIgd2lkdGg9IjI0IiBoZWlnaHQ9IjI0IiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGQ9Ik0yMywxMkwxOSwxNlYxM0g2LjgzQzYuNDIsMTQuMTcgNS4zMSwxNSA0LDE1QTMsMyAwIDAsMSAxLDEyQTMsMyAwIDAsMSA0LDlDNS4zMSw5IDYuNDIsOS44MyA2LjgzLDExSDE5VjhMMjMsMTJaIiAvPjwvc3ZnPg==", + "name": "Raycaster3D", + "previewIconUrl": "https://asset-resources.gdevelop.io/public-resources/Icons/8419f46b76bce482c14b4c03b4141a64d457e4cdc92686f3470381f5d2694abd_ray-start-arrow.svg", + "shortDescription": "Find 3D objects that cross a line.", + "version": "0.1.7", + "description": [ + "It can be useful to:", + "- Find 3D objects under the pointer", + "- Target objects from a 1st person view", + "- Make AI that detect objects in their field of view" + ], + "origin": { + "identifier": "Raycaster3D", + "name": "gdevelop-extension-store" + }, + "tags": [ + "3d", + "recast", + "collision" + ], + "authorIds": [ + "IWykYNRvhCZBN3vEgKEbBPOR3Oc2" + ], + "dependencies": [], + "globalVariables": [], + "sceneVariables": [], + "eventsFunctions": [ + { + "fullName": "", + "functionType": "Action", + "name": "onFirstSceneLoaded", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "Raycaster3D::DefineHelperClasses" + }, + "parameters": [ + "", + "" + ] + } + ] + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "Define helper classes JavaScript code.", + "fullName": "Define helper classes", + "functionType": "Action", + "name": "DefineHelperClasses", + "private": true, + "sentence": "Define helper classes JavaScript code", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "if (gdjs.__raycaster3DExtension) {", + " return;", + "}", + "", + "class Raycaster {", + " raycaster = new THREE.Raycaster();", + " pointer = new THREE.Vector2();", + " /** @type {Array} */", + " raycastResults = [];", + " lastDistance = 0;", + " lastPositionX = 0;", + " lastPositionY = 0;", + " lastPositionZ = 0;", + " lastNormal = new THREE.Vector3();", + "", + " /**", + " * @param objectsLists {Hashtable}", + " * @param objects {gdjs.RuntimeObject[]}", + " * @param pointerX {number}", + " * @param pointerY {number}", + " * @param distanceMax {number}", + " */", + " recastFromCamera(objectsLists, objects, pointerX, pointerY, distanceMax) {", + " if (objects.length === 0) {", + " return false;", + " }", + " const object = objects[0];", + " const layer = object.getInstanceContainer().getLayer(object.getLayer());", + " const camera = layer.getRenderer().getThreeCamera();", + "", + " const raycaster = this.raycaster;", + " const pointer = this.pointer;", + " pointer.x = -1 + 2 * pointerX;", + " pointer.y = 1 - 2 * pointerY;", + " raycaster.setFromCamera(pointer, camera);", + " raycaster.far = distanceMax;", + "", + " return this._doRecast(objectsLists, objects);", + " }", + "", + " /**", + " * @param objectsLists {Hashtable}", + " * @param objects {gdjs.RuntimeObject[]}", + " * @param originX {number}", + " * @param originY {number}", + " * @param originZ {number}", + " * @param rotationAngle {number}", + " * @param elevationAngle {number}", + " * @param distanceMax {number}", + " */", + " recastWithAngle(", + " objectsLists,", + " objects,", + " originX,", + " originY,", + " originZ,", + " rotationAngle,", + " elevationAngle,", + " distanceMax", + " ) {", + " if (objects.length === 0) {", + " return false;", + " }", + " const raycaster = this.raycaster;", + " raycaster.ray.origin.set(", + " originX,", + " -originY,", + " originZ,", + " );", + " const rotation = rotationAngle * Math.PI / 180;", + " const elevation = elevationAngle * Math.PI / 180;", + " const cosElevation = Math.cos(elevation);", + " raycaster.ray.direction.set(", + " Math.cos(rotation) * cosElevation,", + " -Math.sin(rotation) * cosElevation,", + " Math.sin(elevation),", + " );", + " raycaster.far = distanceMax;", + "", + " return this._doRecast(objectsLists, objects);", + " }", + "", + " /**", + " * @param objectsLists {Hashtable}", + " * @param objects {gdjs.RuntimeObject[]}", + " * @param originX {number}", + " * @param originY {number}", + " * @param originZ {number}", + " * @param targetX {number}", + " * @param targetY {number}", + " * @param targetZ {number}", + " * @param distanceMax {number}", + " */", + " recastBetweenPosition(", + " objectsLists,", + " objects,", + " originX,", + " originY,", + " originZ,", + " targetX,", + " targetY,", + " targetZ", + " ) {", + " if (objects.length === 0) {", + " return false;", + " }", + " const raycaster = this.raycaster;", + " raycaster.ray.origin.set(", + " originX,", + " -originY,", + " originZ,", + " );", + " const deltaX = targetX - originX;", + " const deltaY = targetY - originY;", + " const deltaZ = targetZ - originZ;", + " const deltaLength = Math.hypot(deltaX, deltaY, deltaZ);", + " raycaster.ray.direction.set(", + " deltaX / deltaLength,", + " -deltaY / deltaLength,", + " deltaZ / deltaLength,", + " );", + " raycaster.far = deltaLength;", + "", + " return this._doRecast(objectsLists, objects);", + " }", + "", + " /**", + " * @param objectsLists {Hashtable}", + " * @param objects {gdjs.RuntimeObject[]}", + " */", + " _doRecast(objectsLists, objects) {", + " const raycastResults = this.raycastResults;", + " let distanceMin = Number.MAX_VALUE;", + " /** @type {gdjs.RuntimeObject | null} */", + " let nearestObject = null;", + " /** @type {THREE.Object3D | null} */", + " let nearestThreeObject = null;", + " for (const object of objects) {", + " raycastResults.length = 0;", + " const threeObject = object.get3DRendererObject();", + " if (!threeObject) {", + " continue;", + " }", + " this.raycaster.intersectObject(threeObject, true, raycastResults);", + " if (raycastResults.length > 0 && raycastResults[0].distance < distanceMin) {", + " const raycastResult = raycastResults[0];", + " distanceMin = raycastResult.distance;", + " nearestObject = object;", + " this.lastDistance = raycastResult.distance;", + " this.lastPositionX = raycastResult.point.x;", + " this.lastPositionY = -raycastResult.point.y;", + " this.lastPositionZ = raycastResult.point.z;", + " this.lastNormal.copy(raycastResult.normal);", + " nearestThreeObject = raycastResult.object;", + " }", + " }", + " if (!nearestObject) {", + " return false;", + " }", + " this.lastNormal.transformDirection(nearestThreeObject.matrixWorld);", + " this.lastNormal.y = -this.lastNormal.y;", + " raycastResults.length = 0;", + " gdjs.evtTools.object.pickOnly(", + " objectsLists,", + " nearestObject", + " );", + " return true;", + " }", + "}", + "", + "gdjs.__raycaster3DExtension = {", + " Raycaster,", + " raycaster: new Raycaster(),", + "}", + "" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [], + "objectGroups": [] + }, + { + "description": "Sends a ray from the given source position and angle, intersecting the closest object. The intersected object will become the only one taken into account.", + "fullName": "Raycast", + "functionType": "Condition", + "group": "Collision", + "name": "RaycastWithAngle", + "sentence": "Cast a ray from _PARAM2_; _PARAM3_; _PARAM4_ toward a rotation of _PARAM5_°, an elevation of _PARAM6_° and max distance of _PARAM7_ against _PARAM1_", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "eventsFunctionContext.returnValue =", + " gdjs.__raycaster3DExtension.raycaster.recastWithAngle(", + " eventsFunctionContext.getObjectsLists(\"Object\"),", + " objects,", + " eventsFunctionContext.getArgument(\"OriginX\"),", + " eventsFunctionContext.getArgument(\"OriginY\"),", + " eventsFunctionContext.getArgument(\"OriginZ\"),", + " eventsFunctionContext.getArgument(\"RotationAngle\"),", + " eventsFunctionContext.getArgument(\"ElevationAngle\"),", + " eventsFunctionContext.getArgument(\"DistanceMax\")", + " );", + "" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [ + { + "description": "Objects to test against the ray", + "name": "Object", + "type": "objectList" + }, + { + "description": "Ray source X position", + "name": "OriginX", + "type": "expression" + }, + { + "description": "Ray source Y position", + "name": "OriginY", + "type": "expression" + }, + { + "description": "Ray source Z position", + "name": "OriginZ", + "type": "expression" + }, + { + "description": "Rotation angle (in degrees)", + "name": "RotationAngle", + "type": "expression" + }, + { + "description": "Elevation angle (in degrees)", + "name": "ElevationAngle", + "type": "expression" + }, + { + "description": "Ray maximum distance (in pixels)", + "name": "DistanceMax", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": "Sends a ray from the given source position to the final point, intersecting the closest object. The intersected object will become the only one taken into account.", + "fullName": "Raycast to a position", + "functionType": "Condition", + "group": "Collision", + "name": "RaycastBetweenPosition", + "sentence": "Cast a ray from _PARAM2_; _PARAM3_; _PARAM4_ to _PARAM5_; _PARAM6_; _PARAM7_ against _PARAM1_", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "eventsFunctionContext.returnValue =", + " gdjs.__raycaster3DExtension.raycaster.recastBetweenPosition(", + " eventsFunctionContext.getObjectsLists(\"Object\"),", + " objects,", + " eventsFunctionContext.getArgument(\"OriginX\"),", + " eventsFunctionContext.getArgument(\"OriginY\"),", + " eventsFunctionContext.getArgument(\"OriginZ\"),", + " eventsFunctionContext.getArgument(\"TargetX\"),", + " eventsFunctionContext.getArgument(\"TargetY\"),", + " eventsFunctionContext.getArgument(\"TargetZ\")", + " );", + "" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [ + { + "description": "Objects to test against the ray", + "name": "Object", + "type": "objectList" + }, + { + "description": "Ray source X position", + "name": "OriginX", + "type": "expression" + }, + { + "description": "Ray source Y position", + "name": "OriginY", + "type": "expression" + }, + { + "description": "Ray source Z position", + "name": "OriginZ", + "type": "expression" + }, + { + "description": "Ray target X position", + "name": "TargetX", + "type": "expression" + }, + { + "description": "Ray target Y position", + "name": "TargetY", + "type": "expression" + }, + { + "description": "Ray target Z position", + "name": "TargetZ", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": "Sends a ray from the center of the camera, intersecting the closest object. The intersected object will become the only one taken into account.", + "fullName": "Raycast from camera center", + "functionType": "Condition", + "group": "Collision", + "name": "RaycastFromCameraCenter", + "sentence": "Cast a ray from the camera center to a maximum distance of _PARAM2_ against _PARAM1_", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "eventsFunctionContext.returnValue =", + " gdjs.__raycaster3DExtension.raycaster.recastFromCamera(", + " eventsFunctionContext.getObjectsLists(\"Object\"),", + " objects,", + " 0.5,", + " 0.5,", + " eventsFunctionContext.getArgument(\"DistanceMax\")", + " );", + "" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [ + { + "description": "Objects to test against the ray", + "name": "Object", + "type": "objectList" + }, + { + "description": "Ray maximum distance (in pixels)", + "name": "DistanceMax", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": "Sends a ray from the given source point on the camera screen, intersecting the closest object. The intersected object will become the only one taken into account.", + "fullName": "Raycast from a camera point", + "functionType": "Condition", + "group": "Collision", + "name": "RaycastFromCameraPoint", + "sentence": "Cast a ray from the camera point _PARAM2_; _PARAM3_ to a maximum distance of _PARAM4_ against _PARAM1_", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "eventsFunctionContext.returnValue =", + " gdjs.__raycaster3DExtension.raycaster.recastFromCamera(", + " eventsFunctionContext.getObjectsLists(\"Object\"),", + " objects,", + " eventsFunctionContext.getArgument(\"PointerX\"),", + " eventsFunctionContext.getArgument(\"PointerY\"),", + " eventsFunctionContext.getArgument(\"DistanceMax\")", + " );", + "" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [ + { + "description": "Objects to test against the ray", + "name": "Object", + "type": "objectList" + }, + { + "description": "X position on the screen (from 0 to 1)", + "name": "PointerX", + "type": "expression" + }, + { + "description": "Y position on the screen (from 0 to 1)", + "name": "PointerY", + "type": "expression" + }, + { + "description": "Ray maximum distance (in pixels)", + "name": "DistanceMax", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": "Sends a ray from the cursor on the camera screen, intersecting the closest object. The intersected object will become the only one taken into account.", + "fullName": "Raycast from cursor", + "functionType": "Condition", + "group": "Collision", + "name": "RaycastFromCameraCursor", + "sentence": "Cast a ray from the cursor on 2D layer: _PARAM2_ to a maximum distance of _PARAM3_ against _PARAM1_", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const { camera, input } = gdjs.evtTools;", + "", + "const layer2D = eventsFunctionContext.getArgument(\"Layer2D\");", + "", + "const cameraMinX = camera.getCameraBorderLeft(runtimeScene, layer2D, 0);", + "const cameraMaxX = camera.getCameraBorderRight(runtimeScene, layer2D, 0);", + "const cameraMinY = camera.getCameraBorderTop(runtimeScene, layer2D, 0);", + "const cameraMaxY = camera.getCameraBorderBottom(runtimeScene, layer2D, 0);", + "", + "const cursorX = input.getCursorX(runtimeScene, layer2D, 0);", + "const cursorY = input.getCursorY(runtimeScene, layer2D, 0);", + "", + "eventsFunctionContext.returnValue =", + " gdjs.__raycaster3DExtension.raycaster.recastFromCamera(", + " eventsFunctionContext.getObjectsLists(\"Object\"),", + " objects,", + " (cursorX - cameraMinX) / (cameraMaxX - cameraMinX),", + " (cursorY - cameraMinY) / (cameraMaxY - cameraMinY),", + " eventsFunctionContext.getArgument(\"DistanceMax\")", + " );", + "" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [ + { + "description": "Objects to test against the ray", + "name": "Object", + "type": "objectList" + }, + { + "description": "2D layer", + "name": "Layer2D", + "type": "layer" + }, + { + "description": "Ray maximum distance (in pixels)", + "name": "DistanceMax", + "type": "expression" + } + ], + "objectGroups": [] + }, + { + "description": "the last recast intersection distance.", + "fullName": "Last recast distance", + "functionType": "ExpressionAndCondition", + "name": "Distance", + "sentence": "the last recast intersection distance", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": "eventsFunctionContext.returnValue = gdjs.__raycaster3DExtension.raycaster.lastDistance;", + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + }, + { + "description": "Return the last recast intersection position on X axis.", + "fullName": "Last recast X intersection", + "functionType": "Expression", + "name": "IntersectionX", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": "eventsFunctionContext.returnValue = gdjs.__raycaster3DExtension.raycaster.lastPositionX;", + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + }, + { + "description": "Return the last recast intersection position on Y axis.", + "fullName": "Last recast Y intersection", + "functionType": "Expression", + "name": "IntersectionY", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": "eventsFunctionContext.returnValue = gdjs.__raycaster3DExtension.raycaster.lastPositionY;", + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + }, + { + "description": "Return the last recast intersection position on Z axis.", + "fullName": "Last recast Z intersection", + "functionType": "Expression", + "name": "IntersectionZ", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": "eventsFunctionContext.returnValue = gdjs.__raycaster3DExtension.raycaster.lastPositionZ;", + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + }, + { + "description": "Return the last recast intersection normal on X axis.", + "fullName": "Last recast X normal", + "functionType": "Expression", + "name": "NormalX", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": "eventsFunctionContext.returnValue = gdjs.__raycaster3DExtension.raycaster.lastNormal.x;", + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + }, + { + "description": "Return the last recast intersection normal on X axis.", + "fullName": "Last recast X normal", + "functionType": "Expression", + "name": "NormalY", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": "eventsFunctionContext.returnValue = gdjs.__raycaster3DExtension.raycaster.lastNormal.y;", + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + }, + { + "description": "Return the last recast intersection normal on Z axis.", + "fullName": "Last recast Z normal", + "functionType": "Expression", + "name": "NormalZ", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": "eventsFunctionContext.returnValue = gdjs.__raycaster3DExtension.raycaster.lastNormal.z;", + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [], + "objectGroups": [] + } + ], + "eventsBasedBehaviors": [], + "eventsBasedObjects": [] + }, + { + "author": "", + "category": "Visual effect", + "extensionNamespace": "", + "fullName": "Wind Waker Ocean 2D Texture ", + "gdevelopVersion": "", + "helpPath": "", + "iconUrl": "", + "name": "WaterShader", + "previewIconUrl": "", + "shortDescription": "A 3D plane with Wind Waker Ocean 2D shader", + "version": "1.0.0", + "description": [ + "Original shader from:", + "https://www.shadertoy.com/view/ltfGD7" + ], + "tags": [], + "authorIds": [], + "dependencies": [], + "globalVariables": [], + "sceneVariables": [], + "eventsFunctions": [], + "eventsBasedBehaviors": [ + { + "description": "", + "fullName": "", + "name": "WaterShader", + "objectType": "", + "eventsFunctions": [ + { + "fullName": "", + "functionType": "Action", + "name": "onCreated", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "if (objects.length > 0) {\r", + " // Target the first selected object in the GDevelop event\r", + " const gdjsObject = objects[0];\r", + " const mesh = gdjsObject.get3DRendererObject();\r", + "\r", + " // Initialize Three.js context. \r", + " // Get the core Three.js renderer instance from the GDevelop game object\r", + " const renderer = runtimeScene.getGame().getRenderer().getThreeRenderer();\r", + "\r", + " // Get the current Three.js camera for uniform data\r", + " const mainCamera = runtimeScene.getLayer()._renderer.getThreeCamera();\r", + "\r", + " // Create the core water shader material\r", + " const waterMaterial = new THREE.ShaderMaterial({\r", + " side: THREE.DoubleSide,\r", + " transparent: true,\r", + " defines: {\r", + " // Define constants for shader logic based on camera type\r", + " ORTHOGRAPHIC_CAMERA: mainCamera.isOrthographicCamera ? 1 : 0\r", + " },\r", + " uniforms: {\r", + " // Animation time uniform (must be updated every frame)\r", + " time: { value: 0 },\r", + " // Colors\r", + " foamColor: { value: new THREE.Color(0xffffff) },\r", + " waterColorSurface: { value: new THREE.Color(0x14c6a5) },\r", + " // Displacement scale for DUDV noise\r", + " displacementMultiplier: { value: 0.005 },\r", + " tiling: { value: 0.5 },\r", + " // Camera properties for depth reconstruction\r", + " cameraNear: { value: mainCamera.near },\r", + " cameraFar: { value: mainCamera.far }\r", + " },\r", + " vertexShader: `\r", + " varying vec2 vPlaneUV;\r", + "\r", + " void main() {\r", + " // Use object local X/Y coordinates as plane UVs for tiling\r", + " vPlaneUV = position.xy; \r", + "\r", + " // Standard Three.js processing\r", + " #include \r", + " #include \r", + " #include \r", + " }\r", + " `,\r", + "\r", + " fragmentShader: `\r", + " // Standard Three.js headers\r", + " #include \r", + " #include \r", + " #include \r", + "\r", + "\r", + " varying vec2 vPlaneUV; \r", + " \r", + " // Uniforms defined in JavaScript\r", + " uniform sampler2D tDudv;\r", + " uniform vec3 foamColor;\r", + " uniform vec3 waterColorSurface;\r", + " uniform float cameraNear;\r", + " uniform float displacementMultiplier;\r", + " uniform float tiling;\r", + " uniform float cameraFar;\r", + " uniform float time;\r", + " uniform vec2 resolution;\r", + "\r", + " // --- Water shader configuration defines ---\r", + " #define ANTIALIAS 1\r", + " #define DISTORT_WATER 1\r", + " #define PARALLAX_WATER 1\r", + " #define FAST_CIRCLES 1\r", + "\r", + " // Secondary, darker water color for texture mixing\r", + " #define waterColorSecondary (waterColorSurface * 0.8) \r", + " #define M_2PI 6.283185307\r", + " #define M_6PI 18.84955592\r", + "\r", + " // Standard PRNG\r", + " float random(vec2 uv) {\r", + " return fract(sin(dot(uv.xy, vec2(12.9898,78.233))) * 43758.5453123);\r", + " }\r", + "\r", + " // Interpolated noise function\r", + " float noise(vec2 uv) {\r", + " vec2 i = floor(uv);\r", + " vec2 f = fract(uv);\r", + " float a = random(i);\r", + " float b = random(i + vec2(1.0, 0.0));\r", + " float c = random(i + vec2(0.0, 1.0));\r", + " float d = random(i + vec2(1.0, 1.0));\r", + " vec2 u = f*f*(3.0-2.0*f);\r", + " return mix(a, b, u.x) + (c - a) * u.y * (1.0 - u.x) + (d - b) * u.x * u.y;\r", + " }\r", + "\r", + " // Fractal Brownian Motion (FBM) for complex noise\r", + " float fbm(vec2 uv) {\r", + " int octaves = 6;\r", + " float amplitude = 0.5;\r", + " float frequency = 3.0;\r", + " float value = 0.0;\r", + " \r", + " for(int i = 0; i < octaves; i++) {\r", + " value += amplitude * noise(frequency * uv);\r", + " amplitude *= 0.5;\r", + " frequency *= 2.0;\r", + " }\r", + " return value;\r", + " }\r", + "\r", + " // Procedural DUDV (distortion map) using FBM\r", + " vec2 proceduralDuDv(vec2 uv, float time) {\r", + " float n1 = fbm(uv + time * 0.1);\r", + " float n2 = fbm(uv * 2.0 - time * 0.2);\r", + " \r", + " // Map from [0,1] -> [-1,1] range\r", + " vec2 dudv = vec2(n1, n2) * 2.0 - 1.0;\r", + " \r", + " return dudv * 0.5; // scale the distortion\r", + " }\r", + "\r", + "\r", + "\r", + " // Function to generate a circle/spot mask\r", + " float circ(vec2 pos, vec2 c, float s) {\r", + " c = abs(pos - c);\r", + " c = min(c, 1.0 - c);\r", + " #if FAST_CIRCLES\r", + " return dot(c,c) < s ? -1.0 : 0.0;\r", + " #else\r", + " return smoothstep(0.0,0.002, sqrt(s)-sqrt(dot(c,c))) * -1.0;\r", + " #endif\r", + " }\r", + "\r", + " // Function to create the water texture layer\r", + " float waterlayer(vec2 uv) {\r", + " uv = mod(uv, 1.0);\r", + " float ret = 1.0;\r", + " ret += circ(uv, vec2(0.37378, 0.277169), 0.0268181);\r", + " ret += circ(uv, vec2(0.0317477, 0.540372), 0.0193742);\r", + " ret += circ(uv, vec2(0.430044, 0.882218), 0.0232337);\r", + " ret += circ(uv, vec2(0.641033, 0.695106), 0.0117864);\r", + " ret += circ(uv, vec2(0.0146398, 0.0791346), 0.0299458);\r", + " ret += circ(uv, vec2(0.43871, 0.394445), 0.0289087);\r", + " ret += circ(uv, vec2(0.909446, 0.878141), 0.028466);\r", + " ret += circ(uv, vec2(0.310149, 0.686637), 0.0128496);\r", + " ret += circ(uv, vec2(0.928617, 0.195986), 0.0152041);\r", + " ret += circ(uv, vec2(0.0438506, 0.868153), 0.0268601);\r", + " ret += circ(uv, vec2(0.308619, 0.194937), 0.00806102);\r", + " ret += circ(uv, vec2(0.349922, 0.449714), 0.00928667);\r", + " ret += circ(uv, vec2(0.0449556, 0.953415), 0.023126);\r", + " ret += circ(uv, vec2(0.117761, 0.503309), 0.0151272);\r", + " ret += circ(uv, vec2(0.563517, 0.244991), 0.0292322);\r", + " ret += circ(uv, vec2(0.566936, 0.954457), 0.00981141);\r", + " ret += circ(uv, vec2(0.0489944, 0.200931), 0.0178746);\r", + " ret += circ(uv, vec2(0.569297, 0.624893), 0.0132408);\r", + " ret += circ(uv, vec2(0.298347, 0.710972), 0.0114426);\r", + " ret += circ(uv, vec2(0.878141, 0.771279), 0.00322719);\r", + " ret += circ(uv, vec2(0.150995, 0.376221), 0.00216157);\r", + " ret += circ(uv, vec2(0.119673, 0.541984), 0.0124621);\r", + " ret += circ(uv, vec2(0.629598, 0.295629), 0.0198736);\r", + " ret += circ(uv, vec2(0.334357, 0.266278), 0.0187145);\r", + " ret += circ(uv, vec2(0.918044, 0.968163), 0.0182928);\r", + " ret += circ(uv, vec2(0.965445, 0.505026), 0.006348);\r", + " ret += circ(uv, vec2(0.514847, 0.865444), 0.00623523);\r", + " ret += circ(uv, vec2(0.710575, 0.0415131), 0.00322689);\r", + " ret += circ(uv, vec2(0.71403, 0.576945), 0.0215641);\r", + " ret += circ(uv, vec2(0.748873, 0.413325), 0.0110795);\r", + " ret += circ(uv, vec2(0.0623365, 0.896713), 0.0236203);\r", + " ret += circ(uv, vec2(0.980482, 0.473849), 0.00573439);\r", + " ret += circ(uv, vec2(0.647463, 0.654349), 0.0188713);\r", + " ret += circ(uv, vec2(0.651406, 0.981297), 0.00710875);\r", + " ret += circ(uv, vec2(0.428928, 0.382426), 0.0298806);\r", + " ret += circ(uv, vec2(0.811545, 0.62568), 0.00265539);\r", + " ret += circ(uv, vec2(0.400787, 0.74162), 0.00486609);\r", + " ret += circ(uv, vec2(0.331283, 0.418536), 0.00598028);\r", + " ret += circ(uv, vec2(0.894762, 0.0657997), 0.00760375);\r", + " ret += circ(uv, vec2(0.525104, 0.572233), 0.0141796);\r", + " ret += circ(uv, vec2(0.431526, 0.911372), 0.0213234);\r", + " ret += circ(uv, vec2(0.658212, 0.910553), 0.000741023);\r", + " ret += circ(uv, vec2(0.514523, 0.243263), 0.0270685);\r", + " ret += circ(uv, vec2(0.0249494, 0.252872), 0.00876653);\r", + " ret += circ(uv, vec2(0.502214, 0.47269), 0.0234534);\r", + " ret += circ(uv, vec2(0.693271, 0.431469), 0.0246533);\r", + " ret += circ(uv, vec2(0.415, 0.884418), 0.0271696);\r", + " ret += circ(uv, vec2(0.149073, 0.41204), 0.00497198);\r", + " ret += circ(uv, vec2(0.533816, 0.897634), 0.00650833);\r", + " ret += circ(uv, vec2(0.0409132, 0.83406), 0.0191398);\r", + " ret += circ(uv, vec2(0.638585, 0.646019), 0.0206129);\r", + " ret += circ(uv, vec2(0.660342, 0.966541), 0.0053511);\r", + " ret += circ(uv, vec2(0.513783, 0.142233), 0.00471653);\r", + " ret += circ(uv, vec2(0.124305, 0.644263), 0.00116724);\r", + " ret += circ(uv, vec2(0.99871, 0.583864), 0.0107329);\r", + " ret += circ(uv, vec2(0.894879, 0.233289), 0.00667092);\r", + " ret += circ(uv, vec2(0.246286, 0.682766), 0.00411623);\r", + " ret += circ(uv, vec2(0.0761895, 0.16327), 0.0145935);\r", + " ret += circ(uv, vec2(0.949386, 0.802936), 0.0100873);\r", + " ret += circ(uv, vec2(0.480122, 0.196554), 0.0110185);\r", + " ret += circ(uv, vec2(0.896854, 0.803707), 0.013969);\r", + " ret += circ(uv, vec2(0.292865, 0.762973), 0.00566413);\r", + " ret += circ(uv, vec2(0.0995585, 0.117457), 0.00869407);\r", + " ret += circ(uv, vec2(0.377713, 0.00335442), 0.0063147);\r", + " ret += circ(uv, vec2(0.506365, 0.531118), 0.0144016);\r", + " ret += circ(uv, vec2(0.408806, 0.894771), 0.0243923);\r", + " ret += circ(uv, vec2(0.143579, 0.85138), 0.00418529);\r", + " ret += circ(uv, vec2(0.0902811, 0.181775), 0.0108896);\r", + " ret += circ(uv, vec2(0.780695, 0.394644), 0.00475475);\r", + " ret += circ(uv, vec2(0.298036, 0.625531), 0.00325285);\r", + " ret += circ(uv, vec2(0.218423, 0.714537), 0.00157212);\r", + " ret += circ(uv, vec2(0.658836, 0.159556), 0.00225897);\r", + " ret += circ(uv, vec2(0.987324, 0.146545), 0.0288391);\r", + " ret += circ(uv, vec2(0.222646, 0.251694), 0.00092276);\r", + " ret += circ(uv, vec2(0.159826, 0.528063), 0.00605293);\r", + " return max(ret, 0.0);\r", + " }\r", + "\r", + " // Main function to sample the water texture and apply distortion/animation\r", + " vec3 waterTex(vec2 uv, float iTime) {\r", + " uv *= 4.0; // Base texture tiling multiplier\r", + "\r", + " #if DISTORT_WATER\r", + " vec2 a = vec2(0.02,0.02);\r", + " float h = sin(uv.x + iTime);\r", + " uv += a*h;\r", + " h = sin(0.841471*uv.x - 0.540302*uv.y + iTime);\r", + " uv += a*h;\r", + " #endif\r", + " \r", + " // Initialize distortion vector. This is calculated separately from parallax.\r", + " vec2 dist = vec2(0.0);\r", + "\r", + " #if PARALLAX_WATER\r", + " // Time-based wave distortion using sine/cosine functions\r", + " float d1 = mod(uv.x+uv.y, M_2PI);\r", + " float d2 = mod((uv.x+uv.y+0.25)*1.3, M_6PI);\r", + " d1 = iTime*0.07 + d1;\r", + " d2 = iTime*0.5 + d2;\r", + " dist = vec2(\r", + " sin(d1)*0.15 + sin(d2)*0.05,\r", + " cos(d1)*0.15 + cos(d2)*0.05\r", + " );\r", + " #endif\r", + "\r", + " // Mix the two water colors using the waterlayer mask\r", + " vec3 base = mix(waterColorSurface, waterColorSecondary, waterlayer(uv+dist));\r", + " // Mix the result with the foam color based on an inverted, distorted layer\r", + " return mix(base, foamColor, waterlayer(vec2(1.0)-uv-dist.yx));\r", + " }\r", + "\r", + "\r", + " void main() { \r", + " \r", + " // Apply DUDV Distortion based on local plane UVs\r", + " vec2 worldUV = vPlaneUV * tiling;\r", + " vec2 dudvUV = worldUV * 0.2 + time * 0.05;\r", + " \r", + " vec2 displacement = proceduralDuDv(worldUV, time);\r", + " worldUV += displacement * displacementMultiplier;\r", + "\r", + " // Get final water color\r", + " vec3 waterCol = waterTex(worldUV, time);\r", + " \r", + " // Set final color and transparency\r", + " \r", + " gl_FragColor.rgb = waterCol;\r", + " gl_FragColor.a = 0.75; // transparency\r", + "\r", + " // Standard Three.js post-processing includes\r", + " #include \r", + " #include \r", + " #include \r", + " }\r", + " `\r", + " });\r", + "\r", + " /**\r", + " * Helper function to apply the water material recursively to all meshes in the object.\r", + " */\r", + " function applyMaterialRecursive(object3D, waterMaterial) {\r", + " object3D.traverse(child => {\r", + " if (child.isMesh) {\r", + " // Handle multi-material objects\r", + " if (Array.isArray(child.material)) {\r", + " child.material = child.material.map(() => waterMaterial);\r", + " }\r", + " // Handle single material objects\r", + " else {\r", + " child.material = waterMaterial;\r", + " }\r", + " child.needsUpdate = true;\r", + " }\r", + " });\r", + " }\r", + "\r", + " applyMaterialRecursive(mesh, waterMaterial);\r", + "\r", + " // Store references on the mesh's userData for the per-frame update script\r", + " mesh.userData.waterMaterial = waterMaterial;\r", + " mesh.userData.mainCamera = mainCamera;\r", + "}" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "WaterShader::WaterShader", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "Action", + "name": "doStepPreEvents", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "// Updates the water shader uniforms\r", + "function updateWaterUniforms(mesh, deltaTime) {\r", + " const mat = mesh.userData.waterMaterial;\r", + " if (!mat) return; // Stop if no water material is attached\r", + "\r", + " // Update time (used to animate waves)\r", + " mat.uniforms.time.value += deltaTime;\r", + "\r", + " // Wave displacement strength\r", + " mat.uniforms.displacementMultiplier.value = 0.01;\r", + "}\r", + "\r", + "// Get the GDevelop object\r", + "const gdjsObject = objects[0];\r", + "\r", + "// Retrieve the 3D mesh from the object\r", + "const mesh = gdjsObject.get3DRendererObject();\r", + "\r", + "// deltaTime in seconds for smooth animations\r", + "const deltaTime = runtimeScene.getElapsedTime() / 1000;\r", + "\r", + "// Apply uniform updates\r", + "updateWaterUniforms(mesh, deltaTime);\r", + "" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "WaterShader::WaterShader", + "type": "behavior" + } + ], + "objectGroups": [] + } + ], + "propertyDescriptors": [], + "sharedPropertyDescriptors": [] + } + ], + "eventsBasedObjects": [ + { + "areaMaxX": 64, + "areaMaxY": 64, + "areaMaxZ": 64, + "areaMinX": 0, + "areaMinY": 0, + "areaMinZ": 0, + "defaultName": "Water_Plane", + "description": "", + "fullName": "Water Plane Three JS", + "is3D": true, + "isUsingLegacyInstancesRenderer": false, + "name": "WaterPlane", + "private": true, + "objects": [ + { + "assetStoreId": "", + "name": "New3DBox", + "type": "Scene3D::Cube3DObject", + "variables": [], + "effects": [], + "behaviors": [], + "content": { + "width": 100, + "height": 100, + "depth": 100, + "enableTextureTransparency": false, + "facesOrientation": "Y", + "frontFaceResourceName": "", + "backFaceResourceName": "", + "backFaceUpThroughWhichAxisRotation": "X", + "leftFaceResourceName": "", + "rightFaceResourceName": "", + "topFaceResourceName": "", + "bottomFaceResourceName": "", + "frontFaceVisible": true, + "backFaceVisible": true, + "leftFaceVisible": true, + "rightFaceVisible": true, + "topFaceVisible": true, + "bottomFaceVisible": true, + "frontFaceResourceRepeat": false, + "backFaceResourceRepeat": false, + "leftFaceResourceRepeat": false, + "rightFaceResourceRepeat": false, + "topFaceResourceRepeat": false, + "bottomFaceResourceRepeat": false, + "materialType": "StandardWithoutMetalness", + "tint": "255;255;255", + "isCastingShadow": true, + "isReceivingShadow": true + } + } + ], + "objectsFolderStructure": { + "folderName": "__ROOT", + "children": [ + { + "objectName": "New3DBox" + } + ] + }, + "objectsGroups": [], + "layers": [ + { + "ambientLightColorB": 200, + "ambientLightColorG": 200, + "ambientLightColorR": 200, + "camera2DPlaneMaxDrawingDistance": 5000, + "camera3DFarPlaneDistance": 10000, + "camera3DFieldOfView": 45, + "camera3DNearPlaneDistance": 3, + "cameraType": "", + "followBaseLayerCamera": false, + "isLightingLayer": false, + "isLocked": false, + "name": "", + "renderingType": "", + "visibility": true, + "cameras": [ + { + "defaultSize": true, + "defaultViewport": true, + "height": 0, + "viewportBottom": 1, + "viewportLeft": 0, + "viewportRight": 1, + "viewportTop": 0, + "width": 0 + } + ], + "effects": [] + } + ], + "instances": [], + "editionSettings": { + "grid": false, + "gridType": "rectangular", + "gridWidth": 32, + "gridHeight": 32, + "gridDepth": 32, + "gridOffsetX": 0, + "gridOffsetY": 0, + "gridOffsetZ": 0, + "gridColor": 10401023, + "gridAlpha": 0.8, + "snap": false, + "zoomFactor": 10.9375, + "windowMask": false, + "selectedLayer": "" + }, + "eventsFunctions": [ + { + "fullName": "", + "functionType": "Action", + "name": "onCreated", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "// Retrieve the GDevelop Custom Runtime Object\r", + "/** @type {gdjs.CustomRuntimeObject} */\r", + "const object = objects[0];\r", + "\r", + "// Define the geometry for a plane. A size of 100x100 is used here.\r", + "const planeGeometry = new THREE.PlaneGeometry(100, 100);\r", + "\r", + "// Define a basic material (cyan color) for the plane.\r", + "// side: THREE.DoubleSide ensures the plane is visible from both sides.\r", + "const planeMaterial = new THREE.MeshBasicMaterial({\r", + " color: 0x00ffff, // Cyan\r", + " side: THREE.DoubleSide\r", + "});\r", + "\r", + "// Create the final Three.js mesh using the defined geometry and material\r", + "const planeMesh = new THREE.Mesh(planeGeometry, planeMaterial);\r", + "\r", + "// Add the created Three.js mesh to the GDevelop object's 3D renderer.\r", + "// This makes the Three.js mesh visible and attached to the GDevelop object's position/rotation.\r", + "object.get3DRendererObject().add(planeMesh);" + ], + "parameterObjects": "Object", + "useStrict": true, + "eventsSheetExpanded": true + }, + { + "disabled": true, + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "Create" + }, + "parameters": [ + "", + "New3DBox", + "0", + "0", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "WaterShader::WaterPlane", + "type": "object" + } + ], + "objectGroups": [] + } + ], + "propertyDescriptors": [], + "variants": [] + } + ] + }, + { + "author": "", + "category": "User interface", + "extensionNamespace": "", + "fullName": "Toggle switch", + "gdevelopVersion": ">=5.5.230", + "helpPath": "/objects/toggle-switch", + "iconUrl": "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4NCjwhLS0gR2VuZXJhdG9yOiBBZG9iZSBJbGx1c3RyYXRvciAyMy4wLjMsIFNWRyBFeHBvcnQgUGx1Zy1JbiAuIFNWRyBWZXJzaW9uOiA2LjAwIEJ1aWxkIDApICAtLT4NCjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iSWNvbnMiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4Ig0KCSB2aWV3Qm94PSIwIDAgMzIgMzIiIHN0eWxlPSJlbmFibGUtYmFja2dyb3VuZDpuZXcgMCAwIDMyIDMyOyIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+DQo8c3R5bGUgdHlwZT0idGV4dC9jc3MiPg0KCS5zdDB7ZmlsbDpub25lO3N0cm9rZTojMDAwMDAwO3N0cm9rZS13aWR0aDoyO3N0cm9rZS1saW5lY2FwOnJvdW5kO3N0cm9rZS1saW5lam9pbjpyb3VuZDtzdHJva2UtbWl0ZXJsaW1pdDoxMDt9DQo8L3N0eWxlPg0KPHBhdGggY2xhc3M9InN0MCIgZD0iTTIzLDIzSDljLTMuOSwwLTctMy4xLTctN3YwYzAtMy45LDMuMS03LDctN2gxNGMzLjksMCw3LDMuMSw3LDd2MEMzMCwxOS45LDI2LjksMjMsMjMsMjN6Ii8+DQo8Y2lyY2xlIGNsYXNzPSJzdDAiIGN4PSI5IiBjeT0iMTYiIHI9IjQiLz4NCjwvc3ZnPg0K", + "name": "SpriteToggleSwitch", + "previewIconUrl": "https://asset-resources.gdevelop.io/public-resources/Icons/Line Hero Pack/Master/SVG/Interface Elements/8d0cd8cd0c9318f4f6efde6ee6b4c192bd19306467f80c9970387a259300f895_Interface Elements_interface_ui_toggle_switch_on_off.svg", + "shortDescription": "Toggle switch that users can click or touch.", + "version": "2.0.2", + "description": [ + "Toggle switch that users can click or touch. The switch can be customized with sprites.", + "", + "There are ready-to-use toggle switches in the asset-store [settings UI pack](https://editor.gdevelop.io/?initial-dialog=asset-store&asset-pack=settings-ui-settings-ui)." + ], + "origin": { + "identifier": "SpriteToggleSwitch", + "name": "gdevelop-extension-store" + }, + "tags": [ + "ui", + "widget", + "toggle", + "switch", + "check box" + ], + "authorIds": [ + "IWykYNRvhCZBN3vEgKEbBPOR3Oc2", + "gqDaZjCfevOOxBYkK6zlhtZnXCg1" + ], + "changelog": [ + { + "version": "2.0.0", + "breaking": "- Toggle switches now use \"variants\", allowing easy swapping of their visual aspect. You will have to make some adjustments to existing toggle switches in your project. Follow this [migration documentation](https://wiki.gdevelop.io/gdevelop5/objects/custom-objects-prefab-template/migrate-to-variants/) to do these changes." + } + ], + "dependencies": [], + "globalVariables": [], + "sceneVariables": [], + "eventsFunctions": [ + { + "description": "Check if the events are running for the editor.", + "fullName": "Editor is running", + "functionType": "Condition", + "name": "IsInGameEdition", + "private": true, + "sentence": "Events are running for the editor", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const game = runtimeScene.getGame();\r", + "eventsFunctionContext.returnValue = game.isInGameEdition && game.isInGameEdition();" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "parameters": [], + "objectGroups": [] + } + ], + "eventsBasedBehaviors": [ + { + "description": "The finite state machine used internally by the switch object.", + "fullName": "Switch finite state machine", + "name": "SwitchFSM", + "objectType": "", + "private": true, + "eventsFunctions": [ + { + "fullName": "", + "functionType": "Action", + "name": "doStepPreEvents", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "WasChecked", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::IsChecked" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "WasChecked", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::IsClicked" + }, + "parameters": [ + "Object", + "ButtonFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "IsChecked", + "Toggle", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::SwitchFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the toggle switch is checked.", + "fullName": "Is checked", + "functionType": "Condition", + "name": "IsChecked", + "sentence": "_PARAM0_ is checked", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsChecked", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::SwitchFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the toggle switch was checked in the current frame.", + "fullName": "Has just been checked", + "functionType": "Condition", + "name": "HasJustBeenChecked", + "sentence": "_PARAM0_ has just been checked", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsChecked", + "True", + "" + ] + }, + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "WasChecked", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::SwitchFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the toggle switch was unchecked in the current frame.", + "fullName": "Has just been unchecked", + "functionType": "Condition", + "name": "HasJustBeenUnchecked", + "sentence": "_PARAM0_ has just been unchecked", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "IsChecked", + "True", + "" + ] + }, + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "WasChecked", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::SwitchFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the toggle switch was toggled in the current frame.", + "fullName": "Has just been toggled", + "functionType": "Condition", + "name": "HasJustBeenToggled", + "sentence": "_PARAM0_ has just been toggled", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::HasJustBeenChecked" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::HasJustBeenUnchecked" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::SwitchFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check (or uncheck) the toggle switch.", + "fullName": "Check (or uncheck)", + "functionType": "Action", + "name": "SetChecked", + "sentence": "Check _PARAM0_: _PARAM2_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "Value", + "False", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "IsChecked", + "False", + "" + ] + } + ], + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "Avoid a started touch to interfere with a state change from events." + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::IsChecked" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::ResetState" + }, + "parameters": [ + "Object", + "ButtonFSM", + "" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "Value", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "IsChecked", + "True", + "" + ] + } + ], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "SpriteToggleSwitch::SwitchFSM::IsChecked" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::ResetState" + }, + "parameters": [ + "Object", + "ButtonFSM", + "" + ] + } + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::SwitchFSM", + "type": "behavior" + }, + { + "defaultValue": "yes", + "description": "IsChecked", + "name": "Value", + "optional": true, + "type": "yesorno" + } + ], + "objectGroups": [] + }, + { + "description": "Toggle the switch.", + "fullName": "Toggle", + "functionType": "Action", + "name": "ToggleChecked", + "sentence": "Toggle _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "PreviousIsChecked", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::IsChecked" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "PreviousIsChecked", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "PreviousIsChecked", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::SetChecked" + }, + "parameters": [ + "Object", + "Behavior", + "no", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "PreviousIsChecked", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::SetChecked" + }, + "parameters": [ + "Object", + "Behavior", + "yes", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::SwitchFSM", + "type": "behavior" + } + ], + "objectGroups": [] + } + ], + "propertyDescriptors": [ + { + "value": "", + "type": "Behavior", + "label": "Button finite state machine", + "extraInformation": [ + "SpriteToggleSwitch::ButtonFSM" + ], + "choices": [], + "name": "ButtonFSM" + }, + { + "value": "false", + "type": "Boolean", + "label": "Is checked", + "name": "IsChecked" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "PreviousIsChecked" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "hidden": true, + "name": "WasChecked" + } + ], + "sharedPropertyDescriptors": [] + }, + { + "description": "The finite state machine used internally by the button object.", + "fullName": "Button finite state machine", + "name": "ButtonFSM", + "objectType": "", + "private": true, + "eventsFunctions": [ + { + "fullName": "", + "functionType": "Action", + "name": "doStepPostEvents", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "SpriteToggleSwitch::IsInGameEdition" + }, + "parameters": [ + "", + "" + ] + } + ], + "actions": [], + "events": [ + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Finite state machine", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "The \"Validated\" state only last one frame." + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"Validated\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "State", + "=", + "\"Idle\"" + ] + } + ] + }, + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Check position", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "Make sure the cursor position is only checked once per frame." + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "MouseIsInside", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "ShouldCheckHovering", + "True", + "" + ] + }, + { + "type": { + "value": "CollisionPoint" + }, + "parameters": [ + "Object", + "MouseOnlyCursorX(Object.Layer(), 0)", + "MouseOnlyCursorY(Object.Layer(), 0)" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "MouseIsInside", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "Touches are always pressed, so ShouldCheckHovering doesn't matter." + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "TouchIsInside", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "NumberVariable" + }, + "parameters": [ + "TouchId", + "!=", + "0" + ] + }, + { + "type": { + "value": "CollisionPoint" + }, + "parameters": [ + "Object", + "TouchX(TouchId, Object.Layer(), 0)", + "TouchY(TouchId, Object.Layer(), 0)" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "TouchIsInside", + "True", + "" + ] + } + ] + } + ], + "parameters": [] + }, + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Handle touch start", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "HasAnyTouchOrMouseStarted" + }, + "parameters": [ + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "Index", + "=", + "0" + ] + } + ], + "events": [ + { + "type": "BuiltinCommonInstructions::Repeat", + "repeatExpression": "StartedTouchOrMouseCount()", + "conditions": [], + "actions": [], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "CollisionPoint" + }, + "parameters": [ + "Object", + "TouchX(StartedTouchOrMouseId(Index), Object.Layer(), 0)", + "TouchY(StartedTouchOrMouseId(Index), Object.Layer(), 0)" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TouchId", + "=", + "StartedTouchOrMouseId(Index)" + ] + }, + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "TouchIsInside", + "True", + "" + ] + } + ], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BuiltinCommonInstructions::Or" + }, + "parameters": [], + "subInstructions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::PropertyState" + }, + "parameters": [ + "Object", + "Behavior", + "=", + "\"Hovered\"" + ] + }, + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::PropertyState" + }, + "parameters": [ + "Object", + "Behavior", + "=", + "\"Idle\"" + ] + } + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "State", + "=", + "\"PressedInside\"" + ] + } + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "Index", + "+", + "1" + ] + } + ] + } + ] + } + ] + } + ], + "parameters": [] + }, + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Apply position changes", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "MouseIsInside", + "True", + "" + ] + }, + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"Hovered\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "State", + "=", + "\"Idle\"" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "MouseIsInside", + "True", + "" + ] + }, + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"Idle\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "State", + "=", + "\"Hovered\"" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "TouchIsInside", + "True", + "" + ] + }, + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"PressedInside\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "State", + "=", + "\"PressedOutside\"" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "TouchIsInside", + "True", + "" + ] + }, + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"PressedOutside\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "State", + "=", + "\"PressedInside\"" + ] + } + ] + } + ], + "parameters": [] + }, + { + "colorB": 228, + "colorG": 176, + "colorR": 74, + "creationTime": 0, + "name": "Handle touch end", + "source": "", + "type": "BuiltinCommonInstructions::Group", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "HasTouchEnded" + }, + "parameters": [ + "", + "TouchId" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TouchId", + "=", + "0" + ] + } + ], + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"PressedInside\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "State", + "=", + "\"Validated\"" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"PressedInside\"" + ] + }, + { + "type": { + "inverted": true, + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"Validated\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "State", + "=", + "\"Idle\"" + ] + } + ] + } + ] + } + ], + "parameters": [] + } + ], + "parameters": [] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::ButtonFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "Action", + "name": "onDeActivate", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::ResetState" + }, + "parameters": [ + "Object", + "Behavior", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::ButtonFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Reset the state of the button.", + "fullName": "Reset state", + "functionType": "Action", + "name": "ResetState", + "sentence": "Reset the button state of _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetStringVariable" + }, + "parameters": [ + "State", + "=", + "\"Idle\"" + ] + }, + { + "type": { + "value": "SetNumberVariable" + }, + "parameters": [ + "TouchId", + "=", + "0" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::ButtonFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the button is not used.", + "fullName": "Is idle", + "functionType": "Condition", + "name": "IsIdle", + "sentence": "_PARAM0_ is idle", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"Idle\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::ButtonFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the button was just clicked.", + "fullName": "Is clicked", + "functionType": "Condition", + "name": "IsClicked", + "sentence": "_PARAM0_ is clicked", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"Validated\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::ButtonFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the cursor is hovered over the button.", + "fullName": "Is hovered", + "functionType": "Condition", + "name": "IsHovered", + "sentence": "_PARAM0_ is hovered", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"Hovered\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::ButtonFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the button is either hovered or pressed but not hovered.", + "fullName": "Is focused", + "functionType": "Condition", + "name": "IsFocused", + "sentence": "_PARAM0_ is focused", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"Hovered\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"PressedOutside\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::ButtonFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the button is currently being pressed with mouse or touch.", + "fullName": "Is pressed", + "functionType": "Condition", + "name": "IsPressed", + "sentence": "_PARAM0_ is pressed", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"PressedInside\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::ButtonFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the button is currently being pressed outside with mouse or touch.", + "fullName": "Is held outside", + "functionType": "Condition", + "name": "IsPressedOutside", + "sentence": "_PARAM0_ is held outside", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "StringVariable" + }, + "parameters": [ + "State", + "=", + "\"PressedOutside\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::ButtonFSM", + "type": "behavior" + } + ], + "objectGroups": [] + }, + { + "description": "the touch id that is using the button or 0 if none.", + "fullName": "Touch id", + "functionType": "ExpressionAndCondition", + "name": "TouchId", + "sentence": "the touch id", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SetReturnNumber" + }, + "parameters": [ + "TouchId" + ] + } + ] + } + ], + "expressionType": { + "type": "expression" + }, + "parameters": [ + { + "description": "Object", + "name": "Object", + "type": "object" + }, + { + "description": "Behavior", + "name": "Behavior", + "supplementaryInformation": "SpriteToggleSwitch::ButtonFSM", + "type": "behavior" + } + ], + "objectGroups": [] + } + ], + "propertyDescriptors": [ + { + "value": "true", + "type": "Boolean", + "label": "", + "description": "Should check hovering", + "hidden": true, + "name": "ShouldCheckHovering" + }, + { + "value": "Idle", + "type": "Choice", + "label": "State", + "choices": [ + { + "label": "Idle", + "value": "Idle" + }, + { + "label": "Hovered", + "value": "Hovered" + }, + { + "label": "PressedInside", + "value": "PressedInside" + }, + { + "label": "PressedOutside", + "value": "PressedOutside" + }, + { + "label": "Validated", + "value": "Validated" + } + ], + "hidden": true, + "name": "State" + }, + { + "value": "0", + "type": "Number", + "label": "Touch id", + "hidden": true, + "name": "TouchId" + }, + { + "value": "", + "type": "Boolean", + "label": "Touch is inside", + "hidden": true, + "name": "TouchIsInside" + }, + { + "value": "", + "type": "Boolean", + "label": "Mouse is inside", + "hidden": true, + "name": "MouseIsInside" + }, + { + "value": "", + "type": "Number", + "label": "", + "hidden": true, + "name": "Index" + } + ], + "sharedPropertyDescriptors": [] + } + ], + "eventsBasedObjects": [ + { + "areaMaxX": 64, + "areaMaxY": 64, + "areaMaxZ": 64, + "areaMinX": 0, + "areaMinY": 0, + "areaMinZ": 0, + "defaultName": "ToggleSwitch", + "description": "A toggle switch that users can click or touch.", + "fullName": "Toggle switch", + "isUsingLegacyInstancesRenderer": false, + "name": "SpriteToggleSwitch", + "objects": [ + { + "adaptCollisionMaskAutomatically": true, + "assetStoreId": "", + "name": "State", + "type": "Sprite", + "updateIfNotVisible": false, + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "ButtonFSM", + "type": "SpriteToggleSwitch::ButtonFSM", + "ShouldCheckHovering": true, + "State": "Idle", + "TouchId": 0, + "TouchIsInside": false, + "MouseIsInside": false, + "Index": 0 + }, + { + "name": "SwitchFSM", + "type": "SpriteToggleSwitch::SwitchFSM", + "ButtonFSM": "ButtonFSM", + "IsChecked": false, + "WasChecked": false + } + ], + "animations": [ + { + "name": "Unchecked", + "useMultipleDirections": false, + "directions": [ + { + "looping": false, + "timeBetweenFrames": 0.08, + "sprites": [] + } + ] + }, + { + "name": "Checked", + "useMultipleDirections": false, + "directions": [ + { + "looping": false, + "timeBetweenFrames": 0.08, + "sprites": [] + } + ] + } + ] + } + ], + "objectsFolderStructure": { + "folderName": "__ROOT", + "children": [ + { + "objectName": "State" + } + ] + }, + "objectsGroups": [], + "layers": [ + { + "ambientLightColorB": 200, + "ambientLightColorG": 200, + "ambientLightColorR": 200, + "camera2DPlaneMaxDrawingDistance": 5000, + "camera3DFarPlaneDistance": 10000, + "camera3DFieldOfView": 45, + "camera3DNearPlaneDistance": 3, + "cameraType": "", + "followBaseLayerCamera": false, + "isLightingLayer": false, + "isLocked": false, + "name": "", + "renderingType": "", + "visibility": true, + "cameras": [ + { + "defaultSize": true, + "defaultViewport": true, + "height": 0, + "viewportBottom": 1, + "viewportLeft": 0, + "viewportRight": 1, + "viewportTop": 0, + "width": 0 + } + ], + "effects": [] + } + ], + "instances": [ + { + "angle": 0, + "customSize": true, + "depth": 0, + "height": 64, + "layer": "", + "name": "State", + "persistentUuid": "bda60bb1-c312-4710-baf7-ec7a3887c076", + "width": 64, + "x": 0, + "y": 0, + "zOrder": 1, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + } + ], + "editionSettings": {}, + "eventsFunctions": [ + { + "fullName": "", + "functionType": "Action", + "name": "onCreated", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Comment", + "color": { + "b": 109, + "g": 230, + "r": 255, + "textB": 0, + "textG": 0, + "textR": 0 + }, + "comment": "Pass the configuration to the behavior.\nThe PreviousIsChecked property allows to detect a change of \"intial value\" on hot reload." + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsChecked", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::SetChecked" + }, + "parameters": [ + "State", + "SwitchFSM", + "", + "" + ] + }, + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "PreviousIsChecked", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsChecked", + "False", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::SetChecked" + }, + "parameters": [ + "State", + "SwitchFSM", + "no", + "" + ] + }, + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "PreviousIsChecked", + "False", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SpriteToggleSwitch::UpdateStateAnimation" + }, + "parameters": [ + "Object", + "" + ] + }, + { + "type": { + "value": "ChangeSprite" + }, + "parameters": [ + "State", + "=", + "State.AnimationFrameCount() - 1" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [ + { + "name": "Background", + "objects": [ + { + "name": "Idle" + }, + { + "name": "Hovered" + }, + { + "name": "Pressed" + } + ] + } + ] + }, + { + "fullName": "", + "functionType": "Action", + "name": "onHotReloading", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsChecked", + "True", + "" + ] + }, + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "PreviousIsChecked", + "False", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SpriteToggleSwitch::SetChecked" + }, + "parameters": [ + "Object", + "yes", + "no" + ] + }, + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "PreviousIsChecked", + "True", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "IsChecked", + "False", + "" + ] + }, + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "PreviousIsChecked", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SpriteToggleSwitch::SetChecked" + }, + "parameters": [ + "Object", + "SwitchFSM", + "no" + ] + }, + { + "type": { + "value": "SetBooleanVariable" + }, + "parameters": [ + "PreviousIsChecked", + "False", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "Action", + "name": "doStepPostEvents", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SpriteToggleSwitch::UpdateStateAnimation" + }, + "parameters": [ + "Object", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the toggle switch is checked.", + "fullName": "Is checked", + "functionType": "Condition", + "name": "IsChecked", + "sentence": "_PARAM0_ is checked", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::IsChecked" + }, + "parameters": [ + "State", + "SwitchFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the toggle switch was checked in the current frame.", + "fullName": "Has just been checked", + "functionType": "Condition", + "name": "HasJustBeenChecked", + "sentence": "_PARAM0_ has just been checked", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::HasJustBeenChecked" + }, + "parameters": [ + "State", + "SwitchFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the toggle switch was unchecked in the current frame.", + "fullName": "Has just been unchecked", + "functionType": "Condition", + "name": "HasJustBeenUnchecked", + "sentence": "_PARAM0_ has just been unchecked", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::HasJustBeenUnchecked" + }, + "parameters": [ + "State", + "SwitchFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the toggle switch was checked or unchecked in the current frame.", + "fullName": "Has just been toggled", + "functionType": "Condition", + "name": "HasJustBeenToggled", + "sentence": "_PARAM0_ has just been toggled", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::HasJustBeenToggled" + }, + "parameters": [ + "State", + "SwitchFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check (or uncheck) the toggle switch.", + "fullName": "Check (or uncheck)", + "functionType": "Action", + "name": "SetChecked", + "sentence": "Check _PARAM0_: _PARAM1_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "Value", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::SetChecked" + }, + "parameters": [ + "State", + "SwitchFSM", + "no", + "" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "Value", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::SetChecked" + }, + "parameters": [ + "State", + "SwitchFSM", + "yes", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + }, + { + "defaultValue": "yes", + "description": "IsChecked", + "name": "Value", + "optional": true, + "type": "yesorno" + } + ], + "objectGroups": [] + }, + { + "description": "Toggle the switch.", + "fullName": "Toggle", + "functionType": "Action", + "name": "ToggleChecked", + "sentence": "Toggle _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [], + "actions": [ + { + "type": { + "value": "SpriteToggleSwitch::SwitchFSM::ToggleChecked" + }, + "parameters": [ + "State", + "SwitchFSM", + "" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the button is not used.", + "fullName": "Is idle", + "functionType": "Condition", + "name": "IsIdle", + "private": true, + "sentence": "_PARAM0_ is idle", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::IsIdle" + }, + "parameters": [ + "State", + "ButtonFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the button was just clicked.", + "fullName": "Is clicked", + "functionType": "Condition", + "name": "IsClicked", + "private": true, + "sentence": "_PARAM0_ is clicked", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::IsClicked" + }, + "parameters": [ + "State", + "ButtonFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the cursor is hovered over the button.", + "fullName": "Is hovered", + "functionType": "Condition", + "name": "IsHovered", + "sentence": "_PARAM0_ is hovered", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::IsHovered" + }, + "parameters": [ + "State", + "ButtonFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the button is either hovered or pressed but not hovered.", + "fullName": "Is focused", + "functionType": "Condition", + "name": "IsFocused", + "private": true, + "sentence": "_PARAM0_ is focused", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::IsFocused" + }, + "parameters": [ + "State", + "ButtonFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the button is currently being pressed with mouse or touch.", + "fullName": "Is pressed", + "functionType": "Condition", + "name": "IsPressed", + "sentence": "_PARAM0_ is pressed", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::IsPressed" + }, + "parameters": [ + "State", + "ButtonFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Check if the button is currently being pressed outside with mouse or touch.", + "fullName": "Is held outside", + "functionType": "Condition", + "name": "IsPressedOutside", + "sentence": "_PARAM0_ is held outside", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::ButtonFSM::IsPressedOutside" + }, + "parameters": [ + "State", + "ButtonFSM", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "Update the state animation.", + "fullName": "Update state animation", + "functionType": "Action", + "name": "UpdateStateAnimation", + "private": true, + "sentence": "Update the state animation of _PARAM0_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "SpriteToggleSwitch::SpriteToggleSwitch::IsChecked" + }, + "parameters": [ + "Object", + "ButtonFSM", + "" + ] + }, + { + "type": { + "value": "AnimationName" + }, + "parameters": [ + "State", + "\"Unchecked\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetAnimationName" + }, + "parameters": [ + "State", + "\"Checked\"" + ] + }, + { + "type": { + "value": "PlayAnimation" + }, + "parameters": [ + "State" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "SpriteToggleSwitch::SpriteToggleSwitch::IsChecked" + }, + "parameters": [ + "Object", + "ButtonFSM", + "" + ] + }, + { + "type": { + "value": "AnimationName" + }, + "parameters": [ + "State", + "\"Checked\"" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetAnimationName" + }, + "parameters": [ + "State", + "\"Unchecked\"" + ] + }, + { + "type": { + "value": "PlayAnimation" + }, + "parameters": [ + "State" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + }, + { + "description": "De/activate interactions with the button.", + "fullName": "De/activate interactions", + "functionType": "Action", + "name": "Activate", + "sentence": "Activate interactions with _PARAM0_: _PARAM1_", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BooleanVariable" + }, + "parameters": [ + "ShouldActivate", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "ActivateBehavior" + }, + "parameters": [ + "State", + "ButtonFSM", + "yes" + ] + } + ] + }, + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "inverted": true, + "value": "BooleanVariable" + }, + "parameters": [ + "ShouldActivate", + "True", + "" + ] + } + ], + "actions": [ + { + "type": { + "value": "ActivateBehavior" + }, + "parameters": [ + "State", + "ButtonFSM", + "no" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + }, + { + "description": "Activate", + "name": "ShouldActivate", + "type": "yesorno" + } + ], + "objectGroups": [] + }, + { + "description": "Check if interactions are activated on the button.", + "fullName": "Interactions activated", + "functionType": "Condition", + "name": "IsActivated", + "sentence": "Interactions on _PARAM0_ are activated", + "events": [ + { + "type": "BuiltinCommonInstructions::Standard", + "conditions": [ + { + "type": { + "value": "BehaviorActivated" + }, + "parameters": [ + "State", + "ButtonFSM" + ] + } + ], + "actions": [ + { + "type": { + "value": "SetReturnBoolean" + }, + "parameters": [ + "True" + ] + } + ] + } + ], + "parameters": [ + { + "description": "Object", + "name": "Object", + "supplementaryInformation": "SpriteToggleSwitch::SpriteToggleSwitch", + "type": "object" + } + ], + "objectGroups": [] + } + ], + "propertyDescriptors": [ + { + "value": "true", + "type": "Boolean", + "label": "Is checked", + "name": "IsChecked" + }, + { + "value": "", + "type": "Boolean", + "label": "", + "description": "It's used to detect a change at hot reload.", + "hidden": true, + "name": "PreviousIsChecked" + } + ], + "variants": [ + { + "areaMaxX": 143, + "areaMaxY": 59, + "areaMaxZ": 64, + "areaMinX": 0, + "areaMinY": 0, + "areaMinZ": 0, + "name": "Small Green Plastic Round Switch2", + "objects": [ + { + "adaptCollisionMaskAutomatically": false, + "assetStoreId": "", + "name": "State", + "type": "Sprite", + "updateIfNotVisible": false, + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "ButtonFSM", + "type": "SpriteToggleSwitch::ButtonFSM", + "ShouldCheckHovering": true, + "State": "Idle", + "TouchId": 0, + "TouchIsInside": false, + "MouseIsInside": false, + "Index": 0 + }, + { + "name": "SwitchFSM", + "type": "SpriteToggleSwitch::SwitchFSM", + "ButtonFSM": "ButtonFSM", + "IsChecked": false, + "WasChecked": false + } + ], + "animations": [ + { + "name": "Unchecked", + "useMultipleDirections": false, + "directions": [ + { + "looping": false, + "metadata": "{\"pskl\":{}}", + "timeBetweenFrames": 0.08, + "sprites": [ + { + "hasCustomCollisionMask": false, + "image": "Small Plastic Green Round Switch_Off.png", + "points": [], + "originPoint": { + "name": "origine", + "x": 0, + "y": 0 + }, + "centerPoint": { + "automatic": true, + "name": "centre", + "x": 0, + "y": 0 + }, + "customCollisionMask": [] + } + ] + } + ] + }, + { + "name": "Checked", + "useMultipleDirections": false, + "directions": [ + { + "looping": false, + "metadata": "{\"pskl\":{}}", + "timeBetweenFrames": 0.08, + "sprites": [ + { + "hasCustomCollisionMask": false, + "image": "Small Plastic Green Round Switch_On.png", + "points": [], + "originPoint": { + "name": "origine", + "x": 0, + "y": 0 + }, + "centerPoint": { + "automatic": true, + "name": "centre", + "x": 0, + "y": 0 + }, + "customCollisionMask": [] + } + ] + } + ] + } + ] + } + ], + "objectsFolderStructure": { + "folderName": "__ROOT", + "children": [ + { + "objectName": "State" + } + ] + }, + "objectsGroups": [], + "layers": [ + { + "ambientLightColorB": 200, + "ambientLightColorG": 200, + "ambientLightColorR": 200, + "camera2DPlaneMaxDrawingDistance": 5000, + "camera3DFarPlaneDistance": 10000, + "camera3DFieldOfView": 45, + "camera3DNearPlaneDistance": 3, + "cameraType": "", + "followBaseLayerCamera": false, + "isLightingLayer": false, + "isLocked": false, + "name": "", + "renderingType": "", + "visibility": true, + "cameras": [ + { + "defaultSize": true, + "defaultViewport": true, + "height": 0, + "viewportBottom": 1, + "viewportLeft": 0, + "viewportRight": 1, + "viewportTop": 0, + "width": 0 + } + ], + "effects": [] + } + ], + "instances": [ + { + "angle": 0, + "customSize": false, + "depth": 1, + "height": 64, + "layer": "", + "name": "State", + "persistentUuid": "24882334-eec8-403e-8bf1-70fc928a46e6", + "width": 64, + "x": 0, + "y": 0, + "zOrder": 1, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + } + ], + "editionSettings": { + "grid": false, + "gridType": "rectangular", + "gridWidth": 32, + "gridHeight": 32, + "gridDepth": 32, + "gridOffsetX": 0, + "gridOffsetY": 0, + "gridOffsetZ": 0, + "gridColor": 10401023, + "gridAlpha": 0.8, + "snap": false, + "zoomFactor": 4.895104895104895, + "windowMask": false, + "selectedLayer": "" + } + }, + { + "areaMaxX": 143, + "areaMaxY": 59, + "areaMaxZ": 64, + "areaMinX": 0, + "areaMinY": 0, + "areaMinZ": 0, + "assetStoreAssetId": "99f912de1cf5033ae934a8453c2f98a712955bcdb5ea1b1fda2fe2aa616de4a9", + "assetStoreOriginalName": "Small Green Plastic Round Switch", + "name": "Small Green Plastic Round Switch", + "objects": [ + { + "adaptCollisionMaskAutomatically": false, + "assetStoreId": "", + "name": "State", + "type": "Sprite", + "updateIfNotVisible": false, + "variables": [], + "effects": [], + "behaviors": [ + { + "name": "ButtonFSM", + "type": "SpriteToggleSwitch::ButtonFSM", + "ShouldCheckHovering": true, + "State": "Idle", + "TouchId": 0, + "TouchIsInside": false, + "MouseIsInside": false, + "Index": 0 + }, + { + "name": "SwitchFSM", + "type": "SpriteToggleSwitch::SwitchFSM", + "ButtonFSM": "ButtonFSM", + "IsChecked": false, + "WasChecked": false + } + ], + "animations": [ + { + "name": "Unchecked", + "useMultipleDirections": false, + "directions": [ + { + "looping": false, + "timeBetweenFrames": 0.08, + "sprites": [ + { + "hasCustomCollisionMask": false, + "image": "Small Plastic Green Round Switch_Off.png", + "points": [], + "originPoint": { + "name": "origine", + "x": 0, + "y": 0 + }, + "centerPoint": { + "automatic": true, + "name": "centre", + "x": 0, + "y": 0 + }, + "customCollisionMask": [] + } + ] + } + ] + }, + { + "name": "Checked", + "useMultipleDirections": false, + "directions": [ + { + "looping": false, + "timeBetweenFrames": 0.08, + "sprites": [ + { + "hasCustomCollisionMask": false, + "image": "Small Plastic Green Round Switch_On.png", + "points": [], + "originPoint": { + "name": "origine", + "x": 0, + "y": 0 + }, + "centerPoint": { + "automatic": true, + "name": "centre", + "x": 0, + "y": 0 + }, + "customCollisionMask": [] + } + ] + } + ] + } + ] + } + ], + "objectsFolderStructure": { + "folderName": "__ROOT", + "children": [ + { + "objectName": "State" + } + ] + }, + "objectsGroups": [], + "layers": [ + { + "ambientLightColorB": 200, + "ambientLightColorG": 200, + "ambientLightColorR": 200, + "camera2DPlaneMaxDrawingDistance": 5000, + "camera3DFarPlaneDistance": 10000, + "camera3DFieldOfView": 45, + "camera3DNearPlaneDistance": 3, + "cameraType": "", + "followBaseLayerCamera": false, + "isLightingLayer": false, + "isLocked": false, + "name": "", + "renderingType": "", + "visibility": true, + "cameras": [ + { + "defaultSize": true, + "defaultViewport": true, + "height": 0, + "viewportBottom": 1, + "viewportLeft": 0, + "viewportRight": 1, + "viewportTop": 0, + "width": 0 + } + ], + "effects": [] + } + ], + "instances": [ + { + "angle": 0, + "customSize": false, + "depth": 1, + "height": 64, + "layer": "", + "name": "State", + "persistentUuid": "24882334-eec8-403e-8bf1-70fc928a46e6", + "width": 64, + "x": 0, + "y": 0, + "zOrder": 1, + "numberProperties": [], + "stringProperties": [], + "initialVariables": [] + } + ], + "editionSettings": [] + } + ] + } + ] + } + ], + "externalLayouts": [] +} \ No newline at end of file diff --git a/examples/platformer-3d-wipeout/preview.png b/examples/platformer-3d-wipeout/preview.png new file mode 100644 index 000000000..f91ac180f Binary files /dev/null and b/examples/platformer-3d-wipeout/preview.png differ