Why isn't this working?

[lua]if Player:GetLevel() < 5 then
JobCash = math.Round(JobCash * 1.25);
WarningMsg = “‘You have earned $’ … JobCash … ’ ’ … JobText”
end

if (string.find(Player:Nick(), "[M.G]") != nil) then
	JobCash = math.Round(JobCash * 1.10);
	WarningMsg = 'You have earned $' .. JobCash .. ' ' .. JobText
	else
	WarningMsg = 'You have earned $' .. JobCash .. ' ' .. JobText ' (Put [M.G] in your name for increase pay)'
end

[/lua]

How can I put the WarningMsg in quotes because it isn’t working right.

[lua]
if Player:GetLevel() < 5 then
JobCash = math.Round(JobCash * 1.25);
WarningMsg = (“You have earned $” … JobCash … " " … JobText)
end

if (string.find(Player:Nick(), "[M.G]") != nil) then
    JobCash = math.Round(JobCash * 1.10);
    WarningMsg = ("You have earned $" .. JobCash .. " " .. JobText)
    else
    WarningMsg = ("You have earned $" .. JobCash .. " " .. JobText " (Put [M.G] in your name for increase pay)")
end

[/lua]

Try this, I’ve never used ’ for strings.

you’re missing a … in the second one



if Player:GetLevel() < 5 then
        JobCash = math.Round(JobCash * 1.25);
        WarningMsg = "'You have earned $' .. JobCash .. ' ' .. JobText"
    end
     
    if (string.find(Player:Nick(), "[M.G]") != nil) then
        JobCash = math.Round(JobCash * 1.10);
        WarningMsg = 'You have earned $' .. JobCash .. ' ' .. JobText
        else
        WarningMsg = 'You have earned $' .. JobCash .. ' ' .. JobText .. ' (Put [M.G] in your name for increase pay)'
    end


should work