generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Derp. Help please. Output included

Previous Thread :: Next Thread 
MassiveGman is not online. MassiveGman
Joined: 23 Jan 2011
Total Posts: 2019
21 Mar 2013 04:10 PM
17:06:49.206 - Workspace.decalscript:23: unexpected symbol near '='
line 23 is local right = Instance.new(...
I want this script to make a decal on each side of the brick.

for i,v in pairs(Workspace:GetChildren()) do
if v.ClassName == "Part" then
local right = Instance.new("Decal",v).Texture = "http://www.roblox.com/asset/
id=69129747"
right.Face = "Right"
local left = Instance.new("Decal",v).Texture = "http://www.roblox.com/asset/?id=69129747"
left.Face = "Left
local back = Instance.new("Decal",v).Texture = "http://www.roblox.com/asset/?id=69129747"
back.Face = "Back"
local front = Instance.new("Decal",v).Texture = "http://www.roblox.com/asset/?id=69129747"
front.Face = "Front"
local top = Instance.new("Decal",v).Texture = "http://www.roblox.com/asset/?id=69129747"
top.Face = "Top"
local bottom = Instance.new("Decal",v).Texture = "http://www.roblox.com/asset/?id=69129747"
bottom.Face = "Bottom"
end
end


Thanks for any help

|-MassiveGman-| ~|Law Of Inertia|~
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
21 Mar 2013 04:21 PM
You can't set a Texture of a created object that's set as a variable on a single line.

local bottom = Instance.new("Decal", v)
bottom.Texture = "assetURL"
Report Abuse
MassiveGman is not online. MassiveGman
Joined: 23 Jan 2011
Total Posts: 2019
21 Mar 2013 04:36 PM
You can't?
You can set parents and things that way.

Instance.new("Fire",Workspace.Brick).Size = 4

I believe you can.



|-MassiveGman-| ~|Law Of Inertia|~
Report Abuse
MassiveGman is not online. MassiveGman
Joined: 23 Jan 2011
Total Posts: 2019
21 Mar 2013 04:44 PM
Ugh
The problem was the uncompleted string.

nvm



|-MassiveGman-| ~|Law Of Inertia|~
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
21 Mar 2013 05:14 PM
Gman, you can't do this:

item = Instance.new("BoolValue", workspace).Value = true

But you can do this:

item = Instance.new("BoolValue", workspace)
item.Value = true

or:

Instance.new("BoolValue, workspace).Name = "item"
workspace.item.Value = true
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image