Blues714
|
  |
| Joined: 23 Dec 2008 |
| Total Posts: 6507 |
|
|
| 30 Aug 2014 01:22 AM |
how would i return the function?
and if the image is invisible and/or the transparency is 1, it'll run the script?
What I've came up with, that doesn't really work.
if key == "m" then if open then print'player closed menu' plr.CameraMode = Enum.CameraMode.LockFirstPerson camera.CameraType = "Custom" if script.Parent.buttons.player.ImageTransparency<0 then return end |
|
|
| Report Abuse |
|
|
|
| 30 Aug 2014 01:37 AM |
I read ur post 5 times, and..... I still don't know......
if key == "m" then if open then print'player closed menu' plr.CameraMode = Enum.CameraMode.LockFirstPerson camera.CameraType = "Custom" if script.Parent.buttons.player.ImageTransparency<0 then
SomeRandomScript.Disabled = false -- SRS, undefined, so define it..
return -- yeah this is superfluous....
end -- transparent? end -- open? end -- "M"?
--GL
|
|
|
| Report Abuse |
|
|
|
| 30 Aug 2014 01:39 AM |
*Umm .... sorry didn't notice that this line made no sense (Do u have Output > Open?
if script.Parent.buttons.player.ImageTransparency*........>.....0 then |
|
|
| Report Abuse |
|
|
Blues714
|
  |
| Joined: 23 Dec 2008 |
| Total Posts: 6507 |
|
|
| 30 Aug 2014 01:40 AM |
the one I gave is just a part of a script.
if key == "m" then if open then if script.Parent.buttons.player.ImageTransparency==0 then return end elseif script.Parent.buttons.player.ImageTransparency==1 then print'player closed menu' plr.CameraMode = Enum.CameraMode.LockFirstPerson camera.CameraType = "Custom" script.Parent.buttons.player:TweenPosition(UDim2.new(0, 110, 0, -500), "Out", "Sine", nil, true) wait(0.2) script.Parent.buttons.clan:TweenPosition(UDim2.new(0, 110, 0, -500), "Out", "Sine", nil, true) wait(0.2) script.Parent.buttons.messages:TweenPosition(UDim2.new(0, 110, 0, -500), "Out", "Sine", nil, true) wait(0.2) script.Parent.buttons.location:TweenPosition(UDim2.new(0, 110, 0, -500), "Out", "Sine", nil, true) open = false end end end end)
here's half of it. the other part ain't a problem. |
|
|
| Report Abuse |
|
|
|
| 30 Aug 2014 02:06 AM |
Too tired to resd it, BUT, if u put a print statement at every other line, AND READ the Output, I GARUTEEE u will find the logic error..... Go on from my start....:
print ("Key", key == "m") if key == "m" then
print ("Open:", open) if open then
print...............and so on... GL...
if script.Parent.buttons.player.ImageTransparency==0 then return end elseif script.Parent.buttons.player.ImageTransparency==1 then print'player closed menu' plr.CameraMode = Enum.CameraMode.LockFirstPerson camera.CameraType = "Custom" script.Parent.buttons.player:TweenPosition(UDim2.new(0, 110, 0, -500), "Out", "Sine", nil, true) wait(0.2) script.Parent.buttons.clan:TweenPosition(UDim2.new(0, 110, 0, -500), "Out", "Sine", nil, true) wait(0.2) script.Parent.buttons.messages:TweenPosition(UDim2.new(0, 110, 0, -500), "Out", "Sine", nil, true) wait(0.2) script.Parent.buttons.location:TweenPosition(UDim2.new(0, 110, 0, -500), "Out", "Sine", nil, true) open = false end end end end)
|
|
|
| Report Abuse |
|
|
Blues714
|
  |
| Joined: 23 Dec 2008 |
| Total Posts: 6507 |
|
|
| 30 Aug 2014 02:09 AM |
@BJ
the error is around
if script.Parent.buttons.player.ImageTransparency==0 then return end elseif script.Parent.buttons.player.ImageTransparency==1 then
|
|
|
| Report Abuse |
|
|