I made I post earlier today asking how to make a List in a script. After some help and some yt videos I now know that I can use a module script or a dictionary
now I got the next problem, this is an example of the dictionary I used
local Rarities = {
["Giant Dog"] = "SECRET"
["Giant Cat"] = "SECRET"
}
now let's say I have a pet inventory with 3 pets a "Giant Dog" a "Giant Cat" and a normal "Dog" dor example I want to make a script that checks if the name of the pet is "Giant Dog" or "Giant Cat" then it shows a SECRET tag on it here an example script of what I tried:
Local name = PetName -- so the in name is the name of the pet that I need to find in the modulescript/dictionary
if Rarities.FindFirstChild(rName) ~= nil then
PetRarity.Text = Rarities.FindFirstChild(name)
well ofcourse this didn't work
So I want to check if the name of the pet is in the Dictionary/module script but idk how

1 comment
Thx A lot it worked