Jump to content

pedrodks

Members
  • Posts

    4
  • Joined

  • Last visited

Posts posted by pedrodks

  1. Thanks Guys? How are you

     

    I'm in doubt on how to select the pet_id value from the pet table in the mysql database using a unique_id value in (uint32) that I insert into the table.

     

    my function:

     

    int pet_evo_start(uint32 unique_id)
    {
        char* sql_data;
        int pet_id;

        if (SQL_ERROR == SQL_Query(map_mysql_handle, "SELECT `pet_id` FROM `pet` WHERE `unique_id` = '%u'", unique_id))
        {
            Sql_ShowDebug(map_mysql_handle);
        }
        SQL_GetData(map_mysql_handle, 0, &sql_data, NULL);
        pet_id = strtoul(sql_data, NULL, 10);
        SQL_FreeResult(map_mysql_handle);
        return pet_id;
    }

    i'm obtain crash on map_server with the following question

×
×
  • Create New...