SA-MP Forums Archive
[Help]Reloading houses - 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: [Help]Reloading houses (/showthread.php?tid=192909)



[Help]Reloading houses - XePloiT - 24.11.2010

what is the problem with this script? it reloads only house id 0 :\

Код:
for(new i=0;i<MAX_HOUSES;i++)
	{
		new str2[256]; new tmp[3][128];
		format(str2,sizeof(str2),"SELECT `ID` FROM `rHouses` WHERE `ID`='%d'",i);
		mysql_query(str2);
		mysql_store_result();
		if(mysql_num_rows() != 0)
		{
			split(HouseInfoStr(i,"IconPos"),tmp,',');
			if(!strcmp(HouseInfoStr(i,"Owner"),"ForSale"))
				HousePickup[i] = CreatePickup(1273, 23, floatstr(tmp[0]), floatstr(tmp[1]), floatstr(tmp[2]));
			else HousePickup[i] = CreatePickup(1272, 23, floatstr(tmp[0]), floatstr(tmp[1]), floatstr(tmp[2]));
			
			HouseInf[i][hID]=i;
			strcat(HouseInf[i][hOwner],"None");
			HouseInf[i][hPrice]=HouseInfo(i,"Price");
			HouseInf[i][hLock]=HouseInfo(i,"Lock");
			strcat(HouseInf[i][hIcnP],HouseInfoStr(i,"IconPos"));
			strcat(HouseInf[i][hIntP],HouseInfoStr(i,"IntPos"));
			HouseInf[i][hInt]=HouseInfo(i,"Interior");
			strcat(HouseInf[i][hRenter],HouseInfoStr(i,"Renter"));
			HouseInf[i][hRent]=HouseInfo(i,"RentPrice");
			
			hCount++;
		}
	}
	mysql_free_result();



Re: [Help]Reloading houses - XePloiT - 24.11.2010

can someone help me?


Re: [Help]Reloading houses - XePloiT - 24.11.2010

really?... no one?...