BL0X1
|
  |
| Joined: 27 Aug 2009 |
| Total Posts: 389 |
|
|
| 22 Jul 2011 11:52 PM |
| I'm making a game, where fires randomly appear at different spots, and a Gui's Text changes to tell you where the fire is. In my script I made it print in OutPut whatever was on fire, and change the text of one of my Guis. Both in build and play mode, the text only changes the first time, then it stays that way, but when you look in Properties, the Text has changed, but it doesn't change what you actually see. The Gui is Active, and it appears to be working fine, but the Text won't change on the actual Gui. Please help! |
|
|
| Report Abuse |
|
|
wsd906
|
  |
| Joined: 27 Jan 2009 |
| Total Posts: 9880 |
|
|
| 22 Jul 2011 11:53 PM |
Did you forget the part where the text deactivates or whatever you wanna call it?
|
|
|
| Report Abuse |
|
|
BL0X1
|
  |
| Joined: 27 Aug 2009 |
| Total Posts: 389 |
|
| |
|
wsd906
|
  |
| Joined: 27 Jan 2009 |
| Total Posts: 9880 |
|
|
| 22 Jul 2011 11:56 PM |
| Well it could be that your text is still showing after a certain time, make sure you have a script that takes the prevouis text off before you add your new text. |
|
|
| Report Abuse |
|
|
BL0X1
|
  |
| Joined: 27 Aug 2009 |
| Total Posts: 389 |
|
|
| 22 Jul 2011 11:58 PM |
How would I do that? I have a script in another game that is this simple: if script.Parent.Text == "Blah" then script.Parent.Text = "Blah Blah"
and that works fine. |
|
|
| Report Abuse |
|
|
wsd906
|
  |
| Joined: 27 Jan 2009 |
| Total Posts: 9880 |
|
| |
|
wsd906
|
  |
| Joined: 27 Jan 2009 |
| Total Posts: 9880 |
|
|
| 23 Jul 2011 12:00 AM |
Ignore my last question
I forgot you have
I honestly have no idea then, could you maybe print the script out for us? |
|
|
| Report Abuse |
|
|
BL0X1
|
  |
| Joined: 27 Aug 2009 |
| Total Posts: 389 |
|
| |
|
BL0X1
|
  |
| Joined: 27 Aug 2009 |
| Total Posts: 389 |
|
|
| 23 Jul 2011 12:03 AM |
while true do local ran = math.random(1, 4) wait(math.random(10, 30)) if ran == 1 then print("Bank is on Fire!") game.StarterGui.ScreenGui.Reporter.Text = "There is a fire at the bank!" game.Workspace.BankFire1.Fire.Enabled = true game.Workspace.BankFire2.Fire.Enabled = true game.Workspace.BankFire3.Fire.Enabled = true game.Workspace.BankFire4.Fire.Enabled = true elseif ran == 2 then print("Apartment is on fire!") game.StarterGui.ScreenGui.Reporter.Text = "The Aparment is on fire!!" game.Workspace.ApartmentFire1.Fire.Enabled = true game.Workspace.ApartmentFire2.Fire.Enabled = true game.Workspace.ApartmentFire3.Fire.Enabled = true game.Workspace.ApartmentFire4.Fire.Enabled = true game.Workspace.ApartmentFire5.Fire.Enabled = true game.Workspace.ApartmentFire6.Fire.Enabled = true game.Workspace.ApartmentFire7.Fire.Enabled = true elseif ran == 3 then print("Market is on fire!") game.StarterGui.ScreenGui.Reporter.Text = "Fire at the Market!!" game.Workspace.MarketFire1.Fire.Enabled = true game.Workspace.MarketFire2.Fire.Enabled = true game.Workspace.MarketFire3.Fire.Enabled = true game.Workspace.MarketFire4.Fire.Enabled = true elseif ran == 4 then print("The TownHall is on fire!!!") game.StarterGui.ScreenGui.Reporter.Text = "Oh no! The Town Hall is on fire!!" game.Workspace.TownHallFire1.Fire.Enabled = true game.Workspace.TownHallFire2.Fire.Enabled = true game.Workspace.TownHallFire3.Fire.Enabled = true game.Workspace.TownHallFire4.Fire.Enabled = true end end -------------------------------------------------------------------------------- OutPut says nothing besides that the script is running. |
|
|
| Report Abuse |
|
|
kenny126
|
  |
| Joined: 04 Sep 2008 |
| Total Posts: 1776 |
|
| |
|
wsd906
|
  |
| Joined: 27 Jan 2009 |
| Total Posts: 9880 |
|
|
| 23 Jul 2011 12:06 AM |
| My only guess would to be lines 6,11,13,21, Ect ( All Lines with elseif ran== and game.StarterGUI.ScreenGUI ect.) |
|
|
| Report Abuse |
|
|
kenny126
|
  |
| Joined: 04 Sep 2008 |
| Total Posts: 1776 |
|
|
| 23 Jul 2011 12:22 AM |
| Blox, you just need the GUI to refesh every 5-10 seconds. |
|
|
| Report Abuse |
|
|
kenny126
|
  |
| Joined: 04 Sep 2008 |
| Total Posts: 1776 |
|
|
| 23 Jul 2011 12:23 AM |
| And then problem is solved. |
|
|
| Report Abuse |
|
|
BL0X1
|
  |
| Joined: 27 Aug 2009 |
| Total Posts: 389 |
|
|
| 23 Jul 2011 07:20 AM |
So should I put a script in Workspace that says:
while true do wait(4) game.StarterGui.ScreenGui.Reporter.Active = false wait(.1) game.StarterGui.Reporter.Active = true end
? |
|
|
| Report Abuse |
|
|
kenny126
|
  |
| Joined: 04 Sep 2008 |
| Total Posts: 1776 |
|
| |
|