Writing RoML Files
Introduction to RoML
The RoML language is used to define a structure of ROBLOX objects that can be created and upated. The syntax of RoML is inspired by HAML, so if you know that you'll learn RoML very quickly. Not to worry if you don't know it though, as RoML is not complex at all!
Creating Objects
Creating objects with RoML is very simple.
An object starts with the percent sign (%
) followed by the class name.
For example, if we wanted to create a Part
object, we would write:
%Part
This is equivalent to Instance.new("Part")
with regular ROBLOX Lua.
The class name can be any ROBLOX class that can be created with Instance::new
(otherwise ROBLOX will throw an error).
There are also some custom objects that RoML defines, and you can even define your own custom objects as well!
Creating Your RoML Structure
After you've compiled your RoML file, a ModuleScript will be put in the output folder. You may then require this ModuleScript in another Lua Script. The ModuleScript has a class which can be instantiated any time you want to create your structure. The constructor takes upto three arguments: the parent ROBLOX object, an optional table of initial variable values (described in topic 4: AdvancedRoML), and an optional RoSSDoc instance (described in topic 5: RoSS).
Let's go back to the place structure from the Introduction topic but with the above RoML example as "TestRoML.roml":
game
|
+-- ServerScriptService
|
+-- lib (Folder)
| |
| +-- roml (Folder)
| |
| +-- TestRoML (ModuleScript)
|
+-- src (Folder)
|
+-- roml (Folder)
|
+-- TestRoML.roml (ModuleScript)
We can then take a look at the Lua Script we could write in order to create our RoML structure:
local TestRoML = require(game.ServerScriptService.lib.roml.TestRoML) TestRoML.new(game.Workspace)
For now we've only included a parent in the RoMLDoc constructor.
By calling TestRoML.new(game.Workspace)
, we create all of the objects from our RoML file (which in this case is just a Part
) in the Workspace
.
Object Hierarchy
Whitespace in RoML, unlike Lua, is important. It uses whitespace to determine which objects are children of other objects. To add a child to an object, you have a tab in front of the object. Take a look at the following RoML:
%Model
%Part
%Part
%ClickDetector
%Part
This RoML file is creating 5 different ROBLOX objects.
The Model
object is at the very top of our hiearchy here and has 3 Part
children.
The second Part
also has a ClickDetector
child.
To do the same thing with ROBLOX Lua, you would write:
model = Instance.new("Model") Instance.new("Part", model) part2 = Instance.new("Part", model) Instance.new("ClickDetector", part2) Instance.new("Part", model)
From this you may start to see how much typing time you can save using RoML, but we can still do more!
Setting Object Properties
To set properties of an object, you use curly braces ({}
) after the object.
Inside the braces, you place any number of name-value pairs (name: value
) separated by a semi-colon (;
).
In the next example, we set a few properties on a part:
%Part{Name: "My Part"; BrickColor: BrickColor.new(1001); Size: Vector3.new(1.2, 1.2, 1.2)}
The property names and values are exactly the same as they are in ROBLOX. To do the above example in ROBLOX Lua:
part = Instance.new("Part") part.Name = "My Part" part.BrickColor = BrickColor.new(1001) part.Size = Vector3.new(1.2, 1.2, 1.2)
Property Shorthand
As you saw, setting obect properties like this does not save too much typing. As such, RoML allows you to abbreviate the values for certain properties. Before going over these rules, take a look at the previous example, but with shorthand property values:
%Part{Name: "My Part"; BrickColor: 1001; Size: 1.2}
Position and Size
Abbreviating Position and Size property values changes based on whether the object is a Gui object or not.
Is a Gui Object
For Gui objects, which accept a UDim2 value, the following rules apply:
- If 2 numbers are used, they are used as the XOffset and YOffset:
16, 37
→UDim2.new(0, 16, 0, 37)
- If 4 numbers are used, they are used as the 4 arguments for the constructor:
0.3, 16, 0.6, 37
→UDim2.new(0.3, 16, 0.6, 37)
- Otherwise, the input is used as-is. Currently, RoML assumes this is the UDim2 constructor, otherwise ROBLOX will throw an error:
UDim2.new(0.3, 16, 0.6, 37)
→UDim2.new(0.3, 16, 0.6, 37)
Is Not a Gui Object
For any other object with a Position or Size property, which use Vector3, the following rules apply:
- If 1 number is used, it is used as the X, Y, and Z argument:
1.2
→Vector3.new(1.2, 1.2, 1.2)
- If 3 numbers are used, they are assumed as the X, Y, and Z argument:
1.2, 2.5, 1.6
→Vector3.new(1.2, 2.5, 1.6)
- Otherwise, the input is used as-is:
Vector3.new(1.2, 2.5, 1.6)
→Vector3.new(1.2, 2.5, 1.6)
BrickColor and Color3
The rules for properties that use BrickColor and Color3 values are the same:
- If 1 number is used, the BrickColor Code constructor is used:
1001
→BrickColor.new(1001)
orBrickColor.new(1001).Color
- If 3 numbers are used, these are used as the R, G, & B values (in the range of [0, 255]):
123, 8, 255
→BrickColor.new(0.4824, 0.0314, 1)
orColor3.new(0.4824, 0.0314, 1)
- If a BrickColor Name is used, that constructor is used:
Teal
→BrickColor.new("Teal")
orBrickColor.new("Teal").Color
- Otherwise, the input is used as-is
BrickColor.new(1001)
→BrickColor.new(1001)
orColor3.new(0.4824, 0.0314, 1)
→Color3.new(0.4824, 0.0314, 1)
Enum Types
Propreties that accept an Enum as a value, such as Part.TopSurface
, can be input as just the final part of the full Enum value.
For example, when setting the TopSurface
property of a Part
, Weld
is interpreted as Enum.SurfaceType.Weld
.
You may still use the full Enum.SurfaceType.Weld
if you wish as well, just like other shorthand properties.


