INT VW problem
#1

I got a problem about /changename . I replace the coords.

Check This out
Old:
PHP код:
IsAtNameChange(playerid)
{
    if(
IsPlayerConnected(playerid))
    {
        if(
IsPlayerInRangeOfPoint(playerid3.0,1154.7295,-1440.2323,15.7969))
        {
            return 
1;
        }
 }
    return 
0;

NEW:
PHP код:
IsAtNameChange(playerid)
{
    if(
IsPlayerConnected(playerid))
    {
        if(
IsPlayerInRangeOfPoint(playerid3.0,1488.7249,-1771.5569,18.7958)) 
        {
            return 
1;
        }
 }
    return 
0;

when i /changename , It says in the name change place


CMD:
PHP код:
CMD:changename(playeridparams[])
{
    if(
IsAtNameChange(playerid) && PlayerInfo[playerid][pLevel] == 1)
    {
        
ShowPlayerDialogplayeridDIALOG_NAMECHANGEDIALOG_STYLE_INPUT"Name Change","Please enter your new desired name!\n\nNote: Name Changes cost $15,000 per level.""Change""Cancel" );
    }
    else
    {
        
SendClientMessageExplayeridCOLOR_WHITE"   You are not in the Name Change Place, or above level 1" );
    }
    return 
1;




I need a Help with VW INT about this. I hope this problem about VW or INT. Help
Reply
#2

pawn Код:
IsAtNameChange(playerid, interiorid, virtual_world)
{
    return IsPlayerInRangeOfPoint(playerid, 3.0, 1488.7249 ,-1771.5569, 18.7958) && GetPlayerInterior(playerid) == interiorid && GetPlayerVirtualWorld(playerid) == virtual_world;
}
Example:
pawn Код:
if (IsAtNameChange(playerid, 0, 1))
If player is in range and their interior is 0 and virtual world is 1, do something.
Reply
#3

I posted the OLD Code too. You can see it. If i put OLd one, It works perfectly.

I just replace the X Y Z thats it
Reply
#4

Quote:
Originally Posted by SoFahim
Посмотреть сообщение
I posted the OLD Code too. You can see it. If i put OLd one, It works perfectly.

I just replace the X Y Z thats it
By replacing the X, Y and Z you basically change the location. Are you going to the new location or to the old while testing? By the way, what interior and virtual world had to do if you don't use them.
Reply
#5

Old one was in INT = 0 , VW = 0 . I just replace X Y Z . The new place in in VW=0 INT=0
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)