I’ve been searching around and I’m surprised that no one has suggested this one yet.
How about read-only attributes that can be written to in Studio, but not written to in-game? I have a playerdata system that uses attributes and I want the ability to set some attributes to read-only so exploits will have a harder time setting said values.
That’s essentially pointless. Normal exploiters won’t bother attempting to create exploits because they rely on the professionals for the scripts, who will be able to easily bypass it. They will find a way regardless of if it’s read only or writable.
One possible use case would possibly be for a better code debugging process? If for whatever reason a script is attempting to mutate an attribute that isn’t supposed to be, then you could easily track where it happened.
Someone mentioned something like this earlier, but let me reiterate and suggest that a custom object be added that’s essentially like a folder with no behavior and almost no properties on it’s own, but supports the use of the dot operator to index attributes. Please don’t make us use player.Data:GetAttribute(“coins”), or people including myself will just end up using custom wrappers anyway.
Are you looking for the name of the attribute, or the instance that has attributes? We’re looking into how we might make it easier to do searches/filtering.
I was in this instance wanting to scan through the entire workspace for instances that have a attribute of a certain name, and then proceed to clone something into said instance, in this case decals for parts
This doesn’t sound like something attributes would be used for, instead we offer CollectionService which allows you to tag and filter instances. You could use this in conjunction with an attribute if you want to associate a specific value with the instance.
If that doesn’t suit your needs could you explain a little bit more about your use-case and why filtering by attributes specifically would be helpful?
I’m litterally shaking and crying rn I didn’t even know this feature was coming and I just recently found out omg i’m litterly gonna un-exist out of pure excitement, I don’t even fully know what this does yet but it looks very robust and helpful in every single way possible.
This is great, maybe adding :CreateAttribute will be a cool option, why will this be? Well for plugins this will be awsome as they can create their own object and attributes and you could modify them there. Lovely to see this also implemented!
Maybe this can be a part of the :SetAttribute() Function, if they didn’t add it already ofcourse. lets say that you want to set an attribute that doesn’t exist (example: Instance:SetAttribute(“AttributeName”, “AttributeValue”) I’m not 100% if this works I havn’t tried it but I think theres a way to insert attributes (I’ve seen someone use some sort of json code thingy to put tables in) I just think this would be a reasonable way to add an attribute, the only problem is selecting it’s value (I know it can be easily pre-determined on what the value would be like vector3.new(3,2,1) would obviously be a vector value) They might actually have this already in but again I havn’t fully tested the feature out so I guess I’ll try now lol.
Great addition! Is there any reason why cloned parts don’t keep attributes? (I’ve noticed they do through cloning in the command line or duplicating or copy/paste). Would be great if this was also added. Great addition to the development tools though, look forward to making use of them!