Can I give you RMMZ as a gift?
Plug₂in for RPG Maker MV and MZ
A downloadable plug₂in
This is an easy-to use pattern rumble plugin for RPG Maker MV and MZ.
Now completely rewritten in 0.2 for easier maintenance, with more powerful API and including a built-in Options sub-menu to deal with connection and configuration.
There is also now a convenient online Pattern Composer (which should be installable using the itch.io desktop app).
The base price is still free, but please consider leaving a tip if you use this commercally. It was a lot of work.
The plugin works both in standalone games and web deployments.
It works with the stock version of NW.js and instead uses Intiface to connect to Xbox 360 style gamepads (Windows only) as well as a wide variety of vibrating sex toys (cross-platform).
Read https://buttplug-developer-guide.docs.buttplug.io/intro/buttplug-ethics.html before starting and always respect the player's maximum intensity settings.
The https://intiface.com/ server must be running on port 12345 to connect. When running in the browser, connections to localhost must be allowed.
The minified/binary files in the archive are verbatim from buttplug - npm (npmjs.com) (version 1.0.17), from the dist/web/ folder, and you can replace them with fresh copies if necessary.
Generally speaking, you only need to extract the archive into your plugins folder though.
A note on compatibility:
I had to add delete process.versions.node; for this to work, as https://github.com/rust-random/getrandom doesn't work correctly in NW.js without the Node Crypto module otherwise. (This removes the package versions table entry for Node.js at runtime, to make getrandom not detect it and use the browser API instead.)
If this plugin causes issues with others, it's most likely because of that.
Tested with RPG Maker MV Version 1.6.2.
Tested with RPG Maker MZ Version 1.7.0.
Name for Intiface:
The application name to show in the intiface server GUI.
(Defaults to game title.)
Stop on Title/Stop on Game Over:
Automatically stop all activity when reaching certain screens.
End on Title/End on Game Over:
Automatically end all activity when reaching certain screens, without cancelling the current pattern queue. These default to true.
Adds an additional entry to the Options menu for configuration (see screenshots).
The texts of this entry and the menu are also configurable.
# Connect to all available devices (and pulse each briefly to confirm).
# Stop all devices and disconnect from Intiface.
# Opens the interactive configuration screen (pauses gameplay).
PlugPlug config vibe strength <multiplier>
# Set global vibe strength multiplier. 0.0 - 26.0. Default: 1.0
PlugPlug config vibe duration <multiplier>
# Set global vibe duration multiplier: 0.0 - infinity. Default: 1.0
PlugPlug config vibe pause <multiplier>
# Set global vibe pause duration multiplier: 0.0 - infinity. Default: 1.0
Vibration commands now use a queue and block until reached or completed.
PlugPlug vibe pulse <on-duration> <off-duration> <pattern>
# Vibrate once, then pause as specified. Now resumes the repeated pattern afterwards!
PlugPlug vibe start <on-duration> <off-duration> <pattern>
# Set a vibration pattern to repeat until told otherwise.
PlugPlug vibe start requireN <required-count> <off-duration> <pattern>
# Like "start", but will repeat <required-count> times before continuing to process the queue.
# End vibration cleanly after the current queue.
# Stop all motion imediately.
PlugPlug async .../PlugPlug sync
# Commands can be prefixed with "async" to not block. You can use "PlugPlug sync" to only wait for the current queue without doing anything else.
Many commands can be suffixed with "now" to cancel the existing queue and active pattern immediately. See the plugin help text for more information.
# A decimal number, scalar and unit-less.
# The playback duration of the pattern, in seconds.
# The pause between patterns.
# A pattern definition.
# An integer.
There are two possible types of patterns:
- Constant strength (decimal numbers from 0 to 1), for example 0.9
- More complex patterns defined using the letters A through Z (case-insensitive) as well as the . character. 'A' will use the lowest possible non-zero intensity, 'Z' will use the maximum intensity (1.0) and '.' turns off vibration.
A single pattern is applied to all vibration features at once. Otherwise, linear interpolation is used to distribute the patterns across the device, and the strongest influence at each feature "wins".
PlugPlug vibe start 0.3 0 0.5
# Constant half intensity.
PlugPlug vibe pulse 1 0 0.8 0
# 1-second pulse with constant 80% intensity,
# concenctrated on the first motor.
PlugPlug vibe start 2.5 0 ZZZ...ZZ....ZZZ...
# Strong pulsed vibration.
PlugPlug vibe start 5 0 Vbvbvbvbvb..
# Alternating strong and weak vibration, with a pause at the end.
PlugPlug vibe pulse 10 0 mm...mm
# Two slow medium strength vibrations, with a pause.
PlugPlug vibe start 1 2 rrrrrrrr
# Relatively strong vibration,
# but it is not recommended to unnecessarily repeat the pattern.
PlugPlug vibe start 3.0 0 X.X.X.X.X. Y.Y.Y.Y.
# Two patterns in parallel, with mismatched timings.
# (The total duration will be the same.)
PlugPlug vibe pulse 0.5 0 0 abfjmpsvyz
# A curved ramp pattern,
# concentrated on the last motor.
The durations likely won't be entirely accurate and timings may drift a bit, as I tried to make sure the game keeps running no matter what.
It's now easier to use multiple patterns/multiple motors: Patterns are automatically interpolated across devices with differing vibration feature count!
All commands are available through the global `PlugPlug` object.
Just concatenate the command identifiers and pass all parameters in parentheses.
# Set global vibe strength multiplier.
# Connect to all devices.
`PlugPlug.vibe.start(3, 2, 0.2, 'Vb.vb.vb.vb.vb.');`
# Play back the patterns 0.2 and `Vb.vb.vb.vb.vb.`
# focused on the first and last features of each device,
# stretched over three seconds,
# then pause for two seconds. Repeat indefinitely.
What about RPG Maker MZ?
I don't have MZ, so I can't test this plug₂in there. I strongly advise against using robot control software like this in a way that hasn't been thoroughly tested for (reasonable standards of) safety.
What about (linear, rotation…)?
While it would be easy to add additional commands for those interactions, as they are already supported by Intiface, I don't have any test devices for those features.
I'm not comfortable with releasing software that controls mechanical actuators without testing it thoroughly.
How to make a configuration menu?
A configuration menu for players is now included! Please direct them to the Options menu, which will have an additional entry by default when using this plug₂in, or use the PlugPlug config command to show this screen directly.
You can modify this menu by adjusting the global Scene_PlugPlugOptions and Window_PlugPlugOptions classes, or replace it entirely by hooking PlugPlug config and/or proving your own Options menu entry.
Click download now to get access to the following files:
Log in with itch.io to leave a comment.
I got it in a sale a while ago, but didn't have the opportunity to make plugins with commands for it until recently, since it's Windows/Mac only.
I can probably do that now, thinking about it. I'll look into updating this plugin to make it easier to use in MZ.
Aaand there's RMMZ support now. Enjoy!
Hey can you please help me? I can't seem to get it working. The Lovense plug is connected to Intiface and working over their white usb dongle. Vibrations are working from Intiface, its tutorial, and the Plug2in Pattern Composer; but not RPG Maker MV. I've tried a brand new project export with only the plugin and its companion files in the plugin and libs folders. Ran it in Chrome with Wampserver but the intiface vibration and connect + scan stay off. The serverport is 12345, rpgmv version 1.6.2, and sometimes I get a Plugplug not defined error without me having changed anything.
Do you see any other errors in the developer console (which you can open with F12)?
Edit: You don't put anything into the libs folder for this, it all goes into the plugins folder. That's most likely the issue.
Made another new project and only put the files in the plugins folder only, everything works really well now. Thanks a lot for developing the plugin, excellent work!
Glad to hear that 🙂
If you publish your project later, feel free to comment here with a link to it. I'm curious what this plugin gets used for, somewhat regardless of whether that turns out to be my cup of tea or not.
Glad it's working for you!
I haven't had opportunity to get creator feedback on using this plugin so far, so if there's anything that was tricky or didn't work as expected, I'd love to know. (You can also suggest additional features, but there it depends on demand and how difficult it would be to add it. I made this as fun/experimental coding project originally and would like to keep it in that range.)
Everything seems to work the way it should, although I haven't tried it with a device with multiple vibes.
Just a heads-up: I've updated this plugin with better reliability, a number of API improvements and a custom options menu. (And hopefully no new bugs.)
The API changed a bit from version 0.1, so I don't recommend upgrading it for existing projects, but if you make a new mod in the future please give it a spin and let me know what you think.
The main improvement is that you can now seamlessly transition between patterns and wait for them to complete in linear scene events. There's better multi-motor support too, so all patterns are now automatically retargeted for devices with fewer or more features.