Advertisement
7zgi

مدمر حائط البربر الجديد

Apr 13th, 2020
2,274
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /*______________________________________________________________________________
  2. ********************************************************************************
  3. WriterScriptIs : Salim Fadhil                                                  *
  4. VersionScript  : 1.1                                                           *
  5. DateWroteScript: 14-04-2020                                                    *
  6. DateUpdateD    : 15-04-2020                                                    *
  7. URL            : https://forum.tribalwars.ae/index.php?members/abu-rajih.40926/*
  8. _______________________________________________________________________________*
  9. ********************************************************************************
  10.        ########   ##                    #########             $$  $$  ##       *
  11.       ##      ##  ##                    ##      ##   ######   $$  $$  ##       *
  12.       ##      ##  ##                    ##      ##         #          ##       *
  13.       ##########  ## ####  ##    ##     ##     ##   ########  ##  ##  #######  *
  14.       ##      ##  ###   ## ##    ##     ########    ##    ##  ##  ##  ##    ## *
  15.       ##      ##  ##    ## ##    ##     ##     ##   ##    ##  ##  ##  ##    ## *
  16.       ##      ##  ##   ##  ##    ## $$  ##      ##  ##    ##  ##  ##  ##    ## *
  17.       ##      ##  ######    #####   $$  ##       ## ###### #  ##  ##  ##    ## *
  18.                                                               ##               *
  19.                                                          ##  ##                *
  20.                                                           ####                 *
  21. _______________________________________________________________________________*
  22. *******************************************************************************/
  23.  
  24. javascript:
  25.  
  26. (function($) {
  27.     if(window.game_data.screen == 'am_farm' || window.game_data.screen == 'place' || window.game_data.screen == 'report'){
  28. window.RamForWallLevel = {
  29.       '1' : 3,
  30.       '2' : 6,
  31.       '3' : 10,
  32.       '4' : 13,
  33.       '5' : 17,
  34.       '6' : 23,
  35.       '7' : 26,
  36.       '8' : 30,
  37.       '9' : 38,
  38.       '10' : 46,
  39.       '11' : 55,
  40.       '12' : 66,
  41.       '13' : 78,
  42.       '14' : 91,
  43.       '15' : 108,
  44.       '16' : 125,
  45.       '17' : 145,
  46.       '18' : 170,
  47.       '19' : 195,
  48.       '20' : 223
  49.     }
  50.  
  51. var sign = `
  52. <center>
  53. <table id = 'table'>
  54. <tr>
  55. <th id = 'th' colspan = '2'><b style='font-family:times new roman;font-size:16px;text-align:center;'>تم برمجة السكربت من قبل</b></th>
  56. </tr>
  57.  
  58. <tr>
  59. <td id = 'td' colspan = '2'><a id="Salim" title = 'Abu.Rajih'  href="https://forum.tribalwars.ae/index.php?members/abu-rajih.40926/" target="_blank">سيد الاساطير</a></td>
  60. </tr>
  61.  
  62. <tr>
  63. <th id = 'th' colspan="1" > شرح السكربت </th> <th id = 'th' ><a style='font-family:times new roman;font-size:16px;' href="https://forum.tribalwars.ae/index.php?threads/%D9%85%D8%AF%D9%85%D8%B1-%D8%AD%D8%A7%D8%A6%D8%B7-%D8%A7%D9%84%D8%A8%D8%B1%D8%A8%D8%B1-%D8%A7%D9%84%D8%AC%D8%AF%D9%8A%D8%AF-%D9%86%D8%B3%D8%AE%D9%87-%D8%A3%D8%A8%D8%B1%D9%8A%D9%84-2020.97082/" target="_blank">اضغط هنا</a></th>
  64. </tr>
  65.  
  66. <tr>
  67. <th id = 'th' colspan= '2'>
  68. <iframe style="width:100%;height: 200px;" src="https://www.youtube.com/embed/8_3Vyc-8fOM"></iframe>
  69. </th>
  70. </tr>
  71.  
  72. </table>
  73. </center>
  74.  
  75. <style>
  76. #table,#th,#td { border:1px solid black; font-family:times new roman; font-size:16px; text-align:center; width:300px; }
  77. #Salim { font-family:times new roman; font-size: 20px; animation: salim 2s linear infinite; }
  78. @keyframes salim {
  79. 0%  {text-shadow:0 0 3px #000;}
  80. 15% {text-shadow:0 0 9px #000;}
  81. 30% {text-shadow:0 0 3px #000;}
  82. 45% {color:rgba(80,80,80,.1);}
  83. 60% {text-shadow:0 0 3px #7d5d11;color:#222;}
  84. 80% {text-shadow:0 0 9px #000;}
  85. 100%{text-shadow:0 0 3px #000;}
  86. }
  87. </style>`;
  88.  
  89.         if(window.game_data.screen == 'am_farm'){
  90. $('#plunder_list').before(sign);
  91. $('#plunder_list > tbody > tr:nth-child(1) > th:nth-child(10)').after('<th style="text-align:center;" rowspan="2"><img src="https://dsae.innogamescdn.com/asset/bf21430/graphic/unit/unit_ram.png" title="مدمرات حائط" alt="" class=""></th>');
  92. $('#plunder_list > tbody > tr > td:nth-child(11)').after('<td></td>')
  93. $('#plunder_list > tbody > tr').not(':EQ(0) , :EQ(1)').each(function(index , level){
  94.         window.t = $(this);
  95.         level = $.trim($(this).find('td:nth-child(7)').text());
  96.  
  97.         if(level == 0){
  98.             $(this).find('td:nth-child(7)').css({'color':'#0c0','font-weight':'bold'});
  99.             $(window.t).find('td:nth-child(12)').append('<center><img src="https://dl.dropboxusercontent.com/s/rf6h2niqk5qykyq/%D8%B5%D8%AD.png" title="تم تدميره الى 0" style="width:20px; height:20px;" /></center>');
  100.         }
  101.         else if(level > 0 && level <= 20){
  102.             $(window.t).find('td:nth-child(12)').append('<center><input type="button" class="btn" style="background:url(https://dsae.innogamescdn.com/asset/bf21430/graphic/unit/unit_ram.png) no-repeat 3px 1px, linear-gradient(to bottom, #947a62 0%,#7b5c3d 22%,#6c4824 30%,#6c4824 100%);width:52px;text-align:right;" id="RamAttack" value=' + window.RamForWallLevel[level] + ' /></center>');
  103.         }
  104.         else{
  105.             $(this).find('td:nth-child(7)').css({'color':'#c00','font-weight':'bold'});
  106.             $(window.t).find('td:nth-child(12)').append('<center><span style="font-family:times new roman;color:#c00;font-size:14px;font-weight:bold;">?</span></center>');
  107.         }
  108.  
  109.   $(this).find('#RamAttack').on('click' , function(){
  110.       sessionStorage.setItem('RamToAttack' , $(this).val());
  111.       var target = $('#plunder_list > tbody > tr:eq('+ (2 + index) +')').find('td:nth-child(4) > a').text();
  112.       var WallLv = $('#plunder_list > tbody > tr:eq('+ (2 + index) +')').find('td:nth-child(7)').text();
  113.       sessionStorage.setItem('WallLevel' , WallLv);
  114.       sessionStorage.setItem('x' , target.split('(')[1].split('|')[0]);
  115.       sessionStorage.setItem('y' , target.split(')')[0].split('|')[1]);
  116.       window.open('/game.php?village='+window.game_data.village.id+'&screen=place','_blank');
  117.   });
  118.  
  119. });
  120. }
  121.  
  122.         else if(window.game_data.screen == 'report'){
  123.             $('#attack_spy_buildings_right').after(sign);
  124.             $('#attack_spy_buildings_right > tbody > tr').each(function(){
  125.             if($.trim($(this).find('td:nth-child(1) > span').text()).match(/الحائط/)){
  126.                 $(this).find('td:nth-child(2)').css({'color':'#f00','font-weight':'bold'});
  127.               window.Level_Wall = $.trim($(this).find('td:nth-child(2)').text());
  128.                 sessionStorage.setItem('WallLevel' , window.Level_Wall);
  129.                $(this).find('td:nth-child(2)').append('<input type="button" class="btn" style="background:url(https://dsae.innogamescdn.com/asset/bf21430/graphic/unit/unit_ram.png) no-repeat 3px 1px, linear-gradient(to bottom, #947a62 0%,#7b5c3d 22%,#6c4824 30%,#6c4824 100%);width:52px;text-align:right;" id="RamToAttack" value=' + window.RamForWallLevel[sessionStorage.WallLevel] + ' />');
  130.                 $('#RamToAttack').on('click' , function(){
  131.                     sessionStorage.setItem('RamToAttack', $(this).val());
  132.                     var coord = $('#attack_info_def > tbody > tr:nth-child(2) > td:nth-child(2) > span > a:nth-child(1)').text().split('(')[1];
  133.                     coord = coord.split(')')[0];
  134.                     var x = coord.split('|')[0];
  135.                     var y = coord.split('|')[1];
  136.                     sessionStorage.setItem('x' , x);
  137.                     sessionStorage.setItem('y' , y);
  138.                     window.open('/game.php?village='+window.game_data.village.id+'&screen=place','_blank');
  139.                 });
  140.               }
  141.             });
  142.  
  143.         }
  144.  
  145.              if(window.game_data.screen == 'place' && !window.location.href.match(/&screen=place&try=confirm/)){
  146.         if(!sessionStorage.RamToAttack && !sessionStorage.x && !sessionStorage.y && !sessionStorage.WallLevel){
  147.           alert('لا توجد قريه لتدمير حائطها!!\n\nتوجه الى مساعد النهب ثم شغل السكربت \n او شغل السكربت من التقرير');
  148.         }else{
  149.        setTimeout(()=>{
  150.            document.querySelector("#unit_input_axe").value = 200;
  151.            document.querySelector('#unit_input_ram').value = sessionStorage.getItem('RamToAttack');
  152.            document.forms[0].x.value = sessionStorage.getItem('x');
  153.            document.forms[0].y.value = sessionStorage.getItem('y');
  154.      },10);
  155.  
  156.          setTimeout(()=>{
  157.              document.querySelector('#target_attack').click();
  158.          },20);
  159.         }
  160.      }
  161.  
  162.     if(window.location.href.match(/&screen=place&try=confirm/)){
  163.         $('#default_name_span > a ').click();
  164.         setTimeout(()=>{
  165.             document.querySelector('#new_attack_name').value = sessionStorage.getItem('RamToAttack') + ' محطمة حائط في مهمة خاصة لتدمير ' + sessionStorage.getItem('WallLevel') + ' مستوى حائط ';
  166.         },10);
  167.  
  168.         setTimeout(()=>{
  169.             document.querySelector("#attack_name_btn").click();
  170.         },15);
  171.  
  172.         setTimeout(()=>{
  173.             document.querySelector("#troop_confirm_go").click();
  174.         },20);
  175.  
  176.        }
  177. }else{
  178. window.UI.InfoMessage('السكربت يعمل من مساعد النهب ومن التقرير ' , 3000 , 'error');
  179. }
  180. })(window.jQuery);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement