Skip to main content

Roblox SDK

Inworld Roblox SDK Install and Setup Instructions



Overview

The following are steps to install the Roblox - Inworld SDK Toolkit. 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

  1. Requirements
  2. Part 1 - Inworld API Keys
  3. Part 2 - Roblox Inworld SDK Toolkit Plugin Setup
  4. Development Notes
    1. Characters
    2. Custom Character Models
    3. Custom Chat Icons
    4. Chat GUI
    5. Plugin Security Settings



Requirements

  • An Inworld Account
  • An Internet Connection
  • A Web Browser
  • A Terminal Client
  • Node v16.15.1+
  • NPM v8.11.0+
  • GIT
  • Inworld.ai Account API Key, API Secret and a default Scene ID



Part 1 - Inworld API Keys

  1. 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.

  2. Click on the Change Button

1-2



  1. Select the Inworld Workspace you want to use

1-3



  1. 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

1-4



  1. Now click on Integrations from the Studio’s left menu and save your Workspace specific API Key and Secret.

1-5




Part 2 - Roblox Inworld SDK Toolkit Plugin Setup

  1. 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

3-1



  1. Click on ‘Get Plugin’ and install the the Inworld SDK Toolkit plugin for Roblox

3-2



  1. 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.

3-3



  1. Click to open it and then click on Install

3-4



  1. The plugin will then appear in your Roblox Studio Plugins tab.

3-5



  1. Note: In Roblox make sure that ‘Allow HTTP Requests’ and ‘Enabled Studio Access to API Services’ is enabled for any game using this SDK.

3-6



  1. 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


  2. Click on Install SDK

3-8



  1. 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.

3-9



  1. Once you’ve installed the SDK you will see the Generate Characters screen.

3-10



  1. 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.

3-11



  1. 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.

3-13



  1. 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.

3-14



  1. 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.

3-15



  1. 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.

3-16



  1. 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’.

3-17



  1. 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.

3-18



  1. Close the Inworld SDK Toolkit plugin. You should now see the characters have been added to the video game using a Roblox Dummy.

3-19



  1. You can test the game by running it in Studio and walk up to a character to start chatting.

3-20


3-20b


  1. After you’ve successfully tested a chat you have finished the setup process!



Development Notes

Characters

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.

notes-characters



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.

notes-models



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.

notes-models



Chat GUI

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.


notes-models



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.


notes-security-a


notes-security-b