Results 1 to 2 of 2
  1. #1
    antares.........'s Avatar
    Join Date
    Sep 2014
    Gender
    male
    Posts
    2
    Reputation
    10
    Thanks
    0

    How to make a SA:MP Hack from a PAWN Script?

    Hello guys i'm new here... i joined MPGH today.. And i'm very very new in Hacking or Programming or whatever I want to ask how to make a hacking program using a PAWN Script? Like injecting the hack to the SA:MP server... For example.
    The server has this script
    Code:
    CMD:givemoney(playerid, params[])
    {
    	if (PlayerInfo[playerid][pAdmin] >= 5)
    	{
    		new string[128], giveplayerid, money;
    		if(sscanf(params, "ud", giveplayerid, money)) return SendClientMessageEx(playerid, COLOR_WHITE, "USAGE: /givemoney [playerid] [money]");
    
    		if(IsPlayerConnected(giveplayerid))
    		{
    			GivePlayerCash(giveplayerid, money);
    			format(string, sizeof(string), "You have given %s $%d !",GetPlayerNameEx(giveplayerid),money);
    			SendClientMessageEx(playerid, COLOR_WHITE, string);
    			format(string, sizeof(string), "%s has given %s $%d (/givemoney)", GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid),money);
    			Log("logs/stats.log", string);
    		}
    	}
    	else
    	{
    		SendClientMessageEx(playerid, COLOR_GRAD1, "You are not authorized to use that command!");
    	}
    	return 1;
    }
    and how can i make a program and turn the script into like this?
    Code:
    CMD:givemoney(playerid, params[])
    {
    //Admin Removed :)
    		new string[128], giveplayerid, money;
    		if(sscanf(params, "ud", giveplayerid, money)) return SendClientMessageEx(playerid, COLOR_WHITE, "USAGE: /givemoney [playerid] [money]");
    
    		if(IsPlayerConnected(giveplayerid))
    		{
    			GivePlayerCash(giveplayerid, money);
    			format(string, sizeof(string), "You have given %s $%d !",GetPlayerNameEx(giveplayerid),money);
    			SendClientMessageEx(playerid, COLOR_WHITE, string);
    			format(string, sizeof(string), "%s has given %s $%d (/givemoney)", GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid),money);
    			Log("logs/stats.log", string);
    		}
    	}
    	//Removed This aswell :)
    	return 1;
    }
    So, when i type /givemoney, i can give everyone money Is that possible? Well... i think PAWN language are same as C++, but i don't know much about that :/ If you guys can, you can PM me or just comment below Peace

  2. #2
    somewhatpro's Avatar
    Join Date
    May 2014
    Gender
    male
    Posts
    317
    Reputation
    38
    Thanks
    29
    My Mood
    Daring
    You can't inject PAWN script into a server, unless you find a vulnerability which allows code execution...

    The only way i remember that allows you to give money to people, is if the server has a command /givemoney playerid value and in that case you would compile a simple C++ dll that contains the function to send a message, in this situation you would do sendmessage("/givemoney %d 1000", i), and the i can be in a for loop so that it iterates through all the player ids
    Last edited by somewhatpro; 09-11-2014 at 09:08 AM.

Similar Threads

  1. [Help] How to make a SA:MP Hack from a PAWN Script?
    By antares......... in forum Grand Theft Auto San Andreas Multi Player (SAMP) Hacks
    Replies: 1
    Last Post: 09-12-2014, 02:32 AM
  2. [tut for noobs] How to make a anti kick hack with vb
    By atheist in forum WarRock - International Hacks
    Replies: 3
    Last Post: 02-13-2008, 09:17 AM
  3. [Tutorial] How to make you'r first hack in CE!!!
    By Darky in forum WarRock - International Hacks
    Replies: 3
    Last Post: 07-29-2007, 11:02 AM
  4. [ReQuEsT] Does any1 know how to make a gun speed hack
    By Twisted_scream in forum WarRock - International Hacks
    Replies: 4
    Last Post: 05-07-2007, 12:47 PM
  5. How to make a working NFV Hack
    By System79 in forum Game Hacking Tutorials
    Replies: 1
    Last Post: 09-04-2006, 04:56 AM