Kido Posted February 28, 2014 Group: Members Topic Count: 127 Topics Per Day: 0.03 Content Count: 1445 Reputation: 164 Joined: 08/17/13 Last Seen: July 11, 2019 Share Posted February 28, 2014 Well i just want to request a npc that deletes a character on a player account by inputing the name when talked to only usable by gm lv 99 this due to some clients can't delete the char or are having problems with that thanks in advance o:! Quote Link to comment Share on other sites More sharing options...
Pneuma Posted March 1, 2014 Group: Members Topic Count: 82 Topics Per Day: 0.02 Content Count: 846 Reputation: 138 Joined: 02/26/14 Last Seen: March 7, 2018 Share Posted March 1, 2014 You'd need to use a sql script to query the char db and to delete the row of the character name or ID Quote Link to comment Share on other sites More sharing options...
Kido Posted March 1, 2014 Group: Members Topic Count: 127 Topics Per Day: 0.03 Content Count: 1445 Reputation: 164 Joined: 08/17/13 Last Seen: July 11, 2019 Author Share Posted March 1, 2014 i know, that's what im asking because i dont know hot to put the input for search name in the sql and then delet D: Quote Link to comment Share on other sites More sharing options...
Pneuma Posted March 1, 2014 Group: Members Topic Count: 82 Topics Per Day: 0.02 Content Count: 846 Reputation: 138 Joined: 02/26/14 Last Seen: March 7, 2018 Share Posted March 1, 2014 i know, that's what im asking because i dont know hot to put the input for search name in the sql and then delet D: I believe something like this... input .charid$; set .charid$, .charid$; DELETE FROM `ragnarok`.`char` WHERE `char_id`='.charid$'; I'm not 100% sure this will work but you can test it Quote Link to comment Share on other sites More sharing options...
Patskie Posted March 1, 2014 Group: Members Topic Count: 50 Topics Per Day: 0.01 Content Count: 1702 Reputation: 241 Joined: 09/05/12 Last Seen: 17 hours ago Share Posted March 1, 2014 input .@name$; DELETE FROM `char` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"; Quote Link to comment Share on other sites More sharing options...
sandbox Posted March 1, 2014 Group: Members Topic Count: 38 Topics Per Day: 0.01 Content Count: 949 Reputation: 174 Joined: 06/12/12 Last Seen: Friday at 12:25 PM Share Posted March 1, 2014 You might want to delete also the char's items in `inventory`,`cart_inventory`, etc. and also his friends, party info, etc. xD what a pain! Quote Link to comment Share on other sites More sharing options...
Pneuma Posted March 1, 2014 Group: Members Topic Count: 82 Topics Per Day: 0.02 Content Count: 846 Reputation: 138 Joined: 02/26/14 Last Seen: March 7, 2018 Share Posted March 1, 2014 You might want to delete also the char's items in `inventory`,`cart_inventory`, etc. and also his friends, party info, etc. xD what a pain! input .@Name$; query_sql("DELETE FROM `char` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `cart_inventory` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `elemental` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `friends` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `global_reg_value` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `guild` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `guild_member` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `homunculus` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `hotkey` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `inventory` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `memo` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `mercenary` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `mercenary_owner` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `party` WHERE `leader_char` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `pet` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `quest` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `sc_data` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `skill` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); query_sql("DELETE FROM `skillcooldown` WHERE `char_id` = '" +getcharid(0, .@name$)+ "'"); Done. Quote Link to comment Share on other sites More sharing options...
sandbox Posted March 1, 2014 Group: Members Topic Count: 38 Topics Per Day: 0.01 Content Count: 949 Reputation: 174 Joined: 06/12/12 Last Seen: Friday at 12:25 PM Share Posted March 1, 2014 Was too lazy to write that for him and since i'm not that fluent with sql queries. Don't forget to backup @Kido! Quote Link to comment Share on other sites More sharing options...
Pneuma Posted March 1, 2014 Group: Members Topic Count: 82 Topics Per Day: 0.02 Content Count: 846 Reputation: 138 Joined: 02/26/14 Last Seen: March 7, 2018 Share Posted March 1, 2014 Was too lazy to write that for him and since i'm not that fluent with sql queries. Don't forget to backup @Kido! I'm not fluent either; but I'm currently working on an NPC that uses sql...so I used a part of what Patskie said and copied/pasted and renamed the parts needed Quote Link to comment Share on other sites More sharing options...
Kido Posted March 1, 2014 Group: Members Topic Count: 127 Topics Per Day: 0.03 Content Count: 1445 Reputation: 164 Joined: 08/17/13 Last Seen: July 11, 2019 Author Share Posted March 1, 2014 it confuses me a bit o: but i can half understand it o:! thank you i will try to play with it and see if it works o;! gonna update any results o: Quote Link to comment Share on other sites More sharing options...
Question
Kido
Well i just want to request a npc that deletes a character on a player account by inputing the name when talked to
only usable by gm lv 99
this due to some clients can't delete the char or are having problems with that
thanks in advance o:!
Link to comment
Share on other sites
9 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.