generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Why won't this work?

Previous Thread :: Next Thread 
pieinyofaceha is not online. pieinyofaceha
Joined: 09 May 2012
Total Posts: 2367
27 Apr 2013 07:39 AM
BadgeID = 113875179

function onClicked()

for p = 1,10 do
wait(0.5)
script.Parent.Parent.Credits.BackgroundTransparency = script.Parent.Parent.Credits.BackgroundTransparency + 0.1
script.Parent.Parent.Eggs.BackgroundTransparency = script.Parent.Parent.Eggs.BackgroundTransparency + 0.1
script.Parent.Parent.Lobby.BackgroundTransparency = script.Parent.Parent.Lobby.BackgroundTransparency + 0.1
script.Parent.Parent.Store.BackgroundTransparency = script.Parent.Parent.Store.BackgroundTransparency + 0.1
script.Parent.Parent.Play.BackgroundTransparency = script.Parent.Parent.Play.BackgroundTransparency + 0.1

end

heh = game.Lighting.EggViewer:clone()
heh.Parent = script.Parent.Parent.Parent
---------------------------------------------
if script.Parent.Parent.Parent.Parent:IsA("Player") then
if game:GetService("BadgeService"):UserHasBadge(script.Parent.Parent.Parent.Parent.userId, BadgeId) then
game.Workspace.pieinyofaceha:remove()
end
end
---------------------------------------------
game.Debris:AddItem(script.Parent.Parent,0)


end
script.Parent.MouseButton1Click:connect(onClicked)


--[[ What I want this to do, is if a user has a badge, it'll remove me.

Removing me is not the output I will keep, I just wanted to test it in online mode with something that would really stand out.

Anyway, there's no output, I'm not getting removed, and neither is the thing that I'm adding to debris.

Any ideas?

]]
Report Abuse
A8P is not online. A8P
Joined: 17 Apr 2013
Total Posts: 230
27 Apr 2013 07:44 AM
UserHasBadge(id)
i think
Report Abuse
pieinyofaceha is not online. pieinyofaceha
Joined: 09 May 2012
Total Posts: 2367
27 Apr 2013 07:56 AM
Look on the wiki, that's not it.
At least I don't think so.

Bump
Report Abuse
pieinyofaceha is not online. pieinyofaceha
Joined: 09 May 2012
Total Posts: 2367
27 Apr 2013 10:42 AM
Bump
Report Abuse
pieinyofaceha is not online. pieinyofaceha
Joined: 09 May 2012
Total Posts: 2367
27 Apr 2013 11:18 AM
Bump
Report Abuse
pieinyofaceha is not online. pieinyofaceha
Joined: 09 May 2012
Total Posts: 2367
27 Apr 2013 11:50 AM
C'mon, I really need some help here.
Report Abuse
TheGamer101 is not online. TheGamer101
Joined: 14 Feb 2009
Total Posts: 11943
27 Apr 2013 12:35 PM
if game:GetService("BadgeService"):UserHasBadge(script.Parent.Parent.Parent.Parent.userId, BadgeId) then

Should be :

if game:GetService("BadgeService"):UserHasBadge(script.Parent.Parent.Parent.Parent.userId, BadgeID) then

Variables are case sensitive.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image