Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // This is a comment
- // uncomment the line below if you want to write a filterscript
- //#define FILTERSCRIPT
- //все PutPlayerInVehicle замените на putPlayerInVehicle
- #include <a_samp>
- public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger){
- SetPVarInt(playerid,"ac_car_id",vehicleid);
- return 1;
- }
- public OnPlayerStateChange(playerid, newstate, oldstate){
- if(newstate == PLAYER_STATE_DRIVER){
- if(GetPlayerVehicleID(playerid) != GetPVarInt(playerid,"ac_car_id")) {
- SetPVarInt(playerid,"ac_car_id",-1);
- new Float:x,Float:y,Float:z;
- GetPlayerPos(playerid,x,y,z);
- SetPlayerPos(playerid,x,y,z+1);
- SendClientMessage(playerid,-1,"Не шали тут!");
- return 1;
- }
- SetPVarInt(playerid,"ac_car_id",-1);
- }
- return 1;
- }
- putPlayerInVehicle(playerid,vehicle,seat){
- SetPVarInt(playerid,"ac_car_id",vehicle);
- PutPlayerInVehicle(playerid,vehicle,seat);
- }
- public OnPlayerConnect(playerid){
- SetPVarInt(playerid,"ac_car_id",-1);
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement