12.03.2011, 14:03
Hello! I'm makking a BOT NPC now. Helicopter has fly in a particular place. Heli starts from one place and then back to this place.
I recorded file policeheli.rec
In ncpmodes i make a policeheli.amx:
and i make a filterscript:
And now how i am on the server bot is connected....and i go to the place where heli is..... and BOT is standing near the heli.....and the heli doesn't fly?? why
What is wrong??
I recorded file policeheli.rec
In ncpmodes i make a policeheli.amx:
Код:
#define RECORDING "policeheli" #define RECORDING_TYPE 1 #include <a_npc> main(){} public OnRecordingPlaybackEnd() StartRecordingPlayback(RECORDING_TYPE, RECORDING); public OnNPCEnterVehicle(vehicleid, seatid) StartRecordingPlayback(RECORDING_TYPE, RECORDING); public OnNPCExitVehicle() StopRecordingPlayback();
Код:
#include <a_samp> new PoliceHeli; public OnGameModeInit() { ConnectNPC("PoliceHeli","policeheli"); PoliceHeli = AddStaticVehicle(497,-1679.7006,705.9991,30.7217,89.8752,0,1); // heli return 1; } public OnPlayerSpawn(playerid) { if(!IsPlayerNPC(playerid)) return 0; // We only deal with NPC players in this script new playername[64]; GetPlayerName(playerid,playername,64); if(!strcmp(playername,"PoliceHeli",true)) { SetSpawnInfo( playerid, 0, 285, 1958.33, 1343.12, 15.36, 269.15, 0, 0, 0, 0, 0, 0 ); PutPlayerInVehicle(playerid, PoliceHeli, 0); ShowPlayerMarkers(0); } I gdy return 1; }
