![]() |
|
The Most Important Querry - Printable Version +- LCKB (https://lckb.dev/forum) +-- Forum: ** OLD LCKB DATABASE ** (https://lckb.dev/forum/forumdisplay.php?fid=109) +--- Forum: Release Zone (https://lckb.dev/forum/forumdisplay.php?fid=190) +---- Forum: Episode 2 Releases (https://lckb.dev/forum/forumdisplay.php?fid=186) +----- Forum: Server Side (https://lckb.dev/forum/forumdisplay.php?fid=143) +----- Thread: The Most Important Querry (/showthread.php?tid=1652) |
- DrGenius - 02-24-2013 Check where specific mob regen: Credits to Question. SELECT * FROM t_npc_regen where a_npc_idx = 93; Delete Mob from NPC Regen DELETE FROM `t_npc_regen` WHERE `a_npc_idx` = 94 ; Replace Mob from NPC Regen UPDATE t_npc_regen SET a_npc_idx = "2090" WHERE a_npc_idx = "65"; Delete SP/GOLD/ITEM From skills(thats for server side ofc..) UPDATE t_skillLevel SET a_learnSP = 0; UPDATE t_skillLevel SET a_learnItemIndex1 = -1; UPDATE t_skillLevel SET a_learnItemCount1 = 0; UP Guild to level 50 or w.e you want UPDATE t_guild SET a_level = 50; UPDATE t_extend_guild SET a_guild_point = 2147483647; UPDATE t_extend_guild SET a_guild_maxmember = 100; Put that all mob give 200k sp^^ UPDATE t_npc SET a_skill_point = "2111111111"; The mobs important querry, this is when you add new item run that querry cuz if not when you try to use the item will say you are the wrong level. UPDATE t_item SET a_level2 = 999; Update t_item (this querry is good for drop etc..) UPDATE t_npc SET a_item_0 = -1 WHERE a_item_0 = 140; UPDATE t_npc SET a_item_1 = -1 WHERE a_item_1 = 140; UPDATE t_npc SET a_item_2 = -1 WHERE a_item_2 = 140; UPDATE t_npc SET a_item_3 = -1 WHERE a_item_3 = 140; UPDATE t_npc SET a_item_4 = -1 WHERE a_item_4 = 140; UPDATE t_npc SET a_item_5 = -1 WHERE a_item_5 = 140; UPDATE t_npc SET a_item_6 = -1 WHERE a_item_6 = 140; UPDATE t_npc SET a_item_7 = -1 WHERE a_item_7 = 140; UPDATE t_npc SET a_item_8 = -1 WHERE a_item_8 = 140; UPDATE t_npc SET a_item_9 = -1 WHERE a_item_9 = 140; UPDATE t_npc SET a_item_10 = -1 WHERE a_item_10 = 140; UPDATE t_npc SET a_item_11 = -1 WHERE a_item_11 = 140; UPDATE t_npc SET a_item_12 = -1 WHERE a_item_12 = 140; UPDATE t_npc SET a_item_13 = -1 WHERE a_item_13 = 140; UPDATE t_npc SET a_item_14 = -1 WHERE a_item_14 = 140; UPDATE t_npc SET a_item_15 = -1 WHERE a_item_15 = 140; UPDATE t_npc SET a_item_16 = -1 WHERE a_item_16 = 140; UPDATE t_npc SET a_item_17 = -1 WHERE a_item_17 = 140; UPDATE t_npc SET a_item_18 = -1 WHERE a_item_18 = 140; UPDATE t_npc SET a_item_19 = -1 WHERE a_item_19 = 140; in case you have some dupe bug this querry will help you to clear the gold or just to put an specific gold amount to all players.(Credit to HateMe) UPDATE t_inven00 SET a_count0 = 0 + "100" WHERE a_item_idx0 = 19; UPDATE t_inven00 SET a_count1 = 0 + "100" WHERE a_item_idx1 = 19; UPDATE t_inven00 SET a_count2 = 0 + "100" WHERE a_item_idx2 = 19; UPDATE t_inven00 SET a_count3 = 0 + "100" WHERE a_item_idx3 = 19; UPDATE t_inven00 SET a_count4 = 0 + "100" WHERE a_item_idx4 = 19; UPDATE t_inven01 SET a_count0 = 0 + "100" WHERE a_item_idx0 = 19; UPDATE t_inven01 SET a_count1 = 0 + "100" WHERE a_item_idx1 = 19; UPDATE t_inven01 SET a_count2 = 0 + "100" WHERE a_item_idx2 = 19; UPDATE t_inven01 SET a_count3 = 0 + "100" WHERE a_item_idx3 = 19; UPDATE t_inven01 SET a_count4 = 0 + "100" WHERE a_item_idx4 = 19; UPDATE t_inven02 SET a_count0 = 0 + "100" WHERE a_item_idx0 = 19; UPDATE t_inven02 SET a_count1 = 0 + "100" WHERE a_item_idx1 = 19; UPDATE t_inven02 SET a_count2 = 0 + "100" WHERE a_item_idx2 = 19; UPDATE t_inven02 SET a_count3 = 0 + "100" WHERE a_item_idx3 = 19; UPDATE t_inven02 SET a_count4 = 0 + "100" WHERE a_item_idx4 = 19; UPDATE t_inven03 SET a_count0 = 0 + "100" WHERE a_item_idx0 = 19; UPDATE t_inven03 SET a_count1 = 0 + "100" WHERE a_item_idx1 = 19; UPDATE t_inven03 SET a_count2 = 0 + "100" WHERE a_item_idx2 = 19; UPDATE t_inven03 SET a_count3 = 0 + "100" WHERE a_item_idx3 = 19; UPDATE t_inven03 SET a_count4 = 0 + "100" WHERE a_item_idx4 = 19; UPDATE t_inven04 SET a_count0 = 0 + "100" WHERE a_item_idx0 = 19; UPDATE t_inven04 SET a_count1 = 0 + "100" WHERE a_item_idx1 = 19; UPDATE t_inven04 SET a_count2 = 0 + "100" WHERE a_item_idx2 = 19; UPDATE t_inven04 SET a_count3 = 0 + "100" WHERE a_item_idx3 = 19; UPDATE t_inven04 SET a_count4 = 0 + "100" WHERE a_item_idx4 = 19; UPDATE t_inven05 SET a_count0 = 0 + "100" WHERE a_item_idx0 = 19; UPDATE t_inven05 SET a_count1 = 0 + "100" WHERE a_item_idx1 = 19; UPDATE t_inven05 SET a_count2 = 0 + "100" WHERE a_item_idx2 = 19; UPDATE t_inven05 SET a_count3 = 0 + "100" WHERE a_item_idx3 = 19; UPDATE t_inven05 SET a_count4 = 0 + "100" WHERE a_item_idx4 = 19; UPDATE t_inven06 SET a_count0 = 0 + "100" WHERE a_item_idx0 = 19; UPDATE t_inven06 SET a_count1 = 0 + "100" WHERE a_item_idx1 = 19; UPDATE t_inven06 SET a_count2 = 0 + "100" WHERE a_item_idx2 = 19; UPDATE t_inven06 SET a_count3 = 0 + "100" WHERE a_item_idx3 = 19; UPDATE t_inven06 SET a_count4 = 0 + "100" WHERE a_item_idx4 = 19; UPDATE t_inven07 SET a_count0 = 0 + "100" WHERE a_item_idx0 = 19; UPDATE t_inven07 SET a_count1 = 0 + "100" WHERE a_item_idx1 = 19; UPDATE t_inven07 SET a_count2 = 0 + "100" WHERE a_item_idx2 = 19; UPDATE t_inven07 SET a_count3 = 0 + "100" WHERE a_item_idx3 = 19; UPDATE t_inven07 SET a_count4 = 0 + "100" WHERE a_item_idx4 = 19; UPDATE t_inven08 SET a_count0 = 0 + "100" WHERE a_item_idx0 = 19; UPDATE t_inven08 SET a_count1 = 0 + "100" WHERE a_item_idx1 = 19; UPDATE t_inven08 SET a_count2 = 0 + "100" WHERE a_item_idx2 = 19; UPDATE t_inven08 SET a_count3 = 0 + "100" WHERE a_item_idx3 = 19; UPDATE t_inven08 SET a_count4 = 0 + "100" WHERE a_item_idx4 = 19; UPDATE t_inven09 SET a_count0 = 0 + "100" WHERE a_item_idx0 = 19; UPDATE t_inven09 SET a_count1 = 0 + "100" WHERE a_item_idx1 = 19; UPDATE t_inven09 SET a_count2 = 0 + "100" WHERE a_item_idx2 = 19; UPDATE t_inven09 SET a_count3 = 0 + "100" WHERE a_item_idx3 = 19; UPDATE t_inven09 SET a_count4 = 0 + "100" WHERE a_item_idx4 = 19; Credits to all people that has help with these querry, i know is easy to make it but some newbie dont know nothing about, i hope that help you guys^^ - Janebug - 02-24-2013 UPDATE t_quest SET a_prize_data0 = a_prize_data0*1 WHERE a_prize_index0 = 0 and a_prize_type0 = 2 ; UPDATE t_quest SET a_prize_data1 = a_prize_data1*1 WHERE a_prize_index1 = 0 and a_prize_type1 = 2 ; UPDATE t_quest SET a_prize_data2 = a_prize_data2*1 WHERE a_prize_index2 = 0 and a_prize_type2 = 2 ; -- This Code let manage you the Quest Experience Replace 1 with the -- number of Exp Rate that you would to have (thanks for code filix_93 ) -- NPCS that have 0 Value run once even if it gives value to shop npcs atleast all mobs will have Value -- UPDATE t_npc SET a_str = (a_level - 1) WHERE a_str = 0; UPDATE t_npc SET a_dex = (a_level - 1) WHERE a_dex = 0; UPDATE t_npc SET a_int = (a_level - 1) WHERE a_int = 0; UPDATE t_npc SET a_con = (a_level - 1) WHERE a_con = 0; UPDATE t_npc SET a_hit = (a_level * 7) WHERE a_hit = 0; UPDATE t_npc SET a_attack = (a_level * 3) WHERE a_attack = 0; UPDATE t_npc SET a_attacklevel = (a_level - 1) WHERE a_attacklevel = 0 UPDATE t_npc SET a_defenselevel = (a_level - 45) WHERE a_defenselevel = 0; UPDATE t_npc SET a_defense = (a_level - 45) WHERE a_defense = 0; UPDATE t_npc SET a_dodge = (a_level - 45) WHERE a_dodge = 0; UPDATE t_npc SET a_resist = (a_level * 5) WHERE a_resist = 0; UPDATE t_npc SET a_magic = (a_level * 35) WHERE a_magic = 0; UPDATE t_npc SET a_prize = (a_level * 170) WHERE a_prize = 0; UPDATE t_npc SET a_sight = (a_level / 13) WHERE a_sight = 0; UPDATE t_npc SET a_exp = (a_level * 30) WHERE a_exp = 0; UPDATE t_npc SET a_skill_point = (a_level * 23.62) WHERE a_skill_point = 0; by: jane most of these takes the Level of the npc Subtract, adds, divides or multiplies by a Value to give it something to start.. - DrGenius - 02-24-2013 great^^ thanks, thats good idea, people that have some nice querry post it here that can be helpfull - filix_93 - 02-24-2013 UPDATE t_quest SET a_prize_data0 = a_prize_data0*1 WHERE a_prize_index0 = 0 and a_prize_type0 = 2 ; UPDATE t_quest SET a_prize_data1 = a_prize_data1*1 WHERE a_prize_index1 = 0 and a_prize_type1 = 2 ; UPDATE t_quest SET a_prize_data2 = a_prize_data2*1 WHERE a_prize_index2 = 0 and a_prize_type2 = 2 ; -- This Code let manage you the Quest Experience Replace 1 with the -- number of Exp Rate that you would to have (thanks for code filix_93 ) -- NPCS that have 0 Value run once even if it gives value to shop npcs atleast all mobs will have Value -- UPDATE t_npc SET a_str = (a_level - 1) WHERE a_str = 0; UPDATE t_npc SET a_dex = (a_level - 1) WHERE a_dex = 0; UPDATE t_npc SET a_int = (a_level - 1) WHERE a_int = 0; UPDATE t_npc SET a_con = (a_level - 1) WHERE a_con = 0; UPDATE t_npc SET a_hit = (a_level * 7) WHERE a_hit = 0; UPDATE t_npc SET a_attack = (a_level * 3) WHERE a_attack = 0; UPDATE t_npc SET a_attacklevel = (a_level - 1) WHERE a_attacklevel = 0 UPDATE t_npc SET a_defenselevel = (a_level - 45) WHERE a_defenselevel = 0; UPDATE t_npc SET a_defense = (a_level - 45) WHERE a_defense = 0; UPDATE t_npc SET a_dodge = (a_level - 45) WHERE a_dodge = 0; UPDATE t_npc SET a_resist = (a_level * 5) WHERE a_resist = 0; UPDATE t_npc SET a_magic = (a_level * 35) WHERE a_magic = 0; UPDATE t_npc SET a_prize = (a_level * 170) WHERE a_prize = 0; UPDATE t_npc SET a_sight = (a_level / 13) WHERE a_sight = 0; UPDATE t_npc SET a_exp = (a_level * 30) WHERE a_exp = 0; UPDATE t_npc SET a_skill_point = (a_level * 23.62) WHERE a_skill_point = 0; by: jane most of these takes the Level of the npc Subtract, adds, divides or multiplies by a Value to give it something to start.. nice the second one ![]() - Mr Perez - 02-24-2013 awesome post guys tanks alot ^^ +100 - Janebug - 02-26-2013 ooops ...for the ones that you set with zeros that u find that are eather too strong or what ever use these to fine tune what ever npc you find -- update a single Npc just change the number on the end to match, -- a_index 0 would be the Number, -- Werewolf is a_index 1 ...to update just that one change 0 to 1. UPDATE t_npc SET a_hit = a_hit - 10 WHERE a_index = 0; UPDATE t_npc SET a_attack = a_attack / 3 WHERE a_index = 0; UPDATE t_npc SET a_attacklevel = a_attacklevel / 2 WHERE a_index = 0; UPDATE t_npc SET a_attackSpeed = a_attackSpeed / 2 WHERE a_index = 0; UPDATE t_npc SET a_magic = a_magic / 2 WHERE a_index = 0; Jane - Janebug - 02-27-2013 sorry removed - Wizatek - 02-27-2013 ooops ...for the ones that you set with zeros that u find that are eather too strong or what ever use these to fine tune what ever npc you find -- update a single Npc just change the number on the end to match, -- a_index 0 would be the Number, -- Werewolf is a_index 1 ...to update just that one change 0 to 1. UPDATE t_npc SET a_hit = a_hit - 10 WHERE a_index = 0; UPDATE t_npc SET a_attack = a_attack / 3 WHERE a_index = 0; UPDATE t_npc SET a_attacklevel = a_attacklevel / 2 WHERE a_index = 0; UPDATE t_npc SET a_attackSpeed = a_attackSpeed / 2 WHERE a_index = 0; UPDATE t_npc SET a_magic = a_magic / 2 WHERE a_index = 0;Jane UPDATE t_npc SET a_hit = a_hit - 10, a_attack = a_attack / 3, a_attacklevel = a_attacklevel / 2, a_attackSpeed = a_attackSpeed / 2, a_magic = a_magic / 2 WHERE a_index = 0; Your mysql server would probably like u more if u would edit the data from the same record in 1 query ![]() - halohalo - 02-27-2013 Nice post, keep it up all^^ - Wizatek - 02-27-2013 U can also do bitwise things in mysql. SELECT * FROM t_npc WHERE a_flag & (1 to get all boss monsters SELECT * FROM t_item WHERE a_flag & (1 to get all tradable items. |