Here is a snippet from my code:
function convert(suit,value) -- converts the suits and values to be drawn onto card
if value=="Jack" then
local v = {symbol=***,abbrev="J"}
elseif value=="Queen" then
local v = {symobol=***,abbrev="Q"}
elseif value=="King" then
local v = {symbol=***,abbrev="K"}
elseif value=="Ace" then
local v = {symbol=suit,abbrev="A"}
else
local v = {symbol=suit,abbrev=value}
end
if suit=="Diamonds" then
local v = ***
elseif suit=="Hearts" then
local v = ***
elseif suit=="Spades" then
local v = ***
elseif suit=="Clubs" then
local s = ***
end
return {s=s,v=v}
end
And this is in my setup function:
a=convert("Diamonds","Jack")
print(a.s)
This prints nil, why is that and how can I fix it?
Also, emojis can’t be posted, so I just replaced them with asterisks, replace them with emojis when reviewing.