Hey everyone! first post here so, sorry if its formatted a bit wrong. I have recently got into ROBLOX Lua, and I've been trying to learn the language. All was going well, I've found myself understanding the language and did not encounter any major problems until today (not counting the small problems that were just simple grammar mistakes).
So I have encountered a problem while I was doing one of my practices, and I have no clue what is going on. (once again, this is a practice script to get better understanding of Parameters and Arguments, sorry in advance for the messy script haha)
The problem is, is that every time when I try to run the script, the output gives me a "No script currently available" on line #31. I've checked over the code and I don't see any problems, maybe one of you can help me find the problem?
Script:
print("pathScript is trying to run")
-- This is the script that generates the path
function pathScript(a, b, c, x, y, z, name)
local path = Instance.new("Part")
path.Parent = workspace
path.Size = Vector3.new(a, b, c)
path.Position = Vector3.new(x, y, z)
path.Anchored = true
path.BrickColor = BrickColor.new("Brown")
path.TopSurface = "Smooth"
path.Material = "Pebble"
path.Name = name
end
-- This calls the path generation script
pathScript(8, 1, 14, -241, -18.5, 250, "pathOne")
pathScript(8, 1, 14, -237, -18.5, 236, "pathTwo")
pathScript(8, 1, 14, -233, -18.5, 222, "pathThree")
pathScript(8, 1, 14, -237, -18.5, 208, "pathFour")
print("pathScript has successfully ran")
print("houseScript is trying to run")
-- This is the script that generates the house
function houseScript(a, b, c, x, y, z, color, name, mat)
local house = Instance.new("Part")
house.Parent = workspace
house.Size = Vector3.new(a, b, c)
house.Position = Vector3(x, y, z)
house.Anchored = true
house.BrickColor = BrickColor.new(color)
house.TopSurface = "Smooth"
house.Material = Enum.Material.mat
house.Name = name
end
houseScript(63, 1, 39, -238.49, -18.505, 181.49, "Reddish brown", "floor", "Wood Planks")
Image: https://i.imgur.com/Rj4svXb.png
I would really appreciate if someone could help me allocate the problem, thank you!
- NotSoEvilScientist
Edit: I did realize that I forgot to add the ".new" to the vector3, but it still gives me the same output
