Maya Scripts

MEL, Python, Qt (PySide2)

BenMiller_Animated_lifeTool_01.gif

Conway’s “Game of Life” in Maya (Download)

Scripting Language: MEL

Out of sheer curiosity, I created a program that uses square buttons in Maya as pixels for the classic Game of Life. I used Maya’s time slider to measure time. Each generation, a cell examines its surroundings to learn whether it will breed, starve, or survive. New life can be scattered across the entire board or manually drawn out with the mouse. Newborn cells receive the colors of their parents while surviving cells grow saturated with age.

Water tiles act as boundaries while also providing a chance to spontaneously generate new life. You can call down a natural disaster to blot out tiles from the board for a number of turns, devastate the ecosystem to wipe out all life, and even reduce the diversity (color) of all cells.

Several custom settings, like the dimensions of the board, time per generation (controlled by the time slider), scale of the tiles, and mutation rate near water, are presented in a story-like interface before beginning the simulation.

BenMiller_Animated_vera_01.gif

Vera for Maya

Scripting Language: Python with Qt (PySide2)

While working with Construct Studio, I was responsible for making the interface for our Vera plug-in for Maya. While my earliest mock-ups used Maya’s native UI, I eventually learned to use Qt through the PySide2 module now included in Maya. My interface communicated frequently with code written by our engineers to retrieve, edit, and save data. Vera itself was used to automatically attach coded functionality to artists’ models, instantly creating an interactive asset ready to use in a game engine.

My program procedurally generates interface blocks to accept various data inputs requested by a Vera template. The user is able to browse, search (by name or component), and fill out any of these templates. They can even use an embedded viewport to render a thumbnail image. Simple icons represent the type of content (lights, meshes, groups, etc.) and the completion state of each node.

This was by far the largest and most complex program I’ve written and the first that I’ve done while coordinating with a team.

BenMiller_Animated_mayaTool_01.gif

Mirroring, Instancing, Radial Tool (Download)

Scripting Language: Python with Qt (PySide2)

As robust as Maya’s “duplicate special" feature is, I found its interface to be far too clunky. This script takes its most basic elements and simplifies them down into a small, color-coded, and plainly written panel that sits nicely in the work space. Almost all of the mirroring actions I make when modeling are directly across or around an axis which is how I designed the layout. A radial option allows you to create copies or instances in a full circle around an axis (rather than in degrees).

BenMiller_Animated_gridTool_01.gif

Grid Controller (Download)

Scripting Language: MEL

At the start of each session, I check my grid settings to be sure I’m working with the correct units. This script provides thorough control over the grid and its subdivisions in a way that, for me, was faster and more intuitive to work with than digging through menus. A central slider subdivided the grid modularly so if you were working in multiples of 2 (2, 4, 8, 16) or 10 (10, 100, 1000), you could very quickly increase or decrease granularity with ease.

The resulting script was an exercise in procedural UI text with several elements updating to display the correct unit or present a readable explanation of scale to the player.

BenMiller_Animated_layers_01.gif

Scratch Layer Editor (Download)

Scripting Language: MEL

Maya’s built in layer editor is great once your scene stops changing dramatically. During production, however, you’ll end up with piles of empty layers with lost identities. The layer editor I created was designed to be disposable, movable, and quickly edited. It allows you to store groups at any time, delete them, abandon them, and toggle their visibility. There’s even a defrag button that moves all layers up to fill empty spaces. To make your groups easier to remember, each layer automatically gives itself a memorable name like violets, nomads, crumpets, or caterpillars and will accept a custom name if provided.

BenMiller_Animated_UVs_02.gif

Yet Another UV Layout Tool (Download)

Scripting Language: MEL

Everyone has a UV layout script. I’ve nearly retired this one, yet I can’t stop using its vertical and horizontal stretching functions.