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
 

Re: gui

Previous Thread :: Next Thread 
crazyzee is not online. crazyzee
Joined: 24 Aug 2010
Total Posts: 275
19 Jun 2012 06:48 PM
local menu = script.Parent
local enter = menu.Enter
local player = game.Players.LocalPlayer


function teleport()
map = game.Workspace:findFirstChild("field")
if not map then return end
spot = math.random(1,4)
part = "Part" ..spot
Player.Character.Torso.CFrame = CFrame.new(Workspace.field.Teleport:findFirstChild(Part).Position + Vector3.new(0,4,0))

end

enter.MouseButton1Click:connect(teleport)
when i click the gui it doesnt teleport me anywhere

output says nothing

Report Abuse
Spectrumw is not online. Spectrumw
Joined: 04 Aug 2009
Total Posts: 13510
19 Jun 2012 06:51 PM
Is this inside a LocalScript?
Report Abuse
crazyzee is not online. crazyzee
Joined: 24 Aug 2010
Total Posts: 275
19 Jun 2012 06:52 PM
help BUMP
Report Abuse
crazyzee is not online. crazyzee
Joined: 24 Aug 2010
Total Posts: 275
19 Jun 2012 06:53 PM
yes it is
Report Abuse
KnightmareXD is not online. KnightmareXD
Joined: 14 Jul 2009
Total Posts: 11189
19 Jun 2012 06:54 PM
Not sure if it's all, but you capitalized Player and Part.

player.Character.Torso.CFrame = CFrame.new(Workspace.field.Teleport:findFirstChild(part).Position + Vector3.new(0,4,0))


† KMXD †
Report Abuse
Spectrumw is not online. Spectrumw
Joined: 04 Aug 2009
Total Posts: 13510
19 Jun 2012 06:55 PM
Found the problem, here you defined it as 'part':
part = "Part" ..spot

Yet you called it here as 'Part' (With a capital 'P') which is nil:
Player.Character.Torso.CFrame = CFrame.new(Workspace.field.Teleport:findFirstChild(Part).Position + Vector3.new(0,4,0))
Report Abuse
crazyzee is not online. crazyzee
Joined: 24 Aug 2010
Total Posts: 275
19 Jun 2012 06:58 PM
also this is in a local script which is in a textbutton
Report Abuse
crazyzee is not online. crazyzee
Joined: 24 Aug 2010
Total Posts: 275
19 Jun 2012 07:05 PM
ok so now the local script is in the gui

end the text button is in the gui but it still doesnt work
Report Abuse
crazyzee is not online. crazyzee
Joined: 24 Aug 2010
Total Posts: 275
19 Jun 2012 08:43 PM
Bump please help me
Report Abuse
crazyzee is not online. crazyzee
Joined: 24 Aug 2010
Total Posts: 275
19 Jun 2012 09:06 PM
Bump
Report Abuse
aboy5643 is not online. aboy5643
Joined: 08 Oct 2010
Total Posts: 5458
19 Jun 2012 09:16 PM
spectrum showed you your issue. Fix it or learn how to script because you obviously don't know what you're doing.
Report Abuse
crazyzee is not online. crazyzee
Joined: 24 Aug 2010
Total Posts: 275
19 Jun 2012 09:22 PM
Actually I do know how to script but I'm still learning and I'm already an advanced scripter but if I keep on practicing and see my mistakes then I won't ask the forums for the scripts I make unless they are hard scripts.



I'll give you some examples of scripts that I make. I gave my friend scripts for his game and his game is awesome ,but still wip.


That's all I want to say.
Report Abuse
Uuvinu is not online. Uuvinu
Joined: 19 Apr 2012
Total Posts: 2206
19 Jun 2012 09:23 PM
I'd help but this thread is solved as far as I can see.
Report Abuse
crazyzee is not online. crazyzee
Joined: 24 Aug 2010
Total Posts: 275
19 Jun 2012 09:24 PM
Ok I'll make the script the way spectrum did it,there problem solved three no more.
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