Advertisement
Baoulettes

Dokkan UR listing

Mar 17th, 2019
190
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 4.90 KB | None | 0 0
  1. <?php
  2. $Date           =   date("Y").'-'.date("m").'-'.date("d").' '.date("H:i:s").'.'.date("Y").'01';
  3. $File           =   file_get_contents("./cards.json");
  4. $Json           =   json_decode($File, true);
  5. $ID             =   0;
  6. $MaxCardID      =   1999999; //Any other highter than it is boss etc.
  7. $GradeWanted    =   4; //5=LR 4=UR 3=SSR 2=SR 1=R 0=N
  8. $SQLBegin       =   'INSERT INTO "main"."collection_cards" ("id", "collection_unique_id", "card_id", "event_id", "priority", "created_at", "updated_at") VALUES (';
  9. //AGI
  10. $Type0Unique    =   392; //AGI Unused as ur
  11. $Type10Unique   =   393; //Super AGI
  12. $Type20Unique   =   394; //Extreme AGI
  13. $Type0Priority  =   1000;
  14. $Type10Priority =   1000;
  15. $Type20Priority =   1000;
  16.  
  17. //TEC
  18. $Type1Unique    =   392; //TEC Unused as ur
  19. $Type11Unique   =   395; //Super TEC
  20. $Type21Unique   =   396; //Extreme TEC
  21. $Type1Priority  =   1000;
  22. $Type11Priority =   1000;
  23. $Type21Priority =   1000;
  24.  
  25. //INT
  26. $Type2Unique    =   392; //INT Unused as ur
  27. $Type12Unique   =   397; //Super INT
  28. $Type22Unique   =   398; //Extreme INT
  29. $Type2Priority  =   1000;
  30. $Type12Priority =   1000;
  31. $Type22Priority =   1000;
  32.  
  33. //PUI
  34. $Type3Unique    =   392; //PUI Unused as ur
  35. $Type13Unique   =   399; //Super PUI
  36. $Type23Unique   =   400; //Extreme PUI
  37. $Type3Priority  =   1000;
  38. $Type13Priority =   1000;
  39. $Type23Priority =   1000;
  40.  
  41. //END
  42. $Type4Unique    =   392; //END Unused as ur
  43. $Type14Unique   =   401; //Super END
  44. $Type24Unique   =   402; //Extreme END
  45. $Type4Priority  =   1000;
  46. $Type14Priority =   1000;
  47. $Type24Priority =   1000;
  48.  
  49. /*****************************************************\
  50. Element :
  51. 0=392   =  10   =   20
  52. 1=393   =  11   =   21 
  53. 2=394   =  12   =   22
  54. 3=395   =  13   =   23
  55. 4=396   =  14   =   24
  56. \*****************************************************/
  57. foreach($Json as $Count) {
  58.     $CharID     =   $Json[$ID]['id'];
  59.     $Type       =   $Json[$ID]['element'];
  60.     $Grade      =   $Json[$ID]['rarity'];
  61.     if ($CharID<=$MaxCardID) {
  62.         if ($Grade == $GradeWanted){
  63.             //AGI
  64.             if ($Type == 0){
  65.                 //echo $SQLBegin.'\''.$CharID.'\', \''.$Type0Unique.'\', \''.$CharID.'\', \'320\', \''.$Type0Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  66.                 //$Type0Priority -= 10;
  67.             }
  68.             if ($Type == 10){
  69.                 echo $SQLBegin.'\''.$CharID.'\', \''.$Type10Unique.'\', \''.$CharID.'\', \'320\', \''.$Type10Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  70.                 $Type10Priority -= 10;
  71.             }
  72.             if ($Type == 20){
  73.                 echo $SQLBegin.'\''.$CharID.'\', \''.$Type20Unique.'\', \''.$CharID.'\', \'320\', \''.$Type20Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  74.                 $Type20Priority -= 10;
  75.             }
  76.            
  77.             //TEC
  78.             if ($Type == 1){
  79.                 //echo $SQLBegin.'\''.$CharID.'\', \''.$Type1Unique.'\', \''.$CharID.'\', \'320\', \''.$Type1Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  80.                 //$Type1Priority -= 10;
  81.             }
  82.             if ($Type == 11){
  83.                 echo $SQLBegin.'\''.$CharID.'\', \''.$Type11Unique.'\', \''.$CharID.'\', \'320\', \''.$Type11Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  84.                 $Type11Priority -= 10;
  85.             }
  86.             if ($Type == 21){
  87.                 echo $SQLBegin.'\''.$CharID.'\', \''.$Type21Unique.'\', \''.$CharID.'\', \'320\', \''.$Type21Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  88.                 $Type21Priority -= 10;
  89.             }
  90.            
  91.             //INT
  92.             if ($Type == 2){
  93.                 //echo $SQLBegin.'\''.$CharID.'\', \''.$Type2Unique.'\', \''.$CharID.'\', \'320\', \''.$Type2Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  94.                 //$Type2Priority -= 10;
  95.             }
  96.             if ($Type == 12){
  97.                 echo $SQLBegin.'\''.$CharID.'\', \''.$Type12Unique.'\', \''.$CharID.'\', \'320\', \''.$Type12Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  98.                 $Type12Priority -= 10;
  99.             }
  100.             if ($Type == 22){
  101.                 echo $SQLBegin.'\''.$CharID.'\', \''.$Type22Unique.'\', \''.$CharID.'\', \'320\', \''.$Type22Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  102.                 $Type22Priority -= 10;
  103.             }
  104.        
  105.             //PUI
  106.             if ($Type == 3){
  107.                 //echo $SQLBegin.'\''.$CharID.'\', \''.$Type3Unique.'\', \''.$CharID.'\', \'320\', \''.$Type3Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  108.                 //$Type3Priority -= 10;
  109.             }
  110.             if ($Type == 13){
  111.                 echo $SQLBegin.'\''.$CharID.'\', \''.$Type13Unique.'\', \''.$CharID.'\', \'320\', \''.$Type13Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  112.                 $Type12Priority -= 10;
  113.             }
  114.             if ($Type == 23){
  115.                 echo $SQLBegin.'\''.$CharID.'\', \''.$Type23Unique.'\', \''.$CharID.'\', \'320\', \''.$Type23Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  116.                 $Type22Priority -= 10;
  117.             }
  118.  
  119.             //END
  120.             if ($Type == 4){
  121.                 //echo $SQLBegin.'\''.$CharID.'\', \''.$Type4Unique.'\', \''.$CharID.'\', \'320\', \''.$Type4Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  122.                 //$Type4Priority -= 10;
  123.             }
  124.             if ($Type == 14){
  125.                 echo $SQLBegin.'\''.$CharID.'\', \''.$Type14Unique.'\', \''.$CharID.'\', \'320\', \''.$Type14Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  126.                 $Type12Priority -= 10;
  127.             }
  128.             if ($Type == 24){
  129.                 echo $SQLBegin.'\''.$CharID.'\', \''.$Type24Unique.'\', \''.$CharID.'\', \'320\', \''.$Type24Priority.'\', \''.$Date.'\', \''.$Date.'\');<br/>';
  130.                 $Type22Priority -= 10;
  131.             }
  132.        
  133.         }
  134.         $ID++;
  135.     }
  136. }
  137. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement