SA-MP Forums Archive
Making Street Addresses - 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)
+--- Thread: Making Street Addresses (/showthread.php?tid=318897)



Making Street Addresses - Abreezy - 17.02.2012

What would be the easiest way to make an automatic address system? My issue is, Let's say we are on rich st. I would want the address to be say 2025 Rich St. for example. How could I determine where I am, and then make the address? Thank you in advance for any suggestions. All are appreciated!!


Re: Making Street Addresses - Mark_Weston - 17.02.2012

Quote:
Originally Posted by Abreezy
View Post
What would be the easiest way to make an automatic address system? My issue is, Let's say we are on rich st. I would want the address to be say 2025 Rich St. for example. How could I determine where I am, and then make the address? Thank you in advance for any suggestions. All are appreciated!!
I don't remember what I used but I think it was garhouse I think it did that you should check the source. If its not then I think it was on my custom GM . ( Not FC RP )


Re: Making Street Addresses - Abreezy - 17.02.2012

I see no gamemode releases from you. Could you post a link to that, or a download to garhouse.


Re: Making Street Addresses - iggy1 - 17.02.2012

You could create 'areas'. Then use an "IsPlayerInArea" function to determine if a player is in the area (street). This would be very tough for roads that go in a diagonal direction tho. Streamer plugin also streams areas if you use that already i suggest using that. Make a count variable for that area and when you create a house give it that number and increment the var.


Re: Making Street Addresses - Abreezy - 17.02.2012

With the area idea, It might be a good way to do it, But seems like hell of a lot of work lol.


Re: Making Street Addresses - iggy1 - 17.02.2012

It would be, the more i think of it the more things would need to be added. There would be other ways like range checking. But none would be easy.

The easiest way would be to just name the houses on a street by streetname and number (manually ie, in your create house func), very simple anyway. And guaranteed to work.


Re: Making Street Addresses - SnG.Scot_MisCuDI - 17.02.2012

Quote:
Originally Posted by Abreezy
View Post
With the area idea, It might be a good way to do it, But seems like hell of a lot of work lol.
All the hard work pays off :P


Re: Making Street Addresses - Abreezy - 17.02.2012

I guess I could add that, something like /createhouse price streetname