Extractable item data moved from CSV to XML.
This commit is contained in:
parent
f1b7de35a6
commit
84b8e76471
2138
L2J_Mobius_C6_Interlude/dist/game/data/ExtractableItems.xml
vendored
Normal file
2138
L2J_Mobius_C6_Interlude/dist/game/data/ExtractableItems.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
@ -1,364 +0,0 @@
|
||||
#ItemID;Production1,Quantity1,Chance1[;Production2,Quantity2,Chance2... ;ProductionN,QuantityN,ChanceN]
|
||||
|
||||
#Ketra/Varka Rewards
|
||||
#Looted Goods - White Cargo box
|
||||
7629;6688,1,9;6689,1,9;6690,1,9;6691,1,9;6693,1,9;6694,1,9;6695,1,9;6696,1,9;6697,1,9;7579,1,9;57,330000,10
|
||||
#Looted Goods - Blue Cargo box #All chances of 8 should be 8.5, must be fixed if possible!!!
|
||||
7630;6703,1,8;6704,1,8;6705,1,8;6706,1,8;6708,1,8;6709,1,8;6710,1,8;6712,1,8;6713,1,8;6714,1,8;57,292000,20
|
||||
#Looted Goods - Yellow Cargo box
|
||||
7631;6701,1,20;6702,1,20;6707,1,20;6711,1,20;57,930000,20
|
||||
#Looted Goods - Red Filing Cabinet
|
||||
7632;6857,1,8;6859,1,8;6861,1,8;6863,1,8;6867,1,8;6869,1,8;6871,1,8;6875,1,8;6877,1,8;6879,1,8;57,340000,15
|
||||
#Looted Goods - Purple Filing Cabinet
|
||||
7633;6853,1,20;6855,1,20;6865,1,20;6873,1,20;57,850000,20
|
||||
#Looted Goods - Brown Pouch
|
||||
7634;1874,20,10;1875,20,10;1876,20,16;1877,20,11;1879,20,10;1880,20,5;1881,20,10;1882,20,18;57,150000,10
|
||||
#Looted Goods - Gray Pouch
|
||||
7635;4039,4,20;4040,4,10;4041,4,10;4042,4,10;4043,4,20;4044,4,20;57,160000,10
|
||||
#Adventurer's Box: C-Grade Accessory (Low Grade)
|
||||
8534;853,1,17;916,1,17;884,1,17;-1,0,49
|
||||
#Adventurer's Box: C-Grade Accessory (Medium Grade)
|
||||
8535;854,1,17;917,1,17;885,1,17;-1,0,49
|
||||
#Adventurer's Box: C-Grade Accessory (High Grade)
|
||||
8536;855,1,17;119,1,17;886,1,17;-1,0,49
|
||||
#Adventurer's Box: B-Grade Accessory (Low Grade)
|
||||
8537;856,1,17;918,1,17;887,1,17;-1,0,49
|
||||
#Adventurer's Box: B-Grade Accessory (High Grade)
|
||||
8538;864,1,17;926,1,17;895,1,17;-1,0,49
|
||||
#Adventurer's Box: Hair Accessory
|
||||
8539;8177,1,30;8178,1,20;8179,1,10;-1,0,40
|
||||
#Adventurer's Box: Cradle of Creation
|
||||
8540;8175,1,33;-1,0,67
|
||||
# Quest 370: A Wiseman Sows Seeds
|
||||
5916;5917,1,10;5918,1,10;5919,1,10;5920,1,10;736,1,60
|
||||
# Quest 376: Giants Cave Exploration, Part 1
|
||||
5944;5922,1,3;5923,1,3;5924,1,3;5925,1,3;5926,1,3;5927,1,3;5928,1,3;5929,1,3;5930,1,3;5931,1,3;5932,1,3;5933,1,3;5934,1,3;5935,1,3;5936,1,3;5937,1,3;5938,1,3;5939,1,3;5940,1,3;5941,1,3;5942,1,20;5943,1,20
|
||||
# Quest 377: Giants Cave Exploration, Part 2
|
||||
5955;5942,1,25;5943,1,25;5945,1,5;5946,1,5;5947,1,5;5948,1,5;5949,1,5;5950,1,5;5951,1,5;5952,1,5;5953,1,5;5954,1,5
|
||||
# Quest 373: Supplier of Reagents
|
||||
6007;6019,2,30;6013,2,30;6014,1,20;6016,1,20
|
||||
6008;6017,2,10;6020,2,20;6014,1,35;6016,1,35
|
||||
6009;6012,1,20;6018,2,20;6019,2,20;6013,1,40
|
||||
6010;6017,2,20;6020,2,20;6016,1,35;6015,2,25
|
||||
# Quest 372: Legacy of Insolence
|
||||
5966;5978,1,2;5983,1,2;5988,1,2;5994,1,2;5995,1,2;5975,1,8;5976,1,8;5977,1,8;5981,1,8;5982,1,8;5973,1,11;5974,1,11;5980,1,11;5985,1,11;5972,1,2;5979,1,2;5984,1,2
|
||||
5967;5978,1,4;5983,1,4;5988,1,4;5994,1,4;5995,1,4;5975,1,4;5976,1,4;5977,1,4;5981,1,4;5982,1,4;5973,1,10;5974,1,10;5980,1,10;5985,1,10;5972,1,7;5979,1,7;5984,1,6
|
||||
5968;6001,1,2;5970,1,2;5971,1,2;4408,1,2;4409,1,2;5986,1,2;5987,1,2;5993,1,2;5999,1,2;6000,1,2;5991,1,10;5992,1,10;5997,1,10;5998,1,10;5989,1,14;5990,1,13;5996,1,13
|
||||
5969;6001,1,3;5970,1,3;5971,1,3;4408,1,3;4409,1,3;5986,1,2;5987,1,2;5993,1,2;5999,1,2;6000,1,2;5991,1,3;5992,1,3;5997,1,3;5998,1,3;5989,1,21;5990,1,21;5996,1,21
|
||||
# Quest 628: Hunt of Golden Ram
|
||||
7725;6035,1,7;1060,1,39;735,1,7;1540,1,3;1061,1,12;1539,1,32
|
||||
7637;4039,4,20;4041,1,10;4043,4,20;4044,4,20;4042,2,15;4040,2,15
|
||||
7636;1875,3,10;1882,3,20;1880,4,10;1874,1,10;1877,3,10;1881,1,12;1879,3,12;1876,6,16
|
||||
# Compressed SS
|
||||
5134;1835,300,100
|
||||
5135;1463,300,100
|
||||
5136;1464,300,100
|
||||
5137;1465,300,100
|
||||
5138;1466,300,100
|
||||
5139;1467,300,100
|
||||
# Compressed SpS
|
||||
5140;2509,300,100
|
||||
5141;2510,300,100
|
||||
5142;2511,300,100
|
||||
5143;2512,300,100
|
||||
5144;2513,300,100
|
||||
5145;2514,300,100
|
||||
# Compressed BSpS
|
||||
5146;3947,300,100
|
||||
5147;3948,300,100
|
||||
5148;3949,300,100
|
||||
5149;3950,300,100
|
||||
5150;3951,300,100
|
||||
5151;3952,300,100
|
||||
# Greater Compressed SS
|
||||
5250;1835,1000,100
|
||||
5251;1463,1000,100
|
||||
5252;1464,1000,100
|
||||
5253;1465,1000,100
|
||||
5254;1466,1000,100
|
||||
5255;1467,1000,100
|
||||
# Greater Compressed SpS
|
||||
5256;2509,1000,100
|
||||
5257;2510,1000,100
|
||||
5258;2511,1000,100
|
||||
5259;2512,1000,100
|
||||
5260;2513,1000,100
|
||||
5261;2514,1000,100
|
||||
# Greater Compressed BSpS
|
||||
5262;3947,1000,100
|
||||
5263;3948,1000,100
|
||||
5264;3949,1000,100
|
||||
5265;3950,1000,100
|
||||
5266;3951,1000,100
|
||||
5267;3952,1000,100
|
||||
# Fishing rewards
|
||||
6411;6908,6,31;6913,1,18;-1,0,51
|
||||
6412;6908,6,29;6911,2,22;-1,0,49
|
||||
6413;6908,6,35;6915,1,33;-1,0,32
|
||||
6414;6908,6,33;6913,1,23;-1,0,44
|
||||
6415;6908,8,31;6911,2,31;-1,0,38
|
||||
6416;6908,6,45;6915,1,32;-1,0,23
|
||||
6417;6908,12,16;6913,1,18;6920,8,26;-1,0,40
|
||||
6418;6908,8,42;6911,2,38;-1,0,20
|
||||
6419;6908,12,27;6915,1,45;-1,0,28
|
||||
6420;6908,12,21;6913,1,25;6920,8,35;-1,0,19
|
||||
6421;6908,8,47;6911,2,47;-1,0,6
|
||||
6422;6908,12,33;6915,1,55;-1,0,12
|
||||
6423;6908,12,28;6913,1,33;6920,16,23;-1,0,16
|
||||
6424;6908,16,38;6911,4,36;-1,0,26
|
||||
6425;6908,12,46;6915,2,35;-1,0,19
|
||||
6426;6908,12,33;6913,2,22;6920,16,26;-1,0,19
|
||||
6427;6908,16,41;6911,4,38;-1,0,21
|
||||
6428;6908,12,47;6915,2,38;-1,0,15
|
||||
6429;6908,12,33;6913,2,23;6920,16,27;-1,0,17
|
||||
6430;6908,16,41;6911,4,38;-1,0,21
|
||||
6431;6908,12,48;6915,2,39;-1,0,13
|
||||
6432;6904,1,2;6908,14,19;6909,4,17;6913,1,26;6920,16,18;-1,0,18
|
||||
6433;6904,1,2;6908,10,25;6909,2,21;6911,4,17;6921,4,17;-1,0,18
|
||||
6434;6904,1,4;6908,16,26;6909,4,19;6915,4,21;-1,0,30
|
||||
6435;6904,1,2;6908,14,21;6909,4,18;6913,2,14;6920,16,20;-1,0,25
|
||||
6436;6904,1,2;6908,10,24;6909,2,22;6911,4,17;6921,4,17;-1,0,18
|
||||
6437;6904,1,3;6908,16,26;6909,4,20;6915,4,21;-1,0,30
|
||||
6438;6904,1,2;6908,14,19;6909,4,18;6913,2,12;6920,16,16;-1,0,33
|
||||
6439;6904,1,2;6908,20,12;6909,2,20;6911,4,16;6921,4,17;-1,0,33
|
||||
6440;6904,1,3;6908,16,25;6909,4,19;6915,4,20;-1,0,33
|
||||
6441;6904,1,2;6908,14,19;6909,4,18;6913,2,14;6920,16,18;-1,0,29
|
||||
6442;6904,1,3;6908,20,13;6909,4,12;6911,4,18;6921,4,19;-1,0,35
|
||||
6443;6904,1,3;6908,16,25;6909,4,19;6915,4,20;-1,0,33
|
||||
6444;6904,1,2;6908,14,21;6909,4,20;6913,2,14;6920,16,19;-1,0,24
|
||||
6445;6904,1,3;6908,20,14;6909,4,12;6911,4,19;6921,4,21;-1,0,31
|
||||
6446;6904,1,4;6908,16,26;6909,4,19;6915,4,21;-1,0,30
|
||||
6447;6904,1,3;6908,28,11;6909,4,20;6913,2,16;6920,16,20;-1,0,30
|
||||
6448;6904,1,3;6908,20,16;6909,4,13;6911,8,11;6921,8,11;-1,0,46
|
||||
6449;6904,1,4;6908,32,14;6909,4,20;6915,4,23;-1,0,39
|
||||
6450;6910,1,24;6914,2,14;7698,1,5;-1,0,57
|
||||
6451;6910,1,28;6912,8,18;7686,1,7;-1,0,47
|
||||
6452;6910,1,26;6916,4,25;7697,1,7;-1,0,42
|
||||
6453;6910,1,30;6912,2,17;7698,1,6;-1,0,47
|
||||
6454;6910,2,15;6912,8,21;7686,1,7;-1,0,57
|
||||
6455;6910,1,31;6916,4,26;7697,1,7;-1,0,36
|
||||
6456;6910,2,20;6914,2,18;7698,1,7;-1,0,55
|
||||
6457;6910,2,16;6912,8,22;7686,1,8;-1,0,54
|
||||
6458;6910,1,31;6916,4,28;7697,1,8;-1,0,33
|
||||
6459;6910,2,22;6914,2,22;7698,1,8;-1,0,48
|
||||
6460;6910,2,17;6912,8,26;7686,1,9;-1,0,48
|
||||
6461;6910,2,20;6916,4,37;7697,1,10;-1,0,33
|
||||
6462;6907,1,6;6910,2,19;6914,2,17;7685,1,6;7698,1,6;-1,0,46
|
||||
6463;6905,1,8;6910,2,16;6912,8,24;7686,1,8;-1,0,44
|
||||
6464;6906,1,8;6910,2,18;6916,8,16;7697,1,9;-1,0,49
|
||||
6465;6907,1,7;6910,2,20;6914,2,17;7685,1,7;7698,1,8;-1,0,41
|
||||
6466;6905,1,9;6910,2,18;6912,8,27;7686,1,7;-1,0,39
|
||||
6467;6906,1,10;6910,2,18;6916,8,18;7697,1,9;-1,0,45
|
||||
6468;6907,1,8;6910,2,18;6914,2,18;7685,1,6;7698,1,7;-1,0,43
|
||||
6469;6905,1,9;6910,2,17;6912,8,26;7686,1,8;-1,0,40
|
||||
6470;6906,1,10;6910,2,23;6916,8,19;7697,1,11;-1,0,37
|
||||
6471;6907,1,8;6910,4,10;6914,2,20;7685,1,8;7698,1,8;-1,0,46
|
||||
6472;6905,1,10;6910,2,21;6912,8,23;7686,1,10;-1,0,36
|
||||
6473;6906,1,10;6910,2,23;6916,8,19;7697,1,11;-1,0,37
|
||||
6474;6907,1,9;6910,4,13;6914,4,11;7685,1,9;7698,1,9;-1,0,49
|
||||
6475;6905,1,11;6910,2,23;6912,8,27;7686,1,11;-1,0,28
|
||||
6476;6906,1,12;6910,2,25;6916,8,16;7697,1,11;-1,0,36
|
||||
6477;6907,1,9;6910,4,13;6914,4,12;7685,1,8;7698,1,10;-1,0,48
|
||||
6478;6905,1,12;6910,2,24;6912,16,14;7686,1,12;-1,0,38
|
||||
6479;6906,1,11;6910,2,26;6916,8,20;7697,1,11;-1,0,32
|
||||
6480;6907,1,11;6910,4,13;6914,4,12;7685,1,12;7698,1,11;-1,0,41
|
||||
6481;6905,0,14;6910,2,26;6912,16,15;7686,1,15;-1,0,30
|
||||
6482;6906,1,14;6910,2,28;6916,8,20;7697,1,12;-1,0,26
|
||||
6483;6907,1,12;6910,4,16;6914,4,15;7685,1,13;7698,1,14;-1,0,30
|
||||
6484;6905,1,18;6910,4,15;6912,16,16;7686,1,16;-1,0,35
|
||||
6485;6906,1,16;6910,4,15;6916,8,26;7697,1,17;-1,0,26
|
||||
6486;6907,1,12;6910,4,15;6914,4,20;7685,1,15;7698,1,12;-1,0,26
|
||||
6487;6905,1,14;6910,4,20;6912,16,23;7686,2,12;-1,0,31
|
||||
6488;6906,1,18;6910,4,15;6916,8,25;7697,1,16;-1,0,26
|
||||
6489;6907,1,15;6910,4,17;6914,4,16;7685,1,19;7698,1,10;-1,0,23
|
||||
6490;6905,1,22;6910,4,21;6912,16,19;7686,2,16;-1,0,22
|
||||
6491;6906,1,21;6910,4,18;6916,8,31;7697,2,9;-1,0,21
|
||||
6492;6908,12,32;7609,8,51;-1,0,17
|
||||
6493;6908,12,47;7609,16,33;-1,0,20
|
||||
6494;6908,24,28;7609,26,28;-1,0,44
|
||||
6495;6908,24,39;7609,26,35;-1,0,26
|
||||
6496;6908,24,44;7609,26,41;-1,0,15
|
||||
6497;6908,24,46;7609,26,43;-1,0,11
|
||||
6498;6908,24,47;7609,26,42;-1,0,11
|
||||
6499;6904,1,7;6908,28,26;6909,8,23;7609,30,25;-1,0,19
|
||||
6500;6904,1,7;6908,28,25;6909,8,24;7609,30,25;-1,0,19
|
||||
6501;6904,1,5;6908,28,24;6909,8,22;7609,30,22;-1,0,27
|
||||
6502;6904,1,7;6908,28,29;6909,8,23;7609,30,20;-1,0,21
|
||||
6503;6904,1,7;6908,56,13;6909,14,12;7609,30,27;-1,0,41
|
||||
6504;6904,1,8;6908,56,15;6909,14,12;7609,60,13;-1,0,52
|
||||
6505;6910,3,58;-1,0,42
|
||||
6506;6910,3,62;-1,0,38
|
||||
6507;6910,3,62;-1,0,38
|
||||
6508;6910,3,77;-1,0,23
|
||||
6509;6910,3,82;-1,0,18
|
||||
6510;6910,3,90;-1,0,10
|
||||
6511;6910,3,91;-1,0,9
|
||||
6512;6910,6,61;-1,0,39
|
||||
6513;6910,6,64;-1,0,36
|
||||
6514;6910,6,69;-1,0,31
|
||||
6515;6910,6,74;-1,0,26
|
||||
6516;6910,1,81;-1,0,19
|
||||
6517;6910,6,91;-1,0,9
|
||||
6518;6910,6,99;-1,0,1
|
||||
7726;6908,3,44;6913,1,7;-1,0,49
|
||||
7727;6908,4,32;6911,1,17;-1,0,51
|
||||
7728;6908,4,33;6915,1,13;-1,0,54
|
||||
7729;6908,4,36;6913,1,9;-1,0,55
|
||||
7730;6908,4,40;6911,1,26;-1,0,34
|
||||
7731;6908,4,49;6915,1,20;-1,0,31
|
||||
7732;6908,4,33;6913,1,9;6920,4,17;-1,0,41
|
||||
7733;6908,4,58;6911,2,18;-1,0,24
|
||||
7734;6908,6,29;6915,1,15;-1,0,56
|
||||
7735;6908,6,37;6913,1,7;6920,4,28;-1,0,28
|
||||
7736;6908,6,49;6911,2,17;-1,0,34
|
||||
7737;6908,6,47;6915,1,28;-1,0,25
|
||||
7738;6908,6,45;6913,1,11;6920,8,15;-1,0,29
|
||||
7739;6908,6,46;6911,2,20;-1,0,34
|
||||
7740;6908,6,45;6915,1,26;-1,0,29
|
||||
7741;6908,6,47;6913,1,6;6920,8,13;-1,0,34
|
||||
7742;6908,6,41;6911,2,18;-1,0,41
|
||||
7743;6908,6,45;6915,1,28;-1,0,27
|
||||
7744;6908,6,31;6913,1,13;6920,8,13;-1,0,43
|
||||
7745;6908,6,41;6911,2,20;-1,0,39
|
||||
7746;6908,6,42;6915,1,40;-1,0,18
|
||||
7747;6908,8,13;6909,2,17;6913,1,8;6920,8,11;6904,1,1;-1,0,50
|
||||
7748;6908,8,19;6909,2,17;6911,2,10;6920,1,17;6904,1,1;-1,0,36
|
||||
7749;6908,8,20;6909,2,18;6915,1,20;6904,1,2;-1,0,40
|
||||
7750;6908,8,16;6909,2,15;6913,1,11;6920,8,14;6904,1,1;-1,0,43
|
||||
7751;6908,8,17;6909,2,15;6911,2,9;6920,2,11;6904,1,1;-1,0,47
|
||||
7752;6908,8,20;6909,2,13;6915,1,17;6904,1,3;-1,0,47
|
||||
7753;6908,8,15;6909,2,18;6913,1,8;6920,8,11;6904,1,3;-1,0,45
|
||||
7754;6908,8,28;6909,2,16;6911,2,12;6921,2,8;6904,1,1;-1,0,35
|
||||
7755;6908,8,21;6909,2,19;6915,1,19;6904,1,1;-1,0,40
|
||||
7756;6908,12,15;6909,2,18;6913,1,14;6920,8,14;6904,1,1;-1,0,38
|
||||
7757;6908,16,8;6909,16,8;6911,2,19;6921,2,20;6904,1,1;-1,0,44
|
||||
7758;6908,8,21;6909,2,21;6915,2,17;6904,1,1;-1,0,40
|
||||
7759;6908,8,22;6909,2,19;6913,1,10;6920,8,18;-1,0,31
|
||||
7760;6908,16,16;6909,2,14;6911,2,16;6921,2,14;6904,1,2;-1,0,38
|
||||
7761;6908,8,28;6909,2,20;6915,2,13;6904,1,1;-1,0,38
|
||||
7762;6908,14,16;6909,2,21;6913,1,11;6920,8,17;6904,1,2;-1,0,33
|
||||
7763;6908,16,14;6909,2,15;6911,2,19;6921,4,8;6904,1,1;-1,0,33
|
||||
7764;6908,16,14;6909,2,19;6915,2,17;6904,1,3;-1,0,47
|
||||
7765;6910,1,15;6914,1,9;7698,1,2;-1,0,74
|
||||
7766;6910,1,17;6912,1,17;7686,1,1;-1,0,65
|
||||
7767;6910,1,20;6916,2,17;7697,1,3;-1,0,60
|
||||
7768;6910,1,21;6914,1,13;7698,1,1;-1,0,65
|
||||
7769;6910,1,24;6912,1,20;7686,1,3;-1,0,53
|
||||
7770;6910,1,33;6916,2,12;7697,1,1;-1,0,54
|
||||
7771;6910,1,25;6914,1,13;7698,1,5;-1,0,57
|
||||
7772;6910,1,21;6912,2,27;7686,1,2;-1,0,50
|
||||
7773;6910,1,24;6916,2,18;7697,1,5;-1,0,53
|
||||
7774;6910,1,20;6914,1,15;7698,1,3;-1,0,62
|
||||
7775;6910,1,22;6912,4,16;7686,1,5;-1,0,57
|
||||
7776;6910,2,17;6916,2,19;7697,1,4;-1,0,60
|
||||
7777;6910,2,14;6914,1,6;7698,1,2;7685,1,2;6907,1,10;-1,0,66
|
||||
7778;6910,2,19;6912,4,12;6905,1,7;-1,0,62
|
||||
7779;6910,2,20;6916,2,13;7697,1,2;6906,1,2;-1,0,63
|
||||
7780;6910,2,16;6914,1,27;7698,1,4;7685,1,4;6907,1,1;-1,0,48
|
||||
7781;6910,2,28;6912,4,16;6905,1,5;7686,1,5;-1,0,46
|
||||
7782;6910,2,30;6916,2,22;7697,1,6;6906,1,6;-1,0,36
|
||||
7783;6910,2,36;6914,1,11;6907,1,7;7685,1,1;-1,0,45
|
||||
7784;6910,2,39;6912,4,25;7686,1,4;6905,1,1;-1,0,31
|
||||
7785;6910,2,39;6916,2,14;6906,1,8;7697,1,4;-1,0,35
|
||||
7786;6910,2,20;6914,1,14;7685,1,2;6907,1,2;7698,1,2;-1,0,60
|
||||
7787;6910,2,30;6905,1,5;6912,8,1;7686,1,1;-1,0,63
|
||||
7788;6910,2,37;6916,4,12;6906,1,4;7697,1,4;-1,0,43
|
||||
7789;6910,2,17;6914,2,12;7685,1,6;7698,1,4;6907,1,3;-1,0,58
|
||||
7790;6910,2,23;6912,8,15;6905,1,9;7686,1,7;-1,0,46
|
||||
7791;6910,2,29;6916,4,20;6906,1,8;7697,1,2;-1,0,41
|
||||
7792;6910,1,11;6914,2,22;7685,1,5;6907,1,5;7698,1,3;-1,0,54
|
||||
7793;6910,2,27;6912,8,10;6905,1,5;7686,1,3;-1,0,55
|
||||
7794;6910,2,36;6916,4,24;6906,1,10;7697,1,3;-1,0,27
|
||||
7795;6910,2,34;6914,2,25;6907,1,4;-1,0,37
|
||||
7796;6910,2,11;6912,8,23;7686,1,14;6905,1,5;-1,0,47
|
||||
7797;6910,2,31;6916,4,22;7697,1,6;6906,1,4;-1,0,37
|
||||
7798;6910,1,16;6907,1,12;6914,2,8;7685,1,4;7698,1,4;-1,0,56
|
||||
7799;6910,2,15;6912,8,15;6905,1,7;-1,0,63
|
||||
7800;6910,2,6;6916,4,17;6906,1,13;7697,1,10;-1,0,54
|
||||
7801;6910,1,16;6907,1,12;6914,2,8;7685,1,4;7698,1,4;-1,0,56
|
||||
7802;6910,2,15;6912,8,15;6905,1,7;-1,0,63
|
||||
7803;6910,2,6;6916,4,17;6906,1,13;7697,1,10;-1,0,54
|
||||
7804;6910,1,16;6907,1,12;6914,2,8;7685,1,4;7698,1,4;-1,0,56
|
||||
7805;6910,2,15;6912,8,15;6905,1,7;-1,0,63
|
||||
7806;6910,2,6;6916,4,17;6906,1,13;7697,1,10;-1,0,54
|
||||
8403;6911,2,30;6913,1,21;8353,2,47;-1,0,2
|
||||
8404;6911,2,31;6913,1,20;8353,2,47;-1,0,2
|
||||
8405;6911,2,30;6913,1,20;8353,2,48;-1,0,2
|
||||
8406;6911,2,30;6913,1,20;8353,2,48;-1,0,2
|
||||
8407;6911,2,43;6913,1,24;8353,4,31;-1,0,2
|
||||
8408;6911,2,45;6913,1,24;8353,4,29;-1,0,2
|
||||
8409;6911,2,40;6913,1,26;8353,4,32;-1,0,2
|
||||
8410;6911,2,41;6913,1,26;8353,4,32;-1,0,1
|
||||
8411;6911,4,25;6913,1,29;8353,4,45;-1,0,1
|
||||
8412;6911,2,44;6913,1,31;8359,4,23;-1,0,2
|
||||
8413;6911,2,38;6913,1,31;8359,4,30;-1,0,1
|
||||
8414;6911,2,39;6913,1,26;8359,4,33;-1,0,2
|
||||
8415;6911,2,41;6913,1,26;8359,4,31;-1,0,1
|
||||
8416;6911,4,27;6913,1,39;8359,4,32;-1,0,2
|
||||
8417;6911,4,25;6913,1,39;8359,4,34;-1,0,2
|
||||
8418;6911,4,24;6913,1,37;8359,4,38;-1,0,1
|
||||
8419;6911,4,29;6913,1,33;8359,4,37;-1,0,1
|
||||
8420;6911,4,20;6913,1,35;8359,4,44;-1,0,1
|
||||
8421;6911,4,32;6913,1,41;8355,4,25;-1,0,2
|
||||
8422;6911,4,22;6913,1,45;8355,4,32;-1,0,1
|
||||
8423;6911,4,40;6913,1,35;8355,4,23;-1,0,2
|
||||
8424;6911,4,31;6913,1,35;8355,4,32;-1,0,2
|
||||
8425;6911,4,35;6913,1,38;8355,4,25;-1,0,2
|
||||
8426;6911,4,34;6913,1,42;8355,4,22;-1,0,2
|
||||
8427;6911,4,29;6913,1,37;8355,4,33;-1,0,1
|
||||
8428;6911,4,24;6913,1,45;8355,4,29;-1,0,2
|
||||
8429;6911,4,33;6913,1,45;8355,4,21;-1,0,1
|
||||
8430;6911,4,39;6913,1,35;8354,2,25;-1,0,1
|
||||
8431;6911,4,35;6913,1,36;8354,2,28;-1,0,1
|
||||
8432;6911,4,37;6913,1,33;8354,2,28;-1,0,2
|
||||
8433;6911,8,25;6913,2,25;8354,2,45;-1,0,5
|
||||
8434;6911,8,29;6913,2,28;8354,2,42;-1,0,1
|
||||
8435;6911,8,31;6913,2,25;8354,2,43;-1,0,1
|
||||
8436;6911,8,32;6913,2,24;8354,2,42;-1,0,2
|
||||
8437;6911,8,26;6913,2,29;8354,2,43;-1,0,2
|
||||
8438;6911,8,25;6913,2,31;8354,2,43;-1,0,1
|
||||
8439;6911,8,30;6913,2,38;8357,2,30;-1,0,2
|
||||
8440;6911,8,29;6913,2,41;8357,2,29;-1,0,1
|
||||
8441;6911,8,28;6913,2,39;8357,2,32;-1,0,1
|
||||
8442;6912,4,37;6914,1,36;8357,4,26;-1,0,1
|
||||
8443;6912,4,35;6914,1,29;8357,4,29;8377,1,5;-1,0,2
|
||||
8444;6912,4,28;6914,1,32;8357,4,30;8378,1,8;-1,0,2
|
||||
8445;6912,4,33;6914,1,40;8357,4,25;-1,0,2
|
||||
8446;6912,4,35;6914,1,31;8357,4,27;8377,1,6;-1,0,1
|
||||
8447;6912,4,27;6914,1,28;8357,4,32;8378,1,10;-1,0,3
|
||||
8448;6912,8,21;6914,1,40;8358,2,37;-1,0,2
|
||||
8449;6912,8,20;6914,1,34;8358,2,36;8377,1,9;-1,0,1
|
||||
8450;6912,8,20;6914,1,31;8358,2,39;8378,1,8;-1,0,2
|
||||
8451;6912,8,28;6914,1,36;8358,2,34;-1,0,2
|
||||
8452;6912,8,25;6914,1,28;8358,2,38;8377,1,8;-1,0,1
|
||||
8453;6912,8,39;6914,1,26;8358,4,23;8378,1,10;-1,0,2
|
||||
8454;6912,9,34;6914,2,30;8358,4,34;-1,0,2
|
||||
8455;6912,8,32;6914,2,26;8358,4,28;8377,1,12;-1,0,2
|
||||
8456;6912,8,35;6914,2,24;8358,4,27;8378,1,11;-1,0,3
|
||||
8457;6912,9,33;6914,2,35;8352,4,31;-1,0,1
|
||||
8458;6912,9,29;6914,2,30;8352,4,27;8377,1,12;-1,0,2
|
||||
8459;6912,9,28;6914,2,27;8352,4,31;8378,1,12;-1,0,2
|
||||
8460;6912,8,41;6914,2,27;8352,4,26;8373,1,4;-1,0,2
|
||||
8461;6912,8,35;6914,2,27;8352,4,22;8374,1,2;8377,1,12;-1,0,2
|
||||
8462;6912,8,32;6914,2,25;8352,4,25;8375,1,4;8378,1,11;-1,0,3
|
||||
8463;6912,9,29;6914,2,36;8352,4,30;8373,1,3;-1,0,2
|
||||
8464;6912,9,25;6914,2,29;8352,4,29;8374,1,2;8377,1,12;-1,0,3
|
||||
8465;6912,9,26;6914,2,30;8352,4,25;8375,1,2;8378,1,15;-1,0,2
|
||||
8466;6912,9,28;6914,2,38;8356,4,29;8373,1,3;-1,0,2
|
||||
8467;6912,9,24;6914,2,29;8356,4,24;8374,1,4;8377,1,16;-1,0,3
|
||||
8468;6912,9,29;6914,2,32;8356,4,26;8375,1,3;8378,1,9;-1,0,1
|
||||
8469;6912,9,30;6914,2,35;8356,4,27;8373,1,5;-1,0,3
|
||||
8470;6912,9,27;6914,2,29;8356,4,22;8374,1,3;8377,1,17;-1,0,2
|
||||
8471;6912,9,27;6914,2,30;8356,4,23;8375,1,4;8378,1,15;-1,0,1
|
||||
8472;6912,9,33;6914,2,37;8356,4,26;8373,1,2;-1,0,2
|
||||
8473;6912,9,29;6914,2,29;8356,4,20;8374,1,3;8377,1,16;-1,0,3
|
||||
8474;6912,9,25;6914,2,29;8356,4,27;8375,1,3;8378,1,14;-1,0,2
|
||||
8475;6912,9,31;6914,2,38;8351,4,25;8373,1,4;-1,0,2
|
||||
8476;6912,9,30;6914,4,22;8351,4,25;8374,1,5;8377,1,16;-1,0,2
|
||||
8477;6912,9,33;6914,4,17;8351,4,26;8375,1,4;8378,1,17;-1,0,3
|
||||
8478;6912,18,27;6914,4,24;8351,4,42;8373,1,5;-1,0,2
|
||||
8479;6912,18,15;6914,4,23;8351,4,29;8374,1,6;8377,1,25;-1,0,2
|
||||
8480;6912,18,19;6914,4,22;8351,4,31;8375,1,5;8378,1,21;-1,0,2
|
||||
8481;6912,18,31;6914,4,24;8351,4,38;8373,1,5;-1,0,2
|
||||
8482;6912,18,14;6914,4,24;8351,4,40;8374,1,4;8377,1,15;-1,0,3
|
||||
8483;6912,18,30;6914,4,22;8351,7,17;8375,1,5;8378,1,24;-1,0,2
|
|
@ -1,10 +0,0 @@
|
||||
<html>
|
||||
<head><title>Unpack</title>
|
||||
</head><body>
|
||||
You have %count% <font color="LEVEL">%itemname%</font><br>
|
||||
What you want to do?<br><center>
|
||||
<a action="bypass -h custom_extractAll %objectId%">Extract All</a><br1>
|
||||
<a action="bypass -h custom_extractOne %objectId%">Extract One</a>
|
||||
</center>
|
||||
</body>
|
||||
</html>
|
26
L2J_Mobius_C6_Interlude/dist/game/data/xsd/ExtractableItems.xsd
vendored
Normal file
26
L2J_Mobius_C6_Interlude/dist/game/data/xsd/ExtractableItems.xsd
vendored
Normal file
@ -0,0 +1,26 @@
|
||||
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
|
||||
<xs:element name="list">
|
||||
<xs:complexType>
|
||||
<xs:sequence>
|
||||
<xs:element name="item" maxOccurs="unbounded" minOccurs="0">
|
||||
<xs:complexType>
|
||||
<xs:sequence>
|
||||
<xs:element name="extract" maxOccurs="unbounded" minOccurs="0">
|
||||
<xs:complexType>
|
||||
<xs:simpleContent>
|
||||
<xs:extension base="xs:string">
|
||||
<xs:attribute type="xs:short" name="id" use="required"/>
|
||||
<xs:attribute type="xs:int" name="quantity" use="required"/>
|
||||
<xs:attribute type="xs:float" name="chance" use="required"/>
|
||||
</xs:extension>
|
||||
</xs:simpleContent>
|
||||
</xs:complexType>
|
||||
</xs:element>
|
||||
</xs:sequence>
|
||||
<xs:attribute type="xs:short" name="id" use="required"/>
|
||||
</xs:complexType>
|
||||
</xs:element>
|
||||
</xs:sequence>
|
||||
</xs:complexType>
|
||||
</xs:element>
|
||||
</xs:schema>
|
@ -47,7 +47,6 @@ import org.l2jmobius.gameserver.datatables.NobleSkillTable;
|
||||
import org.l2jmobius.gameserver.datatables.OfflineTradeTable;
|
||||
import org.l2jmobius.gameserver.datatables.SchemeBufferTable;
|
||||
import org.l2jmobius.gameserver.datatables.SkillTable;
|
||||
import org.l2jmobius.gameserver.datatables.csv.ExtractableItemData;
|
||||
import org.l2jmobius.gameserver.datatables.csv.MapRegionTable;
|
||||
import org.l2jmobius.gameserver.datatables.csv.NpcWalkerRouteTable;
|
||||
import org.l2jmobius.gameserver.datatables.sql.CharNameTable;
|
||||
@ -67,6 +66,7 @@ import org.l2jmobius.gameserver.datatables.xml.AugmentationData;
|
||||
import org.l2jmobius.gameserver.datatables.xml.BoatData;
|
||||
import org.l2jmobius.gameserver.datatables.xml.DoorData;
|
||||
import org.l2jmobius.gameserver.datatables.xml.ExperienceData;
|
||||
import org.l2jmobius.gameserver.datatables.xml.ExtractableItemData;
|
||||
import org.l2jmobius.gameserver.datatables.xml.FenceData;
|
||||
import org.l2jmobius.gameserver.datatables.xml.FishData;
|
||||
import org.l2jmobius.gameserver.datatables.xml.HennaData;
|
||||
|
@ -1,175 +0,0 @@
|
||||
/*
|
||||
* This file is part of the L2J Mobius project.
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
package org.l2jmobius.gameserver.datatables.csv;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Scanner;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import org.l2jmobius.Config;
|
||||
import org.l2jmobius.gameserver.model.ExtractableItem;
|
||||
import org.l2jmobius.gameserver.model.ExtractableProductItem;
|
||||
|
||||
/**
|
||||
* @author FBIagent
|
||||
*/
|
||||
public class ExtractableItemData
|
||||
{
|
||||
private static final Logger LOGGER = Logger.getLogger(ExtractableItemData.class.getName());
|
||||
|
||||
// Map<itemid, ExtractableItem>
|
||||
private Map<Integer, ExtractableItem> _items;
|
||||
|
||||
public ExtractableItemData()
|
||||
{
|
||||
_items = new HashMap<>();
|
||||
|
||||
Scanner s = null;
|
||||
try
|
||||
{
|
||||
s = new Scanner(new File(Config.DATAPACK_ROOT + "/data/csv/extractable_items.csv"));
|
||||
|
||||
int lineCount = 0;
|
||||
while (s.hasNextLine())
|
||||
{
|
||||
lineCount++;
|
||||
|
||||
final String line = s.nextLine();
|
||||
|
||||
if (line.startsWith("#"))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
else if (line.equals(""))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
final String[] lineSplit = line.split(";");
|
||||
int itemID = 0;
|
||||
try
|
||||
{
|
||||
itemID = Integer.parseInt(lineSplit[0]);
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
LOGGER.info("Extractable items data: Error in line " + lineCount + " -> invalid item id or wrong seperator after item id!");
|
||||
LOGGER.info(" " + line);
|
||||
return;
|
||||
}
|
||||
|
||||
final List<ExtractableProductItem> productTemp = new ArrayList<>(lineSplit.length);
|
||||
for (int i = 0; i < (lineSplit.length - 1); i++)
|
||||
{
|
||||
final String[] lineSplit2 = lineSplit[i + 1].split(",");
|
||||
if (lineSplit2.length != 3)
|
||||
{
|
||||
LOGGER.info("Extractable items data: Error in line " + lineCount + " -> wrong seperator!");
|
||||
LOGGER.info(" " + line);
|
||||
continue;
|
||||
}
|
||||
|
||||
int production = 0;
|
||||
int amount = 0;
|
||||
int chance = 0;
|
||||
|
||||
try
|
||||
{
|
||||
production = Integer.parseInt(lineSplit2[0]);
|
||||
amount = Integer.parseInt(lineSplit2[1]);
|
||||
chance = Integer.parseInt(lineSplit2[2]);
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
LOGGER.info("Extractable items data: Error in line " + lineCount + " -> incomplete/invalid production data or wrong seperator!");
|
||||
LOGGER.info(" " + line);
|
||||
continue;
|
||||
}
|
||||
|
||||
productTemp.add(new ExtractableProductItem(production, amount, chance));
|
||||
}
|
||||
|
||||
int fullChances = 0;
|
||||
for (ExtractableProductItem Pi : productTemp)
|
||||
{
|
||||
fullChances += Pi.getChance();
|
||||
}
|
||||
|
||||
if (fullChances > 100)
|
||||
{
|
||||
LOGGER.info("Extractable items data: Error in line " + lineCount + " -> all chances together are more then 100!");
|
||||
LOGGER.info(" " + line);
|
||||
continue;
|
||||
}
|
||||
|
||||
_items.put(itemID, new ExtractableItem(itemID, productTemp));
|
||||
}
|
||||
|
||||
LOGGER.info("Extractable items data: Loaded " + _items.size() + " extractable items!");
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
LOGGER.info("Extractable items data: Can not find './data/csv/extractable_items.csv'");
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (s != null)
|
||||
{
|
||||
try
|
||||
{
|
||||
s.close();
|
||||
}
|
||||
catch (Exception e1)
|
||||
{
|
||||
LOGGER.warning("Problem with ExtractableItemsData: " + e1.getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public ExtractableItem getExtractableItem(int itemID)
|
||||
{
|
||||
return _items.get(itemID);
|
||||
}
|
||||
|
||||
public int[] itemIDs()
|
||||
{
|
||||
final int size = _items.size();
|
||||
final int[] result = new int[size];
|
||||
int i = 0;
|
||||
for (ExtractableItem ei : _items.values())
|
||||
{
|
||||
result[i] = ei.getItemId();
|
||||
i++;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public static ExtractableItemData getInstance()
|
||||
{
|
||||
return SingletonHolder.INSTANCE;
|
||||
}
|
||||
|
||||
private static class SingletonHolder
|
||||
{
|
||||
protected static final ExtractableItemData INSTANCE = new ExtractableItemData();
|
||||
}
|
||||
}
|
@ -0,0 +1,136 @@
|
||||
/*
|
||||
* This file is part of the L2J Mobius project.
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
package org.l2jmobius.gameserver.datatables.xml;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.w3c.dom.Document;
|
||||
import org.w3c.dom.NamedNodeMap;
|
||||
import org.w3c.dom.Node;
|
||||
|
||||
import org.l2jmobius.commons.util.IXmlReader;
|
||||
import org.l2jmobius.gameserver.model.ExtractableItem;
|
||||
import org.l2jmobius.gameserver.model.ExtractableProductItem;
|
||||
import org.l2jmobius.gameserver.model.StatSet;
|
||||
|
||||
/**
|
||||
* @author Mobius
|
||||
*/
|
||||
public class ExtractableItemData implements IXmlReader
|
||||
{
|
||||
private final Map<Integer, ExtractableItem> _items = new HashMap<>();
|
||||
|
||||
protected ExtractableItemData()
|
||||
{
|
||||
load();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void load()
|
||||
{
|
||||
_items.clear();
|
||||
parseDatapackFile("data/ExtractableItems.xml");
|
||||
}
|
||||
|
||||
@Override
|
||||
public void parseDocument(Document doc, File f)
|
||||
{
|
||||
try
|
||||
{
|
||||
int id;
|
||||
int amount;
|
||||
int production;
|
||||
float totalChance;
|
||||
float chance;
|
||||
final StatSet set = new StatSet();
|
||||
|
||||
final Node n = doc.getFirstChild();
|
||||
for (Node node = n.getFirstChild(); node != null; node = node.getNextSibling())
|
||||
{
|
||||
if ("item".equalsIgnoreCase(node.getNodeName()))
|
||||
{
|
||||
id = Integer.parseInt(node.getAttributes().getNamedItem("id").getNodeValue());
|
||||
final List<ExtractableProductItem> extractables = new ArrayList<>();
|
||||
for (Node b = node.getFirstChild(); b != null; b = b.getNextSibling())
|
||||
{
|
||||
if ("extract".equalsIgnoreCase(b.getNodeName()))
|
||||
{
|
||||
final NamedNodeMap attrs = b.getAttributes();
|
||||
for (int i = 0; i < attrs.getLength(); i++)
|
||||
{
|
||||
final Node attr = attrs.item(i);
|
||||
set.set(attr.getNodeName(), attr.getNodeValue());
|
||||
}
|
||||
|
||||
production = set.getInt("id");
|
||||
amount = set.getInt("quantity");
|
||||
chance = set.getFloat("chance");
|
||||
extractables.add(new ExtractableProductItem(production, amount, chance));
|
||||
|
||||
totalChance = 0;
|
||||
for (ExtractableProductItem extractable : extractables)
|
||||
{
|
||||
totalChance += extractable.getChance();
|
||||
}
|
||||
if (totalChance > 100)
|
||||
{
|
||||
LOGGER.info(getClass().getSimpleName() + ": Extractable with id " + id + " has was more than 100% total chance!");
|
||||
}
|
||||
}
|
||||
}
|
||||
_items.put(id, new ExtractableItem(id, extractables));
|
||||
}
|
||||
}
|
||||
|
||||
LOGGER.info(getClass().getSimpleName() + ": Loaded " + _items.size() + " extractable items.");
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
LOGGER.warning(getClass().getSimpleName() + ": Error while loading extractable items! " + e);
|
||||
}
|
||||
}
|
||||
|
||||
public ExtractableItem getExtractableItem(int itemId)
|
||||
{
|
||||
return _items.get(itemId);
|
||||
}
|
||||
|
||||
public int[] getAllItemIds()
|
||||
{
|
||||
int index = 0;
|
||||
final int[] ids = new int[_items.size()];
|
||||
for (ExtractableItem recipe : _items.values())
|
||||
{
|
||||
ids[index++] = recipe.getItemId();
|
||||
}
|
||||
return ids;
|
||||
}
|
||||
|
||||
public static ExtractableItemData getInstance()
|
||||
{
|
||||
return SingletonHolder.INSTANCE;
|
||||
}
|
||||
|
||||
private static class SingletonHolder
|
||||
{
|
||||
protected static final ExtractableItemData INSTANCE = new ExtractableItemData();
|
||||
}
|
||||
}
|
@ -1,106 +0,0 @@
|
||||
/*
|
||||
* This file is part of the L2J Mobius project.
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
package org.l2jmobius.gameserver.handler.custom;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import org.l2jmobius.Config;
|
||||
import org.l2jmobius.gameserver.handler.ICustomByPassHandler;
|
||||
import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
|
||||
import org.l2jmobius.gameserver.model.entity.Rebirth;
|
||||
|
||||
/**
|
||||
* This 'Bypass Handler' is a handy tool indeed!<br>
|
||||
* Basically, you can send any custom bypass commmands to it from ANY npc and it will call the appropriate function.<br>
|
||||
* <strong>Example:</strong><br>
|
||||
* <button value=" Request Rebirth " action="bypass -h custom_rebirth_confirmrequest" width=110 height=36 back="L2UI_ct1.button_df" fore="L2UI_ct1.button_df">
|
||||
* @author JStar
|
||||
*/
|
||||
public class CustomBypassHandler
|
||||
{
|
||||
private static final Logger LOGGER = Logger.getLogger(CustomBypassHandler.class.getName());
|
||||
|
||||
private final Map<String, ICustomByPassHandler> _handlers;
|
||||
|
||||
private CustomBypassHandler()
|
||||
{
|
||||
_handlers = new HashMap<>();
|
||||
registerCustomBypassHandler(new ExtractableByPassHandler());
|
||||
}
|
||||
|
||||
/**
|
||||
* @param handler as ICustomByPassHandler
|
||||
*/
|
||||
private void registerCustomBypassHandler(ICustomByPassHandler handler)
|
||||
{
|
||||
for (String s : handler.getByPassCommands())
|
||||
{
|
||||
_handlers.put(s, handler);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Handles player's Bypass request to the Custom Content.
|
||||
* @param player
|
||||
* @param command
|
||||
*/
|
||||
public void handleBypass(PlayerInstance player, String command)
|
||||
{
|
||||
// Rebirth Manager and Engine Caller
|
||||
|
||||
String cmd = "";
|
||||
String params = "";
|
||||
final int iPos = command.indexOf(' ');
|
||||
if (iPos != -1)
|
||||
{
|
||||
cmd = command.substring(7, iPos);
|
||||
params = command.substring(iPos + 1);
|
||||
}
|
||||
else
|
||||
{
|
||||
cmd = command.substring(7);
|
||||
}
|
||||
final ICustomByPassHandler ch = _handlers.get(cmd);
|
||||
if (ch != null)
|
||||
{
|
||||
ch.handleCommand(cmd, player, params);
|
||||
}
|
||||
else if (command.startsWith("custom_rebirth"))
|
||||
{
|
||||
// Check to see if Rebirth is enabled to avoid hacks
|
||||
if (!Config.REBIRTH_ENABLE)
|
||||
{
|
||||
LOGGER.warning("[WARNING] Player " + player.getName() + " is trying to use rebirth system when it's disabled.");
|
||||
return;
|
||||
}
|
||||
|
||||
Rebirth.getInstance().handleCommand(player, command);
|
||||
}
|
||||
}
|
||||
|
||||
public static CustomBypassHandler getInstance()
|
||||
{
|
||||
return SingletonHolder.INSTANCE;
|
||||
}
|
||||
|
||||
private static class SingletonHolder
|
||||
{
|
||||
protected static final CustomBypassHandler INSTANCE = new CustomBypassHandler();
|
||||
}
|
||||
}
|
@ -1,65 +0,0 @@
|
||||
/*
|
||||
* This file is part of the L2J Mobius project.
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
package org.l2jmobius.gameserver.handler.custom;
|
||||
|
||||
import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
|
||||
import org.l2jmobius.gameserver.model.entity.Rebirth;
|
||||
|
||||
/**
|
||||
* This will simply manage any custom 'Enter World callers' needed.<br>
|
||||
* Rather then having to add them to the core's. (yuck!)
|
||||
* @author JStar
|
||||
*/
|
||||
public class CustomWorldHandler
|
||||
{
|
||||
private CustomWorldHandler()
|
||||
{
|
||||
// Do Nothing ^_-
|
||||
}
|
||||
|
||||
/**
|
||||
* Requests entry into the world - manages appropriately.
|
||||
* @param player
|
||||
*/
|
||||
public void enterWorld(PlayerInstance player)
|
||||
{
|
||||
// Rebirth's skills must be actived only on main class
|
||||
if (!player.isSubClassActive())
|
||||
{
|
||||
Rebirth.getInstance().grantRebirthSkills(player); // Rebirth Caller - if player has any skills, they will be granted them.
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Requests removal from the world - manages appropriately.
|
||||
* @param player
|
||||
*/
|
||||
public void exitWorld(PlayerInstance player)
|
||||
{
|
||||
// TODO: Remove the rebirth engine's bonus skills from player?
|
||||
}
|
||||
|
||||
public static CustomWorldHandler getInstance()
|
||||
{
|
||||
return SingletonHolder.INSTANCE;
|
||||
}
|
||||
|
||||
private static class SingletonHolder
|
||||
{
|
||||
protected static final CustomWorldHandler INSTANCE = new CustomWorldHandler();
|
||||
}
|
||||
}
|
@ -1,76 +0,0 @@
|
||||
/*
|
||||
* This file is part of the L2J Mobius project.
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
package org.l2jmobius.gameserver.handler.custom;
|
||||
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import org.l2jmobius.gameserver.handler.ICustomByPassHandler;
|
||||
import org.l2jmobius.gameserver.handler.IItemHandler;
|
||||
import org.l2jmobius.gameserver.handler.ItemHandler;
|
||||
import org.l2jmobius.gameserver.handler.itemhandlers.ExtractableItems;
|
||||
import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
|
||||
import org.l2jmobius.gameserver.model.items.instance.ItemInstance;
|
||||
|
||||
/**
|
||||
* @author Nick
|
||||
*/
|
||||
public class ExtractableByPassHandler implements ICustomByPassHandler
|
||||
{
|
||||
protected static final Logger LOGGER = Logger.getLogger(ExtractableByPassHandler.class.getName());
|
||||
private static String[] _IDS =
|
||||
{
|
||||
"extractOne",
|
||||
"extractAll"
|
||||
};
|
||||
|
||||
@Override
|
||||
public String[] getByPassCommands()
|
||||
{
|
||||
return _IDS;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void handleCommand(String command, PlayerInstance player, String parameters)
|
||||
{
|
||||
try
|
||||
{
|
||||
final int objId = Integer.parseInt(parameters);
|
||||
final ItemInstance item = player.getInventory().getItemByObjectId(objId);
|
||||
if (item == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
final IItemHandler ih = ItemHandler.getInstance().getItemHandler(item.getItemId());
|
||||
if (!(ih instanceof ExtractableItems))
|
||||
{
|
||||
return;
|
||||
}
|
||||
if (command.compareTo(_IDS[0]) == 0)
|
||||
{
|
||||
((ExtractableItems) ih).doExtract(player, item, 1);
|
||||
}
|
||||
else if (command.compareTo(_IDS[1]) == 0)
|
||||
{
|
||||
((ExtractableItems) ih).doExtract(player, item, item.getCount());
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
LOGGER.warning("ExtractableByPassHandler: Error while running " + e);
|
||||
}
|
||||
}
|
||||
}
|
@ -19,9 +19,8 @@ package org.l2jmobius.gameserver.handler.itemhandlers;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import org.l2jmobius.commons.util.Rnd;
|
||||
import org.l2jmobius.gameserver.cache.HtmCache;
|
||||
import org.l2jmobius.gameserver.datatables.ItemTable;
|
||||
import org.l2jmobius.gameserver.datatables.csv.ExtractableItemData;
|
||||
import org.l2jmobius.gameserver.datatables.xml.ExtractableItemData;
|
||||
import org.l2jmobius.gameserver.handler.IItemHandler;
|
||||
import org.l2jmobius.gameserver.model.ExtractableItem;
|
||||
import org.l2jmobius.gameserver.model.ExtractableProductItem;
|
||||
@ -29,7 +28,6 @@ import org.l2jmobius.gameserver.model.actor.Playable;
|
||||
import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
|
||||
import org.l2jmobius.gameserver.model.items.instance.ItemInstance;
|
||||
import org.l2jmobius.gameserver.network.SystemMessageId;
|
||||
import org.l2jmobius.gameserver.network.serverpackets.NpcHtmlMessage;
|
||||
import org.l2jmobius.gameserver.network.serverpackets.SystemMessage;
|
||||
|
||||
/**
|
||||
@ -39,93 +37,7 @@ public class ExtractableItems implements IItemHandler
|
||||
{
|
||||
private static final Logger LOGGER = Logger.getLogger(ExtractableItems.class.getName());
|
||||
|
||||
public void doExtract(Playable playable, ItemInstance item, int count)
|
||||
{
|
||||
if (!(playable instanceof PlayerInstance))
|
||||
{
|
||||
return;
|
||||
}
|
||||
final PlayerInstance player = (PlayerInstance) playable;
|
||||
final int itemID = item.getItemId();
|
||||
|
||||
if (count > item.getCount())
|
||||
{
|
||||
return;
|
||||
}
|
||||
while (count-- > 0)
|
||||
{
|
||||
final ExtractableItem exitem = ExtractableItemData.getInstance().getExtractableItem(itemID);
|
||||
if (exitem == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int createItemID = 0;
|
||||
int createAmount = 0;
|
||||
final int rndNum = Rnd.get(100);
|
||||
int chanceFrom = 0;
|
||||
for (ExtractableProductItem expi : exitem.getProductItems())
|
||||
{
|
||||
final int chance = expi.getChance();
|
||||
|
||||
if ((rndNum >= chanceFrom) && (rndNum <= (chance + chanceFrom)))
|
||||
{
|
||||
createItemID = expi.getId();
|
||||
createAmount = expi.getAmmount();
|
||||
break;
|
||||
}
|
||||
|
||||
chanceFrom += chance;
|
||||
}
|
||||
|
||||
if (createItemID == 0)
|
||||
{
|
||||
player.sendMessage("Nothing happened.");
|
||||
return;
|
||||
}
|
||||
|
||||
if (createItemID > 0)
|
||||
{
|
||||
if (ItemTable.getInstance().createDummyItem(createItemID) == null)
|
||||
{
|
||||
LOGGER.warning("createItemID " + createItemID + " doesn't have template!");
|
||||
player.sendMessage("Nothing happened.");
|
||||
return;
|
||||
}
|
||||
|
||||
if (ItemTable.getInstance().createDummyItem(createItemID).isStackable())
|
||||
{
|
||||
player.addItem("Extract", createItemID, createAmount, item, false);
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int i = 0; i < createAmount; i++)
|
||||
{
|
||||
player.addItem("Extract", createItemID, 1, item, false);
|
||||
}
|
||||
}
|
||||
SystemMessage sm;
|
||||
|
||||
if (createAmount > 1)
|
||||
{
|
||||
sm = new SystemMessage(SystemMessageId.EARNED_S2_S1_S);
|
||||
sm.addItemName(createItemID);
|
||||
sm.addNumber(createAmount);
|
||||
}
|
||||
else
|
||||
{
|
||||
sm = new SystemMessage(SystemMessageId.EARNED_ITEM);
|
||||
sm.addItemName(createItemID);
|
||||
}
|
||||
player.sendPacket(sm);
|
||||
}
|
||||
else
|
||||
{
|
||||
player.sendMessage("Item failed to open"); // TODO: Put a more proper message here.
|
||||
}
|
||||
|
||||
player.destroyItemByItemId("Extract", itemID, 1, player.getTarget(), true);
|
||||
}
|
||||
}
|
||||
private static final int[] ITEM_IDS = ExtractableItemData.getInstance().getAllItemIds();
|
||||
|
||||
@Override
|
||||
public void useItem(Playable playable, ItemInstance item)
|
||||
@ -134,30 +46,78 @@ public class ExtractableItems implements IItemHandler
|
||||
{
|
||||
return;
|
||||
}
|
||||
if (item.getCount() > 1)
|
||||
final PlayerInstance player = (PlayerInstance) playable;
|
||||
final int itemId = item.getItemId();
|
||||
|
||||
final ExtractableItem extractable = ExtractableItemData.getInstance().getExtractableItem(itemId);
|
||||
if (extractable == null)
|
||||
{
|
||||
String message = HtmCache.getInstance().getHtm("data/html/others/extractable.htm");
|
||||
if (message == null)
|
||||
return;
|
||||
}
|
||||
|
||||
// Destroy item first.
|
||||
player.destroyItemByItemId("Extract", itemId, 1, player.getTarget(), true);
|
||||
|
||||
int createItemId = 0;
|
||||
int createAmount = 0;
|
||||
float chanceFrom = 0;
|
||||
final float random = Rnd.get(100);
|
||||
for (ExtractableProductItem expi : extractable.getProductItems())
|
||||
{
|
||||
final float chance = expi.getChance();
|
||||
if ((random >= chanceFrom) && (random <= (chance + chanceFrom)))
|
||||
{
|
||||
doExtract(playable, item, 1);
|
||||
createItemId = expi.getId();
|
||||
createAmount = expi.getAmmount();
|
||||
break;
|
||||
}
|
||||
chanceFrom += chance;
|
||||
}
|
||||
|
||||
if (createItemId > 0)
|
||||
{
|
||||
if (ItemTable.getInstance().createDummyItem(createItemId) == null)
|
||||
{
|
||||
LOGGER.warning("Extractable item with id " + createItemId + " does not have a template!");
|
||||
player.sendMessage("Nothing happened.");
|
||||
return;
|
||||
}
|
||||
|
||||
if (ItemTable.getInstance().createDummyItem(createItemId).isStackable())
|
||||
{
|
||||
player.addItem("Extract", createItemId, createAmount, item, false);
|
||||
}
|
||||
else
|
||||
{
|
||||
message = message.replace("%objectId%", String.valueOf(item.getObjectId()));
|
||||
message = message.replace("%itemname%", item.getItemName());
|
||||
message = message.replace("%count%", String.valueOf(item.getCount()));
|
||||
playable.sendPacket(new NpcHtmlMessage(5, message));
|
||||
for (int i = 0; i < createAmount; i++)
|
||||
{
|
||||
player.addItem("Extract", createItemId, 1, item, false);
|
||||
}
|
||||
}
|
||||
|
||||
SystemMessage sm;
|
||||
if (createAmount > 1)
|
||||
{
|
||||
sm = new SystemMessage(SystemMessageId.EARNED_S2_S1_S);
|
||||
sm.addItemName(createItemId);
|
||||
sm.addNumber(createAmount);
|
||||
}
|
||||
else
|
||||
{
|
||||
sm = new SystemMessage(SystemMessageId.EARNED_ITEM);
|
||||
sm.addItemName(createItemId);
|
||||
}
|
||||
player.sendPacket(sm);
|
||||
}
|
||||
else
|
||||
{
|
||||
doExtract(playable, item, 1);
|
||||
player.sendMessage("Nothing happened.");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public int[] getItemIds()
|
||||
{
|
||||
return ExtractableItemData.getInstance().itemIDs();
|
||||
return ITEM_IDS;
|
||||
}
|
||||
}
|
@ -23,9 +23,9 @@ public class ExtractableProductItem
|
||||
{
|
||||
private final int _id;
|
||||
private final int _ammount;
|
||||
private final int _chance;
|
||||
private final float _chance;
|
||||
|
||||
public ExtractableProductItem(int id, int ammount, int chance)
|
||||
public ExtractableProductItem(int id, int ammount, float chance)
|
||||
{
|
||||
_id = id;
|
||||
_ammount = ammount;
|
||||
@ -42,7 +42,7 @@ public class ExtractableProductItem
|
||||
return _ammount;
|
||||
}
|
||||
|
||||
public int getChance()
|
||||
public float getChance()
|
||||
{
|
||||
return _chance;
|
||||
}
|
||||
|
@ -34,7 +34,6 @@ import org.l2jmobius.gameserver.communitybbs.Manager.MailBBSManager;
|
||||
import org.l2jmobius.gameserver.datatables.SkillTable;
|
||||
import org.l2jmobius.gameserver.datatables.csv.MapRegionTable;
|
||||
import org.l2jmobius.gameserver.datatables.xml.AdminData;
|
||||
import org.l2jmobius.gameserver.handler.custom.CustomWorldHandler;
|
||||
import org.l2jmobius.gameserver.instancemanager.CastleManager;
|
||||
import org.l2jmobius.gameserver.instancemanager.ClanHallManager;
|
||||
import org.l2jmobius.gameserver.instancemanager.CoupleManager;
|
||||
@ -53,6 +52,7 @@ import org.l2jmobius.gameserver.model.clan.Clan;
|
||||
import org.l2jmobius.gameserver.model.entity.Announcements;
|
||||
import org.l2jmobius.gameserver.model.entity.ClanHall;
|
||||
import org.l2jmobius.gameserver.model.entity.Hero;
|
||||
import org.l2jmobius.gameserver.model.entity.Rebirth;
|
||||
import org.l2jmobius.gameserver.model.entity.Wedding;
|
||||
import org.l2jmobius.gameserver.model.entity.event.CTF;
|
||||
import org.l2jmobius.gameserver.model.entity.event.DM;
|
||||
@ -431,7 +431,11 @@ public class EnterWorld extends GameClientPacket
|
||||
player.sendMessage("You have been teleported to the nearest town due to you being in siege zone");
|
||||
}
|
||||
|
||||
CustomWorldHandler.getInstance().enterWorld(player);
|
||||
// Rebirth's skills must be actived only on main class
|
||||
if (Config.REBIRTH_ENABLE && !player.isSubClassActive())
|
||||
{
|
||||
Rebirth.getInstance().grantRebirthSkills(player);
|
||||
}
|
||||
|
||||
if (TvT._savePlayers.contains(player.getName()))
|
||||
{
|
||||
|
@ -24,7 +24,6 @@ import org.l2jmobius.gameserver.communitybbs.CommunityBoard;
|
||||
import org.l2jmobius.gameserver.datatables.xml.AdminData;
|
||||
import org.l2jmobius.gameserver.handler.AdminCommandHandler;
|
||||
import org.l2jmobius.gameserver.handler.IAdminCommandHandler;
|
||||
import org.l2jmobius.gameserver.handler.custom.CustomBypassHandler;
|
||||
import org.l2jmobius.gameserver.model.Location;
|
||||
import org.l2jmobius.gameserver.model.World;
|
||||
import org.l2jmobius.gameserver.model.WorldObject;
|
||||
@ -293,7 +292,6 @@ public class RequestBypassToServer extends GameClientPacket
|
||||
|
||||
final String p = _command.substring(6).trim();
|
||||
final int idx = p.indexOf(' ');
|
||||
|
||||
if (idx < 0)
|
||||
{
|
||||
player.processQuestEvent(p, "");
|
||||
@ -304,12 +302,7 @@ public class RequestBypassToServer extends GameClientPacket
|
||||
}
|
||||
}
|
||||
|
||||
// Jstar's Custom Bypass Caller!
|
||||
else if (_command.startsWith("custom_"))
|
||||
{
|
||||
CustomBypassHandler.getInstance().handleBypass(player, _command);
|
||||
}
|
||||
else if (_command.startsWith("OlympiadArenaChange"))
|
||||
if (_command.startsWith("OlympiadArenaChange"))
|
||||
{
|
||||
Olympiad.bypassChangeArena(_command, player);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user