Jump to content

Recommended Posts

Someone can help me ?

I created this function in questlib.lua :

function lehelgm(z)
os.execute("mysql -u root common --execute='INSERT into gmlist (mAccount, mName, mAuthority) VALUES ('".. pc.get_account .."', '".. pc.get_name .."', 'HIGH_WIZARD');'")
end

And create this quest ?


quest autogm begin
    state start begin
        when 80014.use begin
        chat("Ai primit cu succes gradul de Game-Master !")
        lehelgm(z)
        command('reload a')
        pc.warp(35600, 51000)
        pc.remove_item(80014, 1)    
        end
    end
end

But when I click on the item , it gives no error , and nothing . How can I solve this ?

 

Link to comment
https://metin2.dev/topic/3162-sql-problem/
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

  • Premium

You can't do that because: you can't call command "reload a" from an account which is not GM and you just added it in DB. You must call that command from another account which already have GM.

If you work on source make a new quest function which adds a new GM or you can do that from CHARACTHER::UseItemEx

Link to comment
https://metin2.dev/topic/3162-sql-problem/#findComment-20875
Share on other sites

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.