|
| 17 Feb 2015 04:25 PM |
I am beginner scripter, I started scripting yesterday, no this isn't a script I read about, I made it on my own. If you can't tell, I am trying to make it so I can step on Blob and Part will rise. It does nothing at all. What should the parent of the script be? Blob,Part,or Workspace? blob = game.Workspace.Blob part = game.Workspace.Part function onTouch(part) wait(1) blob.Position = Vector3.new (-31,1.5,48) wait(1) blob.Position = Vector3.new (-31,2.5,48) wait(1) blob.Position = Vector3.new (-31,3.5,48) wait(1) blob.Position = Vector3.new (-31,4.5,48) wait(1) blob.Position = Vector3.new (-31,5.5,48) end
blob:connect() part.Touched:connect(onTouch) |
|
|
| Report Abuse |
|
|
|
| 17 Feb 2015 04:26 PM |
| http://wiki.roblox.com/index.php?title=Table |
|
|
| Report Abuse |
|
|
|
| 17 Feb 2015 04:29 PM |
| I don't know what that is :I. I am a very stupid beginner. My IQ is only 142 so I am not very smart, so I have no clue how that wiki page is related to whatI did. I don't even know what a string is, I just make the script... |
|
|
| Report Abuse |
|
|
instawin
|
  |
| Joined: 04 Jun 2013 |
| Total Posts: 8777 |
|
|
| 17 Feb 2015 04:40 PM |
well, i would use a bodyposition for something like that
but this would work i think
blob = game.Workspace.Blob part = game.Workspace.Part bodypos = part.BodyPosition start = game.Workspace.Start -- make start a brick, this is where the part will start to move from finish = game.Workspace.Finish -- make finish a brick, and put it where you want the part to stop
blob.Touched:connect(function(hit) player = game.Players:GetPlayerFromCharacter(hit.Parent)
if player then bodypos.position = start.Position wait(5) bodypos.position = finish.Position wait(5) end
end)
add a debounce too or it would get wonky and i didn't test it but i think that would work
play around with the bodyposition properties as well |
|
|
| Report Abuse |
|
|
|
| 17 Feb 2015 04:49 PM |
| What should the Parent of the script be? |
|
|
| Report Abuse |
|
|
instawin
|
  |
| Joined: 04 Jun 2013 |
| Total Posts: 8777 |
|
|
| 17 Feb 2015 04:51 PM |
i don't think it would matter if you used a variant of my script
put it in ServerScriptStorage |
|
|
| Report Abuse |
|
|
instawin
|
  |
| Joined: 04 Jun 2013 |
| Total Posts: 8777 |
|
|
| 17 Feb 2015 04:53 PM |
also i think roblox made a hour of code video that uses BodyPosition, which would be useful in your case
check out all of the hour of code videos they made, you may learn something new
hour of code BodyPosition video: https://www.youtube.com/watch?v=dqyJk0w2AY0
|
|
|
| Report Abuse |
|
|
|
| 17 Feb 2015 04:57 PM |
Wow. Frustrate me too much and I probably throw away what limited knowledge I gained over past 2 days.
!!!!!!!!!!!!!!!!!!!!!!!!!!!!! |
|
|
| Report Abuse |
|
|
|
| 17 Feb 2015 05:04 PM |
You don't have locals set in the beginning
~Stars for a siggy~ |
|
|
| Report Abuse |
|
|
|
| 17 Feb 2015 05:09 PM |
| When i hit play, Blob doesn't get a "Touch Interest" |
|
|
| Report Abuse |
|
|