• Hi Guest!

    We are extremely excited to announce the release of our first Beta1.1 and the first release of our Public AddonKit!
    To participate in the Beta, a subscription to the Entertainer or Creator Tier is required. For access to the Public AddonKit you must be a Creator tier member. Once subscribed, download instructions can be found here.

    Click here for information and guides regarding the VaM2 beta. Join our Discord server for more announcements and community discussion about VaM2.
  • Hi Guest!

    VaM2 Resource Categories have now been added to the Hub! For information on posting VaM2 resources and details about VaM2 related changes to our Community Forums, please see our official announcement here.
Xtoys Connect

Plugins + Scripts Xtoys Connect

Download [<1 MB]
  Contains executable files or external scripts. Ensure you trust the creator and apply your own security measures.
This plugin and app allows you send and receive data from Xtoys script via websocket.
For example you can control your toys from inside the scene or trigger something in the scene with coyote button or motion sensor.
It's built upon Connect by MacGruber.

Instructions:
Load plugin to some object or scene.
Open Xtoys tcp-websocket bridge app.
1762353165172.png

Input websocket address: wss://webhook.xtoys.app/<webhookID>
You can get webhookID in your Xtoys profile or directly in the script with webhook block.
1762353631293.png

You won't need to input address if you select "accept websocket control commands" and input your webhookID in the plugin instead. I will forward the address and try to connect automatically after you press "connect".

To send trigger to Xtoys script you need to send it's name to the sendTrigger value of the plugin via VAM trigger system and create a block with the same name in Xtoys script to receive it.
1762353815772-png.539178
1762354002880.png
1762353912525.png


To send sliders data you need to create "sliders" block in the script. Their values are passed to the attached blocks via {trigger-sl1}, {trigger-sl2}, etc.
Refresh rate in the plugin affects how often sliders are checked for changes. If you need smooth control 0.06 - 0.1 worked best for me. Smaller values tend to cause buffering in Xtoys script. If you don't need perfect sync you can set it to 1 in case it affects performance (I'm not sure if it actually does).

To receive triggers from Xtoys script you need to input in the attached webhook blocks the same names as in the plugin.
1762354814818.png
1762355046926.png


Haven't tested it much. Hope it works.
  Contains executable files or external scripts. Ensure you trust the creator and apply your own security measures.
Images and attachments
  • 1762353815772.png
    1762353815772.png
    25.3 KB · Views: 0
React to this content...

Share this resource

Back
Top Bottom