Use Cases

Quick-start guides showing minimal implementations of common WebView tasks using PlayMaker custom actions.

Available Use Cases

  • What it does: Create a simple in-app web browser with navigation

  • Complexity: Basic

  • Actions: 4 (Create, LoadURL, Show, OnLoadFinish)

  • Best for: In-app content viewing, help pages, news feeds


  • What it does: Execute JavaScript and retrieve results for Unity-WebView interaction

  • Complexity: Intermediate

  • Actions: 5 (Create, LoadURL, Show, RunJavaScript, GetRunJavaScriptResult) + optional error extractor

  • Best for: Dynamic content manipulation, data extraction, interactive features


  • What it does: Register custom URL schemes for WebView-to-Unity communication

  • Complexity: Intermediate

  • Actions: 4 (Create, AddURLScheme, LoadURL, OnURLSchemeMatchFound)

  • Best for: OAuth callbacks, deep linking, custom protocol handling


  • What it does: Customize WebView appearance, size, and behavior

  • Complexity: Basic

  • Actions: 4 (Create, Configure, LoadURL, Show) + optional OnLoadFinish

  • Best for: Branded content, custom UI integration, responsive layouts


  • What it does: Display local HTML content (terms, privacy, help)

  • Complexity: Basic

  • Actions: 3 (Create, LoadHtmlString, Show)

  • Best for: Terms & conditions, privacy policies, offline help


Choosing the Right Use Case

Start Here:

  • Need to show a website? β†’ Use Case 1 (Basic Browser)

  • Need to interact with web content from Unity? β†’ Use Case 2 (JavaScript) or Use Case 3 (URL Schemes)

  • Need to customize appearance? β†’ Use Case 4 (Styled WebView)

  • Need to show local HTML? β†’ Use Case 5 (HTML Content)

Quick Action Reference

Action
Purpose
Used In

WebViewCreateInstance

Create WebView instance

All use cases

WebViewConfigure

Configure appearance/behavior

4 (optional)

WebViewLoadURL

Load remote URL

1, 2, 3, 4

WebViewLoadHtmlString

Load HTML string

5

WebViewShow

Display WebView

All use cases

WebViewHide

Hide WebView

All use cases

WebViewRunJavaScript

Execute JS code

2

WebViewGetRunJavaScriptResult

Get JS result

2

WebViewGetRunJavaScriptError

Get JS error details

2

WebViewAddURLScheme

Register custom scheme

3

WebViewOnURLSchemeMatchFound

Listen for scheme match

3

WebViewGetInfo

Get URL/title/progress/loading

Optional

WebViewOnLoadFinish

Track load completion

1, 2, 3, 4, 5

  • README.md - Complete actions list + platform notes

Last updated

Was this helpful?