Jump to content
  • 0

Teleport


k3nw00d_kri5ty

Question

hi !

Deci am o mare problema cu teleport-ul ... :|

Vreau: Ca atunci cand sunt pasager la un vehicul sa ma scoata din masina si sa ma teleporteaza.

Dar ! la mine ma scoate din masina si nu se mai vede caracterul :| si nici de miscat nu mai pot ... nimic.

Si primesc un crash de ma scoate afara din joc :|

Script:

    if(strcmp(cmd,"/bstunt1",true) == 0)
	{
        if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
		{
			TogglePlayerControllable(playerid,0);
			SetTimerEx("LoadObjects",3000,false,"i",playerid);
            SetVehiclePos(GetPlayerVehicleID(playerid),530.6929,-1012.7028,1773.1597);
            SetVehicleZAngle(GetPlayerVehicleID(playerid),270.9936);
        }
        else if(GetPlayerState(playerid) == PLAYER_STATE_PASSENGER)
        {
            RemovePlayerFromVehicle(playerid);
            SetPlayerPos(playerid,530.6929,-1012.7028,1773.1597);
			SetPlayerFacingAngle(playerid,270.9936);
			SetPlayerInterior(playerid,0);
		}
        else if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
        {
			TogglePlayerControllable(playerid,0);
			SetTimerEx("LoadObjects",3000,false,"i",playerid);
			SetPlayerPos(playerid,530.6929,-1012.7028,1773.1597);
			SetPlayerFacingAngle(playerid,270.9936);
			SetPlayerInterior(playerid,0);
		}
        return 1;
    }

Link to comment
Share on other sites

7 answers to this question

Recommended Posts

Guest RockStar

 if(strcmp(cmd,"/bstunt1",true) == 0)
	{
        if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
		{
			SetTimerEx("LoadObjects",3000,false,"i",playerid);
            SetVehiclePos(GetPlayerVehicleID(playerid),530.6929,-1012.7028,1773.1597);
            SetVehicleZAngle(GetPlayerVehicleID(playerid),270.9936);
        }
        else if(GetPlayerState(playerid) == PLAYER_STATE_PASSENGER)
        {
            SetPlayerPos(playerid,530.6929,-1012.7028,1773.1597);
			SetPlayerFacingAngle(playerid,270.9936);
			SetPlayerInterior(playerid,0);
		}
        else if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
        {
			SetTimerEx("LoadObjects",3000,false,"i",playerid);
			SetPlayerPos(playerid,530.6929,-1012.7028,1773.1597);
			SetPlayerFacingAngle(playerid,270.9936);
			SetPlayerInterior(playerid,0);
		}
        return 1;
    }

Sami zici daca mai face asa , nu ar trebui sa nu te mai poti misca si nici sa te scoata din masina .

Link to comment
Share on other sites

if(strcmp(cmdtext, "/bstunt1", true) == 0)
{
	if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
	{
		TogglePlayerControllable(playerid,0);
		SetTimerEx("LoadObjects",3000,false,"i",playerid);
		SetVehiclePos(GetPlayerVehicleID(playerid),530.6929,-1012.7028,1773.1597);
		SetVehicleZAngle(GetPlayerVehicleID(playerid),270.9936);
		return 1;
	}
	TogglePlayerControllable(playerid,0);
	SetTimerEx("LoadObjects",3000,false,"i",playerid);
	SetPlayerPos(playerid,530.6929,-1012.7028,1773.1597);
	SetPlayerFacingAngle(playerid,270.9936);
	SetPlayerInterior(playerid,0);
	return 1;
}

Ar trebui sa mearga.

Link to comment
Share on other sites

Tot nu merge ... inainte sa postezi, incearca-l :o

Incearca asa:

if(strcmp(cmdtext, "/bstunt1", true) == 0)
	{
		if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
		{
			TogglePlayerControllable(playerid,0);
			SetTimerEx("LoadObjects",3000,false,"i",playerid);
			SetVehiclePos(GetPlayerVehicleID(playerid),530.6929,-1012.7028,1773.1597);
			return SetVehicleZAngle(GetPlayerVehicleID(playerid),270.9936);
		}
		SetTimerEx("LoadObjects",3000,false,"i",playerid);
		SetPlayerPos(playerid,530.6929,-1012.7028,1773.1597);
		SetPlayerFacingAngle(playerid,270.9936);
		return SetPlayerInterior(playerid,0);
	}

Daca tot nu merge posteaza functia LoadObjects pentru ca la mine merge asa fara sa am functia LoadObjects.

Link to comment
Share on other sites

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.