Contents

Introduction

Ventrilo is a voice communication program for Windows that runs quite well on the latest wine. This article outlines a few workarounds necessary to using Ventrilo naturally on Linux.

Note: Running Ventrilo under wine is no longer necessary; Mangler is a stable open-source client in the AUR that connects to Ventrilo 3.0 servers.

Global Push to Talk Hotkey

One problem that wine Ventrilo users face is that the push to talk hotkey only being detected when a wine window (such as Ventrilo itself) is in focus. The solution to this is using ventriloctrl, a simple program that sends X input to Ventrilo.

Finding the input device

The acceptable input devices are in /dev/input/. If you want to use a mouse use the event-mouse in /dev/input/by-id/. For a keyboard use /dev/input/event[#].

You'll probably need to do a bit of trial and error to find the proper event number or device. The best way to do this is just to run Template:Codeline as root, and press keys or click your mouse and see if it is detected by the program. If it is detected, it will show an example line with a number at the end. That number is the button number that you will use to run ventriloctrl in the future.

If that was the button I wanted to use, I would run ventriloctrl with that line in the future.

Startup Script

Now we'll make a script to run ventriloctrl using the parameters you discovered. This could also be done with an alias or other user-specific methods. Edit your script with your favorite editor and call it whatever you want. Mine is going to be called Template:Filename.

# nano /usr/bin/ventriloctrl+

By default, a normal user does not have the access to the /dev/input/ devices that ventriloctrl needs to use. To get around this you can either make a udev rule, or just use sudo. So far, I'm just going to show what your script should look like with sudo.

Of course, the device and event number should be replaced with the ones you found earlier. Essentially you just want to add sudo to the front of your previous input device line.

Make sure your script is executable:

# chmod +x /usr/bin/ventriloctrl+

All done. Now you just need to make the Template:Filename script run when ventrilo runs.

Example Ventrilo Startup Script

We previously made a script to start ventriloctrl. Now, you may wish to make a script that starts ventriloctrl after Ventrilo starts. The tough part about this is determining when ventrilo has started completely, as it is a wine app. If anyone else has a better way of doing this please add it. Otherwise, here is my method.

Copy it into a script file such as Template:Filename. Make sure the script is executable.

# chmod +x /usr/bin/try

Now create another script to start Ventrilo named whatever you want. Mine will be called Template:Filename.

# nano /usr/bin/ventrilo

In the script, you'll first want to cd to your Ventrilo install. By default, this should work for any users that have it installed to their default Template:Filename directory. In my example, I run Template:Filename and save its pid to the VENT variable, and then I use the try script to run Template:Filename and save its pid to the CTRL variable. Then I wait until VENT finishes, and kill CTRL. The effect? Ventrilo starts and ventriloctrl attempts to start until it does, then it runs until Ventrilo closes. Here's my script: