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: Script Newbie help.

Previous Thread :: Next Thread 
EdvisLT2 is not online. EdvisLT2
Joined: 12 Oct 2010
Total Posts: 92
05 Oct 2014 04:50 PM
Hey pro 360 noscop scripterz etc. out there, I need some help.

Today I started learning scripting, and made a very basic script, but it doesn't seem to work. So where is the error? I typed what does function "Jarraxus" do, typed what "Ur Mom" is, and applied the "Jarraxus" to "UrMom". But as soon as I start the place, nothing happens. Script picture: http://prntscr.com/4tey2w.
I know, that you'll maybe find this funny, but I'm just trying to get better at scripting :3.
Report Abuse
Goulstem is not online. Goulstem
Joined: 04 Jul 2012
Total Posts: 7177
05 Oct 2014 04:58 PM
local player = "Put the player's name here"

local Urmom = game.Workspace:FindFirstChild(player)

function Jarraxus(thing)
thing.Head:Destroy()
end

Jarraxus(Urmom)

------------------------------

Cleaned up:

local player = game.Workspace:FindFirstChild("Your Name here")

if player then
player:BreakJoints()
end
Report Abuse
EdvisLT2 is not online. EdvisLT2
Joined: 12 Oct 2010
Total Posts: 92
05 Oct 2014 05:25 PM
Sorry, but because of my noobism I couldn't get this to work. So first, in my studio test run my name is "Player", right? I've done this way: Put the upper part in script (Because only one part of this script has to be used, right?), which I've put in workspace. And when I launched the game, nothing happened.
If you're smart enough to explain my stupidity, can you explain me in "human speech", what exactly am I doing wrong? Here's my complete script:

local player = "Player"

local Urmom = game.Workspace:FindFirstChild(player)

function Jarraxus(thing)
thing.Head:Destroy()
end

Jarraxus(Urmom)

P.s. can someone answer these questions?

1. The PLAYER itself is classified as "thing"?
2. What IS Child/FindFirstChild etc., and what they're used for?
3. Is there a list of functional basic commands I can read and use later? Explode, Breakjoints, Delete etc. If yes, can you send it in the reply?
Report Abuse
EdvisLT2 is not online. EdvisLT2
Joined: 12 Oct 2010
Total Posts: 92
05 Oct 2014 11:23 PM
bump
Report Abuse
EdvisLT2 is not online. EdvisLT2
Joined: 12 Oct 2010
Total Posts: 92
06 Oct 2014 04:56 AM
Still need explanation and help.
bump.
Report Abuse
EdvisLT2 is not online. EdvisLT2
Joined: 12 Oct 2010
Total Posts: 92
06 Oct 2014 02:06 PM
bumb :/.
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
06 Oct 2014 02:12 PM
local player = "Player"

local Urmom = game.Workspace:FindFirstChild(player)

function Jarraxus(thing)
thing.Head:Destroy()
end

Jarraxus(Urmom)

Wow...

You probably want to run this code I will give you in a local script, Study it and look anything you don't know up on the wiki

local player = "The Players Name Here"

local Urmom = game.Workspace:FindFirstChild(player)

function Jarraxus()
Urmom.Head:Destroy()
end

game.Players.PlayerAdded:connect(Jarraxus)
Report Abuse
EdvisLT2 is not online. EdvisLT2
Joined: 12 Oct 2010
Total Posts: 92
06 Oct 2014 02:59 PM
I tried this code just simply putting it on my Workspace once and changing the name to simply "Player", but assuming from your advice to run it on local script, I found out that it shouldn't even work in the way like this.
So I looked up for what "Local Script" is, and readed the information about that in the wiki. So it says: In order for a LocalScript to function, it must be placed within one of three areas:
In a player's Backpack (can be indirectly, through a Tool or HopperBin)
In a player's character model
In a player's PlayerGui

So I placed the script in the StarterGui, pressed "Play Solo", and it doesn't destroy my head as I spawn. But it doesn't load my character, I don't think it's because of the script though.
I think it's because of running the script, I'm doing something wrong in that.
Here's how I've put everything in: http://prntscr.com/4toqme (Also doesn't work in Workspace), http://prntscr.com/4toquj, http://prntscr.com/4tor8x.
Can somebody show me the proper way this script has to be used in order to destroy my head as I spawn?

P.s. from some reading I assume that Parent is the model/part the some part is. And child is the part that is in some other part. So script.parent stands for where's the script put in. And FindFirstChild(type) takes the first part of the written type in the Model/Part. Is that right?
Report Abuse
FlameYeti is not online. FlameYeti
Joined: 14 Jan 2009
Total Posts: 22158
06 Oct 2014 03:37 PM
local player = "Player"

local Urmom = game.Workspace:FindFirstChild(Player) --must be capitalized

function Jarraxus(thing)
thing.Head:Destroy()
end

Jarraxus(Urmom)
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