dragon829
|
  |
| Joined: 12 Aug 2008 |
| Total Posts: 741 |
|
|
| 03 Nov 2011 07:02 PM |
I was wondering what way is better as you can see it shows a message on the screen to the person who hits it im making a Badge hunt type game but using hints and stuff like that because im NBC Both of these are made by BunnyBoy26 but for some odd reason both work and its only supposed to show up once when they hit it for first time like a badge and after that, you cant get it anymore forever i was wondering what one is better and was wondering if you can fix it by any chance? please help?
-------------------- name = "NAME HERE"
script.Parent.Touched:connect(function(hit) local p = game.Players:GetPlayerFromCharacter(hit.Parent) if p then local g = p:FindFirstChild("PlayerGui") if g then p:WaitForDataReady() local f if not pcall(function() f = p:LoadString(name) end) then local h = Instance.new("Message",g) h.Text = "You have found the first Achievement/Badge" game:GetService("Debris"):AddItem(h,2) p:SaveString(name,"F:"..name) end end end end) ----------------------------------- name = "NAME HERE"
e = true script.Parent.Touched:connect(function(hit) if e then e = false local p = game.Players:GetPlayerFromCharacter(hit.Parent) if p then local g = p:FindFirstChild("PlayerGui") if g then p:WaitForDataReady() local b = pcall(function() f = p:LoadString(name) end) if not b then h = Instance.new("Message",g) h.Text = "You have found the first Achievement/Badge" wait(2) h:remove() p:SaveString(name,name) end end end e = true end end) |
|
|
| Report Abuse |
|
|
DXPower
|
  |
| Joined: 21 Oct 2008 |
| Total Posts: 2866 |
|
|
| 03 Nov 2011 07:05 PM |
| Well if they both work then choose one to use. T_T |
|
|
| Report Abuse |
|
|
dragon829
|
  |
| Joined: 12 Aug 2008 |
| Total Posts: 741 |
|
|
| 03 Nov 2011 07:06 PM |
| Neither work i was asking if someone can fix either one and tell me what one would be easier |
|
|
| Report Abuse |
|
|
|
| 03 Nov 2011 07:14 PM |
| yeah by "both work", he meant neither. I'll try pcalling it. |
|
|
| Report Abuse |
|
|
|
| 03 Nov 2011 07:23 PM |
name = "NAME HERE"
script.Parent.Touched:connect(function(hit) local _,e = pcall(function() local p = game.Players:GetPlayerFromCharacter(hit.Parent) if p then local g = p:FindFirstChild("PlayerGui") if g then p:WaitForDataReady() local f if not pcall(function() f = p:LoadString(name) end) then local h = Instance.new("Message",g) h.Text = "You have found the first Achievement/Badge" game:GetService("Debris"):AddItem(h,2) p:SaveString(name,"F:"..name) end end end end) if not e then Instance.new("Hint",workspace).Text = e end end)
|
|
|
| Report Abuse |
|
|
dragon829
|
  |
| Joined: 12 Aug 2008 |
| Total Posts: 741 |
|
|
| 03 Nov 2011 08:26 PM |
Doesn't work?
Bump, please help
Regards ~dragon829 |
|
|
| Report Abuse |
|
|
dragon829
|
  |
| Joined: 12 Aug 2008 |
| Total Posts: 741 |
|
|
| 03 Nov 2011 09:14 PM |
| Bump anyone please????????????? |
|
|
| Report Abuse |
|
|
dragon829
|
  |
| Joined: 12 Aug 2008 |
| Total Posts: 741 |
|
| |
|
max4971
|
  |
| Joined: 12 Apr 2009 |
| Total Posts: 24 |
|
|
| 03 Nov 2011 10:15 PM |
| Hello im max i looked at videos for scripting help none of them help me at all so maybe you can help me a little thanks for reading this. |
|
|
| Report Abuse |
|
|
dragon829
|
  |
| Joined: 12 Aug 2008 |
| Total Posts: 741 |
|
|
| 03 Nov 2011 10:19 PM |
| Please create your own thread and bump????? |
|
|
| Report Abuse |
|
|
dragon829
|
  |
| Joined: 12 Aug 2008 |
| Total Posts: 741 |
|
|
| 04 Nov 2011 06:13 AM |
| bump can someone please help? |
|
|
| Report Abuse |
|
|
|
| 04 Nov 2011 12:26 PM |
| Dude, I said we can do this a different way. Get some of the badge checklist done first. |
|
|
| Report Abuse |
|
|
dragon829
|
  |
| Joined: 12 Aug 2008 |
| Total Posts: 741 |
|
| |
|