Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tattoo issue on purchase (charge twice) #456

Open
aunkrittin opened this issue Sep 18, 2024 · 1 comment
Open

Tattoo issue on purchase (charge twice) #456

aunkrittin opened this issue Sep 18, 2024 · 1 comment
Labels
needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one.

Comments

@aunkrittin
Copy link

After select a tattoo and confirm you will be charged for a cost on each confirm but after all if you click on save button it will charge again
P.S walkaround if don't need tattoo charged twice after confirm on each zone then click cancel.

@github-actions github-actions bot added the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Sep 18, 2024
@AndiyDev
Copy link

Hello here is a solution if you still need it

--> Add if not shopType == 'tattoo' then TriggerServerEvent("illenium-appearance:server:chargeCustomer", shopType) end

--> or

--> Replace OpenShop() with code below

function OpenShop(config, isPedMenu, shopType)
lib.callback("illenium-appearance:server:hasMoney", false, function(hasMoney, money)
if not hasMoney and not isPedMenu then
lib.notify({
title = "Cannot Enter Shop",
description = "Not enough cash. Need $" .. money,
type = "error",
position = Config.NotifyOptions.position
})
return
end

    client.startPlayerCustomization(function(appearance)
        if appearance then
            if not isPedMenu then
                if not shopType == 'tattoo' then
                    TriggerServerEvent("illenium-appearance:server:chargeCustomer", shopType)
                end
            end
            TriggerServerEvent("illenium-appearance:server:saveAppearance", appearance)
        else
            lib.notify({
                title = _L("cancelled.title"),
                description = _L("cancelled.description"),
                type = "inform",
                position = Config.NotifyOptions.position
            })
        end
        Framework.CachePed()
    end, config)
end, shopType)

end

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one.
Projects
None yet
Development

No branches or pull requests

2 participants