26.04.2011, 12:26
This is my pawno code
i cant enter building
Код:
#include <a_samp> new driving; public OnGameModeInit() { DisableInteriorEnterExits(); driving = CreatePickup(1239,1,2045.5084228516,-1908.2283935547,12.99134349823); return 1; } public OnPlayerCommandText(playerid, cmdtext[]) { if (strcmp("/enter",cmdtext,true,6) == 0) { if(IsPlayerInRangeOfPoint(playerid,10,2045.5084228516,-1908.2283935547,12.99134349823)) { SetPlayerInterior(5,playerid); SetPlayerPos(playerid,1299.14,-794.77,1084.00); return 1; } } if (strcmp("/exit",cmdtext,true,6) == 0) { if(IsPlayerInRangeOfPoint(playerid,10,1299.14,-794.77,1084.00)) { SetPlayerInterior(0,playerid); SetPlayerPos(playerid,2045.5084228516,-1908.2283935547,12.99134349823); return 1; } } public OnPlayerPickUpPickup(playerid, pickupid) { if(pickupid == driving) { GameTextForPlayer(playerid,"~r~ /enter ~y~ to enter this building",5000,5); }