FloorWire Guide

From Legacy Roblox Wiki
Jump to navigationJump to search

Introduction

In this guide we will learn what FloorWire is, how to use it and how it's going to benefit us in the future.

What is FloorWire?

FloorWire is an instance found by going to Insert -> Object -> FloorWire in ROBLOX Studio. It is used to create a wire that runs from one instance to another. It's parent property should be set to the parent of the two instances.

How will it benefit us?

It's general purpose is to create a line of BillboardGUI-like 'decals' which travel along the wire at the specified speed, interval, etc, but it can also be used for lots of other purpouses! For example, dynamic lightning, or making a cool wire that goes along the floor and walls to get to the destination in a building. However if the character stands in it, it will sometimes attempt to go around the character, wire in real life wouldn't do this, so it's non-collideable, which means it's not a good idea to use it for wire unless you're aware of this consequence. However, if it's through a transparent brick, like underground piping, it could be a good idea.

Guide

The first step

First of all we want to create two parts.

Open up ROBLOX Studio and go to Insert -> Object -> Part. Position it where ever you want.

Repeat this step and position the second part away from the first part.

Name the first part 'PartA' and the second part 'PartB'. You might want to anchor the two parts too.

The second step

Next we need to create the FloorWire instance. One problem, there's some properties of FloorWire that we can't access using the properties pane. So we have to insert a script and edit it's source.

Go to Insert -> Object -> Script.

Make its source as followed:

FloorWire = Instance.new("FloorWire", game.Workspace)

Properties

The FloorWire object consists of many useful properties.

From

One of the FloorWire's properties is called From, it determinds what instance the FloorWire starts from.

So, open up the script you just created and make its source as followed,

FloorWire = Instance.new("FloorWire", game.Workspace)
FloorWire.From = game.Workspace.PartA

To

Another of FloorWire's properties is called To, it determinds what instance the FloorWire runs to.

Make the script's source as followed to change the To property to PartB:

FloorWire = Instance.new("FloorWire", game.Workspace)
FloorWire.From = game.Workspace.PartA
FloorWire.To = game.Workspace.PartB

Color

You can change the color of the FloorWire to make its color how you want it:


FloorWire = Instance.new("FloorWire", game.Workspace)
FloorWire.From = game.Workspace.PartA
FloorWire.To = game.Workspace.PartB
FloorWire.Color = BrickColor.new("Bright yellow")

Transparency

You can change the transparency of the wire by using 0 - 1 numbers. 0 being opaque, 0.5 being transparent, 1 being invisible.

FloorWire = Instance.new("FloorWire", game.Workspace)
FloorWire.From = game.Workspace.PartA
FloorWire.To = game.Workspace.PartB
FloorWire.Color = BrickColor.new("Bright yellow")
FloorWire.Transparency = 0.5

WireRadius

You can customize the radius of the wire by changing the value of this property, 0.0625 is the default, meaning the higher the numbers, the bigger your wire.


FloorWire = Instance.new("FloorWire", game.Workspace)
FloorWire.From = game.Workspace.PartA
FloorWire.To = game.Workspace.PartB
FloorWire.Color = BrickColor.new("Bright yellow")
FloorWire.Transparency = 0.5
FloorWire.WireRadius = 1.5

Have fun playing with your FloorWire!