Код:
public OnPlayerUpdate(playerid)
{
new Keys,ud,lr;
GetPlayerKeys(playerid,Keys,ud,lr);
//////////////////////////////////////////////////////////////////////// enter
if(Keys == KEY_JUMP)
{
if(IsPlayerInRangeOfPoint(playerid,5.0,1555.2797851563,-1675.5520019531,16.716053009033))
{
SetPlayerInterior(playerid,6);
SetPlayerPos(playerid,246.5975,65.4092,1003.6406);
GameTextForPlayer(playerid,"LSPD",3000,1);
}
else if(IsPlayerInRangeOfPoint(playerid,5.0,1833.7420654297,-1842.4602050781,14.098865509033))
{
SetPlayerInterior(playerid,4);
SetPlayerPos(playerid,-27.3297290802,-31.713777542114,1004.0572509766);
GameTextForPlayer(playerid,"24/7",3000,1);
}
else if(IsPlayerInRangeOfPoint(playerid,5.0,2105.3913574219,-1806.4764404297,14.5546875))
{
SetPlayerInterior(playerid,9);
SetPlayerPos(playerid,364.88513183594,-11.74192237854,1002.4722900391);
GameTextForPlayer(playerid,"Pizza",3000,1);
}
else if(IsPlayerInRangeOfPoint(playerid,5.0,1481.1466064453,-1772.1932373047,19.509523391724))
{
SetPlayerInterior(playerid,3);
SetPlayerPos(playerid,387.0635,173.9490,1008.3828);
GameTextForPlayer(playerid,"City Hall",3000,1);
}
else if(IsPlayerInRangeOfPoint(playerid,5.0,1460.3770751953,-1010.1955566406,27.464490890503))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,2315.952880,-1.618174,26.742187);
GameTextForPlayer(playerid,"Bank",3000,1);
}
////////////////////////////////////exit exit exit exit exit exit exit///////////////////////////////////
else if(IsPlayerInRangeOfPoint(playerid,5.0,246.90249633789,62.694629669189,1004.361328125))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,1555.2797851563,-1675.5520019531,16.716053009033);
}
else if(IsPlayerInRangeOfPoint(playerid,5.0,-27.3297290802,-31.713777542114,1004.0572509766))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,1833.7420654297,-1842.4602050781,14.098865509033);
}
else if(IsPlayerInRangeOfPoint(playerid,5.0,364.88513183594,-11.74192237854,1002.4722900391))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,2105.3913574219,-1806.4764404297,14.5546875);
}
else if(IsPlayerInRangeOfPoint(playerid,5.0,389.91268920898,173.81463623047,1008.9827880859))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,1481.1466064453,-1772.1932373047,19.509523391724);
}
else if(IsPlayerInRangeOfPoint(playerid,5.0,2315.952880,-1.618174,26.742187))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,1460.3770751953,-1010.1955566406,27.464490890503);
}
}
return 1;
}
and under
Код:
if(strcmp("/enter",cmdtext,true,10) == 0) //ElkaBlazer
{
if(IsPlayerInRangeOfPoint(playerid,5.0,1555.2797851563,-1675.5520019531,16.716053009033))
{
SetPlayerInterior(playerid,6);
SetPlayerPos(playerid,246.5975,65.4092,1003.6406);
GameTextForPlayer(playerid,"LSPD",3000,1);
}
if(IsPlayerInRangeOfPoint(playerid,5.0,1833.7420654297,-1842.4602050781,14.098865509033))
{
SetPlayerInterior(playerid,4);
SetPlayerPos(playerid,-27.3297290802,-31.713777542114,1004.0572509766);
GameTextForPlayer(playerid,"24/7",3000,1);
}
if(IsPlayerInRangeOfPoint(playerid,5.0,2105.3913574219,-1806.4764404297,14.5546875))
{
SetPlayerInterior(playerid,9);
SetPlayerPos(playerid,364.88513183594,-11.74192237854,1002.4722900391);
GameTextForPlayer(playerid,"Pizza",3000,1);
}
if(IsPlayerInRangeOfPoint(playerid,5.0,1481.1466064453,-1772.1932373047,19.509523391724))
{
SetPlayerInterior(playerid,3);
SetPlayerPos(playerid,387.0635,173.9490,1008.3828);
GameTextForPlayer(playerid,"City Hall",3000,1);
}
if(IsPlayerInRangeOfPoint(playerid,5.0,1460.3770751953,-1010.1955566406,27.464490890503))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,2315.952880,-1.618174,26.742187);
GameTextForPlayer(playerid,"Bank",3000,1);
}
return 1;
}
if(strcmp("/exit",cmdtext,true,10) == 0) //ElkaBlazer
{
if(IsPlayerInRangeOfPoint(playerid,5.0,246.90249633789,62.694629669189,1004.361328125))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,1555.2797851563,-1675.5520019531,16.716053009033);
}
if(IsPlayerInRangeOfPoint(playerid,5.0,-27.3297290802,-31.713777542114,1004.0572509766))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,1833.7420654297,-1842.4602050781,14.098865509033);
}
if(IsPlayerInRangeOfPoint(playerid,5.0,364.88513183594,-11.74192237854,1002.4722900391))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,2105.3913574219,-1806.4764404297,14.5546875);
}
if(IsPlayerInRangeOfPoint(playerid,5.0,389.91268920898,173.81463623047,1008.9827880859))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,1481.1466064453,-1772.1932373047,19.509523391724);
}
if(IsPlayerInRangeOfPoint(playerid,5.0,2315.952880,-1.618174,26.742187))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,1460.3770751953,-1010.1955566406,27.464490890503);
}
return 1;
}