moin und zwar habe ich dieses problem das er die db wohl nicht richtig liest siehe
Bitte melden Sie sich an, um diesen Link zu sehen.
Bitte melden Sie sich an, um diesen Link zu sehen.
der geladene player ist eigentlich ein ninja und bei neuerstellung eines chars sagt er mir falscher charname was ja nicht stimmen kann fummel da jetzt schon 2-3 tage dran rum und ich bekomme es nicht hin villt mag ja wer helfen
mysql
Bitte melden Sie sich an, um diesen Link zu sehen.
Code
- ClientManagerLogin
- extern std::string g_stLocale;
- snprintf(szQuery, sizeof(szQuery),
- "SELECT id,"
- "name,"
- "job,"
- "level,"
- "playtime,"
- "st,"
- "ht,"
- "dx,"
- "iq,"
- "part_main,"
- "part_hair,"
- "part_acce,"
- "x,"
- "y,"
- "skill_group,"
- "change_name,"
- #ifdef ENABLE_PLAYER_PIN_SYSTEM
- "pin "
- #endif
- "FROM player%s WHERE account_id=%u",GetTablePostfix(), info->pAccountTable->id);
- CDBManager::instance().ReturnQuery(szQuery, QID_LOGIN, peer->GetHandle(), info);
- ++info->account_index;
- char queryStr[512];
- extern std::string g_stLocale;
- snprintf(queryStr,
- sizeof(queryStr),
- "SELECT id,"
- "name,"
- "job,"
- "level,"
- "playtime,"
- "st,"
- "ht,"
- "dx,"
- "iq,"
- "part_main,"
- "part_hair,"
- "part_acce,"
- "x,"
- "y,"
- "skill_group,"
- "change_name,"
- #ifdef ENABLE_PLAYER_PIN_SYSTEM
- "pin "
- #endif
- "FROM player%s WHERE account_id=%u",GetTablePostfix(), info->pAccountTable->id);
- CDBManager::instance().ReturnQuery(queryStr, QID_LOGIN, peer->GetHandle(), info);
- ClientManagerPlayer
- peer->EncodeHeader(HEADER_DG_PLAYER_CREATE_FAILED, dwHandle, 0);
- return;
- }
- queryLen = snprintf(queryStr, sizeof(queryStr),
- "INSERT INTO player%s "
- "(id, "
- "account_id, "
- "name, "
- "level, "
- "st, "
- "ht, "
- "dx, "
- "iq, "
- "job, "
- "voice, "
- "dir, "
- "x, "
- "y, "
- "z, "
- "hp, "
- "mp, "
- "random_hp, "
- "random_sp, "
- "stat_point, "
- "stamina, "
- "part_base, "
- "part_main, "
- "part_hair, "
- "part_acce, "
- "gold, "
- #ifdef ENABLE_PLAYER_PIN_SYSTEM
- "pin, "
- #endif
- "playtime, "
- "skill_level, "
- "quickslot) "
- "VALUES"
- "(0, "
- "%u, "
- "'%s', "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, "
- "%d, " //acce
- "%lld, "
- #ifdef ENABLE_PLAYER_PIN_SYSTEM
- "%s, "
- #endif
- "0, "
- "%d, "
- "0, "
- ,
- GetTablePostfix()
- , packet->account_id
- , packet->player_table.name
- , packet->player_table.level
- , packet->player_table.st
- , packet->player_table.ht
- , packet->player_table.dx
- , packet->player_table.iq
- , packet->player_table.job
- , packet->player_table.voice
- , packet->player_table.dir
- , packet->player_table.x
- , packet->player_table.y
- , packet->player_table.z
- , packet->player_table.hp
- , packet->player_table.sp
- , packet->player_table.sRandomHP
- , packet->player_table.sRandomSP
- , packet->player_table.stat_point
- , packet->player_table.stamina
- , packet->player_table.part_base
- , packet->player_table.part_base
- , packet->player_table.part_base
- , packet->player_table.gold
- #ifdef ENABLE_PLAYER_PIN_SYSTEM
- ,packet->player_table.pin);
- #endif
Danke schonmal im vorraus