Inworld Roblox SDK Install and Setup Instructions
The following are steps to install the Roblox - Inworld SDK Toolkit. The Inworld SDK Toolkit will require the Inworld node-js-proxy RESTful SDK to be installed and running as well. This will guide you through setting up the Node RESTful SDK as well as the Inworld SDK Toolkit but it assumes you have the following setup already.
Table of Contents
- Part 1 - Inworld API Keys
- Part 2 - Roblox Inworld SDK Toolkit Plugin Setup
- Development Notes
- An Inworld Account
- An Internet Connection
- A Web Browser
- A Terminal Client
- Node v16.15.1+
- NPM v8.11.0+
- Inworld.ai Account API Key, API Secret and a default Scene ID
Part 1 - Inworld API Keys
Open your web browser, navigate to https://studio.inworld.ai and login if you’re not already. In your Inworld Studio select the workspace you wish to integrate into your Roblox Game.
Click on the Change Button
- Select the Inworld Workspace you want to use
- Click on Scenes from the Studio’s left menu. Select any scene from the list to be used to test the connection from the Node RESTful SDK to Inworld. Choose the scene and click on the Copy machine readable id button on the left
- Now click on Integrations from the Studio’s left menu and save your Workspace specific API Key and Secret.
Part 2 - Roblox Inworld SDK Toolkit Plugin Setup
- Open Roblox Studio and then in your web browser go to the Roblox Inworld SDK Toolkit page to download the plugin using the link here: Inworld-SDK-Toolkit Plugin
- Click on ‘Get Plugin’ and install the the Inworld SDK Toolkit plugin for Roblox
- In Roblox open the Tookbox, goto the Inventory tab and select My Plugins from the drop down and the Inworld SDK Toolkit will be listed.
- Click to open it and then click on Install
- The plugin will then appear in your Roblox Studio Plugins tab.
- Note: In Roblox make sure that ‘Allow HTTP Requests’ and ‘Enabled Studio Access to API Services’ is enabled for any game using this SDK.
Click on the Inworld SDK Toolkit to bring up the SDK installer. Click on the ‘Install SDK’ button to begin the process. Note that you will need to install the SDK for every new game you want
Click on Install SDK
- You may see two alerts to both allow Script Injection and to allow API access to 'studio.inworld.ai'. Click on Allow for both and then click on Install SDK again. If you click Deny by mistake go to the bottom of this document to learn how to Allow it.
- Once you’ve installed the SDK you will see the Generate Characters screen.
- You will also notice in the Explorer: Scripts, a GUI, Events and Data have been added to the game. These are the SDK files for chatting with the Characters.
- In the Plugin, copy the API Key and Secret copied from Part 1 to the the Set Inworld API Key and Secret. Click the ‘Save’ button.
- Now that setup is completed. It’s time to start adding your Inworld Characters! Open the web browser, if it isn’t already and goto the Scenes section of your Inworld account. Choose a scene containing the characters you wish to add to Roblox. Click on ‘Copy machine readable id for integration.
Note: You need to make sure the Workspace selected is the same one that was used to configure the Node RESTful SDK.
- Go back to Roblox Studio and in the Inworld SDK Toolkit, paste the Scene ID just copied into the space provided and click on the ‘Load Scene’ button.
- You will see an alert to Allow localhost:3000 access from the plugin. Click on ‘Allow’ to continue. If you make a mistake and click Deny, go here Plugin Security Settings.
- You should now see a list of Characters from your scene in the list. In the example below we’ve used ‘The Caterpillar’s Mushroom’ scene and have loaded ‘The Caterpillar’.
- Click on the ‘The Caterpillar’ to set it to be added to the scene. You may repeat the process to load as many scenes as you’d like to be able to generate multiple Characters. You can also come back at another time to Generate more characters. After you’ve added all the characters you want to create, click on the ‘Generate Characters’ button.
- Close the Inworld SDK Toolkit plugin. You should now see the characters have been added to the video game using a Roblox Dummy.
- You can test the game by running it in Studio and walk up to a character to start chatting.
- After you’ve successfully tested a chat you have finished the setup process!
All Inworld data relating to the Characters is set as custom Attributes on the Character’s model. If you select a model, look at the Properties panel and scroll down to Attributes.
Custom Character Models
You can replace the sample Dummy model with your own custom models. To do so you must copy all the custom Character Attributes over from the Dummy as well as copy the Attachment containing a Proximity Prompt from inside the Head part of the Dummy model.
Custom Chat Icons
Each Character can use a custom icon for the Chat box as you see below for The Cheshire Cat. You update the Icon by selecting the Character’s model and updating the IconID Attribute with a new Roblox asset id. The image used should be square and it’s recommended not being bigger than 300 x 300 pixels.
The Chat GUI is mobile friendly and fluidly resizes to fit any screen. We do not recommend modifying its properties as this would likely cause the chat to not function correctly across all devices. To update the colors of the chat bubbles can be done by updating the script at StarterPlayer > StarterCharacterScripts > Inworld > ChatEventHandler. On lines 233 and 237.
Plugin Security Settings
Note: The plugin will need to access localhost and script injection access. These are dialogs you will see during your setup process.
If you make a mistake and click deny by accident, this can be fixed by clicking on ‘Manage Plugins’. Click on the lower part of the Plugin HTTP Requests or Script Injection Allowed to bring up the settings panel. Make sure the localhost:3000 is checked and Script Injection is enabled.