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 » Scripters
Home Search
 

Re: Can someone spot the error here?

Previous Thread :: Next Thread 
9draco is not online. 9draco
Joined: 13 Nov 2010
Total Posts: 5841
18 Aug 2015 08:05 AM
So I created a script in Notepad++, and tested it in Roblox studios, but for some reason the script doesn't work, no output...

Full script:
Tool = script.Parent
Player = game.Players.LocalPlayer
Mouse = Player:GetMouse()
debounce = false

Tool.Activated:connect(function(Activated)
if not debounce then
debounce = true
local aura = Instance.new("Part")
Instance.new("CylinderMesh", aura)
aura.BrickColor = BrickColor.new("Lime green")
aura.Anchored = true
aura.CanCollide = false
aura.Transparency = 0
aura.Position = Player.Character["Left Leg"].Position
for i = 1, 40 do
wait(0.01)
local x = 1
local y = 1
local a = x + 2.5
local b = y + 2.5
aura.Transparency = aura.Transparency + 0.025
aura.Size = Vector3.new(x, y, 1)
local effect = Instance.new("Part", aura)
Instance.new("CylinderMesh", effect)
effect.BrickColor = BrickColor.new("Royal purple")
effect.CanCollide = false
effect.Anchored = false
effect.Position = aura.Position
effect.Transparency = 0
for i = 1, 40 do
local z = 1
effect.Size = Vector3.new(1, 1, z + 2)
effect.Transparency = effect.Transparency + 0.025
effect.Position = Vector3.new(effect.Position.X, effect.Position.Y, effect.Position.Z + 0.5)
wait(0.01)
effect.Touched:connect(function(touched)
local part = touched.Parent
for i = 1, 10 do
part.Position = Vector3.new(part.Position.X, part.Posititon.Y, part.Position.Z + 0.5)
end
if part.Position.Z > 3 then
local debounce = true
while debounce do
part.Rotation.X = part.Rotaion.X + 1
wait(0.001)
Mouse.Button1Down:connect(function(hit)
local x = Mouse.Position.X
local y = Mouse.Position.Y
local Position = Instance.new("BodyPosition")
Position.position = Vector3.new(x, y, part.Position.Z)
Position.P = 4000
debounce = false
end)
end
end
end)
end
if effect.Transparency == 1 then
effect:remove()
end
end
debounce = true
end
end)

--Even this part doesn't work:

Tool = script.Parent

Tool.Activated:connect(function(Activated)
local aura = Instance.new('Part')
end)

Report Abuse
Rxhan is not online. Rxhan
Joined: 09 Oct 2010
Total Posts: 252
18 Aug 2015 08:06 AM
k so where did the problem start

did anything in the script work at all


r.i.p 5k+ posts ;(
Report Abuse
Immacularity is not online. Immacularity
Joined: 21 Jun 2014
Total Posts: 419
18 Aug 2015 08:07 AM
aura=Instance.new("Part")

you never set aura's parent and effect is inside of aura, so obviously it's not going to work


Waiting for BinaryStringValue API in RBX.Lua for 1337 efficiency.
Report Abuse
9draco is not online. 9draco
Joined: 13 Nov 2010
Total Posts: 5841
18 Aug 2015 08:07 AM
I decided to minimize the script to:

Tool = script.Parent

Tool.Activated:connect(function(Activated)
local aura = Instance.new('Part')
end)

Surprisingly, still doesn't work?!
Report Abuse
Immacularity is not online. Immacularity
Joined: 21 Jun 2014
Total Posts: 419
18 Aug 2015 08:10 AM
le sigh

i told you
you didn't assign aura's parent to anything
so you aren't going to see the part


Waiting for BinaryStringValue API in RBX.Lua for 1337 efficiency.
Report Abuse
Datamora is not online. Datamora
Joined: 06 Jun 2014
Total Posts: 78
18 Aug 2015 08:11 AM
You forgot to make a part in your tool called: 'Handle'.
If you do not want this, you can try to use a HopperBin instead.
Report Abuse
Rxhan is not online. Rxhan
Joined: 09 Oct 2010
Total Posts: 252
18 Aug 2015 08:14 AM
Tool.Activated:connect(function(Activated)
if not debounce then
debounce = true
local aura = Instance.new("Part", game.Workspace)

you can change workspace to whatever you want, irdc. after that where else does the problem start


r.i.p 5k+ posts ;(
Report Abuse
9draco is not online. 9draco
Joined: 13 Nov 2010
Total Posts: 5841
18 Aug 2015 08:17 AM
ok, thanks!
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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