Doesn't find the weapon.
#1

Ewaah!

Here is my code.
I got at slot 3 a spas12(27)
But when I use this cmd it doesn't work.
The pS[Weapon][All] is 27 but the weapon[All] stays on 0.
Somebody know why? Did I use the getplayerweapondata wrong?

Код:
	if (strcmp("/test", cmdtext, true, 10) == 0)
	{
	    new ammo,weapon[13];
		for (new All=0; All<13; All++)
		{
	    	GetPlayerWeaponData(playerid, All, weapon[All], ammo);
	    	if(pS[Weapon][All] != weapon[All])
	    	{
	    	    return SendClientOOCMessage(playerid,"Hacked weapon found!");
	    	}
		}
		return 1;
	}
Edit: wierd, the player gets the weapons at onplayerspawn, when I use /test it says hacked weapon found, but when I scroll with my weapons and use /test again, it doesn't say something so it works 50/50 ...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)