|
| 10 Aug 2011 11:41 AM |
This works in Play Solo but not in an actual game server:
How come?
time = 15
while true do a = game.Players:GetChildren() for i = 1, #a do b = game.Lighting.TextAdder:clone() b.Parent = a[i].PlayerGui repeat time = time - 1 wait(1) until b.EnterClicked.Value == true or time == 0 time = 15 b:remove() print("Changed") end end
What it is supposed to do: One player will have the GUI. The GUI should stay on there screen until A. The player clicks enter or B. 15 seconds passes. At that point, the GUI goes to the next players screen and so on. |
|
|
| Report Abuse |
|
|
sdfgw
|
  |
 |
| Joined: 08 Jan 2009 |
| Total Posts: 41681 |
|
|
| 10 Aug 2011 11:42 AM |
"Okay, well I have a script for a good message, but I have no idea how to get it to activate when a player hits the brick."
If you have a bit of code, it's possible that just doing this:
function touch() [code] end script.Parent.Touched:connect(touch)
will turn it into a touch script. See if that works. |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 11:43 AM |
| Thanks. I'll let you know what I get. |
|
|
| Report Abuse |
|
|
sdfgw
|
  |
 |
| Joined: 08 Jan 2009 |
| Total Posts: 41681 |
|
|
| 10 Aug 2011 11:45 AM |
Impressively late posted there. Okay mmm
@BANDICOOT: Okay, your script is more complex than I thought. I won't be able to help because it's part of some bigger system and it's not really a script fix so much as an edit.
@obedient: Try testing it by hitting the little arrow shaped play button in studio. |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 11:50 AM |
| Yeah I went to try it and it made no difference. I think the script i have is too complicated for me... -_- That's why I was wondering if you would be able to tell me what to add to it or help me come up with a new less complicated one. Since you already said you weren't here to make scripts, I guess I'll have to look for help somewhere else... :( |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 11:59 AM |
| It doesn't run the script. |
|
|
| Report Abuse |
|
|
sdfgw
|
  |
 |
| Joined: 08 Jan 2009 |
| Total Posts: 41681 |
|
| |
|
|
| 10 Aug 2011 12:04 PM |
| No error.. I set it to print the time, and it does that in play solo, but when I press play, it just says its loaded or whatever. It might be freezing.. I will have a better internet connection tonight so I'll try it again then and see if it works when I click play. |
|
|
| Report Abuse |
|
|
sdfgw
|
  |
 |
| Joined: 08 Jan 2009 |
| Total Posts: 41681 |
|
|
| 10 Aug 2011 12:08 PM |
| Ahhhhh, I see what's happening. That's actually kinda funny. When there are no players in the server, the while loop just goes round in a circle ad infinitum and probably crashes. Just stick a wait() at the beginning of the loop and see if it works then. |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 12:28 PM |
@BAND
Im not really a good scripter but... you put the gui starting in Hello! right? ok and you put it in StarterGui file too right? ok. if it doesnt wrk, (its 95% about not going to) send me bak the output:
[GuiButton Name Here. Take away the []'s] = game.StarterGui.TextButton wait(3) [GuiButton Name Here.].Text = new.Text"What's Your Name?" -- change this to what you want. wait(3) game.StarterGui.remove.[GuiButton Name Here] end
|
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 12:48 PM |
| That wasn't really what the problem was, but don't worry. I'm getting a completely new script right now. I've got some help already. Thanks anyway. :) |
|
|
| Report Abuse |
|
|
sdfgw
|
  |
 |
| Joined: 08 Jan 2009 |
| Total Posts: 41681 |
|
|
| 10 Aug 2011 02:44 PM |
| Okai then. Any other questions? |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 02:50 PM |
for i = 1, 2.3, 0.1 do door.CFrame = CFrame.new(door.Position+Vector3.new(0,i,0)) wait(0.1) end
If I want a brick that is 17 studs high to move at 0.2 studs every 0.1 seconds, then what would the numbers be? I want the door to move up 17 studs high. |
|
|
| Report Abuse |
|
|
sdfgw
|
  |
 |
| Joined: 08 Jan 2009 |
| Total Posts: 41681 |
|
|
| 10 Aug 2011 02:53 PM |
From 0 to 17 in increments of 0.2? I guess you could do
for i = 0.2, 17, 0.2 do
and add 0.2 to the height each time. You wouldn't even need to use i. In fact, you could do
for i = 1, 65 do
and add 0.2 each time, just to make the loop easier to read. |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 03:05 PM |
wn't werk
print("fix dis plz") |
|
|
| Report Abuse |
|
|
sdfgw
|
  |
 |
| Joined: 08 Jan 2009 |
| Total Posts: 41681 |
|
|
| 10 Aug 2011 03:15 PM |
@Mario:
This script appears fully functional - I can't seem to identify any particular errors, so I assume there's a bug that causes it to do something other than you wanted. It looks to me that the script prints the string "fix dis plz". Was that what you intended to happen? |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 03:20 PM |
UDim2 So none of my click go away scripts wrk. will this one wrk? its an auto go-away (i made it up on just this post)
StartingButton = game.StarterGui.TextButton wait(3) StartingButton.Position = UDim2.new(0, 200 0, 320) (--and so on...) game.StarterGui.remove:StartingButton
I know this is not going to work... is anything wrong with it? |
|
|
| Report Abuse |
|
|
DtimX
|
  |
| Joined: 06 Feb 2010 |
| Total Posts: 447 |
|
|
| 10 Aug 2011 03:21 PM |
I got a Rain script off the wiki, but all it does is slow my place down so much that you cant do anything. (build mode) in online server it wont even load, it says you have lost connection.
while true do wait(0.1) droplet = game.Workspace.Drop:clone() droplet.Parent = game.Workspace droplet.Anchored = false droplet.Position = Vector3.new(math.random(-512,512),100,math.random(-512,512)) end
Whats wrong? |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 03:22 PM |
| Lawl, unexpected response is unexpected |
|
|
| Report Abuse |
|
|
huner2
|
  |
| Joined: 27 Apr 2008 |
| Total Posts: 1681 |
|
|
| 10 Aug 2011 03:28 PM |
The hint nevers goes away
function brick() a = Instance.new("Hint",Workspace) a.Text = "Hello!" wait(3) a:Remove() end script.Parent.Touched:connect(brick) |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 03:30 PM |
I got here first :D
d = true
function brick() if not d then return end d = false a = Instance.new("Hint",Workspace) a.Text = "Hello!" wait(3) a:Remove() d = true end script.Parent.Touched:connect(brick) |
|
|
| Report Abuse |
|
|
huner2
|
  |
| Joined: 27 Apr 2008 |
| Total Posts: 1681 |
|
|
| 10 Aug 2011 03:35 PM |
| How do I have it say more than one message? |
|
|
| Report Abuse |
|
|
huner2
|
  |
| Joined: 27 Apr 2008 |
| Total Posts: 1681 |
|
|
| 10 Aug 2011 03:38 PM |
| Also thanks it goes away now |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 04:05 PM |
d = true
function brick() if not d then return end d = false a = Instance.new("Hint",Workspace) a.Text = "Hello!" wait(3) a.Text = "Bye!" wait(3) a:Remove() d = true end script.Parent.Touched:connect(brick) |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2011 04:37 PM |
Noone answered my post... @ creator of topic Srry if I'm being rude or spamming ur topic but I need a differ script. This time I want the GUI to automaticly go away after 3 seconds. Can you tell me what wrong on the script? (it's the last post I did.) |
|
|
| Report Abuse |
|
|