Khalis_Aiman

Sample script

Jan 21st, 2013
92
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.09 KB | None | 0 0
  1. <?php
  2.  
  3. header('Content-Type: image/png');
  4. $json_content = file_get_contents("http://team-tt.com/userinfo.php?userinfo&fields=getAll&username=_Savior.", false);
  5. $player_info = json_decode($json_content);
  6.  
  7. $image = imagecreatefrompng('IMAGENAMEHERE.png');
  8.  
  9. $orange = imagecolorallocate($image, 255, 64, 0);
  10. $blue = imagecolorallocate($image, 0, 178, 238);
  11. $black = imagecolorallocate($image, 0, 0, 0);
  12. $yellow = imagecolorallocate($image, 225, 106, 0);
  13.  
  14. $font1 = 'arial.ttf';
  15.  
  16. imagettftext($image, 11, 0, 93, 97, $orange, $font1, $player_info->Username);
  17. imagettftext($image, 11, 0, 60, 117, $orange, $font1, $player_info->Score);
  18. imagettftext($image, 11, 0, 80, 137, $orange, $font1, $player_info->Robbery_Skill);
  19. imagettftext($image, 11, 0, 361, 154, $orange, $font1, $player_info->Hour_Played);
  20. imagettftext($image, 11, 0, 108, 157, $orange, $font1, $player_info->Terrorist_Skill);
  21. imagettftext($image, 11, 0, 82, 177, $orange, $font1, $player_info->Arrests_Made);
  22. imagettftext($image, 11, 0, 379, 174, $orange, $font1, $player_info->Minute_Played);
  23.  
  24. imagepng($image);
  25. imagedestroy($image);
  26.  
  27. ?>
Advertisement
Add Comment
Please, Sign In to add comment