Heartbreak Posted June 17, 2014 Posted June 17, 2014 (edited) please help me.. i didnt changed anything in my kafra except the location.. this only happen to one player.. (as far as i know)it doesnt happen to my own character..and when that character reconnects.. it double the item Edited June 17, 2014 by Heartbreak Quote
Kido Posted June 17, 2014 Posted June 17, 2014 Interesting o: do you get any error in the consoe when the player duplicates the item? if so, can you show us please? Quote
Kido Posted June 17, 2014 Posted June 17, 2014 Hmm loooks like when you isntalled the server and the sql, somehow you did it wrong, i'm not too sure about this, i would recommend a reinstall of the sql, sry i'm not being of help at all, i hope someone else can lend you a hand o: Quote
Jasc Posted June 18, 2014 Posted June 18, 2014 Could be a server error too, suggest a fresh SVN Quote
Winz Posted June 18, 2014 Posted June 18, 2014 Heartbreak, please reload every SQL table. if you have ever updated your server, please do the SQL upgrades. to make it easy (but you'll lose everything), drop the ragnarok database, create a new one. then, reload main.sql and logs.sql on your ragnarok database (schema). @Jasc, please do not mention SVN anymore. we are now using GIT. some guides asks users to use SVN and it leads to a horrible error. The guide as well as the rAthena SVN are outdated. Only for rAthena's SVN. Quote
Sin Posted June 18, 2014 Posted June 18, 2014 (edited) What did you change in your source code? It looks like you changed something that is in char.c, int_storage.c, int_mail.c or int_auction. Look at all the changes you've changed within the source.Here is an example of what you might have done: StringBuf_AppendStr(&buf, "SELECT `id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `expire_time`, `unique_id`, `bound`, `favorite`, `customtable`"); for( j = 0; j < MAX_SLOTS; ++j ) StringBuf_Printf(&buf, ", `card%d`", j); StringBuf_Printf(&buf, " FROM `%s` WHERE `char_id`=? LIMIT %d", schema_config.cart_db, MAX_CART); if( SQL_ERROR == SqlStmt_PrepareStr(stmt, StringBuf_Value(&buf)) || SQL_ERROR == SqlStmt_BindParam(stmt, 0, SQLDT_INT, &char_id, 0) || SQL_ERROR == SqlStmt_Execute(stmt) || SQL_ERROR == SqlStmt_BindColumn(stmt, 0, SQLDT_INT, &tmp_item.id, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt, 1, SQLDT_SHORT, &tmp_item.nameid, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt, 2, SQLDT_SHORT, &tmp_item.amount, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt, 3, SQLDT_UINT, &tmp_item.equip, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt, 4, SQLDT_CHAR, &tmp_item.identify, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt, 5, SQLDT_CHAR, &tmp_item.refine, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt, 6, SQLDT_CHAR, &tmp_item.attribute, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt, 7, SQLDT_UINT, &tmp_item.expire_time, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt, 8, SQLDT_ULONGLONG, &tmp_item.unique_id, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt, 9, SQLDT_CHAR, &tmp_item.bound, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt,10, SQLDT_CHAR, &tmp_item.favorite, 0, NULL, NULL) || SQL_ERROR == SqlStmt_BindColumn(stmt,11, SQLDT_INT, &tmp_item.customtable, 0, NULL, NULL) ) SqlStmt_ShowDebug(stmt); for( i = 0; i < MAX_SLOTS; ++i ) if( SQL_ERROR == SqlStmt_BindColumn(stmt, 11+i, SQLDT_SHORT, &tmp_item.card[i], 0, NULL, NULL) ) if you look closely below, customtable is assigned within the same area that card0 starts to begin. || SQL_ERROR == SqlStmt_BindColumn(stmt,11, SQLDT_INT, &tmp_item.customtable, 0, NULL, NULL) ) SqlStmt_ShowDebug(stmt); for( i = 0; i < MAX_SLOTS; ++i ) if( SQL_ERROR == SqlStmt_BindColumn(stmt,11+i, SQLDT_SHORT, &tmp_item.card[i], 0, NULL, NULL) ) to fix this you would have to change the value of if( SQL_ERROR == SqlStmt_BindColumn(stmt, 11+i, SQLDT_SHORT, &tmp_item.card[i], 0, NULL, NULL) ) to if( SQL_ERROR == SqlStmt_BindColumn(stmt, 12+i, SQLDT_SHORT, &tmp_item.card[i], 0, NULL, NULL) ) The end result would look like this. || SQL_ERROR == SqlStmt_BindColumn(stmt,11, SQLDT_INT, &tmp_item.customtable, 0, NULL, NULL) ) SqlStmt_ShowDebug(stmt); for( i = 0; i < MAX_SLOTS; ++i ) if( SQL_ERROR == SqlStmt_BindColumn(stmt,12+i, SQLDT_SHORT, &tmp_item.card[i], 0, NULL, NULL) ) There may be multiple areas that you have changed that looks similar to what i've shown above.Please note that this is an assumption of where you may have editted within your source code. Also take note of how customtable is a INT and card is a SHORT which may be another case of why it's being truncated. For future reference, try backing up your files before applying new changes to it. Hope this helps, Sin Edited June 18, 2014 by Sin Quote
Heartbreak Posted June 18, 2014 Author Posted June 18, 2014 i found 2 of those in my char.c.. =/here: || SQL_ERROR == SqlStmt_BindColumn(stmt, 9, SQLDT_ULONGLONG, &tmp_item.unique_id, 0, NULL, NULL) ) SqlStmt_ShowDebug(stmt); for( i = 0; i < MAX_SLOTS; ++i ) if( SQL_ERROR == SqlStmt_BindColumn(stmt, 10+i, SQLDT_USHORT, &tmp_item.card[i], 0, NULL, NULL) ) SqlStmt_ShowDebug(stmt); and here: || SQL_ERROR == SqlStmt_BindColumn(stmt, 9, SQLDT_ULONGLONG, &tmp_item.unique_id, 0, NULL, NULL) ) SqlStmt_ShowDebug(stmt); for( i = 0; i < MAX_SLOTS; ++i ) if( SQL_ERROR == SqlStmt_BindColumn(stmt, 10+i, SQLDT_USHORT, &tmp_item.card[i], 0, NULL, NULL) ) SqlStmt_ShowDebug(stmt); should i edit both ? tried changing both.. but nothing happen.. =/does it have something to do with this error ? i get this everytime i start the server.. Quote
Sin Posted June 19, 2014 Posted June 19, 2014 (edited) I don't know what the error above is directed to. Can you provide information on what you've changed within the source and what it looks like to you before you changed it. Also are you able to log in? If so, can you check if your items are still being duplicated or not. Are you still getting truncation errors on your console? Whats shown above could be a different issue. Edited June 19, 2014 by Sin Quote
Heartbreak Posted June 19, 2014 Author Posted June 19, 2014 i didn't change anything in my src.. my whole server just got reinstalled by a dev.. i was able to log in.. after i followed those instructions.. but im still getting the same error.. Quote
Kichi Posted June 25, 2014 Posted June 25, 2014 this happened because your column has greater value than the size of columnthis ever happened to someone, and crashing his server Quote
Ronald Posted July 14, 2014 Posted July 14, 2014 Same happens to mine. Hope to have it fixed. I just changed mine into a fresh SVN and loaded previous database and then poof! Storage bug. Quote
iZeal Posted July 14, 2014 Posted July 14, 2014 lol this reminds of what happen to DarkRO before Storage got bugged.. everyone can dupe just by storage and then logout. Quote
Cydh Posted July 14, 2014 Posted July 14, 2014 there was update to change SHORT to UNSIGNED SHORT for item id, also for the card0~card3 does it have something to do with this error ? i get this everytime i start the server.. I imagine how long u don't update ur file? u just simple copy-paste db/const.txt value to newer copy? because those constant for Option hardcoded on script.c, not in db/const.txt anymore Quote
Ronald Posted July 17, 2014 Posted July 17, 2014 lol this reminds of what happen to DarkRO before Storage got bugged.. everyone can dupe just by storage and then logout. This is actually we're encountering how to fix this Sir Zeal? @Cydh What should we do then? Thank you in advance Sir Quote
Question
Heartbreak
please help me.. i didnt changed anything in my kafra except the location..
Edited by Heartbreakthis only happen to one player.. (as far as i know)
it doesnt happen to my own character..
and when that character reconnects.. it double the item
15 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.