27.12.2010, 19:42
Quote:
I don't really get it.. I'm trying to do, that when player looks at other player and presses middle mouse button and then at targets position create explosion. I'm doing it like this:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys) { if (PRESSED( KEY_LOOK_BEHIND )) { if(IsPlayerFacingPlayer(playerid, targetid, 15.0)) { new Float: x, Float: y, Float: z; GetPlayerPos(targetid, x, y, z); CreateExplosion(x, y, z, 12, 10); } } return 1; } What's wrong? sorry for bad english. |