Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

bad argument #3 to 'Value' (string expected, got boolean)...?

Asked by
tber8 37
6 years ago

I do not understand what issue I had here, but I pretty much have values, one representing a player, which stands for a specific character. Currently I have this statement:

if NumHelp.Value == 1 then
        script.Help.CharHelp2.C1.Player.Value = plyr.Value

This means in the randomization process, once a players number is randomized, their "plyr" value containing their name also becomes the "C" value, or character value, so pretty much one value is given the value, aka a player's name, from another value. For some reason I get the error in the title. I have no idea what happened, as both values happen to be strings. Please help, and feel free to ask questions.

0
Help?????? We dont know what NumHelp is, plyr is, or anything! hiimgoodpack 2009 — 6y
0
"NumHelp" is just what is randomized to mean what character type someone is. "Plyr" is a variable for a value containing the player's name, the one that will not make the other value the same. tber8 37 — 6y
0
is script.Help.CharHelp2.C1.Player.Value a StringValue and plyr.Value is a BoolValue? creeperhunter76 554 — 6y
0
No they are both strings... tber8 37 — 6y
View all comments (5 more)
0
Since the error says "bad argument", it has something to do with a function call. You haven't shown us any code with those. GoldenPhysics 474 — 6y
0
give context man. MrDefaultMan 113 — 6y
0
more context* so we know exactly what CharHelp2 and etc. are. MrDefaultMan 113 — 6y
0
Need more context. I can't answer your question if you give me only 2 lines of code. T0XN 276 — 6y
0
Ok I'll create new, detailed question tber8 37 — 6y

Answer this question