Advertisement
Guest User

Untitled

a guest
Jul 19th, 2017
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 2.01 KB | None | 0 0
  1. <?php
  2.     $pclkey = "betas";//Nevermind this    
  3.     require_once ("library.php");
  4.     require_once("tasks.php");
  5.  
  6.     define ("NUM_THREAD", 8);// Set this to the number of penguins
  7.     $user = array();
  8.     $pass = array();
  9.     $servertogo = "Breeze";//Set this to the server you want them to go to.
  10.     $room = 100;//Set this to the ID of the room you want them to go to.
  11.  
  12.    
  13.     $user[1] = "Username for penguin 1";
  14.     $user[2] = "Username for penguin 2";
  15.     $user[3] = "Username for penguin 3";
  16.     $user[4] = "Username for penguin 4";
  17.     $user[5] = "Username for penguin 1";
  18.     $user[6] = "Username for penguin 2";
  19.     $user[7] = "Username for penguin 3";
  20.     $user[8] = "Username for penguin 4";
  21.  
  22.  
  23.     $pass[1] = "Password for penguin 1";
  24.     $pass[2] = "Password for penguin 2";
  25.     $pass[3] = "Password for penguin 3";
  26.     $pass[4] = "Password for penguin 4";
  27.     $pass[5] = "Password for penguin 1";
  28.     $pass[6] = "Password for penguin 2";
  29.     $pass[7] = "Password for penguin 3";
  30.     $pass[8] = "Password for penguin 4";
  31.  
  32.  
  33.     $numberphrases = 5;
  34.     $phrases = array();
  35.     $phrases[0] = "BALLS";
  36.     $phrases[1] = "BIGGER BALLS";
  37.     $phrases[2] = "GAINT BALLS";
  38.     $phrases[3] = "SUPREME BIG BALLS";
  39.     $phrases[4] = "Keith";
  40.     $phrases[5] = "Is a FridgeLocker";
  41.    
  42.      $penguins = array();
  43.      for($x = 1; $x <= NUM_THREAD; $x++){
  44.           $penguins[$x] = new Pickle();
  45.           $connect = $penguins[$x]->connect($user[$x], $pass[$x], $servertogo);
  46.           if($connect != -1){
  47.                die($connect);
  48.           }
  49.           if($penguins[$x]->extRoomID != $room){
  50.                $penguins[$x]->joinRoom($room, rand(100,700), rand(100,700));
  51.            }
  52.       }
  53.      while(true){
  54.      for($x = 1; $x <= NUM_THREAD; $x++){
  55.           $penguins[$x]->sendPosition(rand(100,700), rand(100,700));
  56.           $phrase = rand(1, $numberphrases);
  57.           $penguins[$x]->sendMessage($phrases[$phrase]);
  58.           usleep((2000000 / NUM_THREAD));
  59.       }
  60.       }
  61.  
  62.     ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement