EuedeAdodooedoe Posted April 18, 2017 Share Posted April 18, 2017 (edited) To add tag to a certain object or instances of an object rather, you would need to put in: inst:AddTag("[tag name]") Either within a function that you're using or at the fn, to define whether at the start the thing has this tag. But what if I wanted to remove the tag within a function? So, for the tag to be there by default, but so that certain actions carried from certain functions can remove a tag while the game is running? inst:RemoveTag("[tag name]") The above code does nothing. No errors, but nothing changes either. Any ideas how to actually remove a tag the way I've described it? EDIT: Whoops, wrong section, this was supposed to be in Mods and Tools :~ Edited April 18, 2017 by EuedeAdodooedoe Link to comment Share on other sites More sharing options...
Lumina Posted April 18, 2017 Share Posted April 18, 2017 Maybe the function works only if the tag isn't something that the prefab should always have ? For example, Wx78 has an "overcharge" tag that can be added and removed, but he doesn't have the tag by default, so maybe it's why the tag can be removed. Link to comment Share on other sites More sharing options...
EuedeAdodooedoe Posted April 18, 2017 Author Share Posted April 18, 2017 15 minutes ago, Lumina said: Maybe the function works only if the tag isn't something that the prefab should always have ? For example, Wx78 has an "overcharge" tag that can be added and removed, but he doesn't have the tag by default, so maybe it's why the tag can be removed. Removing "inst:AddTag("lighter")" at fn function in lighter.lua, even though I have the tag with owner character checks that are supposed to add tags back in on equip and unequip, will disable the lighter from being possible to light something on fire even as Willow Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now