SA-MP Forums Archive
Why dosent spawn on corectly position? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Why dosent spawn on corectly position? (/showthread.php?tid=171020)



Why dosent spawn on corectly position? - DarkPower - 25.08.2010

I have this code under OnPlayerSpawn

pawn Код:
for(new i; i<MAX_HOUSES; i++)
     {
       if(strcmp(Ime, HouseInfo[i][HouseOwner]))
       {
         SetPlayerPos(playerid, HouseInfo[i][TeleX], HouseInfo[i][TeleY], HouseInfo[i][TeleZ]);
         SetPlayerInterior(playerid, HouseInfo[i][Interior]);
         InHouse[playerid] = i;
         SetPlayerVirtualWorld(playerid, HouseInfo[i][Virtual]);
       }
     }
and when i spawn in house my pos get set on this




Re: Why dosent spawn on corectly position? - iggy1 - 25.08.2010

pawn Код:
for(new i; i<MAX_HOUSES; i++)
     {
       if(!strcmp(Ime, HouseInfo[i][HouseOwner]))
       {
         SetPlayerPos(playerid, HouseInfo[i][TeleX], HouseInfo[i][TeleY], HouseInfo[i][TeleZ]);
         SetPlayerInterior(playerid, HouseInfo[i][Interior]);
         InHouse[playerid] = i;
         SetPlayerVirtualWorld(playerid, HouseInfo[i][Virtual]);
       }
     }
Use '!' in strcmp Whats Ime btw?


Re: Why dosent spawn on corectly position? - DarkPower - 25.08.2010

Ime = playername

btw: now i get this on player spawn




Re: Why dosent spawn on corectly position? - iggy1 - 25.08.2010

Looks lke you co-ordinates are messed up make a command that does the same as the pickup/checkpoint and see if thats the same result. If it is look at your CreateHouse function that will be where the problem is. (or you just have co-ords messed up)


Re: Why dosent spawn on corectly position? - DarkPower - 25.08.2010

how i can fix co-ordinates if is a problem in that


Re: Why dosent spawn on corectly position? - iggy1 - 25.08.2010

Well if you have our co-ords messed up, just go and save some more make sure your setting to the correct interior too.