Game Templates: A Smart Way to Start Building and Scripting
by Dan Healy
You may remember us mentioning our new Capture the Flag template a few weeks ago. Since then, the Content Team has been hard at work creating new templates–particularly prime for competitive gameplay, with more styles of games to come in the future. ROBLOX Software Engineers Dan Healy and Kip Turner explain.
Each of the templates we’ve built is designed to serve a specific purpose, though there are numerous assets you could pull from them. There are standard death-match templates, and a few that may flip that basic mode on its head.
The new templates include: Team Deathmatch, Free for All (no teams, just frags), Control Points and Capture the Flag. We’ve also created blank baseplate and terrain templates that allow you to build from scratch.
We’re particularly interested in seeing what users build using the Control Points template–it’s a fun concept that’s been used in several FPS games. Essentially, your team must “hold” points throughout the map by staying put in a certain location (represented, in the template, by a beam of light on a circular disc). This makes for some intense cat-and-mouse scenarios, where you’ve got to infiltrate points with your team while defending captured points.
What’s great about these templates is that each of them can be taken apart, piece by piece. Every facet of a template–whether it’s an in-game radar or team spawn points–can be extracted and used individually in your place. We encourage you to pick pieces out of the existing templates to add to your place.
Steps to use an individual component (for beginner scripters and up):
- Go to the Build page and click Build New –> Game
- At the bottom of the New Place page, choose the Team Deathmatch template (this one uses the most components)
- Go to the Places page and make your new place Active
- Open up ROBLOX Studio, sign in, and go to your new place’s page
- Click Edit and check out the scripts in Workspace, StarterGui, and StarterPack
- Pick the components you want and copy them into your own place
- Check out how the components are used inside MainGameScript
We’re working on streamlining this process, with the ultimate goal of making it a “drag and drop” process.
These templates were built as starting points for builders. You can take these templates and simply place things around the map–spruce them up–or use them as inspiration for your own type of game. Utilizing the aforementioned how-to guide, you can actually grab individual facets of a template and apply them to your game. There are a lot of possibilities.
Scripters can benefit from templates as well. We consciously wrote the templates’ built-in scripts in an easy-to-read manner to encourage you to edit the configuration variables at the top and modify how the game plays. For example, you can easily modify your game’s round duration by going to the MainGameScript and editing the “RoundDuration” variable in the MyGame structure. The scripts in the templates also teach valuable lessons in scripting architecture and how to structure your code.
We’re certainly not done with templates–we’ve got a lot of work to do. We want users to be able to use this in ROBLOX Studio. We want to make it easier to transfer files from a template to a game. We’re working on ironing these things out. For now, take advantage of our new templates and submit any bugs you experience or tweaks and enhancements you’d like to see. We check our accounts often at onlytwentycharacters (Dan) and SolarCrane (Kip). You can also discuss games with other ROBLOX users by checking out our Game Design Forum.