Page 1 of 1

GM Powers don't work after recent update?

Posted: Sun Dec 29, 2013 2:12 pm
by namine207
Hello! I just updated my server files to the most recent changes, and everything looks and works great- that is, except GM commands. My character is set in the server files to be a level 5 gm, but every time I enter any gm command, including @togglegm, nothing happens. Is there anything about this recent update that could stop gm things from working?

Thanks! :D

Re: GM Powers don't work after recent update?

Posted: Sun Dec 29, 2013 3:25 pm
by atom0s
Are you sure that you have adjusted your characters GM level in the database properly to reflect that?
The new command update works just like the old system did in terms of power to use a command.

Code: Select all

    // Ensure this user can use this command..
    if (permission > PChar->m_GMlevel)
    {
        ShowWarning("cmdhandler::call: Character %s attempting to use higher permission command %s\n", PChar->name.c_str(), cmdname.c_str());

        // Delete the cmdprops table..
        lua_pushnil(m_LState);
        lua_setglobal(m_LState, "cmdprops");

        return -1;
    }
If the permission required is higher then your GM level it wont allow the command to fire.
Does your server console report anything? Any errors or warnings displayed when you try to use a command?

Re: GM Powers don't work after recent update?

Posted: Sun Dec 29, 2013 3:42 pm
by kjLotus
atom0s wrote:If the permission required is higher then your GM level it wont allow the command to fire.
Does your server console report anything? Any errors or warnings displayed when you try to use a command?
i had no errors or warnings when i tried (they didn't work for me either), but it was 4 AM and i didn't really feel like looking up why

Re: GM Powers don't work after recent update?

Posted: Sun Dec 29, 2013 3:44 pm
by namine207
atom0s wrote:Are you sure that you have adjusted your characters GM level in the database properly to reflect that?
The new command update works just like the old system did in terms of power to use a command.

Code: Select all

    // Ensure this user can use this command..
    if (permission > PChar->m_GMlevel)
    {
        ShowWarning("cmdhandler::call: Character %s attempting to use higher permission command %s\n", PChar->name.c_str(), cmdname.c_str());

        // Delete the cmdprops table..
        lua_pushnil(m_LState);
        lua_setglobal(m_LState, "cmdprops");

        return -1;
    }
If the permission required is higher then your GM level it wont allow the command to fire.
Does your server console report anything? Any errors or warnings displayed when you try to use a command?
Not that I know of, but I'll check real quick to see. One thing that is new is that when it's loading the map server, it says:

Error - cannot open conf/commands.conf: No such file or directory

Loading the game now to see if it says anything when I try to use a command. I'll update this post as soon as I know!

UPDATE: Yeah, it doesn't seem to say anything different. One or two client cannot receive packet or key is invalid, but I've always had those, and one [Debug] CLIENT (username) PERFORMING ACTION 14. Other than that, everything's 100% normal.

Re: GM Powers don't work after recent update?

Posted: Sun Dec 29, 2013 3:52 pm
by n00bgames
I'm running on the latest revision, though I don't think I ever changed my conf directory and commands are working fine. I think I excluded my conf directory from the update out of laziness.

Re: GM Powers don't work after recent update?

Posted: Sun Dec 29, 2013 3:53 pm
by demolish
You need to rebuild DSGameServer when there are changes to the src/map/ .cpp or .h files.

Re: GM Powers don't work after recent update?

Posted: Sun Dec 29, 2013 4:24 pm
by namine207
Xx_DeMoLiSH wrote:You need to rebuild DSGameServer when there are changes to the src/map/ .cpp or .h files.
Oh, dang. I'm stupid. XD Building now. Thank you very much! :D

Re: GM Powers don't work after recent update?

Posted: Sun Dec 29, 2013 7:20 pm
by atom0s
Anything that changes a .h/.cpp file requires you to rebuild the server.