{"id":11432,"date":"2023-01-30T00:40:08","date_gmt":"2023-01-29T15:40:08","guid":{"rendered":"https:\/\/www.webcyou.com\/?p=11432"},"modified":"2023-01-30T00:45:17","modified_gmt":"2023-01-29T15:45:17","slug":"%e3%80%90unity-x-webassembly%e3%80%91unity%e3%82%b3%e3%83%b3%e3%83%86%e3%83%b3%e3%83%84%e3%82%92blazor%e3%81%a8flutter%e3%81%a7web%e3%82%a2%e3%83%97%e3%83%aa%e3%81%a8%e3%81%97%e3%81%a6%e6%89%b1","status":"publish","type":"post","link":"https:\/\/www.webcyou.com\/?p=11432","title":{"rendered":"\u3010Unity x WebAssembly\u3011Unity\u30b3\u30f3\u30c6\u30f3\u30c4\u3092Blazor\u3068Flutter\u3067Web\u30a2\u30d7\u30ea\u3068\u3057\u3066\u6271\u3046"},"content":{"rendered":"\n<p>\u3069\u3082\u3067\u3059\u3002<\/p>\n<p>2\u5e74\u7a0b\u524d\u3067\u3059\u304b\u306d\u3002<\/p>\n<p>\u8077\u5834\u3067\u30ac\u30c3\u30c4\u30eaBlazor\u3092\u6271\u3063\u3066\u3044\u305f\u306e\u3067\u3059\u304c\u3001\u30d1\u30bf\u30c3\u3068\u89e6\u3089\u306a\u304f\u306a\u308b\u3068\u3055\u3059\u304c\u306b\u3059\u3063\u304b\u308a\u5fd8\u308c\u3061\u3083\u3044\u307e\u3059\u3088\u306dw<\/p>\n<p>\u306a\u3093\u304b\u3001\u3084\u3063\u3071\u308aBlazor\u3068\u3044\u3046\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306f\u7279\u6b8a\u3067\u3001\u666e\u6bb5\u306eWeb\u958b\u767a\u3067\u306e\u9078\u629e\u80a2\u3068\u3057\u3066\u306f\u3042\u307e\u308a\u8003\u3048\u3089\u308c\u306a\u3044\u3068\u3053\u308d\u3082\u3042\u3063\u3066\u3001\u6271\u3046\u6a5f\u4f1a\u3082\u591a\u304f\u306f\u306a\u3044\u3067\u3059\u3002<\/p>\n<p>\u3067\u3059\u304c\u3001Blazor\u306b\u3082\u52ff\u8ad6\u30e1\u30ea\u30c3\u30c8\u3082\u3042\u308a\u3001C#\uff08.net\uff09\u3067Web\u30a2\u30d7\u30ea\u306e\u958b\u767a\u304c\u884c\u3048\u308b\u3068\u8a00\u3046\u3053\u3068\u3067\u3001.NET\u3084Nuget\u30d1\u30c3\u30b1\u30fc\u30b8\u306a\u3069\u3001C#\u306e\u8cc7\u7523\u304c\u305d\u306e\u307e\u307e\u4f7f\u7528\u3067\u304d\u3001Unity\u30a2\u30d7\u30ea\u3068\u306e\u89aa\u548c\u6027\u3082\u9ad8\u3044\u3068\u52dd\u624b\u306b\u601d\u3063\u3066\u304a\u308a\uff08\u305f\u3060\u8a00\u8a9e\u304c\u4e00\u7dd2\u306a\u3060\u3051\u3068\u3044\u3046\u3053\u3068\u3082\u3042\u308a\u307e\u3059\u304c\uff09Blazor\u306bUnity\u30a2\u30d7\u30ea\u3092\u4e57\u305b\u308c\u3070\u3001Unity\u30a8\u30f3\u30b8\u30cb\u30a2\u3082web\u958b\u767a\u3092\u884c\u3046\u3053\u3068\u3082\u3067\u304d\u3001Unity\u958b\u767a\u3082web\u958b\u767a\u3082\u30b9\u30e0\u30fc\u30ba\u306b\u3044\u304f\u306e\u3067\u306f\u306a\u3044\u304b\uff1f<\/p>\n<p>\u3068\u3001\u601d\u3063\u30662\u5e74\u524d\u306f\u89e6\u3063\u3066\u3044\u305f\u306e\u3067\u3059\u3002<\/p>\n<p>\u305d\u3057\u3066\u3001\u518d\u3073\u89e6\u308b\u6a5f\u4f1a\u304c\u3042\u308a\u307e\u3057\u305f\u306e\u3067\u3001\u4e45\u3057\u3076\u308a\u306b\u3068\u89e6\u308a\u51fa\u3057\u305f\u306e\u3067\u3059\u304c\u3001<\/p>\n<p>\u305d\u306e\u3084\u308a\u65b9\u3092\u5fd8\u308c\u305f\u306e\u3067\uff08\u7b11\uff09 \u30e1\u30e2\u4ee3\u308f\u308a\u306b\u8a18\u4e8b\u3067\u3082\u66f8\u304f\u304b\u3068\u66f8\u3044\u3066\u304a\u308a\u307e\u3059\u3002<\/p>\n<p>\u3042\u3002\u3042\u3051\u307e\u3057\u3066\u304a\u3081\u3067\u3068\u3046\u3054\u3056\u3044\u307e\u3059\u3002<\/p>\n<p>\u3044\u3084\u3041\u3002<\/p>\n<p>\u6c17\u304c\u3064\u3051\u3070\u30012023\u5e74\u30821\u6708\u304c\u7d42\u308f\u308d\u3046\u3068\u3057\u3066\u3044\u3066\u3002<\/p>\n<p>\u65e9\u3044\u3067\u3059\u306d\u3002\u65e5\u304c\u7d4c\u3064\u306e\u306f\u3002<\/p>\n<p>\u3068\u3044\u3046\u4e8b\u3067\u3001<\/p>\n<p>\u4eca\u56de\u306f\u3001Unity\u30a2\u30d7\u30ea\u3092Blazor\u3068Flutter\u30682\u3064\u306e\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u3092\u7528\u3044\u3066\u3001Web\u30a2\u30d7\u30ea\u306e\u4e00\u90e8\u3068\u3057\u3066\u4f5c\u3063\u3066\u884c\u304d\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<h4>\u74b0\u5883<\/h4>\n<ul>\n<li>Mac mini (M1, 2020)<\/li>\n<li>macOS Big Sur 11.6<\/li>\n<li>Unity 2019.3.13\u30012020.3.18f1<\/li>\n<li>Visual Studio Community 2019 for Mac Version 8.10.25 (build 2)<\/li>\n<li>.NET Core 3.1 SDK<\/li>\n<li>.NET 5.0 SDK<\/li>\n<\/ul>\n<h4>Unity Build<\/h4>\n<p>\u307e\u305a\u306f\u3001\u30aa\u30fc\u30d7\u30f3\u30bd\u30fc\u30b9\u3067\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u300c<strong><span class=\"notion-enable-hover\" data-token-index=\"1\">CubeWorld<\/span><\/strong>\u300d\u3092\u4f7f\u7528\u3057\u3066\u3044\u304d\u305f\u3044\u306e\u3067\u3001\u3053\u3061\u3089\u3092clone\u3057\u307e\u3059\u3002<\/p>\n<p><strong>GitHub<\/strong><\/p>\n<p><a href=\"https:\/\/github.com\/federicodangelo\/CubeWorld\" target=\"_blank\" rel=\"noopener\">https:\/\/github.com\/federicodangelo\/CubeWorld<\/a><\/p>\n<p>\u300c<strong>CubeWorld<\/strong>\u300d\u306f\u30de\u30a4\u30f3\u30af\u30e9\u30d5\u30c8\u306e\u3088\u3046\u306a\u30b2\u30fc\u30e0\u306e\u30c7\u30e2\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u307e\u305a\u306f\u3001\u3053\u3061\u3089\u3092Unity\u3067\u8d77\u3061\u4e0a\u3052\u305f\u3044\u306e\u3067\u8d77\u52d5\u3057\u3088\u3046\u3068\u3059\u308b\u3068\u3001\u4f55\u3084\u3089<strong>Unity 2019.3.13<\/strong>\u3092\u4f7f\u3048\u3088\u3068\u8b66\u544a\u304c\u51fa\u305f\u306e\u3067\u3001<strong>Unity 2019.3.13<\/strong>\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>\uff08\u5f8c\u3067\u5206\u304b\u3063\u305f\u306e\u3067\u3059\u304c\u3001<strong>2020.3.18f1<\/strong>\u3067\u3082\u5927\u4e08\u592b\u3067\u3057\u305f\u3002\u3002\uff09<\/p>\n<p><strong>Unity 2019.3.13<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11433\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-1.png\" alt=\"\" width=\"300\" height=\"267\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-1.png 486w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-1-300x267.png 300w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/p>\n<p>\u3068\u308a\u3042\u3048\u305a\u3001\u300c<strong>Unity 2019.3.13<\/strong>\u300d\u3092\u4f7f\u7528\u3002\u300cMain\u300d\u30b7\u30fc\u30f3\u3092\u958b\u3044\u3066 Unity \u3092\u518d\u751f\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11434\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-2.png\" alt=\"\" width=\"240\" height=\"70\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-2.png 364w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-2-300x87.png 300w\" sizes=\"auto, (max-width: 240px) 100vw, 240px\" \/><\/p>\n<p>\u518d\u751f\u3059\u308b\u3068\u3001\u4ee5\u4e0b\u306e\u69d8\u306a\u30e1\u30cb\u30e5\u30fc\u304c\u8868\u793a\u3055\u308c\u307e\u3059\u306e\u3067\u3001\u300c<strong><span class=\"notion-enable-hover\" data-token-index=\"1\">Create Random World<\/span><\/strong>\u300d\u3092\u9078\u629e\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11435\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-3.png\" alt=\"\" width=\"377\" height=\"367\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-3.png 900w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-3-300x292.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-3-768x748.png 768w\" sizes=\"auto, (max-width: 377px) 100vw, 377px\" \/><\/p>\n<p>\u7d9a\u3044\u3066\u3001\u300c<strong><span class=\"notion-enable-hover\" data-token-index=\"1\">Generate<\/span><\/strong>\u300d\u3092\u9078\u629e\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11436\" style=\"font-size: revert; color: initial; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-4.png\" alt=\"\" width=\"392\" height=\"381\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-4.png 900w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-4-300x291.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-4-768x746.png 768w\" sizes=\"auto, (max-width: 392px) 100vw, 392px\" \/><\/p>\n<p>\u3059\u308b\u3068\u3001\u30ef\u30fc\u30eb\u30c9\u304c\u5c55\u958b\u3055\u308c\u3001\u300c<span class=\"notion-enable-hover\" data-token-index=\"1\">CubeWorld<\/span>\u300d\u3092\u697d\u3057\u3080\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11437\" style=\"font-size: revert; color: initial; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-5.png\" alt=\"\" width=\"620\" height=\"512\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-5.png 900w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-5-300x248.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-5-768x635.png 768w\" sizes=\"auto, (max-width: 620px) 100vw, 620px\" \/><\/p>\n<p>\u4eca\u56de\u306f\u3001web\u66f8\u304d\u51fa\u3057\u3068\u3044\u3046\u3053\u3068\u306a\u306e\u3067\u3001<strong>\u30e1\u30cb\u30e5\u30fc File\uff1eBuildSettings<\/strong>\u3092\u9078\u629e\u3057\u3001\u300c<strong>Switch Platform<\/strong>\u300d\u62bc\u4e0b\u3067\u3001WebGL\u3092\u9078\u629e\u3057\u307e\u3059\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11438\" style=\"font-size: revert; color: initial; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-6.png\" alt=\"\" width=\"220\" height=\"91\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-6.png 304w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-6-300x124.png 300w\" sizes=\"auto, (max-width: 220px) 100vw, 220px\" \/><\/p>\n<p>\u300c<strong>Build And Run<\/strong>\u300d\u62bc\u4e0b\u3067\u3001Chrome\u304c\u7acb\u3061\u4e0a\u304c\u308a\u3001\u8d77\u52d5\u3067\u304d\u308b\u306e\u304c\u78ba\u8a8d\u3067\u304d\u307e\u3057\u305f\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11439\" style=\"font-size: revert; color: initial; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-7.png\" alt=\"\" width=\"599\" height=\"488\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-7.png 900w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-7-300x244.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-7-768x625.png 768w\" sizes=\"auto, (max-width: 599px) 100vw, 599px\" \/><\/p>\n<p>Build\u30d5\u30a9\u30eb\u30c0\u4ee5\u4e0b\u306b\u751f\u6210\u3055\u308c\u305f\u6210\u679c\u7269\u3092\u78ba\u8a8d\u3059\u308b\u3068\u4ee5\u4e0b\u306e\u69d8\u3068\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11440\" style=\"font-size: revert; color: initial; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-8-1024x225.png\" alt=\"\" width=\"595\" height=\"131\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-8-1024x225.png 1024w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-8-300x66.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-8-768x169.png 768w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-8.png 1330w\" sizes=\"auto, (max-width: 595px) 100vw, 595px\" \/><\/p>\n<p>\u3042\u3089\u3001\u3053\u3093\u306a\u3001\u300cunityweb\u300d\u62e1\u5f35\u5b50\u304c\u3064\u3044\u305f\u30d5\u30a1\u30a4\u30eb\u304c\u751f\u6210\u3055\u308c\u305f\u3063\u3051\uff1f\uff1f<\/p>\n<p>\u30b7\u30f3\u30d7\u30eb\u306b\u4ee5\u4e0b\u306e\u69d8\u306a\u30d5\u30a1\u30a4\u30eb\u3060\u3063\u305f\u6c17\u304c\u3002\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11441\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-9.png\" alt=\"\" width=\"258\" height=\"163\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-9.png 390w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-9-300x189.png 300w\" sizes=\"auto, (max-width: 258px) 100vw, 258px\" \/><\/p>\n<p>\u3068\u3001\u5f8c\u3067\u6c17\u304c\u3064\u3044\u305f\u306e\u3067\u3059\u304c\u3001<strong>Unity2019.4<\/strong>\u307e\u3067\u304c\u3001\u300c<strong>unityweb<\/strong>\u300d\u62e1\u5f35\u5b50\u304c\u3064\u3044\u305f\u30d5\u30a1\u30a4\u30eb\u304c\u751f\u6210\u3055\u308c\u3001<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">UnityLoader.instantiate(container, url, override)<\/pre>\n\n<p>\u306e\u3088\u3046\u306a\u5f62\u3067\u3001JS\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u6271\u3046\u3088\u3046\u3067\u3001<strong>Unity2020.1<\/strong>\u304b\u3089\u306f\u3001\u300c<strong>unityweb<\/strong>\u300d\u62e1\u5f35\u5b50\u304c\u306a\u3044\u30b7\u30f3\u30d7\u30eb\u306a\u30d5\u30a1\u30a4\u30eb\u304c\u751f\u6210\u3055\u308c\u3001<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">createUnityInstance(canvas, config, onProgress).then(onSuccess).catch(onError);<\/pre>\n\n<p>\u306e\u3088\u3046\u306a\u5f62\u3067\u3001JS\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u6271\u3046\u3088\u3046\u3067\u3057\u305f\u3002<\/p>\n\n\u306a\u306e\u3067\u3001\u751f\u6210\u3055\u308c\u305fHTML\u306e\u8a18\u8ff0\u3082\u7570\u306a\u308b\u3002\n\n<h4>Blazor WebAssembly<\/h4>\n\n<p>\u3068\u3044\u3046\u3053\u3068\u3067\u3001Blazor\u306e\u65b9\u3092\u6271\u3063\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n\n<p>Blazor\u306f\u3001.NET \u3092\u4f7f\u3063\u3066\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u5074 Web UI \u3092\u69cb\u7bc9\u3059\u308b\u305f\u3081\u306e\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u3067\u3042\u308a\u3001C# \u3067 SPA \u304c\u4f5c\u308c\u308b\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u3067\u3042\u308b\u3053\u3068\u304c\u7279\u5fb4\u3067\u3059\u3002<\/p>\n\n<p>Blazor Server\u306a\u3069\u3082\u69cb\u7bc9\u3059\u308b\u3053\u3068\u304c\u53ef\u80fd\u3067\u3059\u304c\u3001\u4eca\u56de\u306fWeb\u30a2\u30d7\u30ea\u306e\u300cBlazor WebAssembly\u300d\u3092\u4f7f\u7528\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n\n<p>\u307e\u305a\u306f\u3001Visual Studio\u3092\u8d77\u52d5\u3057\u3001\u300c\u65b0\u898f\u300d\u3092\u62bc\u4e0b\u3002<\/p>\n\n<p><img decoding=\"async\" class=\"alignnone  wp-image-11442\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-10.png\" alt=\"\" width=\"280\" data-mce-src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-10.png\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-10.png 520w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-10-300x126.png 300w\" sizes=\"(max-width: 520px) 100vw, 520px\" \/><\/p>\n\n<p>\u7d9a\u3044\u3066\u3001\u300c<strong>Blazor WebAssembly \u30a2\u30d7\u30ea<\/strong>\u300d\u3092\u9078\u629e\u3002<\/p>\n\n<p><img decoding=\"async\" class=\"alignnone  wp-image-11443\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-11.png\" alt=\"\" width=\"450\" data-mce-src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-11.png\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-11.png 804w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-11-300x124.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-11-768x317.png 768w\" sizes=\"(max-width: 804px) 100vw, 804px\" \/><\/p>\n\n<p>\u6b21\u306f\u3001\u53d6\u308a\u6562\u3048\u305a\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u307e\u307e\u3067\u3002<\/p>\n\n<p><img decoding=\"async\" class=\"alignnone  wp-image-11444\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-12-1024x595.png\" alt=\"\" width=\"500\" data-mce-src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-12-1024x595.png\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-12-1024x595.png 1024w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-12-300x174.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-12-768x446.png 768w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-12.png 1126w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/p>\n\n<p>\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u540d\u306f\u9069\u5f53\u306b\u300c<strong>unityweb<\/strong>\u300d\u3068\u5165\u529b\u3002<\/p>\n\n<p><img decoding=\"async\" class=\"alignnone  wp-image-11445\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-13-1024x214.png\" alt=\"\" width=\"480\" data-mce-src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-13-1024x214.png\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-13-1024x214.png 1024w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-13-300x63.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-13-768x160.png 768w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-13.png 1082w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/p>\n\n<p>\u3059\u308b\u3068\u3001Chorome\u304c\u8d77\u52d5\u3057\u3001\u4ee5\u4e0b\u306e\u69d8\u306b\u300c<strong>Blazor WebAssembly \u30a2\u30d7\u30ea<\/strong>\u300d\u304c\u8d77\u52d5\u3057\u307e\u3059\u3002<\/p>\n\n<p>\u3042\u3041\u3002\u306a\u3093\u304b\u3001\u61d0\u304b\u3057\u3044\u611f\u3058\u3002<\/p>\n\n<p><img decoding=\"async\" class=\"alignnone  wp-image-11446\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-14.png\" alt=\"\" width=\"600\" data-mce-src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-14.png\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-14.png 900w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-14-300x257.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-14-768x657.png 768w\" sizes=\"(max-width: 900px) 100vw, 900px\" \/><\/p>\n\n<p>Unity\u5074\u3067Build\u3057\u3066\u751f\u6210\u3055\u308c\u305f\u300c<strong>Build<\/strong>\u300d\u30d5\u30a9\u30eb\u30c0\u3092\u300c<strong>wwwroot<\/strong>\u300d\u30d5\u30a9\u30eb\u30c0\u4ee5\u4e0b\u306b\u3001\u305d\u306e\u307e\u307e\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11447\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-15.png\" alt=\"\" width=\"350\" height=\"198\" data-mce-src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-15.png\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-15.png 520w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-15-300x170.png 300w\" sizes=\"auto, (max-width: 350px) 100vw, 350px\" \/><\/p>\n\n<p>\u307e\u305f\u3001\u300c<strong>TemplateDate<\/strong>\u300d\u3082\u5fc5\u8981\u3067\u3057\u305f\u306e\u3067\u3001\u300c<strong>wwwroot<\/strong>\u300d\u30d5\u30a9\u30eb\u30c0\u4ee5\u4e0b\u306b\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11448\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-16.png\" alt=\"\" width=\"320\" height=\"386\" data-mce-src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-16.png\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-16.png 398w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-16-249x300.png 249w\" sizes=\"auto, (max-width: 320px) 100vw, 320px\" \/><\/p>\n\n\u300c<strong>wwwroot<\/strong>\u300d\u30d5\u30a9\u30eb\u30c0\u4ee5\u4e0b\u306eindex.html\u3092\u4fee\u6b63\u3002\n\n\u4ee5\u4e0b\u306e\u69d8\u306b\u300cUnityProgress.js\u300d\u3068\u300cUnityLoader.js\u300d\u3092\u8aad\u307f\u8fbc\u307f\u3001UnityLoader.instantiate\u30e1\u30bd\u30c3\u30c9\u3067\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u751f\u6210\u3057\u307e\u3059\u3002\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">&lt;script src=&quot;TemplateData\/UnityProgress.js&quot;&gt;&lt;\/script&gt;\n&lt;script src=&quot;Build\/UnityLoader.js&quot;&gt;&lt;\/script&gt;\n&lt;script&gt;\n    var unityInstance = UnityLoader.instantiate(&quot;unityContainer&quot;, &quot;Build\/cube.json&quot;, {onProgress: UnityProgress});\n&lt;\/script&gt;<\/pre>\n\n<p>\u5b9f\u969b\u306b\u306f\u3001Blazor\u5074\u3067\u4f7f\u7528\u3067\u304d\u308b\u3088\u3046\u306b\u4ee5\u4e0b\u306e\u69d8\u306b\u3001<\/p>\n<p>\u4eca\u56de\u3001<strong>Unity 2019.3.13<\/strong>\u3067\u30d3\u30eb\u30c9\u3092\u884c\u3063\u305f\u306e\u3067\u3001\u4ee5\u4e0b\u306e\u69d8\u306a\u8a18\u8ff0\u3068\u306a\u308a\u307e\u3059\u3002\u300cwindow.jsFunctions\u300d\u3067window\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306b\u5b9a\u7fa9\u3057\u3001\u300cshowUnity\u300d\u3068\u8a00\u3063\u305f\u611f\u3058\u95a2\u6570\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">&lt;script src=&quot;TemplateData\/UnityProgress.js&quot;&gt;&lt;\/script&gt;\n&lt;script src=&quot;Build\/UnityLoader.js&quot;&gt;&lt;\/script&gt;\n&lt;script&gt;window.jsFunctions = {\n        showUnity: function () {\n            var unityInstance = UnityLoader.instantiate(&quot;unityContainer&quot;, &quot;Build\/cube.json&quot;, { onProgress: UnityProgress });\n        },\n}&lt;\/script&gt;<\/pre>\n\n<p>\u8868\u793a\u3055\u305b\u305f\u3044\u3068\u3053\u308d\u306b\u3001id unityContainer\u306e\u4ed8\u4e0e\u3055\u308c\u305fdiv\u3092\u914d\u7f6e\u3057\u307e\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306f\u3001\u300cPages\/index.razor\u300d\u306b\u8ffd\u52a0\u3002<\/p>\n\n<p><strong>index.razor<\/strong><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">&lt;div id=&quot;unityContainer&quot; style=&quot;width: 100%; height: calc(100% - 10px);&quot;&gt;&lt;\/div&gt;<\/pre>\n\n<p>JS\u3092\u547c\u3073\u51fa\u3059\u305f\u3081\u3001\u300c@inject IJSRuntime JSRuntime;\u300d\u3092\u8ffd\u52a0\u3002<\/p>\n<p><strong>index.razor<\/strong><\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">@page \"\/\"\n@inject IJSRuntime JSRuntime;<\/pre>\n<p>\u00a0<\/p>\n<p>\u5b9f\u969b\u306b\u547c\u3073\u51fa\u3059\u51e6\u7406\u3092\u300c@code\u300d\u5185\u306b\u8a18\u8ff0\u3002<\/p>\n<p><strong>index.razor<\/strong><\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">@code {\nprotected override async Task OnAfterRenderAsync(bool firstRender)\n    {\n        if (firstRender)\n        {\n            await JSRuntime.InvokeVoidAsync(\"jsFunctions.showUnity\");\n\n        }\n    }\n\n}<\/pre>\n<p>\u00a0<\/p>\n<p>\u30c7\u30d5\u30a9\u30eb\u30c8\u306eStyle\u3060\u3068\u3001margin\u3001padding\u304c\u9069\u5fdc\u3055\u308c\u3066\u3044\u307e\u3059\u306e\u3067\u3001\u3061\u3087\u3063\u3068\u4fee\u6b63\u3002<\/p>\n<p><strong>app.css<\/strong><\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">.content {\n    padding-top: 0;\n    height: calc(100% - 56px);\n}\n\ndiv.main .content.px-0 {\n    padding-left: 0 !important;\n    padding-right: 0 !important;\n}<\/pre>\n<p>\u65b0\u3057\u304f\u5b9a\u7fa9\u3057\u305f\u3001padding0\u3092\u9069\u5fdc\u3055\u305b\u308b\u305f\u3081\u3001MainLayout.razor\u306eCSS class\u3092\u4fee\u6b63\u3002<\/p>\n\n<p><strong>MainLayout.razor<\/strong><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">&lt;div class=&quot;content px-0&quot;&gt;\n     @Body\n&lt;\/div&gt;<\/pre>\n<p>\u3053\u3053\u307e\u3067\u884c\u3048\u3070\u3001Blazor\u30a2\u30d7\u30ea\u306bUnity\u30b3\u30f3\u30c6\u30f3\u30c4\u306e\u8868\u793a\u304c\u884c\u3048\u307e\u3059\u3002<\/p>\n<p>\u6bd4\u8f03\u7684\u7c21\u5358\u3067\u5b9f\u88c5\u53ef\u80fd\u3067\u3059\u306d\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11449\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-17.png\" alt=\"\" width=\"700\" height=\"459\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-17.png 900w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-17-300x197.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-17-768x503.png 768w\" sizes=\"auto, (max-width: 700px) 100vw, 700px\" \/><\/p>\n<p>\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u306f\u3053\u3061\u3089\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n\n<p><strong>GitHub<\/strong><\/p>\n<p><a href=\"https:\/\/github.com\/webcyou-org\/unity-blazor\" target=\"_blank\" rel=\"noopener\">https:\/\/github.com\/webcyou-org\/unity-blazor<\/a><\/p>\n<p>\u00a0<\/p>\n\n<h4>Flutter<\/h4>\n<p>\u7d9a\u3044\u3066\u3001\u307f\u3093\u306a\u5927\u597d\u304dFlutter\u3067\u3082\u540c\u3058\u69d8\u306bUnity\u30b3\u30f3\u30c6\u30f3\u30c4\u3092\u8868\u793a\u3055\u305b\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\uff08Flutter\u306e\u6982\u8981\u3001\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306b\u95a2\u3057\u3066\u306f\u5272\u611b\u3055\u305b\u3066\u3044\u305f\u3060\u304d\u307e\u3059\u3002\uff09<\/p>\n<p>create\u30b3\u30de\u30f3\u30c9\u3067\u65b0\u3057\u304f\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u4f5c\u6210\u3002<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">flutter create unityweb<\/pre>\n<p>\u4eca\u56de\u306fWeb\u66f8\u304d\u51fa\u3057\u3068\u306a\u308b\u306e\u3067\u30012\u3092\u5165\u529b\u3002<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">&#x5B;1]: macOS (macos)\n&#x5B;2]: Chrome (chrome)\nPlease choose one (To quit, press \"q\/Q\"): 2<\/pre>\n<p>\u3059\u308b\u3068\u3001Flutter\u304c\u7528\u610f\u3057\u3066\u304f\u308c\u3066\u3044\u308b\u3001boot strap\u7528\u306e\u753b\u9762\u8868\u793a\u3002<\/p>\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11450\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-18.png\" alt=\"\" width=\"600\" height=\"604\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-18.png 900w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-18-298x300.png 298w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-18-150x150.png 150w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-18-768x773.png 768w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-18-120x120.png 120w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/p>\n<p>Flutter\u306e\u8d77\u52d5\u78ba\u8a8d\u53d6\u308c\u307e\u3057\u305f\u306e\u3067\u3001Unity\u30b3\u30f3\u30c6\u30f3\u30c4\u3092\u8ffd\u52a0\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\u3053\u3061\u3089\u306f\u3001\u300c<strong>Unity 2020.3.18f1<\/strong>\u300d\u3067\u306e\u30d3\u30eb\u30c9\u3067\u3082\u4f55\u3089\u554f\u984c\u306a\u306a\u304b\u3063\u305f\u306e\u3067\u3001\u300c<strong>Unity 2020.3.18f1<\/strong>\u300d\u3067\u30d3\u30eb\u30c9\u3092\u884c\u3063\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\u3069\u3046\u3084\u3089\u3001<strong>Decompression fallback\u3092<\/strong>\u6709\u52b9\u306b\u3057\u305f\u65b9\u304c\u3088\u3055\u305d\u3046\u306a\u306e\u3067\u3001<\/p>\n<p><strong>ProjectSettings -&gt; Player -&gt; WebGL -&gt; Publishing Settings<\/strong><\/p>\n<p>\u306b\u3066\u3001\u300c<strong>Decompression fallback<\/strong>\u300d\u306b\u30c1\u30a7\u30c3\u30af\u5165\u308c\u3001\u6709\u52b9\u5316\u3057\u307e\u3059\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11451\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-19.png\" alt=\"\" width=\"490\" height=\"147\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-19.png 966w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-19-300x90.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-19-768x231.png 768w\" sizes=\"auto, (max-width: 490px) 100vw, 490px\" \/><\/p>\n<p>Blazor\u540c\u69d8\u306bWebGL\u3067\u30d3\u30eb\u30c9\u3092\u884c\u3044\u307e\u3059\u3002<\/p>\n<p>Flutter\u3067\u306f\u3001\u300cweb\u300d\u30d5\u30a9\u30eb\u30c0\u4ee5\u4e0b\u306bUnity\u306e\u30d3\u30eb\u30c9\u6210\u679c\u7269\u3092\u683c\u7d0d\u3059\u308b\u5f62\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11452\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-20.png\" alt=\"\" width=\"299\" height=\"173\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-20.png 412w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-20-300x173.png 300w\" sizes=\"auto, (max-width: 299px) 100vw, 299px\" \/><\/p>\n<p>Blazor\u540c\u69d8\u306b\u3001Unity\u30d3\u30eb\u30c9\u3067\u751f\u6210\u3055\u308c\u305f\u300c<strong>Build<\/strong>\u300d\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3068\u300c<strong>TemplateDate<\/strong>\u300d\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3068\u300c<strong>index.html<\/strong>\u300d\u3092\u65b0\u305f\u306b\u4f5c\u6210\u3057\u305f\u300c<strong>unity<\/strong>\u300d\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u4ee5\u4e0b\u306b\u3001\u305d\u306e\u307e\u307e\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11453\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-21.png\" alt=\"\" width=\"290\" height=\"245\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-21.png 526w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-21-300x253.png 300w\" sizes=\"auto, (max-width: 290px) 100vw, 290px\" \/><\/p>\n<p>\u300c<strong>index.html<\/strong>\u300d\u3092\u5c11\u3057\u4fee\u6b63\u3057\u307e\u3059\u3002<\/p>\n<p>\u4ee5\u4e0b\u306e2\u884c\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">window.parent.postMessage(\"unity_loaded\", \"*\");\nglobalUnityInstance = unityInstance;<\/pre>\n<p>\u8ffd\u52a0\u3059\u308b\u7b87\u6240\u306f\u3001createUnityInstance\u95a2\u6570\u5b9f\u884c\u5f8c\u306ethen\u306e\u7b87\u6240\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">script.onload = () =&gt; {\n    createUnityInstance(canvas, config, (progress) =&gt; {\n        progressBarFull.style.width = 100 * progress + &quot;%&quot;;\n    })\n    .then((unityInstance) =&gt; {\n        \/\/ \u3053\u3053\u304b\u3089<\/pre>\n<p>\u305d\u306e\u4ed6\u3001\u4ee5\u4e0b\u306e\u7b87\u6240\u306a\u3069\u4e0d\u8981\u3067\u3001\u30b3\u30e1\u30f3\u30c8\u30a2\u30a6\u30c8\u3057\u3066\u3082\u554f\u984c\u306a\u304f\u8868\u793a\u3057\u307e\u3057\u305f\u306e\u3067\u3001\u30b3\u30e1\u30f3\u30c8\u30a2\u30a6\u30c8\u3057\u3066\u304a\u308a\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">&lt;!-- &lt;div id=&quot;unity-mobile-warning&quot;&gt;\n         WebGL builds are not supported on mobile devices.\n     &lt;\/div&gt;\n     &lt;div id=&quot;unity-footer&quot;&gt;\n          &lt;div id=&quot;unity-webgl-logo&quot;&gt;&lt;\/div&gt;\n          &lt;div id=&quot;unity-fullscreen-button&quot;&gt;&lt;\/div&gt;\n          &lt;div id=&quot;unity-build-title&quot;&gt;CubeWorld&lt;\/div&gt;\n     &lt;\/div&gt; --&gt;<\/pre>\n\n<p>\u3053\u306e\u8fba\u308a\u3082\u3002<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\/\/ var fullscreenButton = document.querySelector(\n\/\/     \"#unity-fullscreen-button\"\n\/\/ );\n\/\/ var mobileWarning = document.querySelector(\"#unity-mobile-warning\");<\/pre>\n<p>\u00a0<\/p>\n<h4>flutter_unity_widget_web\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u5229\u7528<\/h4>\n<p>Flutter\u3067Unity\u30b3\u30f3\u30c6\u30f3\u30c4\u3092\u6271\u3048\u308b\u3088\u3046\u306b\u3001\u300cflutter_unity_widget_web\u300d\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n<p><strong>pub.dev<\/strong><\/p>\n<p><a href=\"https:\/\/pub.dev\/packages\/flutter_unity_widget_web\">https:\/\/pub.dev\/packages\/flutter_unity_widget_web<\/a><\/p>\n<p>\u4ee5\u4e0b\u306eflutter\u30b3\u30de\u30f3\u30c9\u3067\u8ffd\u52a0\u3002<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">flutter pub add flutter_unity_widget_web<\/pre>\n\n<p>http\u5468\u308a\u3082\u5229\u7528\u3057\u3066\u3044\u308b\u69d8\u5b50\u3067\u3001\u4f9d\u5b58\u30d1\u30c3\u30b1\u30fc\u30b8\u306f\u4ee5\u4e0b\u306e\u69d8\u306a\u5f62\u3068\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">+ crypto 3.0.2\n+ flutter_unity_widget_web 1.0.1\n+ http 0.13.5\n+ http_parser 4.0.2\n+ plugin_platform_interface 2.1.3\n+ pointer_interceptor 0.9.3+3\n+ typed_data 1.3.1\n+ uuid 3.0.7\n+ webview_flutter 2.8.0 (4.0.2 available)\n+ webview_flutter_android 2.10.4 (3.2.1 available)\n+ webview_flutter_platform_interface 1.9.5 (2.0.1 available)\n+ webview_flutter_wkwebview 2.9.5 (3.0.2 available)\n+ webviewx 0.2.1<\/pre>\n<p>\u00a0<\/p>\n<p>pubspec.yaml\u306b\u3082\u8ffd\u52a0\u3055\u308c\u3066\u304a\u308a\u307e\u3059\u3002<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">dependencies:\n  flutter_unity_widget_web: ^1.0.1<\/pre>\n<p>lib\/main.dart\u30d5\u30a1\u30a4\u30eb\uff08\u4f7f\u7528\u3059\u308b\u5834\u6240\uff09\u3067\u3001flutter_unity_widget_web\u306eimport\u6587\u3092\u8a18\u8ff0\u3002<\/p>\n\n<p><strong>lib\/main.dart<\/strong><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">import 'package:flutter_unity_widget_web\/flutter_unity_widget_web.dart';<\/pre>\n\n<p>\u305d\u306e\u4ed6\u306f<a href=\"https:\/\/pub.dev\/documentation\/flutter_unity_widget_web\/latest\/\">flutter_unity_widget_web\u306e\u516c\u5f0f\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8<\/a>\u3092\u53c2\u8003\u306b\u3001<strong>UnityWebWidget\u95a2\u6570<\/strong>\u306a\u3069\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002<\/p>\n\n<p>\u4eca\u56de\u306f\u3001Flutter\u306escaffold\u306b\u3066\u751f\u6210\u3055\u308c\u305fmain.dart\u3092\u305d\u306e\u307e\u307e\u5229\u7528\u3057\u305f\u306e\u3067\u3001\u4ee5\u4e0b\u306e\u69d8\u306a\u5f62\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">class _MyHomePageState extends State&lt;MyHomePage&gt; {\n  late UnityWebController _unityWebController;\n\n  @override\n  Widget build(BuildContext context) {\n    return UnityWebWidget(\n      url: 'http:\/\/localhost:${Uri.base.port}\/unity\/index.html',\n      listenMessageFromUnity: _listenMessageFromUnity,\n      onUnityLoaded: _onUnityLoaded,\n    );\n  }\n\n  @override\n  void dispose() {\n    _unityWebController.dispose();\n    super.dispose();\n  }\n\n  void _listenMessageFromUnity(String data) {\n    if (data == 'load_next_scene') {\n      \/\/ any message emitted from unty.\n      _unityWebController.sendDataToUnity(\n        gameObject: 'GameWindow',\n        method: 'LoadNextScene',\n        data: '0', \/\/ data sent to unity from flutter web.\n      );\n    }\n  }\n\n  void _onUnityLoaded(UnityWebController controller) {\n    _unityWebController = controller;\n    setState(() {});\n  }\n}<\/pre>\n<p>\u305d\u306e\u4ed6\u306f\u3001github\u306e\u30bd\u30fc\u30b9\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u3053\u3053\u307e\u3067\u3067\u304d\u308c\u3070\u3001flutter\u3092chrome\u30d9\u30fc\u30b9\u3067\u8d77\u52d5\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">flutter run -d chrome<\/pre>\n<p>Flutter\u3082\u8d77\u52d5\u3067\u304d\u3001Unity\u30b3\u30f3\u30c6\u30f3\u30c4\u3082\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone  wp-image-11454\" src=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-22.png\" alt=\"\" width=\"618\" height=\"466\" srcset=\"https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-22.png 900w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-22-300x226.png 300w, https:\/\/www.webcyou.com\/wp-content\/uploads\/2023\/01\/unityweb-22-768x579.png 768w\" sizes=\"auto, (max-width: 618px) 100vw, 618px\" \/><\/p>\n<p>flutter_unity_widget_web\u30d1\u30c3\u30b1\u30fc\u30b8\u306f\u3001html\u81ea\u4f53\u3092\u8aad\u307f\u8fbc\u3093\u3067\u3044\u308b\u69d8\u5b50\u3067\u3001\u3053\u3061\u3089\u306estyle\u306a\u3069\u304c\u9069\u5fdc\u3055\u308c\u3066\u3044\u3066\u3001Unity\u306e\u30b3\u30f3\u30c6\u30f3\u30c4\u3082\u771f\u3093\u4e2d\u8868\u793a\u3068\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n<p>\u300c<strong>TemplateDate<\/strong>\u300d\u4ee5\u4e0b\u306eCSS\u3067style\u3082\u5b9a\u7fa9\u3055\u308c\u3066\u3044\u307e\u3059\u306e\u3067\u3001\u7d30\u304b\u3044\u3068\u3053\u308d\u306e\u8abf\u6574\u306f\u3001\u305d\u3061\u3089\u306a\u3069\u306eCSS\u30d5\u30a1\u30a4\u30eb\u306e\u4fee\u6b63\u304c\u767a\u751f\u3057\u305d\u3046\u3067\u3059\u3002<\/p>\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">#unity-container.unity-desktop {\n    left: 50%;\n    top: 50%;\n    transform: translate(-50%, -50%);\n}<\/pre>\n<p>\u3068\u8a00\u3063\u305f\u611f\u3058\u3067\u3001Flutter\u306b\u95a2\u3057\u3066\u3082\u53d6\u308a\u6562\u3048\u305a\u554f\u984c\u306a\u304f\u8868\u793a\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>Flutter\u3067\u306eUnity\u30b3\u30f3\u30c6\u30f3\u30c4\u8868\u793a\u306e\u30bd\u30fc\u30b9\u306f\u3053\u3061\u3089\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><strong>GitHub<\/strong><\/p>\n<p><a href=\"https:\/\/github.com\/webcyou-org\/unity-flutter\" target=\"_blank\" rel=\"noopener\">https:\/\/github.com\/webcyou-org\/unity-flutter<\/a><\/p>\n<p>\u3068\u3044\u3046\u308f\u3051\u3067\u3001Blazor\u3068Flutter\u3067Unity webGL\u3092\u8868\u793a\u3055\u305b\u3066\u307f\u307e\u3057\u305f\u3002<\/p>\n<p>\u3068\u308a\u3042\u3048\u305a\u3001\u73fe\u72b6\u3082\u5909\u308f\u3089\u305a\u8868\u793a\u3057\u3066\u3088\u304b\u3063\u305f\u3067\u3059\u3002<\/p>\n<p>Unity\u3068Web\u5074\u3067\u9023\u643a\u3055\u305b\u3064\u3064\u3002\u3063\u3066\u3044\u3046\u306e\u304c\u4eca\u5f8c\u3082\u767a\u751f\u3057\u305d\u3046\u306a\u306e\u3067\u3001\u307c\u3061\u307c\u3061\u6271\u3063\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\u3067\u306f\u3067\u306f\u3002<\/p>\n<p>\u307e\u305f\u307e\u305f\u3041\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3069\u3082\u3067\u3059\u3002 2\u5e74\u7a0b\u524d\u3067\u3059\u304b\u306d\u3002 \u8077\u5834\u3067\u30ac\u30c3\u30c4\u30eaBlazor\u3092\u6271\u3063\u3066\u3044\u305f\u306e\u3067\u3059\u304c\u3001\u30d1\u30bf\u30c3\u3068\u89e6\u3089\u306a\u304f\u306a\u308b\u3068\u3055\u3059\u304c\u306b\u3059\u3063\u304b\u308a\u5fd8\u308c\u3061\u3083\u3044\u307e\u3059\u3088\u306dw \u306a\u3093\u304b\u3001\u3084\u3063\u3071\u308aBlazor\u3068\u3044\u3046\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306f\u7279\u6b8a\u3067\u3001\u666e\u6bb5\u306eWeb\u958b\u767a\u3067\u306e\u9078 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":11449,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[298],"tags":[176,166,37,45,178,78,114,118],"class_list":["post-11432","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-unity","tag-html5","tag-iphone","tag-iphone-","tag-web","tag-178","tag-78","tag-114","tag-118"],"_links":{"self":[{"href":"https:\/\/www.webcyou.com\/index.php?rest_route=\/wp\/v2\/posts\/11432","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.webcyou.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.webcyou.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.webcyou.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.webcyou.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=11432"}],"version-history":[{"count":18,"href":"https:\/\/www.webcyou.com\/index.php?rest_route=\/wp\/v2\/posts\/11432\/revisions"}],"predecessor-version":[{"id":11473,"href":"https:\/\/www.webcyou.com\/index.php?rest_route=\/wp\/v2\/posts\/11432\/revisions\/11473"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.webcyou.com\/index.php?rest_route=\/wp\/v2\/media\/11449"}],"wp:attachment":[{"href":"https:\/\/www.webcyou.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=11432"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.webcyou.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=11432"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.webcyou.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=11432"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}