dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
|
| 26 Jun 2012 09:08 PM |
so its effects reverse after 30 seconds
function onTouched(part) local h = part.Parent:findFirstChild("Humanoid") if h~=nil and h.WalkSpeed > 0 then h.WalkSpeed = h.WalkSpeed - 2 end end script.Parent.Touched:connect(onTouched)
|
|
|
| Report Abuse |
|
|
|
| 26 Jun 2012 09:10 PM |
Put a wait(30) and then just reverse all the effects.
~"If I win the lottery, the first thing I'm buying is an optical mouse"~ |
|
|
| Report Abuse |
|
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
| |
|
|
| 26 Jun 2012 09:28 PM |
wait(30) h.Walkspeed + 2
??? xO
-Tester- |
|
|
| Report Abuse |
|
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
| |
|
WhiteRain
|
  |
| Joined: 24 Apr 2010 |
| Total Posts: 2723 |
|
|
| 26 Jun 2012 09:32 PM |
| Does it work with the current code you have? If it does I have no idea why it wouldn't with a simple wait(30) and reversing it. |
|
|
| Report Abuse |
|
|
|
| 26 Jun 2012 09:32 PM |
*facepalm*
function onTouched(part) local h = part.Parent:findFirstChild("Humanoid") if h and h.WalkSpeed > 0 then h.WalkSpeed = h.WalkSpeed - 2 wait(30) h.WalkSpeed = h.WalkSpeed + 2 end end script.Parent.Touched:connect(onTouched)
> † KMXD † |
|
|
| Report Abuse |
|
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
|
| 26 Jun 2012 09:33 PM |
| i dunno either but that script somehow doesn't work. |
|
|
| Report Abuse |
|
|
WhiteRain
|
  |
| Joined: 24 Apr 2010 |
| Total Posts: 2723 |
|
|
| 26 Jun 2012 09:35 PM |
| This script is inside the brick to be touched right? |
|
|
| Report Abuse |
|
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
|
| 26 Jun 2012 09:37 PM |
| its not a brick its a pellet from the Slingshot tol roblox has |
|
|
| Report Abuse |
|
|
|
| 26 Jun 2012 09:37 PM |
If the script isn't in the brick I will facepalm big time, this script looks like it should work...
-Tester- |
|
|
| Report Abuse |
|
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
|
| 26 Jun 2012 09:38 PM |
| Well its in the brick This SHOULD work but its not |
|
|
| Report Abuse |
|
|
|
| 26 Jun 2012 09:38 PM |
function onTouched(hit) ?????? xO
-Tester-
btw, (not to be mean) a pellet is still a brick, derp |
|
|
| Report Abuse |
|
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
| |
|
WhiteRain
|
  |
| Joined: 24 Apr 2010 |
| Total Posts: 2723 |
|
|
| 26 Jun 2012 09:40 PM |
The pellets don't last long enough in game for the script to finish I think. Try editing the script that deals with the removal of the projectiles to a longer time period or just lower the wait or add this bit of code next to where the damage code is in the actual tool script and not inside the pellet because I don't think that you even cloned this script to go inside the pellets. |
|
|
| Report Abuse |
|
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
| |
|
|
| 26 Jun 2012 09:40 PM |
Is nothing happening? If the pellet is instanced into Workspace, did you clone the script to them?
> † KMXD † |
|
|
| Report Abuse |
|
|
WhiteRain
|
  |
| Joined: 24 Apr 2010 |
| Total Posts: 2723 |
|
| |
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
|
| 26 Jun 2012 09:46 PM |
| still not working at this point can I just model it to you... |
|
|
| Report Abuse |
|
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
|
| 26 Jun 2012 10:47 PM |
| Okay would this idea Work I copy the 1 damage script a bunch of time but each time At a script I put a Wait(x) b4 the script starts? |
|
|
| Report Abuse |
|
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
| |
|
mamaguy
|
  |
| Joined: 07 Oct 2010 |
| Total Posts: 7073 |
|
|
| 26 Jun 2012 11:03 PM |
Gonna fail but: script.Source = string.reverse
Joke ^ To really fix: Instance.new("ManualJointSurfaceInstance", workspace) |
|
|
| Report Abuse |
|
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
|
| 26 Jun 2012 11:04 PM |
| Stupid question but Where do I put dat in da script |
|
|
| Report Abuse |
|
|
mamaguy
|
  |
| Joined: 07 Oct 2010 |
| Total Posts: 7073 |
|
| |
|
dasfunny
|
  |
| Joined: 24 Jan 2011 |
| Total Posts: 911 |
|
|
| 26 Jun 2012 11:19 PM |
| now it doesn't even work at all |
|
|
| Report Abuse |
|
|