29.04.2011, 13:51
Well i try 10 times why this code not work -_-
code:
code:
Код:
#include < a_samp > new CheckPoint; public OnGameModeInit() { DisableInteriorEnterExits( ); CheckPoint = CreatePickup(1318,1,1411.9040527344, -1699.5897216797, 13.787961959839); return 1; } public OnPlayerCommandText( playerid, cmdtext[ ] ) { if( strcmp( "/enter", cmdtext, true, 6) == 0) { if( IsPlayerInRangeOfPoint( playerid,10,1411.9040527344, -1699.5897216797, 13.787961959839 ) ) { SetPlayerPos( playerid,501.77899169922, -67.483757019043, 998.25628662109 ); SetPlayerInterior(playerid,11); return 1; } } if( strcmp( "/exit",cmdtext,true,6) == 0) { if( IsPlayerInRangeOfPoint( playerid,10,501.77899169922, -67.483757019043, 998.25628662109 ) ) { SetPlayerPos( playerid,1411.9040527344, -1699.5897216797, 13.787961959839 ); SetPlayerInterior(playerid,0); return 1; } } return 0; } public OnPlayerPickUpPickup( playerid, pickupid ) { if(pickupid == CheckPoint) { GameTextForPlayer(playerid,"~r~ /enter ~y~ to enter this building",3000,1); } return 1; }