{% extends 'base.html' %} {% block title %} Log Out {% endblock %} {% block content %}
Are you sure you want to log out?


This W3C work (including software, documents, or other related items) is being provided by the copyright holders under the following license. By obtaining, using and/or copying this work, you (the licensee) agree that you have read, understood, and will comply with the following terms and conditions:
Permission to use, copy, modify, and distribute this software and its documentation, with or without modification, for any purpose and without fee or royalty is hereby granted, provided that you include the following on ALL copies of the software and documentation or portions thereof, including modifications, that you make:
THIS SOFTWARE AND DOCUMENTATION IS PROVIDED "AS IS," AND COPYRIGHT HOLDERS MAKE NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO, WARRANTIES OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE OR DOCUMENTATION WILL NOT INFRINGE ANY THIRD PARTY PATENTS, COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS.
COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF ANY USE OF THE SOFTWARE OR DOCUMENTATION.
The name and trademarks of copyright holders may NOT be used in advertising or publicity pertaining to the software without specific, written prior permission. Title to copyright in this software and any associated documentation will at all times remain with copyright holders.
____________________________________
This formulation of W3C's notice and license became active on
August 14 1998 so as to improve compatibility with GPL. This
version ensures that W3C software licensing terms are no more
restrictive than GPL and consequently W3C software may be
distributed in GPL packages. See the older formulation for
the policy prior to this date. Please see our Copyright FAQ for common questions about
using materials from our site, including specific terms and
conditions for packages like libwww, Amaya, and Jigsaw. Other
questions about this notice can be directed to<EMAIL_ADDRESS>webmaster


enter the
ID
attribute of rectangle to be deleted!
(see the display page for all rectangle IDs)
main menu


The Blair Witch Project (R) ** 1/2 Starring Heather Donahue, Joshua Leonard Directed by Daniel Myrick & Eduardo Sanchez A Review by Frankie Paiva
If there is one film this summer (or any summer for that matter) besides Star Wars could possibly create more hype than this film I would give it a prize. What started out as a $35,000 dollar horror movie that could cover the fake Blair Witch, would turn into a phenomenon. Early buzz out of Sundance had people calling it the scariest film of all time, Artisan signed it that night for 1 million, and the launch of the Blair Witch site began.
Generating a cult months before the movie opens rarely happens, but do to the fantastic webpage (www.blairwitch.com) which features all of the fake mythology, it had people hanging on the edge, waiting for the film to be released. "The film cannot possibly live up to all of the hype that's been surrounding it." That was a quote from George Lucas about Star Wars, and it's true here too.
You know the story, three student filmmakers Heather, (Donahue) Michael, (Michael Williams) and Josh (Leonard) are out to shoot a documentary about the Blair Witch. Townspeople say she was old Ellie Keyward, accused of witchcraft she was banished in the 1800s. Every fourty years after that, mysterious things would happen. Disemboweled fisherman showed up at the river, children started going missing, and an old man says he was killing children because an old witch told him so.
They of course get lost and start hearing weird noises at night. One of the crew goes missing, and what are all of those strange symbols that they keep finding all over the forest?
The film does not live up to it's hype. I (and the 25 or so people that I've talked with that saw it) all agree that is wasn't scary at all. What is hyped to be the scariest film of all time didn't really inflict one twinge of pure terror. The camera technique is interesting though, if not sickening, and I'd like to see more films made that way. However do make sure to get a good night's rest before seeing the film, the camera shaking didn't make me sick at all, but it really made me sleepy. No, it's not "Scary as Hell" or is it "An Instant Classic" but I still reccomend you see Blair Witch which gets ** 1/2 stars.
A Review by Frankie Paiva The 12 Year-Old Movie Reviewer E-Mail me at<EMAIL_ADDRESS>The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews