I'm just trying to work out string.reverse
, but it says attempted to index "string, a nil value"
This is what I have
local encryptThese = {} function basicEncryption() for i,v in pairs(game.Workspace:GetChildren()) do if v.Parent == game.workspace then print(v) table.insert(encryptThese, v) encryptThese.string.reverse() end end end basicEncryption()
string.reverse
is used like this:
string.reverse("test") --> tset
No, but you can set them like this.
local atable = {'Hello', 'from', 'hiimgoodpack!'} for i = 1, #atable do atable[i] = string.reverse(atable[i]) end
This will turn the table keys from Hello from hiimgoodpack! to olleH morf !kcapdoogmiih I hope this helps you in the future!