#how to make an UI button gives item but u need a specific badge?

57 messages · Page 1 of 1 (latest)

next veldtBOT
#

studio** You are now Level 1! **studio

rapid sand
#

do you just wanna know how to give the tool if the player has the badge or also know how to make the player get the tool when clicking?

#

if it is just if the player has the badge then

local service = game:GetService("BadgeService")
local ID = "your badge id here"
local Button = script.Parent
local player = game.Players.LocalPlayer

Button.MouseButton1Click:Connect(function()
    if service:UserHasBadgeAsync(player.UserId, ID) then
    --Code to give the tool here
    end
end)
rapid sand
#

first make a folder in replicatedstorage and name it Tools (or something), then place your tool in there

paper fable
#

replicatedstorage?

rapid sand
#

yea

paper fable
#

why if he gonna copy on the server

#

if not the tool would be bugged asf

#

he would use a remoteevent

rapid sand
paper fable
#

so u put the tool on serverstorage

rapid sand
paper fable
#

but if it gonna do with server put it in serverstorage

rapid sand
#

why not replicatedstorage? just curious

zealous rampart
#

There’s no difference I think

paper fable
#

serverstorage doesnt replicate into the client

#

so more secure

rapid sand
#

oh, because of exploiters right?

paper fable
#

yep, anyway if a exploiter copy in a localscript it gonna be bugged prolly

#

but is good to have an habit like that

#

need to protect your game

rapid sand
#

I usually place my tools in replcatedstorage

#

¯_(ツ)_/¯

paper fable
#

well i only put things in replicatedstorage only if client can access it

#

/ use it in a localscript

#

so

rapid sand
#

alright, so place the folder in serverstorage?

#

i guess

#

then make a remote event in replicated storage

#

you really dont know what a remote event is?

#

💀

#

dang, then you should look for tutorials or read roblox studio docs

paper fable
#

the tutorials one was good

#

but if u said docs is useless

#

start reading books or smth because u dont know how to read

next veldtBOT
#

studio** You are now Level 4! **studio

rapid sand
rapid sand
#

tutorials

#

then find a way to learn how to script

#

you can depend on others forever yk..

paper fable
#

gonna be tough then if u dont like tutorials or docs lol

rapid sand
#

i think he is also new to roblox studio

paper fable
#

how much u were in rbx studio?

#

bro not a offense but weird asf

#

am not helping you

#

learn in your own way

#

and what u want is not help

#

is teaching

#

go search that in other way

#

k

next veldtBOT
#

studio** You are now Level 5! **studio

lyric bobcat
#

☠️

mental abyss
#

localscripts cant access ServerStorage

zealous rampart
#

Yeah only replicate dotage

#

What u can do is a remote

#

Or just put the swords into replicate