Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

webgl load - unload Scene produces error #1065

Open
nitroman123 opened this issue Apr 4, 2024 · 1 comment
Open

webgl load - unload Scene produces error #1065

nitroman123 opened this issue Apr 4, 2024 · 1 comment

Comments

@nitroman123
Copy link

this is the error that i face
image

also a problem with the margings while i set it to 190 from the top (190 doesnt change) it keeps giving me a small gap

image

@KojiNakamaru
Copy link
Member

For example, if we add "Next Scene" and modified SampleWebView.cs as below, it works okay. I tested it for 2022.3.14f1.

diff --git a/sample/Assets/Scripts/SampleWebView.cs b/sample/Assets/Scripts/SampleWebView.cs
index faabee0..997f4f2 100644
--- a/sample/Assets/Scripts/SampleWebView.cs
+++ b/sample/Assets/Scripts/SampleWebView.cs
@@ -24,6 +24,7 @@ using UnityEngine;
 using UnityEngine.Networking;
 #endif
 using UnityEngine.UI;
+using UnityEngine.SceneManagement;
 
 public class SampleWebView : MonoBehaviour
 {
@@ -202,6 +203,11 @@ public class SampleWebView : MonoBehaviour
     {
         var x = 10;
 
+        if (GUI.Button(new Rect(x, 10, 80, 80), "next scene")) {
+            SceneManager.LoadScene("NextScene");
+        }
+        x += 90;
+
         GUI.enabled = (webViewObject == null) ? false : webViewObject.CanGoBack();
         if (GUI.Button(new Rect(x, 10, 80, 80), "<")) {
             webViewObject?.GoBack();

Could you please provide a modified sample app project that reproduces your issues?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants