Jump to content
  • 0

Problema ENTER


MrAndrei

Question

Problema intalnita (descriere):Am incercat sa fac comenzile ENTER / EXIT pe tasta ENTER , insa cand apasi pe ENTER , spre exemplu la Burger , te baga in interior , dar imediat de si scoate in acelasi loc unde ai dat enter.Mentionez ca la unele factiuni / etc nu face la fel , enter-ul functioneaza corect insa exitul face ca in video-ul de mai jos.
Ero(area / rile) / warning-(ul / urile):-
Liniile de cod / sursa / script-ul:-
Imagini / Video (optional):

public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
    if((newkeys == KEY_ACTION)&&(IsPlayerInAnyVehicle(playerid))&&(GetPlayerState(playerid)==PLAYER_STATE_DRIVER))
	{
 		new vid = GetPlayerVehicleID(playerid);
   		if(LightsSTATE == 0)
     	{
      		GetVehicleParamsEx(vid,engine,lights1,alarm,doors1,bonnet,boot,objective);
        	SetVehicleParamsEx(vid,engine,VEHICLE_PARAMS_ON,alarm,doors1,bonnet,boot,objective);
         	LightsSTATE = 1;
       	}
        else
        {
        	GetVehicleParamsEx(vid,engine,lights1,alarm,doors1,bonnet,boot,objective);
            SetVehicleParamsEx(vid,engine,VEHICLE_PARAMS_OFF,alarm,doors1,bonnet,boot,objective);
            LightsSTATE = 0;
        }
    }
    //--------------------------*** ENTER ***-----------------------------------------------
     if (PlayerToPoint(2, playerid, 2229.9072,-1721.2985,13.5617))//Gym
		{
			SetPlayerPos(playerid,772.111999,-3.898649,1000.728820);
			SetPlayerInterior(playerid,5);
			GivePlayerMoney(playerid,- 500);
	        GameTextForPlayer(playerid, "~g~Gym ~y~Los Santos~n~~r~-$500", 1000, 1);
			return 1;
		}
		else if (PlayerToPoint(2, playerid, 1554.9100,-1675.6428,16.1953))//LSPD
		{
			SetPlayerPos(playerid,246.5325,62.4251,1003.6406);
		    SetPlayerInterior(playerid,6);
	        GameTextForPlayer(playerid, "~w~Police Departament", 1000, 1);
		    return 1;
		}

Am revenit si cu VIDEO :

 

 

Ati incercat sa rezolvati singur?:Da si nu am reusit!

Edited by MrAndrei
Link to comment
Share on other sites

4 answers to this question

Recommended Posts

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.