VirtualVEX: Open Source VEX Robotics Competition Simulator

<Cross-posted on the VEX Forum>

This project has been in development for several months now and we’ve seen it fit to now release an open alpha to the community.

As the title of this post says, VirtualVEX is an open source VEX simulator. It is created using Unity3d (a free game development tool) and is programmed primarily in C# with some JavaScript (technically UnityScript) providing support scripts. It began in May of this year as an independent project and gained official support from Team 254 in late August. The aim of the VirtualVEX project is to provide a free platform which can be used by teams to practice their driving and operating skills when access to their physical robot is either unavailable or inconvenient for whatever reason.

Some of the CURRENT features of this release include:

Multiple robot types: right now only clawbot and conveyor belt robot ("ConveyorBot") are implemented, with work on a vertical intake roller style robot in progress.
Programmable: You can change the controls of the virtual robot by downloading your own user code. VirtualVEX is compatible with the ROBOTC API, but user code must be compiled into a DLL which is loaded at runtime.
A lightweight IDE, VVDevelop, is also available for download to help with the creation of custom driver control code (since the program can't interface with the regular ROBOTC IDE).
Timed Robot Skills mode: This allows teams to practice for the Robot Skills competition. It features a built-in game timer that disables your robot once 1 minute is up.
Automated Scoring: Your score is instantly calculated and updated throughout the simulation. Note that parts of this implementation, namely the doublers/negators, have not been added, but the first score bonus is implemented.

As has been stated earlier, the program is still in an alpha stage. It is currently usable for general practice, but we hope to add some new features, such as autonomous support or AI opponents. Precedence however is given to adding more basic functions such as match loading.

You can obtain the current release from our website:

Documentation can also be found on the website but it is still under construction. You can also see screenshots there.

If you do use VirtualVEX, I won’t ask for payment since it’s free, but I do ask that you leave feedback in this thread.

List of known issues, please don’t post these as we know about them…
-Conveyor intake twists when it runs into a goal at high speed. Normally this corrects itself after driving a while
-Keyboard shortcuts for gate raising causes gates to move strangely
-Clawbot intake loose at full height


I can’t figure out how to load user code that controls the arm or gripper of either robot.

Absolutely awesome piece of software. Great job coding a 3-d robot simulator in only a few months, if that!

The default code should already be able to control the arm and gripper. Keep in mind that the program is designed to use dual-axis joysticks (like the logitech dual action gamepad) for input, and that keyboard controls are provided for backup only. Furthermore, the default setup is designed for a driver and operator. That being said, if you are looking to create your own custom code that uses only one joystick or something, there are instructions on the website on how to do that.

As far as the rapid development of the application, Unity handles a lot of the grunt work, making true RAD a possibility.

Um while I was using the conveyor bot, one side got stuck on the side of the field and when I drove away it caused the entire bot to explode and disappear from the field.

Isn’t that normal?

See the list of known bugs; for whatever reason the intake pieces are not very rigid and you should try to avoid ramming them into things. I’ve been trying to figure out a workaround, but the hinge joints Unity offers are simply not rigid enough…

I’ve tried but can’t seem to figure out how to write good code for a single person to control the robot. I wanna play! :slight_smile: Anyone got any code of their own?

Some things here:

  1. I find that one person using two remotes for the ConveyorBot is not difficult. Though that could just be me.

  2. I realized something very, very important regarding that VVDevelop IDE: Annoying Vista/7 User Accounts Controls makes some of its features - most importantly compile and download - unusable. I will issue a repaired version soon that works with UAC. For now, if you want to use VVDevelop you can disable UAC, or you can wait for the next release if you don’t mind. It’s all up to you. I apologize for the inconvenience, I didn’t have UAC in mind…